Thursday, 9 February 2023

In the Vicinity of Cubic Numbers

In searching for properties of the number associated with my diurnal age, 26975, I noticed that the difference between this number and the nearest cubic number is 25 and that 25 divides 27000 (the nearest cubic number) to give 1080. I got to thinking about how many numbers, in the range up to 40,000, have this property.

Well, it turns out that 711 numbers do. A list of them is included at the end of this post. These numbers are not evenly distributed. They tend to cluster around cubic numbers with a large number of divisors and are sparsest around cubic numbers that are the cubes of primes. Figure 1 shows a list of the numbers from 1 to 35, together with their cubes and the numbers of both their divisors.


Figure 1: permalink

The graph of the 711 numbers is interesting, displaying a sinuous pattern. See Figure 2.


Figure 2: permalink

If we zoom in, things become clearer. Let's consider the cubic number 27000 that is the cube of 30. The former has 8 divisors and the latter 64. We'll look at the range from 26000 to 28000. Figure 3 shows the plot of the 94 numbers that qualify.


Figure 3: permalink

Notice how the graph is the same shape as that of \(y=x^3\). Next look at the cubic number 29791 that is the cube of 31. The former has four divisors (1, 31, 31 x 31 and 31 x 31 x 31) while the latter has two (1 and 31). The plot is shown in Figure 4 for the range from 28791 to 30791.


Figure 4: permalink

There are only six numbers and these are 28830, 29760, 29790, 29792, 29822, 30752. The numbers immediately preceding and succeeding the cubic number will always qualify since the difference is 1. Thus 26970 and 26972 are represented. Numbers with a difference of 31 will qualify and thus 26760 and 29822 are represented. Numbers with a difference of 31 x 31 will qualify and thus 28830 and 30752 are represented.

An interesting fact is that is that the difference not only divides the cubic number, it also always divides the number itself. For example, in the case 26975, the difference of 25 between 26975 and 27000 also divides 26975. To see why this is so, let's consider a cubic number \(c^3\) and a number \(n<c^3\) such that:
$$ 

\begin{align} \frac{c^3}{c^3-n} = k \text{ with integer }k>0\\

kc^3-kn =c^3\\

kn=kc^3-c^3\\

kn=c^3(k-1)\\

n=\dfrac{c^3}{k} (k-1) \\

n= \text{ difference } \times (k-1) \end{align}
$$Hence \(n\) is always divisible by the difference. Take \(n=26975\) as an example. $$ \begin{align} \frac{27000}{25} &=1080\\26975=25 \times (1080-1) &=25 \times 1079 \end{align}$$A similar proof can be concocted for the case where \(n>c^3\). Here is the list of the 711 numbers (permalink).

2, 4, 6, 7, 9, 10, 12, 18, 24, 26, 28, 30, 36, 48, 56, 60, 62, 63, 65, 66, 68, 72, 80, 100, 120, 124, 126, 130, 150, 180, 189, 192, 198, 204, 207, 208, 210, 212, 213, 214, 215, 217, 218, 219, 220, 222, 224, 225, 228, 234, 240, 243, 252, 270, 294, 336, 342, 344, 350, 392, 448, 480, 496, 504, 508, 510, 511, 513, 514, 516, 520, 528, 544, 576, 648, 702, 720, 726, 728, 730, 732, 738, 756, 810, 875, 900, 950, 960, 975, 980, 990, 992, 995, 996, 998, 999, 1001, 1002, 1004, 1005, 1008, 1010, 1020, 1025, 1040, 1050, 1100, 1125, 1210, 1320, 1330, 1332, 1342, 1452, 1536, 1584, 1620, 1632, 1656, 1664, 1674, 1680, 1692, 1696, 1701, 1704, 1710, 1712, 1716, 1719, 1720, 1722, 1724, 1725, 1726, 1727, 1729, 1730, 1731, 1732, 1734, 1736, 1737, 1740, 1744, 1746, 1752, 1755, 1760, 1764, 1776, 1782, 1792, 1800, 1824, 1836, 1872, 1920, 1944, 2028, 2184, 2196, 2198, 2210, 2366, 2548, 2646, 2688, 2695, 2716, 2730, 2736, 2737, 2740, 2742, 2743, 2745, 2746, 2748, 2751, 2752, 2758, 2772, 2793, 2800, 2842, 2940, 3150, 3240, 3250, 3300, 3330, 3348, 3350, 3360, 3366, 3370, 3372, 3374, 3376, 3378, 3380, 3384, 3390, 3400, 3402, 3420, 3450, 3500, 3510, 3600, 3840, 3968, 4032, 4064, 4080, 4088, 4092, 4094, 4095, 4097, 4098, 4100, 4104, 4112, 4128, 4160, 4224, 4352, 4624, 4896, 4912, 4914, 4930, 5202, 5508, 5589, 5616, 5670, 5724, 5751, 5760, 5778, 5796, 5805, 5808, 5814, 5820, 5823, 5824, 5826, 5828, 5829, 5830, 5831, 5833, 5834, 5835, 5836, 5838, 5840, 5841, 5844, 5850, 5856, 5859, 5868, 5886, 5904, 5913, 5940, 5994, 6048, 6075, 6156, 6318, 6498, 6840, 6858, 6860, 6878, 7220, 7500, 7600, 7680, 7750, 7800, 7840, 7875, 7900, 7920, 7936, 7950, 7960, 7968, 7975, 7980, 7984, 7990, 7992, 7995, 7996, 7998, 7999, 8001, 8002, 8004, 8005, 8008, 8010, 8016, 8020, 8025, 8032, 8040, 8050, 8064, 8080, 8100, 8125, 8160, 8200, 8250, 8320, 8400, 8500, 8820, 8918, 9072, 9114, 9198, 9212, 9234, 9240, 9252, 9254, 9258, 9260, 9262, 9264, 9268, 9270, 9282, 9288, 9310, 9324, 9408, 9450, 9604, 9702, 10164, 10406, 10527, 10560, 10604, 10626, 10637, 10640, 10644, 10646, 10647, 10649, 10650, 10652, 10656, 10659, 10670, 10692, 10736, 10769, 10890, 11132, 11638, 12144, 12166, 12168, 12190, 12696, 13056, 13248, 13312, 13392, 13440, 13536, 13568, 13608, 13632, 13680, 13696, 13716, 13728, 13752, 13760, 13770, 13776, 13788, 13792, 13797, 13800, 13806, 13808, 13812, 13815, 13816, 13818, 13820, 13821, 13822, 13823, 13825, 13826, 13827, 13828, 13830, 13832, 13833, 13836, 13840, 13842, 13848, 13851, 13856, 13860, 13872, 13878, 13888, 13896, 13920, 13932, 13952, 13968, 14016, 14040, 14080, 14112, 14208, 14256, 14336, 14400, 14592, 14688, 15000, 15500, 15600, 15620, 15624, 15626, 15630, 15650, 15750, 16250, 16900, 17238, 17407, 17472, 17524, 17550, 17563, 17568, 17572, 17574, 17575, 17577, 17578, 17580, 17584, 17589, 17602, 17628, 17680, 17745, 17914, 18252, 18954, 19440, 19602, 19656, 19674, 19680, 19682, 19684, 19686, 19692, 19710, 19764, 19926, 20412, 21168, 21266, 21504, 21560, 21609, 21728, 21756, 21840, 21854, 21888, 21896, 21903, 21920, 21924, 21936, 21938, 21944, 21945, 21948, 21950, 21951, 21953, 21954, 21956, 21959, 21960, 21966, 21968, 21980, 21984, 22001, 22008, 22016, 22050, 22064, 22148, 22176, 22295, 22344, 22400, 22638, 22736, 23548, 24360, 24388, 24390, 24418, 25230, 25875, 25920, 26000, 26100, 26250, 26325, 26400, 26460, 26500, 26550, 26625, 26640, 26700, 26730, 26750, 26775, 26784, 26800, 26820, 26850, 26865, 26875, 26880, 26892, 26900, 26910, 26925, 26928, 26940, 26946, 26950, 26955, 26960, 26964, 26970, 26973, 26975, 26976, 26980, 26982, 26985, 26988, 26990, 26991, 26992, 26994, 26995, 26996, 26997, 26998, 26999, 27001, 27002, 27003, 27004, 27005, 27006, 27008, 27009, 27010, 27012, 27015, 27018, 27020, 27024, 27025, 27027, 27030, 27036, 27040, 27045, 27050, 27054, 27060, 27072, 27075, 27090, 27100, 27108, 27120, 27125, 27135, 27150, 27180, 27200, 27216, 27225, 27250, 27270, 27300, 27360, 27375, 27450, 27500, 27540, 27600, 27675, 27750, 27900, 28000, 28080, 28125, 28350, 28830, 29760, 29790, 29792, 29822, 30752, 31744, 32256, 32512, 32640, 32704, 32736, 32752, 32760, 32764, 32766, 32767, 32769, 32770, 32772, 32776, 32784, 32800, 32832, 32896, 33024, 33280, 33792, 34606, 34848, 35574, 35640, 35816, 35838, 35904, 35910, 35926, 35928, 35934, 35936, 35938, 35940, 35946, 35948, 35964, 35970, 36036, 36058, 36234, 36300, 37026, 37268, 38148, 38726, 39015, 39168, 39236, 39270, 39287, 39296, 39300, 39302, 39303, 39305, 39306, 39308, 39312, 39321, 39338, 39372, 39440, 39593, 39882

A Property of the Determinant of a Circulant Matrix

 I've written about the circulant matrix only twice before in the following posts:

Today, with my diurnal age being 26975, I was struggling to find some interesting properties for this number and my thoughts fell to testing whether the sum of its digits divided the determinant of its circulant matrix. It did. I tested for other numbers and to my surprise this was always the case. What is going on?

Well, it all becomes clear when we consider generalised 2 x 2 circulant matrix (ignoring the trivial case of one digit numbers). Let's start with a generalised two digit number. Let's call it \(ab\). This number produces the circulant matrix shown in Figure 1.

Figure 1

This matrix has a determinant of \(a^2-b^2=(a+b)(a-b) \) and thus \(a+b\) will always divide it. Let's now consider a three digit number \(abc\) with sum of digits \(a+b+c\). It's circulant matrix is shown in Figure 2.

Figure 2

The determinant of this matrix is:$$a^3 - 3 a b c + b^3 + c^3\\ = (a + b + c) (a^2 - a b - a c + b^2 - b c + c^2)$$Once again, \(a+b+c\) will always divide this determinant. Let's look at a four digit number \(abcd\) with sum of digits \(a+b+c+d\). The circulant matrix is shown in Figure 3.

Figure 3

The determinant of this matrix is:$$ \begin{align} a^4 - 4 a^2 b d - 2 a^2 c^2 + 4 a b^2 c + 4 a c d^2 - b^4 + 2 b^2 d^2 - 4 b c^2 d + c^4 - d^4\\=(a - b + c - d) (a + b + c + d) (a^2 - 2 a c + b^2 - 2 b d + c^2 + d^2) \end{align} $$Once again, \(a+b+c+d\) will always divide this determinant. I won't go any further nor attempt a completely generalised proof but it seems apparent that the sum of the digits of any number will always divide the determinant of the number's circulant matrix. A surprising and interesting result.


Figure 4

I give credit to Wolfram Alpha for quickly calculating the determinants and factorising them.


Figure 5

In fact, I felt guilty after using Wolfram Alpha, because I knew SageMath could do the job just as well. So here is the latter's handling of the generalised five digit number \(abcde\). Figure 6 shows the number' circulant matrix:


Figure 6: permalink

Here is the determinant of this matrix:$$ \begin{align} a^5 + b^5 - 5ab^3c + 5a^2bc^2 + c^5\\ + 5a^2b^2d - 5a^3cd - 5bc^3d + 5b^2cd^2 + 5ac^2d^2\\ - 5abd^3 + d^5 - 5a^3be + 5b^2c^2e - 5ac^3e\\ - 5b^3de - 5abcde + 5a^2d^2e - 5cd^3e + 5ab^2e^2\\ + 5a^2ce^2 + 5c^2de^2 + 5bd^2e^2 - 5bce^3 - 5ade^3 + e^5 \end{align}$$This factorises to:$$ \begin{align} (a^4 - a^3b + a^2b^2 - ab^3\\ + b^4 - a^3c + 2a^2bc - 3ab^2c - b^3c\\ + a^2c^2 + 2abc^2 + b^2c^2 - ac^3 - bc^3\\ + c^4 - a^3d + 2a^2bd + 2ab^2d - b^3d\\ - 3a^2cd - abcd + 2b^2cd + 2ac^2d - 3bc^2d\\- c^3d + a^2d^2 - 3abd^2 + b^2d^2 + 2acd^2\\ + 2bcd^2 + c^2d^2 - ad^3 - bd^3 - cd^3 + d^4 \\- a^3e - 3a^2be + 2ab^2e - b^3e + 2a^2ce\\ - abce + 2b^2ce - 3ac^2e + 2bc^2e - c^3e\\ + 2a^2de - abde - 3b^2de - acde - bcde\\ + 2c^2de + 2ad^2e + 2bd^2e - 3cd^2e - d^3e\\ + a^2e^2 + 2abe^2 + b^2e^2 + 2ace^2 - 3bce^2\\ + c^2e^2 - 3ade^2 + 2bde^2 + 2cde^2 + d^2e^2\\ - ae^3 - be^3 - ce^3 - de^3 + e^4)\\(a + b + c + d + e) \end{align} $$Clearly, once again, the sum of the digits \(a+b+c+d+e\) divides the determinant.

If we consider the permanent of the circulant matrix and not the determinant, then out of the first one million numbers there are 106343 numbers, roughly 10%, whose sum of digits divides the permanent (permalink).

Monday, 6 February 2023

Even Numbers as Sums and Differences of Two Pronic Numbers

It was a form of Goldbach's conjecture that got me thinking about an equivalent involving pronic numbers. The conjecture is that every even number can be written as a sum of two prime numbers. Pronic numbers, that is numbers of the form \(n \times (n-1) \), are always even and so the sum of two pronic numbers must be even as well. 

Can every even number be written as a sum of two not necessarily distinct pronic numbers. Let's consider the numbers from 1 to 100. The results are as follows:

  • 4 = 2 + 2
  • 8 = 2 + 6
  • 12 = 6 + 6
  • 14 = 2 + 12
  • 18 = 6 + 12
  • 22 = 2 + 20
  • 24 = 12 + 12
  • 26 = 6 + 20
  • 32 = 2 + 30
  • 32 = 12 + 20
  • 36 = 6 + 30
  • 40 = 20 + 20
  • 42 = 12 + 30
  • 44 = 2 + 42
  • 48 = 6 + 42
  • 50 = 20 + 30
  • 54 = 12 + 42
  • 58 = 2 + 56
  • 60 = 30 + 30
  • 62 = 6 + 56
  • 62 = 20 + 42
  • 68 = 12 + 56
  • 72 = 30 + 42
  • 74 = 2 + 72
  • 76 = 20 + 56
  • 78 = 6 + 72
  • 84 = 12 + 72
  • 84 = 42 + 42
  • 86 = 30 + 56
  • 92 = 2 + 90
  • 92 = 20 + 72
  • 96 = 6 + 90
  • 98 = 42 + 56
As can be seen, not all even numbers between 4 and 100 can be written as a sum of two pronic numbers. We are missing 6, 10, 16, 20, 28, 30, 34, 38, 46, 52, 56, 64, 70, 80, 82, 88, 90, 94 and 100. Some numbers however, can be written as a sum of two pronic numbers in more than one way. These numbers are 32, 62, 84 and 92. Each can be written in two ways.

Let's take another range of one hundred numbers, this time from 26900 to 27000. The results are as follows:

  • 26906 = 4556 + 22350
  • 26912 = 506 + 26406
  • 26912 = 6320 + 20592
  • 26912 = 13340 + 13572
  • 26914 = 182 + 26732
  • 26916 = 3660 + 23256
  • 26916 = 8010 + 18906
  • 26916 = 8556 + 18360
  • 26916 = 13110 + 13806
  • 26922 = 1482 + 25440
  • 26922 = 10920 + 16002
  • 26924 = 12882 + 14042
  • 26928 = 1806 + 25122
  • 26930 = 9900 + 17030
  • 26936 = 2756 + 24180
  • 26936 = 12656 + 14280
  • 26940 = 4290 + 22650
  • 26942 = 210 + 26732
  • 26942 = 2450 + 24492
  • 26942 = 7482 + 19460
  • 26942 = 9120 + 17822
  • 26948 = 6642 + 20306
  • 26950 = 1190 + 25760
  • 26950 = 3080 + 23870
  • 26952 = 870 + 26082
  • 26952 = 12432 + 14520
  • 26958 = 552 + 26406
  • 26968 = 2162 + 24806
  • 26968 = 10712 + 16256
  • 26972 = 240 + 26732
  • 26972 = 12210 + 14762
  • 26984 = 3422 + 23562
  • 26984 = 4032 + 22952
  • 26994 = 6972 + 20022
  • 26994 = 9702 + 17292
  • 26996 = 11990 + 15006
  • 27000 = 1560 + 25440
There are 21 numbers in the range of 51 even numbers that can be expressed as a sum of two pronic numbers. This is a percentage of about 42%. These are (permalink):

26906, 26912, 26912, 26912, 26914, 26916, 26916, 26916, 26916, 26922, 26922, 26924, 26928, 26930, 26936, 26936, 26940, 26942, 26942, 26942, 26942, 26948, 26950, 26950, 26952, 26952, 26958, 26968, 26968, 26972, 26972, 26984, 26984, 26994, 26994, 26996, 27000

Some numbers can be expressed as a sum in four ways. Here is the count of ways with four ways numbers marked in bold): 

(26906, 1), (26912, 3), (26914, 1), (26916, 4), (26922, 2), (26924, 1), (26928, 1), (26930, 1), (26936, 2), (26940, 1), (26942, 4), (26948, 1), (26950, 2), (26952, 2), (26958, 1), (26968, 2), (26972, 2), (26984, 2), (26994, 2), (26996, 1), (27000, 1)

Thus is the range selected there are only two numbers that meet the four ways criterion and these are 26916 and 26942. This is a percentage of about 4%. What becomes of interest then is what numbers in a given range can be expressed as a sum of two pronic numbers in exactly four ways. Let's consider a range of two thousand, from 26000 to 28000. There are only 33 such numbers, representing about 3.3% of the range, and they are (permalink):

26032, 26052, 26102, 26214, 26222, 26292, 26312, 26342, 26382, 26432, 26630, 26682, 26752, 26868, 26916, 26942, 27042, 27062, 27072, 27102, 27176, 27192, 27242, 27402, 27480, 27522, 27572, 27602, 27752, 27852, 27854, 27922, 27990

Some numbers can be written is five different ways. There are two numbers in the range between 26000 and 28000 and they are 26732 and 27812. Other numbers can be written as a sum of pronic numbers in six different ways. These numbers are 26462, 26562, 27162, 27332 and 27462. Below is shown the sums for 27462:
  • 27462 = 72 + 27390
  • 27462 = 1056 + 26406
  • 27462 = 2970 + 24492
  • 27462 = 5112 + 22350
  • 27462 = 8556 + 18906
  • 27462 = 12210 + 15252
There are no numbers in the range that can be expressed as a sum in seven ways. Notice that throughout this investigation, we imposed the condition that the two pronic numbers need not be distinct. If we imposed the condition that they must be distinct, then there would be slightly fewer numbers that satisfy.

It's also possible to consider numbers that are a difference of two pronic numbers. For example in the range between 26900 and 27000, there are 35 numbers out the 51 even numbers that can expressed as differences, many in multiple ways. However, there are 16 that cannot and these are (permalink):

26902, 26914, 26916, 26926, 26930, 26932, 26938, 26948, 26954, 26958, 26968, 26974, 26982, 26984, 26990, 26998

This post is just meant as an initial investigation into this topic and it would be useful to expand the investigation to include all even numbers in the range up to about 40000.

Saturday, 4 February 2023

Infinite Sums of Reciprocals of Pronic Numbers

I'd heard the term pronic number before but not promic number. However, the number associated with my diurnal age today, 26970, is such a number according to OEIS  A007531:

 
 A007531

\(a(n) = n \times (n-1) \times (n-2)   \)  
                


The sequence runs:

0, 0, 0, 6, 24, 60, 120, 210, 336, 504, 720, 990, 1320, 1716, 2184, 2730, 3360, 4080, 4896, 5814, 6840, 7980, 9240, 10626, 12144, 13800, 15600, 17550, 19656, 21924, 24360, 26970, 29760, 32736, 35904, 39270, 42840, 46620, 50616, 54834, 59280, 63960, 68880

Interestingly, the next such number, 29760, is a permutation of the digits of 26970. The comments to OEIS A007531 state that members of this sequence are "three-dimensional promic (or oblong) numbers". While I initially thought that I hadn't heard the term "promic" before, I realised in fact that I had and it was in the entry for Pronic Number is Wolfram MathWorld. Here is the text of interest:
Pronic numbers are also known as oblong (Merzbach and Boyer 1991, p. 50) or heteromecic numbers. However, "pronic" seems to be a misspelling of "promic" (from the Greek promekes, meaning rectangular, oblate, or oblong). However, no less an authority than Euler himself used the term "pronic," so attempting to "correct" it at this late date seems inadvisable.

So that clears matters up and it would seem that the terms pronic and oblong can be applied to numbers of the form \(n \times (n-1) \) with \(n \geq 1\) as well as those of the form \(n \times (n-1) \times (n-2) \) with \(n \geq 2\). Anyway, this is just nomenclature and these types of numbers might indeed be referred to as generalised factorial numbers because they can be written in the following form:$$P_{n,k}=\frac{n!}{(n-k)!} \text{ where } k \geq 2$$The notation \(P_{n,k}\) can be interpreted as the \(n\)-th pronic number of dimension \(k\).  When \(k=2\) the dimensionality is two, when \(k=3\) the dimensionality is three and so on. In this notational system, we have:$$26970=P_{31,3}=\frac{31!}{(31-3)!}=31 \times 30 \times 29$$The sequences for various values of \(k\) can be generated using this SageMath code. For example, when \(k=4\), the sequence becomes OEIS A052762:

24, 120, 360, 840, 1680, 3024, 5040, 7920, 11880, 17160, 24024, 32760, 43680, 57120, 73440, 93024, 116280, 143640, 175560, 212520, 255024, 303600, 358800, 421200, 491400, 570024, 657720, 755160, 863040, 982080, 1113024, 1256640, 1413720, 1585080, 1771560, 1974024, 2193360, 2430480, 2686320, 2961840, 3258024, 3575880, 3916440, 4280760, 4669920, 5085024, 5527200

In my post titled My Yearly Pronic Number on Saturday, 11th June 2022, I noted that:$$\sum_{n=1}^{\infty} \frac{1}{n \times (n+1)}=1$$To this it can be added that:

$$\sum_{n=1}^{\infty} \frac{1}{n \times (n+1) \times (n+2)}=\frac{1}{4}$$The infinite sums can be worked out for any value of \(k\) in \(P_{n,k} \) using this permalink. For \(k=4\), the value is 1/18. To summarise, the infinite sums are:
  • \( \displaystyle \sum_{n=2}^{\infty} \dfrac{1}{P_{n,2}}=1 \)
  • \( \displaystyle \sum_{n=3}^{\infty} \dfrac{1}{P_{n,3}}=\dfrac{1}{4} \)
  • \( \displaystyle \sum_{n=4}^{\infty} \dfrac{1}{P_{n,4}}=\dfrac{1}{18} \)
  • \( \displaystyle \sum_{n=5}^{\infty} \dfrac{1}{P_{n,5}}=\dfrac{1}{96} \)
  • \( \displaystyle \sum_{n=6}^{\infty} \dfrac{1}{P_{n,6}}=\dfrac{1}{600} \)
In general, the result is that:$$ \sum_{n=k}^{\infty} \dfrac{1}{P_{n,k}}=\dfrac{1}{k!-(k-1)!}  \text{ for } k \geq 2$$

Sunday, 29 January 2023

Iteration: Reverse and Add Sum of Digits

My previous post, titled Iteration: Reverse and Subtract Maximum Digit, encouraged me to look at some variants on this theme. I discovered that Reverse and Add Sum of Digits is interesting. In the range up to 100,000, this iteration always produces a loop. The trajectory of maximum length is achieved by 84761 with a length of 126. Here is the trajectory:

84761, 16774, 47786, 68806, 60914, 41926, 62936, 63952, 25961, 16975, 57989, 99013, 31121, 12121, 12128, 82135, 53147, 74155, 55169, 96181, 18194, 49204, 40313, 31315, 51326, 62332, 23342, 24346, 64361, 16366, 66383, 38392, 29408, 80515, 51527, 72535, 53549, 94561, 16574, 47584, 48602, 20704, 40715, 51721, 12731, 13735, 53750, 5755, 5597, 7981, 1922, 2305, 5042, 2416, 6155, 5533, 3371, 1747, 7490, 967, 791, 214, 419, 928, 848, 868, 890, 115, 518, 829, 947, 769, 989, 1015, 5108, 8029, 9227, 7249, 9449, 9475, 5774, 4798, 9002, 2020, 206, 610, 23, 37, 83, 49, 107, 709, 923, 343, 353, 364, 476, 691, 212, 217, 722, 238, 845, 565, 581, 199, 1010, 103, 305, 511, 122, 226, 632, 247, 755, 574, 491, 208, 812, 229, 935, 556, 671, 190, 101, 103

Figure 1 shows a graph of the trajectory.


Figure 1: permalink

Figure 2 shows the same graph by with a logarithmic scale for the y axis.


Figure 2: permalink

Figure 3 shows a plot of the trajectory lengths for the first 100,000 numbers.


Figure 3: permalink

The average trajectory length is a little of over 43. As the numbers get bigger, it's not surprising that the trajectory lengths grow larger. For example, take the set of numbers corresponding to the dates in 2023 (see Turning Dates Into Numbers). For this set of numbers, the average trajectory length is a little over 72 and the record is achieved by 20230518 (corresponding to 18th May 2023) with a trajectory length of 162:

20230518, 81503223, 32230542, 24503244, 44230566, 66503274, 47230599, 99503313, 31330632, 23603334, 43330656, 65603364, 46330689, 98603403, 30430722, 22703424, 42430746, 64703454, 45430779, 97703493, 39430821, 12803523, 32530845, 54803553, 35530878, 87803592, 29530920, 2903622, 2263116, 6113643, 3463140, 413664, 466338, 833694, 496371, 173724, 427395, 593754, 457428, 824784, 487461, 164814, 418485, 584844, 448518, 815874, 478551, 155904, 409575, 575934, 439608, 806964, 469641, 146994, 499674, 477033, 330798, 897063, 360831, 138084, 480855, 558114, 411879, 978144, 441912, 219165, 561936, 639195, 591969, 969234, 433002, 200346, 643017, 710367, 763041, 140388, 883065, 560418, 814089, 980448, 844122, 221469, 964146, 641499, 994179, 971538, 835212, 212559, 955236, 632589, 985269, 962628, 826302, 203649, 946326, 623679, 976359, 953718, 817392, 293748, 847425, 524778, 877458, 854817, 718491, 194847, 748524, 425877, 778557, 755916, 619590, 95946, 64992, 29976, 68025, 52107, 70140, 4119, 9129, 9240, 444, 456, 669, 987, 813, 330, 39, 105, 507, 717, 732, 249, 957, 780, 102, 204, 408, 816, 633, 348, 858, 879, 1002, 2004, 4008, 8016, 6123, 3228, 8238, 8349, 9462, 2670, 777, 798, 921, 141, 147, 753, 372, 285, 597, 816

Figure 4 shows a graph of this trajectory:


Figure 4: permalink

Figure 5 shows the same trajectory but uses a logarithmic scale for the y axis:


Figure 5: permalink

I suspect that a loop is eventually reached for any number, no matter how large. However, I can't prove this but a proof may be possible. This iteration that I've just examined is just another of many possible iterations and I may investigate others at a future date.

Saturday, 28 January 2023

Iteration: Reverse and Subtract Maximum Digit

Today I turned 26963 days old and one of the interesting properties of this number is that it's a member of OEIS  A097155:


 A097155

Numbers that reach the fixed point 89 under iteration of f(x) = reverse(x) - maxdigit(x).



In the range up to 40,000, there are only 45 numbers with this property. They are:

89, 890, 998, 2125, 3126, 5207, 6207, 7018, 7019, 8099, 8900, 9098, 9899, 9980, 10151, 10152, 10224, 12205, 12259, 12268, 14085, 14086, 15095, 15096, 17972, 18971, 21250, 22015, 22269, 23077, 24005, 24086, 24087, 25096, 26963, 27962, 30225, 31116, 31260, 33006, 33077, 33078, 34087, 35954, 36953

The remaining 39955 numbers end in zero. Here is a permalink to the calculation that generated these numbers. Let's follow the trajectory of 26963 (permalink):

26963, 36953, 35954, 45944, 44945, 54935, 53936, 63926, 62927, 72917, 71918, 81908, 80909, 90899, 99800, 890, 89

ONLY 0 AND 89 REMAIN INVARIANT
UNDER THE OPERATION OF
REVERSE AND SUBTRACT LARGEST DIGIT

Figure 1 shows the trajectory of 26963. Note how 99800 collapses to 899 when it's reversed, leading quickly to 89.


Figure 1: trajectory of 26963

Compare this trajectory to that 26962 (see What's Special About 26962?) and most other numbers (permalink):

26962, 26953, 35953, 35944, 44944, 44935, 53935, 53926, 62926, 62917, 71917, 71908, 80908, 80899, 99799, 99790, 9790, 970, 70, 0

Figure 2 shows the trajectory of 26962 which is similar to that of 26963, except that it collapses to 0.


Figure 2: trajectory of 26962

If we look at the numbers corresponding to the dates in 2023 (see Turning Dates Into Numbers), there are only two numbers that lead to in 89 and these are (permalink):
  • 20230213 corresponding to the 13th February 2023
  • 20231112 corresponding to the 12th November 2023
The numbers corresponding to the other 363 dates all end in zero.

In the range up to 100,000, there are 124 numbers that end in 89 making for a percentage of 0.124% (permalink). Figure 3 shows the distribution of these numbers over the range.


Figure 3

What's Special About 26962?

I'm following my tradition of making a special post for my palindromic days. The last one was 26862 and titled What's Special About 26862? Now I've reached 26962 and this palindrome has some interesting properties. The first is that it can be split up into two factors, each of which is the reverse of the other (with square numbers such as 121 excluded).

26962 = 122 x 221 = 221 x 122

There are not many palindromes with this property in the range up to one million. Here is the list:

  • 252 =12 x 21 = 21 x 12
  • 20502 = 102 x 201 = 201 x 102
  • 23632 = 112 x 211 = 211 x 112
  • 26962 = 122 x 221 = 221 x 122
As can be seen, 26962 is last palindrome with this property in the range up to one million. We have to extend the range in order to find more. In the range between one and two million, the following palindromes are found (permalink):
  • 1113111 = 1011 x 1101 = 1101 x 1011
  • 1226221 = 1021 x 1201 = 1201 x 1021
  • 1357531 = 1121 x 1211 = 1211 x 1121
Notice how all the factors are comprised of the digits 0, 1 and 2 only. If we relax the rule that square numbers are excluded then, with their inclusion, 26962 is a member of OEIS A158642:


 A158642

Palindromic numbers which are the product of a number n and its reversal (n written backwards)



The members of this sequence, up to two million, are:

0, 1, 4, 9, 121, 252, 484, 10201, 12321, 14641, 20502, 23632, 26962, 40804, 44944, 1002001, 1113111, 1226221, 1234321, 1357531

The previously mentioned non-square numbers are marked in blue.

********************************************

26962 is a palindrome which is 
a product of a pair of emirpimes

In the case of 26962, it can be noted that the factors 122 and 221 are products of emirpimes:
  • 122 = 2 x 61
  • 221 = 13 x 17
This property of being a product of emirpimes qualifies 26962 for membership in OEIS A158126:


 A158126

Products of emirpimes pairs, sorted.                                    


The initial members of the sequence are:

765, 1612, 3627, 4606, 4930, 26962, 39483, 48763, 58765, 61306, 69723, 85405, 102910, 107485, 118809, 129682, 134458, 136467, 140572, 146047, 148930, 151209, 155038, 162409, 178555, 194242, 196315, 203098, 213310, 236421, 283798, 291247

********************************************

26962 is a palindrome 
with four distinct prime factors

26962 has four distinct prime factors: 2, 13, 17 and 61. Palindromes with this property are fairly rare and constitute OEIS A046394: 

 
 A046394

Palindromes with exactly four distinct prime factors.                              



The initial members of this sequence, up to 100,000, are (permalink):

858, 2002, 2442, 3003, 4774, 5005, 5115, 6666, 10101, 15351, 17871, 22422, 22722, 24242, 26562, 26962, 28482, 35853, 36363, 41314, 43734, 43834, 45654, 47874, 49494, 49794, 49894, 51015, 51315, 51415, 53535, 53835, 53935, 56865, 58485, 59295, 59595, 60006, 62526, 62826, 64246, 64446, 66666, 66766, 68286, 73437, 74347, 78387, 81618, 81718, 83638, 83838, 87078, 87178, 89598, 89698, 92829, 96369, 98889

26962 is also a palindrome in base 11, being represented as 19291. This property qualifies it for membership in OEIS A180454.

********************************************

26962 can be written as a sum of two distinct palindromic primes in three different ways

Still on the topic of palindromes, 26962 is a member of OEIS A356854:


 A356854

Palindromes that can be written in more than one way as the sum of two distinct palindromic primes.



The primes are 10301 + 16661 = 10601 + 16361 = 11411 + 15551 = 26962.

The initial members of the sequence are (permalink):

282, 484, 858, 888, 21912, 22722, 23832, 24642, 25752, 26662, 26762, 26862, 26962, 27672, 27772, 27872, 27972, 28482, 28782, 28882, 28982, 29692, 29792, 29892, 29992, 40704, 41514, 41614, 41814, 42624, 42824, 42924, 43434, 43734, 43834, 43934, 44744, 44844, 44944, 45354

********************************************

26962 is a palindromic Ulam number

26962 is also an Ulam number and so, being a palindromic Ulam number, it qualifies for membership in OEIS A173542:


 A173542

Palindromic Ulam numbers.   
                                       


The initial members of the sequence are:

1, 2, 3, 4, 6, 8, 11, 77, 99, 131, 282, 363, 414, 434, 585, 646, 949, 2112, 2332, 2552, 2662, 5335, 5665, 8008, 8338, 8668, 10501, 13531, 13931, 15251, 16961, 17071, 18381, 18581, 18681, 22122, 22322, 23632, 23932, 25452, 26962, 28582, 28682, 30703, 30803, 32123