One of the assumptions of both religion and much of science is the perfection of pure numbers.

Imagine my surprise when I discovered that integers vary from perfection, that there are irregularities and imperfections in pure mathematics!

I call your attention to the prime numbers.

Up until about 20 years ago, I thought a prime number was just a prime number and never considered classes or groupings or statistics on prime numbers. It was obvious to me, without checking, that the higher the range of interest, the fewer the percentage of prime numbers. I also assumed, without checking, that at extremely high number ranges, primes would be extremely rare.

None of these assumptions proved to be completely true. My results, a partial snapshot of which you’ve just seen, surprised me. It turns out we don’t have “perfection” even in basic integers themselves. The percentage of prime numbers, even at ranges in the tens of millions occur 5 or 6% of the time. And the percentage of prime numbers in equal-sized ranges (the highlighted percentages) do not fall along a simple asymptotic curve, but vary significantly.

When I started seriously looking at primes in the trillions, I had to have primes in the millions to eliminate all prime factors and I again was surprised. Using the limits of my spreadsheet, I assembled blocks of primes: 27 columns of 3,000 primes per column; 81,000 primes in a block. The first block had 2,3,5,7,11,13,…, all the way up to 1,033,421. The second block I expected to take me into gigantic numbers. Instead, it went from 1,033,423 up to only 2,204,483; a range of only 1,171,060 integers, only slightly larger than the first! Even in the trillions, where I merely sampled 5,000-integer ranges, primes are still not rare.

The first
81,000 primes take us from 2 all the way to: 1,033,421: 1,033,421
integers.

The second 81,000 primes takes us to:
2,204,483: 1,171,062 integers.

The third 81,000 primes take us
to: 3,404041: 1,199,558 integers.

Then I took a
class where I was introduced to the concept of “bracelets”.
Bracelets are formed by adding two integers under a particular
modulo^{1}
to get a new integer which is then added to its immediate predecessor
until the original two integers reappear in the cycle, at which time,
we have a complete bracelet. Each integer modulo has its own unique
and unvarying set of bracelets.

This intrigued me so much that I studied bracelets for two years and did an original treatise on them which I submitted to the college professor who had taught the original class. He referred me to a colleague, but it went nowhere. (There’s no money in pure mathematics.)

I discovered categories and predictable behavior within bracelets and significant differences between primes and factorable integers that were revealed by their unique bracelet sets. Primes have bracelets which differ from those of non-primes – and prime bracelets can further be separated into categories. It turns out that, in general, primes have “regular” bracelets and integers which can be factored have “irregular” bracelets.

The bracelets for two are:

{0,0} (a bracelet of length 1 where zero is linked to itself)

{0,1,1,0} (length 3 of the unique form {0,^{n}/2,^{n}/2,0}, present for all even numbers)

……………………..note the total of all lengths = 2*2 = 4,

………………………the “bead” being two unique ordered digits

The bracelets for three are:

{0,0},

{0,1,1,2,0,2,2,1,0} (len 8 where 2nd half complements^{2} (n-x) the first

…………………………note lengths total 3*3 = 9 and that the start is also the end.

The bracelets for four (2*2) are:

{0,0},

{0,1,1,2,3,1,0} (len 6 which does not complement itself),

{0,2,2,0) (len 3 from the 2 bracelets) (factor 2)

{0,3,3,2,1,3,0} (the complement of the {0,1,…} bracelet

………..the total lengths = 4*4 = 16

The bracelets
for five are:

{0,0}

{0,1,1,2,3,0,3,3,1,4,0,4,4,3,2,0,2,2,4,1,0}
(self-complementary^{3},
length 20)

{1,3,4,2,1}

the total lengths = 5*5 = 25

Please note that the bracelets for 5 are unique among all primes as the bracelets for 10 are unique for all nonprimes. I have no idea why. It isn’t the representation of the integers – our decimal number base. If another number base represents these integers, we get the same results.

The bracelets
for six are:

{0,0}

{0,1,1,2,3,5,2,1,3,4,1,5,0,5,5,4,3,2,5,1,0}
self-complementary, length 24

{0,2,2,4,0,4,4,2,0}
self-complementary, length 8 (factor 3)

{0,3,3,0} ( of the form
{0,^{n}/2,^{n}/2,0}
length 3) (factor 2)

the total lengths = 6*6 = 36

The bracelets for seven are:

{0,0}

{0,1,1,2,3,5,1,6,0,6,6,5,4,2,6,1,0} self-complementary, length 16

{0,2,2,4,6,3,2,5,0,5,5,3,1,4,5,2,0} self-complementary, length 16

{0,3,3,6,2,1,3,4,0,4,4,1,5,6,4,3,0} self-complementary, length 16

the total lengths = 7*7 = 49 (the first really regular prime)

1/2*(n-1) bracelets have the length 2*(n+1)!

Note that the
ubiquitous {0,0} bracelets makes for forms like (n+1)*(n-1) = n^{2}
-1. This is what makes primes regular!

If an integer has a factor, that factor will have its own form which almost never matches the rest of the set. Note already that even integers always have that unique bracelet of length 3 in their middle and integers with a factor of 3 always have a self-complementary bracelet of length 8: {0,n/3,n/3,2n/3,0,2n/3,2n/3,n/3,0}, and so forth; since 7 has a form which is regular according to the integer 7, embedding it within another set which has 7 as a factor interferes with the regularity of the non-prime, non-power.

Then I looked at bracelets for squares, cubes, and powers and discovered another interesting behavior.

The
bracelets for 7^{2}
= 49 include the 0 bracelet, 3 self-complementary bracelets of length
16 for its factor of 7: {0,7,… {0,14,… and {0,21,…. plus 21
self-complementary bracelets of length 112. 1+(3*16)+(21*112) =
2401 = 49*49. Even in the power series, we get regular rectangles.

The
bracelets for 7^{3}
= 343 include the 0 bracelet, 3 self-complementary bracelets of
length 16 for its factor of 7: {0,49,… {0,98,… and {0,147,… ;
21 self-complementary bracelets of length 112 for its factor of 49;
and 147 self-complementary bracelets of length 784 to equal 117649 or
343^{2}.

Note that the length of the long self-complementary bracelets for 7 is 16 = 2*(n+1). The length of the long self-complementary bracelets for 7^{2 } is 7 * 16 = 112. And the length of the long self-complementary bracelets for 7^{3} is 784 = 7*7*16. This pattern does have a few exceptions in the lower powers of the **non-prime** integers, but power series always seem to settle into this pattern and **primes** ALWAYS conform immediately to this pattern.

Long bracelets for **2** are 3 long, for **4** are 6 long, for **8** are 12 long, for **16** are 24 long, for **32** are 48 long and for **64** are 96 long. I believe this pattern persists indefinitely and consistently for all prime integers.

So the prime number bracelets do follow a pattern of rectangles which are (n+1) by (n-1) or some set of elongated versions of those rectangles. And the power series bracelets seem to settle into a pattern where both the lengths and the number of bracelets to grow longer in direct proportion to the increase.

I find all this surprising in that there seem to be rules to all this, but not the simple rules I expected.

One reason for my intense interest in all this is my encryption algorithm using pseudo-random numbers and large number base changes. By taking a file as a long integer, changing its digits by adding a pseudo-random number modulo its base (making sure the highest digit isn’t zero by adding again if it is), converting the resulting large number into a different number base which is a large prime, and then reiterating this process several times, there is no remaining information to retrieve the original file without the requisite keys or an astronomical number of tries. At one time, I actually made a crude version of this and it worked. I sent it to the Pentagon, but never got a reply.

Summary of Bracelet Power series:

Prime Bracelet Power Series (the length of the {0,1,…} bracelets):

2 ==> len 3 1 3-bead nc bracelet + zero bracelet; 3+1 = 4

2^{2} ==> len 3*2 2 6-bead nc bracelets + above with each digit*2; 2*6+4 = 16

2^{3} ==> len 3*2^{2 } 4 12-bead nc bracelets + above digits*2; 4*12+16 = 64

2^{4} ==> len 3*2^{3} 8 24-bead nc bracelets + above digits*2; 8*24+64 = 256

2^{5} ==> len 3*2^{4} 16 48-bead nc bracelets + above digits*2; 16*48+256 = 1024

2^{6} ==> len 3*2^{5}

2^{7} ==> len 3*2^{6}

2^{8} ==> len 3*2^{7}

2^{9} ==> len 3*2^{8}

2^{10} ==> len 3*2^{9}

2^{11} ==> len 3*2^{10}

2^{12} ==> len 3*2^{11}

3 ==> len 8 ….. {0,1,1,2,0,2,2,1,0} (len 8)

3^{2} ==> len 8*3 ….. {0,1,1,2,3,5,8,4,3,7,1,8,0,8,8,7,6,4,1,5,6,2,8,1,0} (len 24)

3^{3} ==> len 8*3^{2} ….. {0,1,1,2,3,5,8,13,21,7,1,8,9,17,26,16,15,4,19,23,15, 11,26,10,

………………… 9,19,1,20,21,14,8,22,3,25,1,26,0, 26,26,25,24,22,19,14,6,20,26,19,

…………….. 18,10,1,11,12,23,8,4,12,16,1,17,18,8,26,7,6,13,19,5,24,2,26,1,0 (len 72)

3^{4} ==> length 8*3^{3}3^{5} ==> length 8*3^{4}3^{6} ==> length 8*3^{5}3^{7} ==> length 8*3^{6}

3^{8} ==> length 8*3^{7}

5
==> length 20

5^{2} ==> length
20*5

5^{3} ==> length 20*5^{2}5^{4}
==> length 20*5^{3}5^{5}
==> length 20*5^{4}

5^{6}
==> length 20*5^{5}

5^{7}
==> length 20*5^{6}

7
==> length 16

7^{2} ==> length
16*7

7^{3} ==> length 16*7^{2}

7^{4}
==> length 16*7^{3}

7^{5}
==> length 16*7^{4}

7^{6}
==> length 16*7^{5}

11
==> length 10

11^{2} ==> length
10*11

11^{3} ==> length 10*11^{2}

11^{4}
==> length 10*11^{3}

11^{5}
==> length 10*11^{4}

13
==> length 28

13^{2} ==> length
28*13

13^{3} ==> length 28*13^{2}

13^{4}
==> length 28*13^{3}

13^{5}
==> length 28*13^{4}

17
==> length 36

17^{2} ==> length
36*17

17^{3} ==> length 36*17^{2}

17^{4}
==> length 36*17^{3}

19
==> length 18

19^{2} ==> length
18*19

19^{3} ==> length 18*19^{2}

19^{4}
==> length 18*19^{3}

As far as I can tell this pattern repeats for all primes in all power series.

Non-primes tend to the same power series but break down because of one or more small factors in the first powers:

6
==> length 24

6^{2} ==> length
24 <== 2,3

6^{3} ==> length 24*3
<== 2

6^{4} ==> length 24*3^{2}
<== 2

6^{5} ==> length
24*3^{2}*6

6^{6}
==> length 24*3^{2}*6^{2}

10
==> length 60

10^{2} ==> length
60*5 <== 2

10^{3} ==> length
60*5^{2} <== 2

10^{4}
==> length 60*5^{2}*10

10^{5}
==> length 60*5^{2}*10^{2}

12
==> length 24

12^{2} ==> length
24 <== 2^{2}*3

12^{3}
==> length 24*12

12^{4} ==>
length 24*12^{2}12^{5}
==> length 24*12^{3}

14
==> length 48

14^{2} ==> length
48*7 <== 2

14^{3} ==> length
48*7^{2} <== 2

14^{4}
==> length 48*7^{3} <== 2

14^{5}
==> length 48*7^{4} <== 2

14^{6}
==> length 48*7^{4}*14

18
==> length 24

18^{2} ==> length
24*9 <== 2

18^{3} ==> length
24*9^{2} <== 2

18^{4}
==> length 24*9^{2}*18

22
==> length 30

22^{2} ==> length
30*11 <== 2

22^{3} ==> length
30*11*22

22^{4} ==> length
30*11*22^{2}

24 ==> length 24

24^{2} ==> length 24*12 <== 2

24^{3} ==> length 24*12*24

24^{4} ==> length 24*12*24^{2}

26
==> length 84

26^{2} ==> length
84*13 <== 2

26^{3} ==> length
84*13^{2} <== 2

26^{4}
==> length 84*13^{2}*26

Based on the characteristics of their bracelets, (the collective behavior of their limited set of repetitive modulo additions), I discovered that there are four distinct groups of prime numbers:

- The first group contains a single prime with the self-complementary {0,1,… } bracelet, the only even prime with the unique self-complementary bracelet of the form {0,n/2,n/2,0}:
- 2: {0,1,

……1,0} of length 3 = n+1 as well as {0,0}

- 2: {0,1,
- The second group consists of another single prime with the exceptionally long self-complementary {0,1,…} bracelet of length 20 (length = 4*n) plus an anomalous 4-member third bracelet, making 5 unique among all prime numbers (and it has nothing to do with our decimal number base as these patterns do not rely on how we represent the integers but are intrinsic to the integers themselves:
- 5: {0,1,1,2,3,0,3,3,1,4,

……0,4,4,3,2,0,2,2,4,1,0}

and {1,3,4,2,1} as well as {0,0}

- 5: {0,1,1,2,3,0,3,3,1,4,
- The third group of primes consists of prime numbers whose decimal representation ends in the digit 3 or the digit 7. They consistently have an {0,1,…} self-complementary bracelet of the length 2(n+1)/x where n is the prime and x is a small integer, usually 1:
- 3: {0,1,1,2,

……0,2,2,1,0} len=8=2*(n+1)

- 7: {0,1,1,2,3,5,1,6,

……0,6,6,5,4,2,6,1,0} len=16=2*(n+1) - 13: {0,1,1,2,3,5,8,0,8,8,3,11,1,12,

……..0,12,12,11,10,8,5,0,5,5,10,2,12,1,0} (len=28=2*(n+1) - 17: {0,1,1,2,3,5,8,13,4,0,4,4,8,12,3,15,1,16,

……..0,16,16,15,14,12,9,4,13,0,13,13,9,5,14,2,16,1,0} len=36=2*(n+1) - 23: {0,1,1,2,3,5,8,13,21,11,9,20,6,3,9,12,21,10,8,18,3,21,1,22,

……..0,22,22,21,20,18,15,10,2,12,14,3,17,20,14,11,2,13,15,5,20,

……………………………………………………………..2,22,1,0} len=48=2*(n+1) - 37: length = 76 = 2*(n+1)
- 43: length = 88 = 2*(n+1)
- 47: length = 32 = 2*(n+1)/3
- 53: length = 108 = 2*(n+1)
- 67: length = 136 = 2*(n+1)
- 73: length = 148 = 2*(n+1)
- 83: length = 168 = 2*(n+1)
- 97: length = 196 = 2*(n+1)
- 103: length = 208 = 2*(n+1)
- 107: length = 72 = 2*(n+1)/3
- 113: length = 76 = 2*(n+1)/3
- 127: length = 256 = 2*(n+1)

- 3: {0,1,1,2,
- The fourth and last group of primes consists of prime numbers whose decimal representation ends in the digit 1 or the digit 9. They consistently have an {0,1,…} bracelet of the length (n-1)/x where n is the prime and x is a small integer, usually 1:
- 11: {0,1,1,2,3,5,8,2,10,1,0} len=10=(n-1)

- 19: {0,1,1,2,3,5,8,13,2,15,17,13,11,5,16,2,18,1,0} len=18=(n-1)
- 29: {0,1,1,2,3,5,8,13,21,5,26,2,28,1,0} len=14=(n-1)/2
- 31: {0,1,1,2,3,5,8,13,21,3,24,27,20,16,5,21,

……..26,16,11,27,7,3,10,13,23,5,28,2,30,1,0} len=30=(n-1) - 41: length = 40 = (n-1) {self-complementary}
- 59: length = 58 = (n-1) {NOT self-complementary}
- 61: length = 60 = (n-1) {self-complementary}
- 71: length = 70 = (n-1) {NOT self-complementary}
- 79: length = 78 = (n-1) {NOT self-complementary}
- 89: length = 44 = (n-1)/2 {self-complementary}
- 101: length = 50 = (n-1)/2 {NOT self-complementary}
- 109: length = 108 = (n-1) {self-complementary}

Since there is only one prime whose last decimal digit is 2, one prime whose last decimal digit is 5, and no primes ending in 0,4,6,or 8, this accounts for all prime numbers.

I’ve checked these prime groupings into the tens of thousands with no primes not conforming to these patterns. However, in checking non-primes, there are extremely rare non-primes that seem to mimic these characteristics. As we venture into the realm of larger integers, it seems to get increasingly more unusual for a non-prime to have a characteristic that might look like that of a prime.

I ran into a few non-primes that might have looked like primes, but, the work being several years ago, I wasn’t sure, so I went back today. The first false prime, using the {0,1,…} bracelet’s characteristics as a test was 377=13*29, but it’s {0,1,…} bracelet was only 28 beads long and **not** self-complementary, as all bracelets for primes ending in 3 or 7 are, but it did fit 27 bracelets 28 beads long into 2*(n+1). As I remember, the first really convincing false prime was in the 600s. This may take a while. Got past 1000 with no even possible false primes but 377 and, as I said earlier, it’s not really a serious fake. Still, I’m reluctant to conclude that this is a way to determine if a number is prime. It weeds out just about all non-primes for sure, but, until this is tested on far more values, I wouldn’t completely rely on it.

I’m fairly certain that, except for 5, all the primes I looked at were fairly regular and followed the expected pattern called for by the trailing digit of its decimal representation.

In any case, I thought that regular and significant behavioral differences between groups of integers was an interesting topic and might be significant to people doing encryption/decryption algorithms, pseudo-random number generators, or looking for different types of humongous primes.

©David N. Dodson, November 2016, Phoenix, AZ

1**Modulo
addition** is like the last digit of a decimal number, which is
modulo 10. 8+3=1 mod 10. 8+3=2 mod 9. There is no eight in modulo
8, the digits being 0 through 7. Modulo arithmetic, by its nature,
is finite and bounded.

2In modulo 3, the **complement **of 0 is 0, the complement of 1 is 2 and the complement of 2 is 1. Complements are paired with the sum being the modulo in question or zero. The only permissible digits under modulo 3 are 0, 1 and 2.

3In a** self-complementary** bracelet, the second half mirrors the first half with each digit matched with its complement. In the case of five:

….{0,1,1,2,3,0,3,3,1,4,0 and

……0,4,4,3,2,0,2,2,4,1,0}.