Post Reply 
(12C) 3n + 1 conjecture
07-07-2018, 07:36 AM
Post: #9
RE: (12C) 3n + 1 conjecture
(07-06-2018 09:50 PM)Joe Horn Wrote:  I'm not familiar with programing the 12C, but perhaps the following "trick" can be used to shrink the program even further. The following sequence changes any even X to X/2, and any odd X to (3X+1)/2, which is valid for this conjecture since 3*odd+1 is always an even number.

OK, but if you want to show the complete sequence (both x/2 and 3x+1) two more steps are required:

Code:
01 ENTER
02 ENTER
03 2
04 /
05 ENTER
06 FRAC
07 x=0?
08 GTO 12
09 +
10 +
11 ENTER
12 +

(07-06-2018 09:50 PM)Joe Horn Wrote:  Putting this into a loop which pauses at each iteration, and exits when it reaches 1, is left as an exercise for the programmer.

Adding this makes the program as long as Thomas' and my version. ;-)

Dieter
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
(12C) 3n + 1 conjecture - Gamo - 07-06-2018, 10:16 AM
RE: (12C) 3n + 1 conjecture - Thomas Klemm - 07-06-2018, 06:59 PM
RE: (12C) 3n + 1 conjecture - Dieter - 07-06-2018, 07:25 PM
RE: (12C) 3n + 1 conjecture - Dieter - 07-06-2018, 07:13 PM
RE: (12C) 3n + 1 conjecture - Joe Horn - 07-06-2018, 09:50 PM
RE: (12C) 3n + 1 conjecture - Dieter - 07-07-2018 07:36 AM
RE: (12C) 3n + 1 conjecture - Thomas Klemm - 07-06-2018, 10:31 PM
RE: (12C) 3n + 1 conjecture - Joe Horn - 07-07-2018, 03:10 AM
RE: (12C) 3n + 1 conjecture - Gamo - 07-07-2018, 01:51 AM
RE: (12C) 3n + 1 conjecture - Thomas Klemm - 07-07-2018, 08:37 AM
RE: (12C) 3n + 1 conjecture - Joe Horn - 07-07-2018, 02:24 PM
RE: (12C) 3n + 1 conjecture - Dieter - 07-07-2018, 04:57 PM
RE: (12C) 3n + 1 conjecture - Joe Horn - 07-07-2018, 07:04 PM



User(s) browsing this thread: 1 Guest(s)