The Trivial Troot

Here is the square root of 2:

√2 = 1·414213562373095048801688724209698078569671875376948073176679738...

Here is the square root of 20:

√20 = 4·472135954999579392818347337462552470881236719223051448541794491...

And here are the first few triangular numbers:

1, 3, 6, 10, 15, 21, 28, 36, 45, 55, 66, 78, 91, 105, 120, 136, 153, 171, 190, 210, 231, 253, 276, 300, 325, 351, 378, 406, 435, 465, 496, 528, 561, 595, 630, 666, 703, 741, 780, 820, 861, 903, 946, 990, 1035...

What links √2 and √20 strongly with the triangular numbers? At first glance, nothing does. The square roots of 2 and 20 are very different from the triangular numbers. Square roots like those are irrational, that is, they can’t be represented as a fraction or ratio of integers. This means that their digits go on for ever, never falling into a regular pattern. So the digits are hard to calculate. The sequence of triangular numbers also goes on for ever, but it’s very easy to calculate. The triangular numbers get their name from the way they can be arranged into simple triangles, like this:

* = 1


*
** = 3


*
**
*** = 6


*
**
***
**** = 10


*
**
***
****
***** = 15

The 1st triangular number is 1, the 2nd is 3 = 1+2, the 3rd is 6 = 1+2+3, the 4th is 10 = 1+2+3+4, and so on. The n-th triangular number = 1+2+3…+n, so the formula for the n-th triangular number is n*(n+1)/2 = (n^2+n)/2. So what’s the 123456789th triangular number? Easy: it’s 7620789436823655 (see A077694 at the OEIS). But what’s the 123456789th digit of √2 or √20? That’s not easy to answer. But here’s something else that is easy to answer. If tri(n) is the n-th triangular number, what are the values of n when tri(n) is one digit longer than tri(n-1)? That is, what are the values of n when tri(n) increases in length by one digit? If you look at the beginning of the sequence, you can see the first three answers:

1, 3, 6, 10, 15, 21, 28, 36, 45, 55, 66, 78, 91, 105...

1 is one digit longer than nothing, as it were, and 1 = tri(1); 10 is one digit longer than 6 and 10 = tri(4); 105 is one digit longer than 91 and 105 = tri(14). Here are some more answers, giving triangular numbers on the left, as they increase in length by one digit, and the n of tri(n) on the right:

1 ← 1
10 ← 4
105 ← 14
1035 ← 45
10011 ← 141
100128 ← 447
1000405 ← 1414
10001628 ← 4472
100005153 ← 14142
1000006281 ← 44721
10000020331 ← 141421
100000404505 ← 447214
1000001326005 ← 1414214
10000002437316 ← 4472136
100000012392316 ← 14142136
1000000042485480 ← 44721360
10000000037150046 ← 141421356
100000000000018810 ← 447213595
1000000000179470703 ← 1414213562
10000000002237948990 ← 4472135955
100000000010876002500 ← 14142135624
1000000000022548781025 ← 44721359550
10000000000026940078203 ← 141421356237
100000000000242416922750 ← 447213595500
1000000000000572687476751 ← 1414213562373
10000000000004117080477500 ← 4472135955000
100000000000007771272992046 ← 14142135623731
1000000000000031576491575006 ← 44721359549996
10000000000000140731196136705 ← 141421356237310
100000000000000250760786750861 ← 447213595499958
1000000000000000638090771126060 ← 1414213562373095
10000000000000000479330922588410 ← 4472135954999579
100000000000000000169466805816725 ← 14142135623730950
1000000000000000025572412483843115 ← 44721359549995794
10000000000000000087657358700327265 ← 141421356237309505
100000000000000000097566473134542830 ← 447213595499957939
1000000000000000000987561276980703725 ← 1414213562373095049
10000000000000000003048443380954913921 ← 4472135954999579393
100000000000000000006832246143819194316 ← 14142135623730950488
1000000000000000000014155501020518731556 ← 44721359549995793928

Can you spot the patterns? When tri(n) has an odd number of digits, n approximates the digits of √2; when tri(n) has an even number of digits, n approximates the digits of √20. And what can you call the approximations? Well, in a way they’re triangular roots so I’m calling them troots. Here are the troots for tri(n) with an odd number of digits:

1 → 1
14 → 105
141 → 10011
1414 → 1000405
14142 → 100005153
141421 → 10000020331
1414214 → 1000001326005
14142136 → 100000012392316
141421356 → 10000000037150046
1414213562 → 1000000000179470703
14142135624 → 100000000010876002500
141421356237 → 10000000000026940078203
1414213562373 → 1000000000000572687476751
14142135623731 → 100000000000007771272992046
141421356237310 → 10000000000000140731196136705
1414213562373095 → 1000000000000000638090771126060
14142135623730950 → 100000000000000000169466805816725
141421356237309505 → 10000000000000000087657358700327265
1414213562373095049 → 1000000000000000000987561276980703725
14142135623730950488 → 100000000000000000006832246143819194316
14142135623730950488... = √2 (without the decimal point)

When I first found these patterns, I thought I might have discovered something mathematically profound. I hadn’t. Troots are trivial. I think troots are beautiful too, but a little thought soon showed me how easily and obviously they arise. Remember that the formula for tri(n), the n-th triangular number, is tri(n) = (n^2+n)/2. As you can see above, when tri(n) is increasing in length by one digit, it rises above the next power of 10, which always begins with 1 followed by only 0s. Therefore n^2+n will begin with the digit 2 followed by some 0s, which then becomes 1 followed by some 0s as (n^2+n) is divided by 2. So n for tri(n) increasing-by-one-digit will be the first integer, n, where n^2+n yields a number with 2 as the leading digit followed by more and more 0s.

And that’s why n approximates the digits of √2·0000… and √20·0000…, for tri(n) with an odd and even number of digits, respectively. Similar trootful patterns exist in other bases and for other polygonal numbers, like the square numbers, the pentagonal numbers and so on. The troots are beautiful to see but trivial to explain. All the same, there is a sense in which you can say the mindless sequence of triangular numbers is “calculating” the digits of √2 and √20. It even rounds up the final digits when necessary:

1414214 → 1000001326005
14142136 → 100000012392316
141421356 → 10000000037150046
141421356... = √2
[...]
14142135624 → 100000000010876002500
141421356237 → 10000000000026940078203
141421356237... = √2
[...]
14142135623731 → 100000000000007771272992046
141421356237310 → 10000000000000140731196136705
1414213562373095 → 1000000000000000638090771126060
1414213562373095... = √2
[...]
1414213562373095049 → 1000000000000000000987561276980703725
14142135623730950488 → 100000000000000000006832246143819194316
14142135623730950488... = √2

Spiral Artefact

What’s the next number in this sequence of integers?


5, 14, 19, 23, 28, 32, 37, 41, 46, 50, 55... (A227793 at the OEIS)

It shouldn’t be hard to work out that it’s 64 — the sum-of-digits of n is divisible by 5, i.e., digsum(n) mod 5 = 0. Now try summing the numbers in that sequence:


5 + 14 = 19
19 + 19 = 38
38 + 23 = 61
61 + 28 = 89
89 + 32 = 121
121 + 37 = 158
158 + 41 = 199
199 + 46 = 245
[...]

Here are the cumulative sums as another sequence:


5, 19, 38, 61, 89, 121, 158, 199, 245, 295, 350, 414, 483, 556, 634, 716, 803, 894, 990, 1094, 1203, 1316, 1434, 1556, 1683, 1814, 1950, 2090, 2235, 2389, 2548, 2711, 2879, 3051, 3228, 3409, 3595, 3785, 3980, 4183, 4391, 4603, 4820, 5041, 5267, 5497, 5732, 5976, 6225...

And there’s that cumulative-sum sequence represented as a spiral:

Spiral for cumulative sum of n where digsum(n) mod 5 = 0


You can see how the spiral is created by following 0,1,2,3,4,5,6,7,8,9,A,B,C,D,E… from the center:


ZYXWVU
GFEDCT
H432BS
I501AR
J6789Q
KLMNOP

What about other values for the cumulative sums of digsum(n) mod m = 0? Here’s m = 2,3,4,5,6,7:

Spiral for cumulative sum of n where digsum(n) mod 2 = 0
s1 = 2, 4, 6, 8, 11, 13, 15, 17, 19, 20, 22…
s2 = 2, 6, 12, 20, 31, 44, 59, 76, 95, 115… (cumulative sum of s1)


sum of digsum(n) mod 3 = 0
s1 = 3, 6, 9, 12, 15, 18, 21, 24, 27, 30, 33…
s2 = 3, 9, 18, 30, 45, 63, 84, 108, 135, 165…


sum of digsum(n) mod 4 = 0
s1 = 4, 8, 13, 17, 22, 26, 31, 35, 39, 40, 44…
s2 = 4, 12, 25, 42, 64, 90, 121, 156, 195, 235…


sum of digsum(n) mod 5 = 0
s1 = 5, 14, 19, 23, 28, 32, 37, 41, 46, 50, 55…
s2 = 5, 19, 38, 61, 89, 121, 158, 199, 245, 295…


sum of digsum(n) mod 6 = 0
s1 = 6, 15, 24, 33, 39, 42, 48, 51, 57, 60, 66…
s2 = 6, 21, 45, 78, 117, 159, 207, 258, 315, 375…


sum of digsum(n) mod 7 = 0
s1 = 7, 16, 25, 34, 43, 52, 59, 61, 68, 70, 77…
s2 = 7, 23, 48, 82, 125, 177, 236, 297, 365, 435…


The spiral for m = 2 is strange, but the spirals are similar after that. Until m = 8, when something strange happens again:

sum of digsum(n) mod 8 = 0
s1 = 8, 17, 26, 35, 44, 53, 62, 71, 79, 80, 88…
s2 = 8, 25, 51, 86, 130, 183, 245, 316, 395, 475…


Then the spirals return to normal for m = 9, 10:

sum of digsum(n) mod 9 = 0
s1 = 9, 18, 27, 36, 45, 54, 63, 72, 81, 90, 99…
s2 = 9, 27, 54, 90, 135, 189, 252, 324, 405, 495…


sum of digsum(n) mod 10 = 0
s1 = 19, 28, 37, 46, 55, 64, 73, 82, 91, 109, 118…
s2 = 19, 47, 84, 130, 185, 249, 322, 404, 495, 604…


Here’s an animated gif of m = 8 at higher and higher resolution:

sum of digsum(n) mod 8 = 0 (animated gif)


You might think this strange behavior is dependant on the base in which the dig-sum is calculated. It isn’t. Here’s an animated gif for other bases in which the mod-8 spiral behaves strangely:

sum of digsum(n) mod 8 = 0 in base b = 5, 6, 7, 9, 11, 12, 13 (animated gif)


But the mod-8 spiral stops behaving strangely when the spiral is like this, as a diamond:


   W
  XIV
 YJ8HU
ZK927GT
LA3016FS
 MB45ER
  NCDQ
   OP

Now the mod-8 spiral looks like this:

sum of digsum(n) mod 8 = 0 (diamond spiral)


But the mod-4 and mod-9 spirals look like this:

sum of digsum(n) mod 4 = 0 (diamond spiral)


sum of digsum(n) mod 9 = 0 (diamond spiral)


You can also construct the spirals as a triangle, like this:


     U
    VCT
   WD2CS
  XE301AR
 YF456789Q
ZGHIJKLMNOP

Here’s the beginning of the mod-5 triangular spiral:

sum of digsum(n) mod 5 = 0 (triangular spiral) (open in new window for full size)


And the beginning of the mod-8 triangular spiral:

sum of digsum(n) mod 8 = 0 (triangular spiral) (open in new window for full size)


The mod-8 spiral is behaving strangely again. So the strangeness is partly an artefact of the way the spirals are constructed.


Post-Performative Post-Scriptum

“Spiral Artefact”, the title of this incendiary intervention, is of course a tip-of-the-hat to core Black-Sabbath track “Spiral Architect”, off core Black-Sabbath album Sabbath Bloody Sabbath, issued in core Black-Sabbath success-period of 1973.

RevNumSum

If you take an integer, n, and reverse its digits to get the integer r, there are three possibilities:


n > r (e.g. 85236 > 63258)
n < r (e.g. 17783 < 38771)
n = r (e.g. 45154 = 45154)

If n = r, n is a palindrome. If n > r, I call n a major number. If n < r, I call n a minor number. And here are the minor and major numbers represented as white squares on an Ulam-like spiral (the negative of a minor spiral is a major spiral, and vice versa — sometimes one looks better than the other):

b=2 (minor numbers)


b=3


b=4


b=5


b=6


b=7 (major numbers)


b=8 (minor numbers)


b=9 (mjn)


b=10 (mjn)


b=11 (mjn)


b=12 (mjn)


b=13 (mjn)


b=14 (mjn)


b=15 (mjn)


b=16 (mjn)


b=17 (mjn)


b=18 (mjn)


b=19 (mjn)


b=20 (mjn)


Minor numbers, b=2..20 (animated)


Now let’s look at a sequence formed by summing the reversed numbers, minor ones, major ones and palindromes. Here are the standard integers:


1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17...

If you sum the integers, you get what are called the triangular numbers:


1 = 1
3 = 1 + 2
6 = 1 + 2 + 3
10 = 1 + 2 + 3 + 4
15 = 1 + 2 + 3 + 4 + 5
21 = 1 + 2 + 3 + 4 + 5 + 6
28 = 1 + 2 + 3 + 4 + 5 + 6 + 7
36 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8
45 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9
55 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10
66 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11
78 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12
91 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13
105 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14
120 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15
136 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16
153 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17
171 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17 + 18
190 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17 + 18 + 19
210 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17 + 18 + 19 + 20

But what happens if you reverse the integers before summing them? Here side-by-side are the triangular numbers and the underlined revnumsums (as they might be called):


45 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9
45 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9
55 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10
46 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 1
66 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11
57 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 1 + 11
78 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12
78 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 1 + 11 + 21
91 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13
109 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 1 + 11 + 21 + 31
105 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14
150 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 1 + 11 + 21 + 31 + 41
120 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15
201 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 1 + 11 + 21 + 31 + 41 + 51
136 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16
262 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 1 + 11 + 21 + 31 + 41 + 51 + 61
153 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17
333 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 1 + 11 + 21 + 31 + 41 + 51 + 61 + 71
171 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17 + 18
414 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 1 + 11 + 21 + 31 + 41 + 51 + 61 + 71 + 81
190 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17 + 18 + 19
505 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 1 + 11 + 21 + 31 + 41 + 51 + 61 + 71 + 81 + 91
210 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17 + 18 + 19 + 20
507 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 1 + 11 + 21 + 31 + 41 + 51 + 61 + 71 + 81 + 91
+ 2

Unlike triangular numbers, revnumsums are dependent on the base they’re calculated in. In base 2, the revnumsum is always smaller than the triangular number, except at step 1. In base 3, the revnumsum is equal to the triangular number at steps 1, 2 and 15 (= 120 in base 3). Otherwise it’s smaller than the triangular number.

And in higher bases? In bases > 3, the revnumsum rises and falls above the equivalent triangular number. When it’s higher, it tends towards a maximum height of (base+1)/4 * triangular number.

Palindrought

The alchemists dreamed of turning dross into gold. In mathematics, you can actually do that, metaphorically speaking. If palindromes are gold and non-palindromes are dross, here is dross turning into gold:


22 = 10 + 12
222 = 10 + 12 + 13 + 14 + 15 + 16 + 17 + 18 + 19 + 20 + 23 + 24
484 = 10 + 12 + 13 + 14 + 15 + 16 + 17 + 18 + 19 + 20 + 21 + 23 + 24 + 25 + 26 + 27 + 28 + 29 + 30 + 31 + 32 + 34
555 = 10 + 12 + 13 + 14 + 15 + 16 + 17 + 18 + 19 + 20 + 21 + 23 + 24 + 25 + 26 + 27 + 28 + 29 + 30 + 31 + 32 + 34 + 35 + 36
2002 = nonpalsum(10,67)
36863 = nonpalsum(10,286)
45954 = nonpalsum(10,319)
80908 = nonpalsum(10,423)
113311 = nonpalsum(10,501)
161161 = nonpalsum(10,598)
949949 = nonpalsum(10,1417)
8422248 = nonpalsum(10,4136)
13022031 = nonpalsum(10,5138)
14166141 = nonpalsum(10,5358)
16644661 = nonpalsum(10,5806)
49900994 = nonpalsum(10,10045)
464939464 = nonpalsum(10,30649)
523434325 = nonpalsum(10,32519)
576656675 = nonpalsum(10,34132)
602959206 = nonpalsum(10,34902)
[...]

The palindromes don’t seem to stop arriving. But something unexpected happens when you try to turn gold into gold. If you sum palindromes to get palindromes, you’re soon hit by what you might call a palindrought, where no palindromes appear:


1 = 1
3 = 1 + 2
6 = 1 + 2 + 3
111 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 11 + 22 + 33
353 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 11 + 22 + 33 + 44 + 55 + 66 + 77
7557 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 11 + 22 + 33 + 44 + 55 + 66 + 77 + 88 + 99 + 101 + 111 + 121 + 131 + 141 + 151 + 161 + 171 + 181 + 191 + 202 + 212 + 222 + 232 + 242 + 252 + 262 + 272 + 282 + 292 + 303 + 313 + 323 + 333 + 343 + 353 + 363 + 373 + 383
2376732 = palsum(1,21512)

That’s sequence A046488 at the OEIS. And I suspect that the sequence is complete and that the palindrought never ends. For some evidence of that, here’s an interesting pattern that emerges if you look at palsums of 1 to repdigits 9[…]9:


50045040 = palsum(1,99999)
50045045040 = palsum(1,9999999)
50045045045040 = palsum(1,999999999)
50045045045045040 = palsum(1,99999999999)
50045045045045045040 = palsum(1,9999999999999)
50045045045045045045040 = palsum(1,999999999999999)
50045045045045045045045040 = palsum(1,99999999999999999)
50045045045045045045045045040 = palsum(1,9999999999999999999)
50045045045045045045045045045040 = palsum(1,999999999999999999999)

As the sums get bigger, the carries will stop sweeping long enough and the sums may fall into semi-regular patterns of non-palindromic numbers like 50045040. If you try higher bases like base 909, you get more palindromes by summing palindromes, but a palindrought arrives in the end there too:


1 = palsum(1)
3 = palsum(1,2)
6 = palsum(1,3)
A = palsum(1,4)
[...]
66 = palsum(1,[104]) (palindromes = 43)
LL = palsum(1,[195]) (44)
[37][37] = palsum(1,[259]) (45)
[73][73] = palsum(1,[364]) (46)
[114][114] = palsum(1,[455]) (47)
[172][172] = palsum(1,[559]) (48)
[369][369] = palsum(1,[819]) (49)
6[466]6 = palsum(1,[104][104]) (50)
L[496]L = palsum(1,[195][195]) (51)
[37][528][37] = palsum(1,[259][259]) (52)
[73][600][73] = palsum(1,[364][364]) (53)
[114][682][114] = palsum(1,[455][455]) (54)
[172][798][172] = palsum(1,[559][559]) (55)
[291][126][291] = palsum(1,[726][726]) (56)
[334][212][334] = palsum(1,[778][778]) (57)
[201][774][830][774][201] = palsum(1,[605][707][605]) (58)
[206][708][568][708][206] = palsum(1,[613][115][613]) (59)
[456][456][569][569][456][456] = palsum(1,11[455]11) (60)
22[456][454][456]22 = palsum(1,21012) (61)

Note the palindrome for palsum(1,21012). All odd bases higher than 3 seem to produce a palindrome for 1 to 21012 in that base (21012 in base 5 = 1382 in base 10, 2012 in base 7 = 5154 in base 10, and so on):


2242422 = palsum(1,21012) (base=5)
2253522 = palsum(1,21012) (b=7)
2275722 = palsum(1,21012) (b=11)
2286822 = palsum(1,21012) (b=13)
2297922 = palsum(1,21012) (b=15)
22A8A22 = palsum(1,21012) (b=17)
22B9B22 = palsum(1,21012) (b=19)
22CAC22 = palsum(1,21012) (b=21)
22DBD22 = palsum(1,21012) (b=23)

And here’s another interesting pattern created by summing squares in base 9 (where 17 = 16 in base 10, 40 = 36 in base 10, and so on):


1 = squaresum(1)
5 = squaresum(1,4)
33 = squaresum(1,17)
111 = squaresum(1,40)
122221 = squaresum(1,4840)
123333321 = squaresum(1,503840)
123444444321 = squaresum(1,50483840)
123455555554321 = squaresum(1,5050383840)
123456666666654321 = squaresum(1,505048383840)
123456777777777654321 = squaresum(1,50505038383840)
123456788888888887654321 = squaresum(1,5050504838383840)

Then a palindrought strikes again. But you don’t get a palindrought in the triangular numbers, or numbers created by summing the integers, palindromic and non-palindromic alike:


1 = 1
3 = 1 + 2
6 = 1 + 2 + 3
55 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10
66 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11
171 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17 + 18
595 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17 + 18 + 19 + 20 + 21 + 22 + 23 + 24 + 25 + 26 + 27 + 28 + 29 + 30 + 31 + 32 + 33 + 34
666 = 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17 + 18 + 19 + 20 + 21 + 22 + 23 + 24 + 25 + 26 + 27 + 28 + 29 + 30 + 31 + 32 + 33 + 34 + 35 + 36
3003 = palsum(1,77)
5995 = palsum(1,109)
8778 = palsum(1,132)
15051 = palsum(1,173)
66066 = palsum(1,363)
617716 = palsum(1,1111)
828828 = palsum(1,1287)
1269621 = palsum(1,1593)
1680861 = palsum(1,1833)
3544453 = palsum(1,2662)
5073705 = palsum(1,3185)
5676765 = palsum(1,3369)
6295926 = palsum(1,3548)
35133153 = palsum(1,8382)
61477416 = palsum(1,11088)
178727871 = palsum(1,18906)
1264114621 = palsum(1,50281)
1634004361 = palsum(1,57166)
5289009825 = palsum(1,102849)
6172882716 = palsum(1,111111)
13953435931 = palsum(1,167053)
16048884061 = palsum(1,179158)
30416261403 = palsum(1,246642)
57003930075 = palsum(1,337650)
58574547585 = palsum(1,342270)
66771917766 = palsum(1,365436)
87350505378 = palsum(1,417972)
[...]

If 617716 = palsum(1,1111) and 6172882716 = palsum(1,111111), what is palsum(1,11111111)? Try it for yourself — there’s an easy formula for the triangular numbers.

The Glamor of Gamma

The factorial function, n!, is easy to understand. You simply take an integer and multiply it by all integers smaller than it (by convention, 0! = 1):

0! = 1
1! = 1
2! = 2 = 2*1
3! = 6 = 3*2*1
4! = 24 = 4*3*2*1
5! = 120 = 5*4*3*2*1
6! = 720 = 6*120 = 6*5!
7! = 5040
8! = 40320
9! = 362880
10! = 3628800
11! = 39916800
12! = 479001600
13! = 6227020800
14! = 87178291200
15! = 1307674368000
16! = 20922789888000
17! = 355687428096000
18! = 6402373705728000
19! = 121645100408832000
20! = 2432902008176640000

The gamma function, Γ(n), isn’t so easy to understand. It allows you to find the factorials of not just the integers, but everything between the integers, like fractions, square roots, and transcendental numbers like π. Don’t ask me how! And don’t ask me how you get this very beautiful and unexpected result:

Γ(1/2) = √π = 1.77245385091...

But a blog called Mathematical Enchantments can tell you more:

The Square Root of Pi


Post-Performative Post-Scriptum

glamour | glamor, n. Originally Scots, introduced into the literary language by Scott. A corrupt form of grammar n.; for the sense compare gramarye n. (and French grimoire ), and for the form glomery n. 1. Magic, enchantment, spell; esp. in the phrase to cast the glamour over one. 2. a. A magical or fictitious beauty attaching to any person or object; a delusive or alluring charm. b. Charm; attractiveness; physical allure, esp. feminine beauty; frequently attributive colloquial (originally U.S.). — Oxford English Dictionary

B a Pal

As a keyly committed core component of the counter-cultural community (I wish!), I like to post especially edgy and esoteric material to Overlord In Terms of Core Issues Around Maximal Engagement with Key Notions of the Über-Feral on the 23rd of each month. And today I may be posting the especially edgiest and esoterickest material ever dot dot dot

After all, this entry at the Online Encyclopedia of Integer Sequences is about numbers that are palindromes in two particularly pertinent bases:

A060792 Numbers that are palindromic in bases 2 and 3.

0, 1, 6643, 1422773, 5415589, 90396755477, 381920985378904469, 1922624336133018996235, 2004595370006815987563563, 8022581057533823761829436662099, 392629621582222667733213907054116073, 32456836304775204439912231201966254787, 428027336071597254024922793107218595973 (A060792 at OEIS, with more entries)


And here are the underlying palindromes:

0: 0 ↔ 0
1: 1 ↔ 1
6643: 1100111110011 ↔ 100010001
1422773: 101011011010110110101 ↔ 2200021200022
5415589: 10100101010001010100101 ↔ 101012010210101
90396755477: 1010100001100000100010000011000010101 ↔ 22122022220102222022122
381920985378904469: 10101001100110110110001110011011001110001101101100110010101 ↔ 2112200222001222121212221002220022112
1922624336133018996235: 11010000011100111000101110001110011011001110001110100011100111000001011 ↔
122120102102011212112010211212110201201021221
2004595370006815987563563: 110101000011111010101010100101111011110111011110111101001010101010111110000101011 ↔ 221010112100202002120002212200021200202001211010122
8022581057533823761829436662099: 1100101010000100101101110000011011011111111011000011100001101111111101101100000111011010010000101010011 ↔ 21000020210011222122220212010000100001021202222122211001202000012
392629621582222667733213907054116073: 10010111001111000100010100010100000011011011000101011011100000111011010100011011011000000101000101000100011110011101001 ↔ 122102120011102000101101000002010021111120010200000101101000201110021201221
32456836304775204439912231201966254787: 11000011010101111010110010100010010011011010101001101000001000100010000010110010101011011001001000101001101011110101011000011 ↔ 1222100201002211120110022121002012121101011212102001212200110211122001020012221
428027336071597254024922793107218595973: 101000010000000110001000011111100101011110011100001110100011100010001110001011100001110011110101001111110000100011000000010000101 ↔ 222001200110022102121001000200200202022111220202002002000100121201220011002100222

Pi and By

Here’s √2 in base 2:

√2 = 1.01101010000010011110... (base=2)

And in base 3:

√2 = 1.10201122122200121221... (base=3)

And in bases 4, 5, 6, 7, 8, 9 and 10:

√2 = 1.12220021321212133303... (b=4)
√2 = 1.20134202041300003420... (b=5)
√2 = 1.22524531420552332143... (b=6)
√2 = 1.26203454521123261061... (b=7)
√2 = 1.32404746317716746220... (b=8)
√2 = 1.36485805578615303608... (b=9)
√2 = 1.41421356237309504880... (b=10)

And here’s π in the same bases:

π = 11.00100100001111110110... (b=2)
π = 10.01021101222201021100... (b=3)
π = 03.02100333122220202011... (b=4)
π = 03.03232214303343241124... (b=5)
π = 03.05033005141512410523... (b=6)
π = 03.06636514320361341102... (b=7)
π = 03.11037552421026430215... (b=8)
π = 03.12418812407442788645... (b=9)
π = 03.14159265358979323846... (b=10)

Mathematicians know that in all standard bases, the digits of √2 and π go on for ever, without falling into any regular pattern. These numbers aren’t merely irrational but transcedental. But are they also normal? That is, in each base b, do the digits 0 to [b-1] occur with the same frequency 1/b? (In general, a sequence of length l will occur in a normal number with frequency 1/(b^l).) In base 2, are there as many 1s as 0s in the digits of √2 and π? In base 3, are there as many 2s as 1s and 0s? And so on.

It’s a simple question, but so far it’s proved impossible to answer. Another question starts very simple but quickly gets very difficult. Here are the answers so far at the Online Encyclopedia of Integer Sequences (OEIS):

2, 572, 8410815, 59609420837337474 – A049364

The sequence is defined as the “Smallest number that is digitally balanced in all bases 2, 3, … n”. In base 2, the number 2 is 10, which has one 1 and one 0. In bases 2 and 3, 572 = 1000111100 and 210012, respectively. 1000111100 has five 1s and five 0s; 210012 has two 2s, two 1s and two 0s. Here are the numbers of A049364 in the necessary bases:

10 (n=2)
1000111100, 210012 (n=572)
100000000101011010111111, 120211022110200, 200011122333 (n=8410815)
11010011110001100111001111010010010001101011100110000010, 101201112000102222102011202221201100, 3103301213033102101223212002, 1000001111222333324244344 (n=59609420837337474)

But what number, a(6), satisfies the definition for bases 2, 3, 4, 5 and 6? According to the notes at the OEIS, a(6) > 5^434. That means finding a(6) is way beyond the power of present-day computers. But I assume a quantum computer could crack it. And maybe someone will come up with a short-cut or even an algorithm that supplies a(b) for any base b. Either way, I think we’ll get there, π and by.

Mod’s Chosen

When you divide one integer by another, one of two things happens. Either the second number goes perfectly into the first or there’s a remainder:


15 / 5 = 3
18 / 5 = 3⅗

In the first case, there’s no remainder, that is, the remainder is 0. In the second case, there’s a remainder of 3. And all that gives you the basis for what’s called modular arithmetic. It returns the remainder when one number is divided by another:


15 mod 5 = 0
16 mod 5 = 1
17 mod 5 = 2
18 mod 5 = 3
19 mod 5 = 4
20 mod 5 = 0
21 mod 5 = 1
22 mod 5 = 2...

It looks simple but a lot of mathematics is built on it. I don’t know much of that maths, but I know one thing I like: the patterns you can get from modular arithmetic. Suppose you draw a square, then find a point and measure the distances from that point to all the vertices of the square. Then add the distances up, turn the result into an integer if necessary, and test whether the result is divisible by 2 or not. If it is divisible, colour the point in. If it isn’t, leave the point blank.

Then move on to another point and perform the same test. This is modular arithematic, because for each point you’re asking whether d mod 2 = 0. The result looks like this:

d mod 2 = 0


Here are more divisors:

d mod 3 = 0


d mod 4 = 0


d mod 5 = 0


d mod 6 = 0


d mod 7 = 0


d mod 8 = 0


d mod 9 = 0


d mod 10 = 0


d mod various = 0 (animated)


You can also use modular arithmetic to determine the colour of the points. For example, if d mod n = 0, the point is black; if d mod n = 1, the point is red; if d mod n = 2, the point is green; and so on.

d mod 3 = 0, 1, 2 (coloured)


d mod 4 = 0, 1, 2, 3 (coloured)


d mod 5 = 0, 1, 2, 3, 4 (coloured)



d mod 5 = 0, 1, 2, 3, 4 (animated and expanding)


Zequality Now

Here are the numbers one to eight in base 2:

1, 10, 11, 100, 101, 110, 111, 1000…

Now see what happens when you count the zeroes:


1, 10[1], 11, 10[2]0[3], 10[4]1, 110[5], 111, 10[6]0[7]0[8]...

In base 2, the numbers one to eight contain exactly eight zeroes, that is, zerocount(1..8,b=2) = 8. But it doesn’t work out so exactly in base 3:


1, 2, 10[1], 11, 12, 20[2], 21, 22, 10[3]0[4], 10[5]1, 10[6]2, 110[7], 111, 112, 120[8], 121, 122, 20[9]0[10], 20[11]1, 20[12]2, 210[13], 211, 212, 220[14], 221, 222, 10[15]0[16]0[17], 10[18]0[19]1, 10[20]0[21]2, 10[22]10[23], 10[24]11, 10[25]12, 10[26]20[27], 10[28]21, 10[29]22, 110[30]0[31], 110[32]1, 110[33]2, 1110[34], 1111, 1112, 1120[35], 1121, 1122, 120[36]0[37], 120[38]1, 120[39]2, 1210[40], 1211, 1212, 1220[41], 1221, 1222, 20[42]0[43]0[44], 20[45]0[46]1, 20[47]0[48]2, 20[49]10[50], 20[51]11, 20[52]12, 20[53]20[54], 20[55]21, 20[56]22, 210[57]0[58], 210[59]1, 210[60]2, 2110[61], 2111, 2112, 2120[62], 2121, 2122, 220[63]0[64], 220[65]1, 220[66]2, 2210[67], 2211, 2212, 2220[68], 2221, 2222, 10[69]0[70]0[71]0[72], 10[73]0[74]0[75]1, 10[76]0[77]0[78]2, 10[79]0[80]10[81], 10[82]0[83]11, 10[84]0[85]12, 10[86]0[87]20[88]...

In base 3, 10020 = 87 and zerocount(1..87,b=3) = 88. And what about base 4? zerocount(1..1068,b=4) = 1069 (n=100,230 in base 4). After that, zerocount(1..16022,b=5) = 16023 (n=1,003,043 in base 5) and zerocount(1..284704,b=6) = 284,705 (n=10,034,024 in base 6).

The numbers are getting bigger fast and it’s becoming increasingly impractible to count the zeroes individually. What you need is an algorithm that will take any given n and work out how many zeroes are required to write the numbers 1 to n. The simplest way to do this is to work out how many times 0 has appeared in each position of the number. The 1s position is easy: you simply divide the number by the base and discard the remainder. For example, in base 10, take the number 25. The 0 must have appeared in the 1s position twice, for 10 and 20, so zerocount(1..25) = 25 \ 10 = 2. In 2017, the 0 must have appeared in the 1s position 201 times = 2017 \ 10. And so on.

It gets a little trickier for the higher positions, the 10s, 100s, 1000s and so on, but the same basic principle applies. And so you can easily create an algorithm that takes a number, n, and produces zerocount(1..n) in a particular base. With this algorithm, you can quickly find zerocount(1..n) >= n in higher bases:


zerocount(1..1000,b=2) = 1,000 (n=8)*
zerocount(1..10020,b=3) = 10,021 (n=87)
zerocount(1..100230,b=4) = 100,231 (n=1,068)
zerocount(1..1003042,b=5) = 1,003,043 (n=16,022)
zerocount(1..10034024,b=6) = 10,034,025 (n=284,704)
zerocount(1..100405550,b=7) = 100,405,551 (n=5,834,024)
zerocount(1..1004500236,b=8) = 1,004,500,237 (n=135,430,302)
zerocount(1..10050705366,b=9) = 10,050,705,367 (n=3,511,116,537)
zerocount(1..100559404366,b=10) = 100,559,404,367
zerocount(1..1006083A68919,b=11) = 1,006,083,A68,919 (n=3,152,738,985,031)*
zerocount(1..10066AA1430568,b=12) = 10,066,AA1,430,569 (n=107,400,330,425,888)
zerocount(1..1007098A8719B81,b=13) = 100,709,8A8,719,B81 (n=3,950,024,143,546,664)*
zerocount(1..10077C39805D81C7,b=14) = 1,007,7C3,980,5D8,1C8 (n=155,996,847,068,247,395)
zerocount(1..10080B0034AA5D16D,b=15) = 10,080,B00,34A,A5D,171 (n=6,584,073,072,068,125,453)
zerocount(1..10088DBE29597A6C77,b=16) = 100,88D,BE2,959,7A6,C77 (n=295,764,262,988,176,583,799)*
zerocount(1..10090C5309AG72CBB3F,b=17) = 1,009,0C5,309,AG7,2CB,B3G (n=14,088,968,131,538,370,019,982)
zerocount(1..10099F39070FC73C1G73,b=18) = 10,099,F39,070,FC7,3C1,G75 (n=709,394,716,006,812,244,474,473)
zerocount(1..100A0DC1258614CA334EB,b=19) = 100,A0D,C12,586,14C,A33,4EC (n=37,644,984,315,968,494,382,106,708)
zerocount(1..100AAGDEEB536IBHE87006,b=20) = 1,00A,AGD,EEB,536,IBH,E87,008 (n=2,099,915,447,874,594,268,014,136,006)

And you can also easily find the zequal numbers, that is, the numbers n for which, in some base, zerocount(1..n) exactly equals n:


zerocount(1..1000,b=2) = 1,000 (n=8)
zerocount(1..1006083A68919,b=11) = 1,006,083,A68,919 (n=3,152,738,985,031)
zerocount(1..1007098A8719B81,b=13) = 100,709,8A8,719,B81 (n=3,950,024,143,546,664)
zerocount(1..10088DBE29597A6C77,b=16) = 100,88D,BE2,959,7A6,C77 (n=295,764,262,988,176,583,799)
zerocount(1..100CCJFFAD4MI409MI0798CJB3,b=24) = 10,0CC,JFF,AD4,MI4,09M,I07,98C,JB3 (n=32,038,681,563,209,056,709,427,351,442,469,835)
zerocount(1..100DDL38CIO4P9K0AJ7HK74EMI7L,b=26) = 1,00D,DL3,8CI,O4P,9K0,AJ7,HK7,4EM,I7L (n=160,182,333,966,853,031,081,693,091,544,779,177,187)
zerocount(1..100EEMHG6OE8EQKO0BF17LCCIA7GPE,b=28) = 100,EEM,HG6,OE8,EQK,O0B,F17,LCC,IA7,GPE (n=928,688,890,453,756,699,447,122,559,347,771,300,777,482)
zerocount(1..100F0K7MQO6K9R1S616IEEL2JRI73PF,b=29) = 1,00F,0K7,MQO,6K9,R1S,616,IEE,L2J,RI7,3PF (n=74,508,769,042,363,852,559,476,397,161,338,769,391,145,562)
zerocount(1..100G0LIL0OQLF2O0KIFTK1Q4DC24HL7BR,b=31) = 100,G0L,IL0,OQL,F2O,0KI,FTK,1Q4,DC2,4HL,7BR (n=529,428,987,529,739,460,369,842,168,744,635,422,842,585,510,266)
zerocount(1..100H0MUTQU3A0I5005WL2PD7T1ASW7IV7NE,b=33) = 10,0H0,MUT,QU3,A0I,500,5WL,2PD,7T1,ASW,7IV,7NE (n=4,262,649,311,868,962,034,947,877,223,846,561,239,424,294,726,563,632)
zerocount(1..100HHR387RQHK9OP6EDBJEUDAK35N7MN96LB,b=34) = 100,HHR,387,RQH,K9O,P6E,DBJ,EUD,AK3,5N7,MN9,6LB (n=399,903,937,958,473,433,782,862,763,628,747,974,628,490,691,628,136,485)
zerocount(1..100IISLI0CYX2893G9E8T4I7JHKTV41U0BKRHT,b=36) = 10,0II,SLI,0CY,X28,93G,9E8,T4I,7JH,KTV,41U,0BK,RHT (n=3,831,465,379,323,568,772,890,827,210,355,149,992,132,716,389,119,437,755,185)
zerocount(1..100LLX383BPWE[40]ZL0G1M[40]1OX[39]67KOPUD5C[40]RGQ5S6W9[36],b=42) = 10,0LL,X38,3BP,WE[40],ZL0,G1M,[40]1O,X[39]6,7KO,PUD,5C[40],RGQ,5S6,W9[36] (n=6,307,330,799,917,244,669,565,360,008,241,590,852,337,124,982,231,464,556,869,653,913,711,854)
zerocount(1..100MMYPJ[38]14KDV[37]OG[39]4[42]X75BE[39][39]4[43]CK[39]K36H[41]M[37][43]5HIWNJ,b=44) = 1,00M,MYP,J[38]1,4KD,V[37]O,G[39]4,[42]X7,5BE,[39][39]4,[43]CK,[39]K3,6H[41],M[37][43],5HI,WNJ (n=90,257,901,046,284,988,692,468,444,260,851,559,856,553,889,199,511,017,124,021,440,877,333,751,943)
zerocount(1..100NN[36]3813[38][37]16F6MWV[41]UBNF5FQ48N0JRN[40]E76ZOHUNX2[42]3[43],b=46) = 100,NN[36],381,3[38][37],16F,6MW,V[41]U,BNF,5FQ,48N,0JR,N[40]E,76Z,OHU,NX2,[42]3[43] (n=1,411,636,908,622,223,745,851,790,772,948,051,467,006,489,552,352,013,745,000,752,115,904,961,213,172,605)
zerocount(1..100O0WBZO9PU6O29TM8Y0QE3I[37][39]A7E4YN[44][42]70[44]I[46]Z[45][37]Q2WYI6,b=47) = 1,00O,0WB,ZO9,PU6,O29,TM8,Y0Q,E3I,[37][39]A,7E4,YN[44],[42]70,[44]I[46],Z[45][37],Q2W,YI6 (n=182,304,598,281,321,725,937,412,348,242,305,189,665,300,088,639,063,301,010,710,450,793,661,266,208,306,996)
zerocount(1..100PP[39]37[49]NIYMN[43]YFE[44]TDTJ00EAEIP0BIDFAK[46][36]V6V[45]M[42]1M[46]SSZ[40],b=50) = 1,00P,P[39]3,7[49]N,IYM,N[43]Y,FE[44],TDT,J00,EAE,IP0,BID,FAK,[46][36]V,6V[45],M[42]1,M[46]S,SZ[40] (n=444,179,859,561,011,965,929,496,863,186,893,220,413,478,345,535,397,637,990,204,496,296,663,272,376,585,291,071,790)
zerocount(1..100Q0Y[46][44]K[49]CKG[45]A[47]Z[43]SPZKGVRN[37]2[41]ZPP[36]I[49][37]EZ[38]C[44]E[46]00CG[38][40][48]ROV,b=51) = 10,0Q0,Y[46][44],K[49]C,KG[45],A[47]Z,[43]SP,ZKG,VRN,[37]2[41],ZPP,[36]I[49],[37]EZ,[38]C[44],E[46]0,0CG,[38][40][48],ROV (n=62,191,970,278,446,971,531,566,522,791,454,395,351,613,891,150,548,291,266,262,575,754,206,359,828,753,062,692,619,547)
zerocount(1..100QQ[40]TL[39]ZA[49][41]J[41]7Q[46]4[41]66A1E6QHHTM9[44]8Z892FRUL6V[46]1[38][41]C[40][45]KB[39],b=52) = 100,QQ[40],TL[39],ZA[49],41]J[41],7Q[46],4[41]6,6A1,E6Q,HHT,M9[44],8Z8,92F,RUL,6V[46],1[38][41],C[40][45],KB[39] (n=8,876,854,501,927,007,077,802,489,292,131,402,136,556,544,697,945,824,257,389,527,114,587,644,068,732,794,430,403,381,731)
zerocount(1..100S0[37]V[53]Y6G[51]5J[42][38]X[40]XO[38]NSZ[42]XUD[47]1XVKS[52]R[39]JAHH[49][39][50][54]5PBU[42]H3[45][46]DEJ,b=55) = 100,S0[37],V[53]Y,6G[51],5J[42],[38]X[40],XO[38],NSZ,[42]XU,D[47]1,XVK,S[52]R,[39]JA,HH[49],[39][50][54],5PB,U[42]H,3[45][46],DEJ (n=28,865,808,580,366,629,824,612,818,017,012,809,163,332,327,132,687,722,294,521,718,120,736,868,268,650,080,765,802,786,141,387,114)

Autonomata

“Describe yourself.” You can say it to people. And you can say it to numbers too. For example, here’s the number 3412 describing the positions of its own digits, starting at 1 and working upward:


3412 – the 1 is in the 3rd position, the 2 is in the 4th position, the 3 is in the 1st position, and the 4 is in the 2nd position.

In other words, the positions of the digits 1 to 4 of 3412 recreate its own digits:


3412 → (3,4,1,2) → 3412

The number 3412 describes itself – it’s autonomatic (from Greek auto, “self” + onoma, “name”). So are these numbers:


1
21
132
2143
52341
215634
7243651
68573142
321654798

More precisely, they’re panautonomatic numbers, because they describe the positions of all their own digits (Greek pan or panto, “all”). But what if you use the positions of only, say, the 1s or the 3s in a number? In base ten, only one number describes itself like that: 1. But we’re not confined to base 10. In base 2, the positions of the 1s in 110 (= 6) are 1 and 10 (= 2). So 110 is monautonomatic in binary (Greek mono, “single”). 10 is also monautonomatic in binary, if the digit being described is 0: it’s in 2nd position or position 10 in binary. These numbers are monoautonomatic in binary too:


110100 = 52 (digit = 1)
10100101111 = 1327 (d=0)

In 110100, the 1s are in 1st, 2nd and 4th position, or positions 1, 10, 100 in binary. In 10100101111, the 0s are in 2nd, 4th, 5th and 7th position, or positions 10, 100, 101, 111 in binary. Here are more monautonomatic numbers in other bases:


21011 in base 4 = 581 (digit = 1)
11122122 in base 3 = 3392 (d=2)
131011 in base 5 = 5131 (d=1)
2101112 in base 4 = 9302 (d=1)
11122122102 in base 3 = 91595 (d=2)
13101112 in base 5 = 128282 (d=1)
210111221 in base 4 = 148841 (d=1)

For example, in 131011 the 1s are in 1st, 3rd, 5th and 6th position, or positions 1, 3, 10 and 11 in quinary. But these numbers run out quickly and the only monautonomatic number in bases 6 and higher is 1. However, there are infinitely long monoautonomatic integer sequences in all bases. For example, in binary this sequence at the Online Encyclopedia of Integer Sequences describes itself using the positions of its 1s:


A167502: 1, 10, 100, 111, 1000, 1001, 1010, 1110, 10001, 10010, 10100, 10110, 10111, 11000, 11010, 11110, 11111, 100010, 100100, 100110, 101001, 101011, 101100, 101110, 110000, 110001, 110010, 110011, 110100, 111000, 111001, 111011, 111101, 11111, …

In base 10, it looks like this:


A167500: 1, 2, 4, 7, 8, 9, 10, 14, 17, 18, 20, 22, 23, 24, 26, 30, 31, 34, 36, 38, 41, 43, 44, 46, 48, 49, 50, 51, 52, 56, 57, 59, 61, 62, 63, 64, 66, 67, 68, 69, 70, 71, 75, 77, 80, 83, 86, 87, 89, 91, 94, 95, 97, 99, 100, 101, 103, 104, 107, 109, 110, 111, 113, 114, 119, 120, 124, … (see A287515 for a similar sequence using 0s)