Wednesday 22 May 2024

The Cubic Attractiveness of 153


From 2012 post, with additional detail and a guest followup:

Just in time for June 1st, which is the 153rd day of this leap year.  I recently discovered an interesting quality about the number 153.

Ok, I was amazed. I was lead from a comment (below) that this is all shown in the online integer sequence, but it is still great fun.

Pick any old number you want, and multiply by three (or just pick a number that is a multiple of three).
Now take all the digits and cube them and add the cubes together.
For example, if you picked 231, you would add 23 + 3 3 + 1 3 to get 36. 
Yeah, So what you're probably thinking... but take that new number and do the same thing... cube the digits and add them up... Nothing?  Keep going... eventually you get to 153, and then when you  do it again, you get 153 forever.
A digression about notation and terminology
In slightly more formal language, it seems that 153 is the fixed point attractor of any multiple of three under the process of summing the cubes of the digits. This process of an n-digit number, k,  which has a sun of the nth power of its digits equal to k, is variously called a narcissistic number, an Armstrong number, or a perfect digital invariant(often written PDI and PPDI).  So 153 is a Narcissistic number.  The other three digit numbers that are narcisscistic are 370, 371, and 407.  

In his famous A Mathematicians Apology, G, H. Hardy dismisses these numbers with the comment that, "There is nothing in these odd facts which appeals to the mathematician."  

But recreational mathematicians move on undisturbed by Hardy's judgement.  The first use of Narcissistic numbers that I have found, although defined a little more broadly than is now done, was in  Joseph S. Madachy's Mathematics on Vacation in 1966. He described them as a number that is equal to a function of its digits, and included numbers like 145 = 1! + 4! + 5! 

The earliest record of Armstrong Numbers was in a 1971 book,  Computer Science Laboratory Exercises  by F. D. Federighi, ‎Edwin D. Reilly . I suspect much of the popularity of the numbers sprang from being a good programming exercise.

END Digression

The 231 that I used above goes to 36, which goes to 243, then 99, 1458, 702 and 351, which give 153. 

If you started with something like 72, it gets there pretty quickly,  72 →   351 →  153.  

Other numbers take a little longer.  717, for example, takes 13 iterations of the cubing process to get there...but it does.  
And 153 is special... ONLY the multiples of three go there.  Pick another number that's not a multiple of three and run the process and several things might happen, but what won't happen, is going to 153. 

When I began to explore why this happened I could figure out a few things easy enough.  The first realization was that the iterations couldn't just get bigger and bigger and diverge to infinity.  93 is 729 and so any four digit number has to iterate to a value less than 4 * 729 or 2916, and anything with more digits just keeps getting pushed down until it gets under that limit.
So all the numbers in the world have to end up doing something other than just keep getting bigger.
That only leaves a few options.  They might just keep jumping around in some orbit that cycles through several numbers.  This happens with 46 for example.  
After a few iterations you fall into a three cycle. 

46 → 280 → 520 →  133 → 55  → 250 →133

Other numbers also do this, and there are a few different three cycles and  two cycles, but that is sort of an oddity, at least for numbers less than 1000 (still have work to do here).
Most numbers go to a fixed aatractor.  For multiples of three, that seems to always be 153.   For numbers that are not multiples of three, the general fixed points are either 370, or 371.  And they have a modulo three relationship as well.  Numbers that are congruent to 2 Mod3 (they have a remainder of 2 when you divide by three) generally go to 371.  The exceptions are a couple of numbers; 47 , 74, 77,  89 & 98,   which go to 407 (of course 707, 908, 980, etc would also, I counted 30 numbers less than 1000 that go to 407 as a fixed point).  

All the cycles that I have found are numbers that are equivalent to 1 Mod3.  The cycles seem pretty common with less than 1/2 the smaller numbers going to a fixed value of 370 and the occasional few like 1, 10, 100, that have a fixed point at one. Similar to the Happy numbers under the squared sum.  118 is in that group as well, for example.  

The reason for the separation into modulus classes of three is easy enough to explain.  When you cube a number, it's modulus in base three isn't changed.  For example, 4 Mod3 is 1, and 43 = 64 is also equivalent to 1 Mod3.  So the Modulus of a number doesn't change under this process, grouping the results together.  

Now when you add in the fact that there are not really that many of these smaller (less than 3000, say) numbers that can be made with the sum of cubes unless you allow for weird numbers like 11,111 or something to get five.  

I haven't explored much beyond 1000, so I'm not sure if I will come across other cyclic orbits. Or why only the 3n+1 type numbers produce cycles. And I'm not sure what else I may find, but I'm thinking that what I've seen so far makes 153 a very special number. 

After I wrote this back in 2012, a young friend working on his degree at Pitt sent me notes on his reaults when he  took off on the fourth power,  He surmised that all the numbers two through nine went to a fixed value of 13139 and then repeated the cycle (13139 --> 6725 --> 4338 --> 4514 --> 1138 --> 4179 --> 9219 --> 13139...)  I checked this for a couple and it took a few iterations to get there, but the ones I checked did.  That means numbers like 11, 20, 30, .. 101, 111, 200,  and similar numbers if digits sum to 2-9.

He also found that 12 had a fixed point attractor at 8208, ( 12 --> 17 --> 2402 --> 288 --> 8208 --> 8208 --> 8208 ) which means that 17, 21, 71, 102, 107, 170, 201, 210, 224, 242, 288, 422, 701, 710,828, 882 will all go to the same attractor (and of course many more).  

I have now convinced myself that 13, 14, 15, 16, 18, 19,   go to the same cycle as 2 through 9 so now 2 through 9, 11, 13, 14, 15, 16, 18, 19, 20, 22, 23, 24, 25, 26,27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 50, 51, 52, 56, 62, 65, 72, 81, 91 101, 111, 200...
All end in the cycle (13139 --> 6725 --> 4338 --> 4514 --> 1138 --> 4179 --> 9219 --> 13139...

If my calculating does not contain any big errors, so far I have found end behavior for the following numbers under 50:

Two  have fixed attractors at 1 (1,10)

forty (listed above) end at the cycle (13139 --> 6725 --> 4338 --> 4514 --> 1138 --> 4179 --> 9219 --> 13139...

Three end in the fixed point 8208 (12, 17, 21 )  

5 of the numbers are not yet checked. In time I will reduce these. 

A little over a year after I did this, Derek had spent more time working on this and I asked him to guest post his work in progress. 

So here are his notes (I'll add notes of what I have found over the last decade in italics along the way):

Digits to the Fourth Power

By Derek J. Orr, University of Pittsburgh

I was perusing through Pat’s blog here and I noticed two pages that involved summing the squares of digits and summing the cubes of digits. I, then, proposed taking the fourth power of these digits. When I did so, I found some pretty interesting results. Unfortunately, it is time consuming to do each of these numbers manually but I plan to get up to 1,000 and maybe even 10,000 (if motivation and free time permit).

Some numbers that I found went to 1 and are called “happy numbers”. Unfortunately, the only ones I’ve found were 1, 10 and 100 (I went up to 225 so far). However, I am assuming the next smallest happy number is 1,000 just because it’s hard to find one. I wanted to find one and, since I couldn’t, I forced myself to.

I know that a happy number is a number that will eventually reduce to the number 1 and repeat forever. So, the guaranteed happy numbers are 1, 10, 100, 1000, 10000, etc. Thus, I figured out what numbers can get me to these guaranteed happy numbers and, though they aren’t small, I found a few. First, I’ll write out the fourth powers of the single digit numbers: 

Using these values, I found different combinations that could get me to the guaranteed happy numbers. Also, since we have 1 as a possibility, it’s impossible to skip any number I choose. The table below (above) lists a few combinations that I found.

The numbers inside the table represent how many of the digits we need. So, for the first line of the table, the number 1,111,111,111 is a happy number because added together 10 times gets us 10. From this table, the smallest happy number that is not a multiple of 10 (and that is not 1) is 11,123. However, in just two steps, this number can reach 1. What if there are longer iterations that still get us to 1? What if there is a number that can get us 11,123? So, I experimented:

(the other equation I found has 18 digits, so I won’t write it out)

So, we see that there is a new happy number, 22,233,489. Once again, what numbers get to this number? I could do this all day but I won’t, mainly because 22,233,489 can be divided by over 3,388 times. So, this means that the next number has more than 3,388 digits, which is far too many. I’ve assumed that up to now, the numbers will only get bigger. However, what if we tried a different number instead of 11,123? Since the digits are added, we can always change the order. So, 12113, 13112, 21113, 31112, 12131, 13121, 12311, 13211, etc. are also happy numbers. Again, I could experiment on these but I won’t just to save time. I believe it is safe to say that the smallest happy number without a zero (and that is not 1) is 11,123. Since the happy numbers are so hard to find, I looked at different numbers.

One loop that I found was with the number 2,178. I saw it for the first time when I tried the number 127. Here is the iteration for 127.

127 -- 2418 -- 4369 -- 8194 --10914 -- 6819 -- 11954 -- 7444 -- 3169 -- 7939 -- 15604 -- 2178 -- 6514 -- 2178 -- 6514 --…

So, we can see it goes through this 2,178----6,514 loop. Now, I’ve only seen this work for 127, 172, and 217 (so far) but the four- and five-digit numbers above will also bring about this loop.

Also, I found that there seems to be a fixed point where some numbers end up at, similar to what Pat found when cubing the digits. This number was 8,208, and satisfies the condition (ie 8^4 + 2^4 + 0^4 + 8^4 = 8208) . What numbers gave me 8,208? I computed a bit more than the first 200 digits (225 to be exact) and found the numbers 12, 17, 21, 46, 64, 71, 102, 107, 120, 137, 145, 154, 170, 173, 201, 210, and 224 (and of course 288) will get to 8,208 and stay there. Now, past these, it’s obvious that 317, 415, 514, 710, 701, 713, 422, etc. also work. When you cubed the digits, Pat found that you reach the number 153 and it repeats forever. However, Pat found that if you have any multiple of three, you will reach 153. There is a pattern there. I am sadly not able to find any pattern with these; they seem to be random, like the happy numbers when you square the digits (1, 7, 10, 13, 19, 23, 28…etc.).

Other four digit 

Another loop number these could go to is 13,139. With 13,139, there is a loop involved (13139 -- 6725 -- 4338 -- 4514 -- 1138 -- 4179 -- 9219 -- 13139…). This has happened with every number I haven’t mentioned (around 90% of the numbers I’ve tried).(lots of numbers take a very long time to drop into their cycle)  

Going back to 8208, I keep wondering if there is another fixed point. When cubing the digits, there are five numbers that equal the sum of their digits cubed: 1, 153, 370, 371, and 407. When squaring the digits, there is only one number that equals the sum of its digits squared: 1. But, when taking the fourth power, I have only found two numbers that work: 1 and 8,208.  I do wonder if there are more or not; perhaps a good problem for a computer programmer because doing these manually, though possible, takes up a lot of time. (Derek didn't find the other two fixed point attractors, 1634 and 9474)

It would seem that the only sum of four fourth powers that sum to 1634 are the actual digits of 1,6,3 and 4. My reasoning is that there can not be any digit greater than 6, since the fourth powers of 7,8, and 9 all exceed 1634.  No four digits picked from 0, 1, 2, 3, and 4 can have a sum large enough since 1634 exceeds 4 times 4^4 .  So there must be at least one five or one six, but not one of each , nor two sixes.  So we need only to check using one six and three less than 5, or one or two fives with the rest less than five. trying each of these combinations fails.

9474 seems to suffer a similar fate of attracting only the numbers made up of the same four digits.


I will mention one oddity I came across over the years playing with these, the palindrome 11^4 =14641  is the smallest fourth power whose digits sum to a fourth power, 16.

I haven't pursued the behavior of the fifth power of these, but have been told that the fixed point attractors are 1, 4150, 4151, 54748, 92727, 93084, 194979

If you are one of those number curious folks who also happens to be a really good programmer, I would love to receive a list of other fixed points and cycles in third, fourth, and fifth powers of digits. (Or maybe you can send your own guest blog.)

No comments: