L1VM - 3x1 problem
L1VM - 3x1 problem
I did write a small program for the “3x1” Collatz problem which is still unsolved.
It is like this: start with a natural positive number. If it is odd then multiply by three and add one.
If it is even then divide by two. Stop if the number one is reached.
I did write a program which uses my MPFR big number module.
You can find my program in the L1VM GitHub repo. Here it is: math-3x1
And here is an example output:
l1vm prog/math-3x1 -q -args 100
100, 50, 25, 76, 38, 19, 58, 29, 88, 44, 22, 11, 34, 17, 52, 26, 13, 40, 20, 10, 5, 16, 8, 4, 2, 1
The number is set by the shell argument as seen above!
Have some fun!