Thursday, 15 March 2018

The Collatz Conjecture Revisited

Some time ago I posted about the Collatz Conjecture. Today's and yesterday's numbers (25183 and 25182 respectively) are connected to this conjecture. In general, these numbers arise because I'm tracking the number of days that I've been alive, numbering the day I was born (April 3rd 1949) as day zero and counting forward from there.

Both numbers appear in the Online Encyclopaedia of Integer Sequences (OEIS) A224303, whose members comprise numbers n for which number of iterations to reach the largest equals number of iterations to reach 1 from the largest in Collatz (3x+1) trajectory of n.

It's easy enough to set up a spreadsheet that calculates the number of steps to reach 1 and also the number of steps to reach the largest number in the trajectory. This is what I've done in Google Sheets and I've included a screenshot below for 25183.


As can be seen, 116 steps are required to get to the largest number (6,810,136) in the trajectory and then the same number of steps to reach 1, making for 232 steps in all. The steps for the previous number 25182 are the same. Here is a graph of the trajectory:


Looking at the sequence of such numbers, it's apparent that they tend to cluster and often appear in groups of two or more. Here is the list as it is shown in OEIS A224303 (with clusters shown in different colours):

1, 6, 120, 334, 335, 804, 1249, 2008, 2010, 2012, 2013, 6556, 6557, 6558, 6801, 6802, 6803, 7496, 7498, 7500, 7501, 7505, 10219, 22633, 25182, 25183, 27074, 27075, 27864, 27866, 27868, 31838, 31839, 32078, 36630, 36633, 36690, 36691, 36914, 39126, 39344

The second member of the sequence, 6, is given as an example: 6 is in the list because the Collatz trajectory of 6 is {6, 3, 10, 5, 16, 8, 4, 2, 1} and four steps are required to reach the largest number number (16) and four steps are required to reach 1 from 16:

6 --> 3 --> 10 --> 5 --> 16 and then 16 --> 8 --> 4 ---> 2 --> 1

Of course, there's a site on the Internet that will calculate the number of steps and graph the result. It also contains other interesting information relating to the Collatz conjecture. My spreadsheet will graph the trajectory but one has to manually alter the upper bound to get the best looking graph. I haven't figured out a way to adjust it automatically but I'll keep working on it.

Remember that the rule is to divide by 2 if the number is even and multiply by 3 and add 1 if the number is odd (hence the "3x+1 problem" as an alternative moniker). However, the site mentioned also allows one to customise the algorithm, so that for example instead of multiplying by 3, one can multiply by 2.


Interestingly, the trajectory still reaches 1 but it takes 669 steps and it's graph is quite different to that followed using the standard algorithm. Using larger multipliers like 4 doesn't seem to lead to convergence. For example after 10000 iterations using 4 as the multiplier, one gets 6,922,158,704,601,770. I'm not sure what happens with more iterations. The site also has a page for testing Lychrel numbers. I've looked at these sorts of numbers before but hadn't realised that they were called Lychrel numbers. I'd been referring to the algorithm to find them, namely reverse and add. See this post and this post to view.

See also: https://voodooguru23.blogspot.com/2018/03/the-px1-map.html

Read about Terence Tao's latest discovery: https://t.co/h8cMC9QKes

No comments:

Post a Comment