OEIS/3x+1 Problem: Difference between revisions

From tehowiki
Jump to navigation Jump to search
imported>Gfis
coverage
imported>Gfis
iterating 48,, 96, 192
Line 11: Line 11:
* Gottfried Helms: ''[http://go.helms-net.de/math/collatz/aboutloop/collatzgraphs.htm The Collatz-Problem]''. A view into some 3x+1-trees and a new fractal graphic representation. Univ. Kassel.
* Gottfried Helms: ''[http://go.helms-net.de/math/collatz/aboutloop/collatzgraphs.htm The Collatz-Problem]''. A view into some 3x+1-trees and a new fractal graphic representation. Univ. Kassel.
* Klaus Brennecke: ''[https://de.wikibooks.org/wiki/Collatzfolgen_und_Schachbrett Collatzfolgen und Schachbrett]'', on Wikibooks
* Klaus Brennecke: ''[https://de.wikibooks.org/wiki/Collatzfolgen_und_Schachbrett Collatzfolgen und Schachbrett]'', on Wikibooks
===Collatz Graph===
==Collatz Graph==
When all Collatz sequences are read backwards, they form the '''Collatz graph''' starting with 1, 2, 4, 8 ... . At each node n > 4 in the graph, the path from the root (4) can be continued
When all Collatz sequences are read backwards, they form the '''Collatz graph''' starting with 1, 2, 4, 8 ... . At each node n > 4 in the graph, the path from the root (4) can be continued
* always to n * 2, and  
* always to n * 2, and  
Line 33: Line 33:
|}
|}
When moving towards the root (4) of the graph, d/u operations are used, while δ/µ operations are used to move away from the root.
When moving towards the root (4) of the graph, d/u operations are used, while δ/µ operations are used to move away from the root.
====Detailed Segment Construction====
==Segment Construction==
We will now construct special portions of paths in the Collatz graph which we call ''segments''. They lead away from the root, and they always start with a node x ≡ 4 mod 6. Then they split into a ''northern'' and a ''southern'' subsegment by applying the following operations:
We will now construct special portions of paths in the Collatz graph which we call ''segments''. They lead away from the root, and they always start with a node x ≡ 4 mod 6. Then they split into a ''northern'' and a ''southern'' subsegment by applying the following operations:
* northern: µ µ δ µ δ µ δ ...
* northern: µ µ δ µ δ µ δ ...
Line 39: Line 39:
The two subsegements are built in parallel, and the process is stopped when one of the two new nodes becomes divisible by 3, resp. when a δ operation is not possible.
The two subsegements are built in parallel, and the process is stopped when one of the two new nodes becomes divisible by 3, resp. when a δ operation is not possible.


We will call these segments ''detailled'', and a '''[http://www.teherba.org/fasces/oeis/collatz/rails.html  segment directory]''' can easily be created by a [https://github.com/gfis/fasces/blob/master/oeis/collatz/collatz_rails.pl Perl program]. We will later come back to more properties of detailed segments.  
We will call these segments ''detailed'', and a '''[http://www.teherba.org/fasces/oeis/collatz/rails.html  segment directory]''' can easily be created by a [https://github.com/gfis/fasces/blob/master/oeis/collatz/collatz_rails.pl Perl program]. We will later come back to more properties of detailed segments.  


====Compressed Segments====
===Compressed Segments===
For the moment we will concentrate on the nodes x &#x2261; 4 mod 6 in the detailed segments (which are highlighted in the directory). For each segment we define a row i in an array <nowiki>C[i,j]</nowiki> as follows:
For the moment we will concentrate on the nodes x &#x2261; 4 mod 6 in the detailed segments (which are highlighted in the directory). For each segment we define a row i in an array <nowiki>C[i,j]</nowiki> as follows:
{| class="wikitable" style="text-align:center"
{| class="wikitable" style="text-align:center"
Line 63: Line 63:


If we interprete the <nowiki>C[i,j]</nowiki> as 6*p - 2, we observe that factors 3 in p are successively replaced by factors 2 for increasing j &gt;= 2.
If we interprete the <nowiki>C[i,j]</nowiki> as 6*p - 2, we observe that factors 3 in p are successively replaced by factors 2 for increasing j &gt;= 2.
====Connectivity of Segments====
===Connectivity of Segments===
We now claim that all numbers of the form 6*p - 2 (<nowiki>C[i,1]</nowiki>, the ''left side'' ) occur exactly once in the ''right side'' <nowiki>C[i,j], j &gt; 1</nowiki>.
We now claim that all numbers of the form 6*p - 2 (<nowiki>C[i,1]</nowiki>, the ''left side'' ) occur exactly once in the ''right side'' <nowiki>C[i,j], j &gt; 1</nowiki>.


Line 74: Line 74:
  <nowiki>C[i,5]</nowiki> = 48*(i - 7)/9 + 34    if i &#x2261; 7 mod 9   
  <nowiki>C[i,5]</nowiki> = 48*(i - 7)/9 + 34    if i &#x2261; 7 mod 9   
We thereby cover the highlighted numbers of the form 6*p - 2 &lt; 48:
We thereby cover the highlighted numbers of the form 6*p - 2 &lt; 48:
  '''4'''  '''10'''  '''16'''  22  '''28'''  '''34'''  '''40'''  46
  '''4''', '''10''', '''16''', ''22'', '''28'','  '''34''', '''40''',  ''46''
or - modulo 96 - we miss the numbers:
  22, 46, 70, 94
We continue our observations by:
<nowiki>C[i,6]</nowiki> = 96*(i - 7)/9  + 70  if i &#x2261; 7 mod 9 
<nowiki>C[i,7]</nowiki> = 96*(i - 7)/27 + 22  if i &#x2261; 7 mod 27 
which leaves us - modulo 192 - with
46, 94, 142, 190
Then
<nowiki>C[i,8]</nowiki> = 192*(i - 7)/27  + 46  if i &#x2261; 7  mod 27 
<nowiki>C[i,9]</nowiki> = 192*(i - 61)/81 + 94  if i &#x2261; 61 mod 81

Revision as of 22:33, 18 September 2018

Introduction

Collatz sequences are sequences of non-negative integer numbers with a simple construction rule:

Even elements are halved, and odd elements are multiplied by 3 and then incremented by 1.

Since decades it is unknown whether the final cyle 4 - 2 - 1 is always reached for any start value. This problem is the Collatz conjecture, for which the english Wikipedia states:

It is also known as the 3n + 1 conjecture, the Ulam conjecture (after Stanisław Ulam), Kakutani's problem (after Shizuo Kakutani), the Thwaites conjecture (after Sir Bryan Thwaites), Hasse's algorithm (after Helmut Hasse), or the Syracuse problem; the sequence of numbers involved is referred to as the hailstone sequence or hailstone numbers (because the values are usually subject to multiple descents and ascents like hailstones in a cloud), or as wondrous numbers.

Straightforward visualizations of the Collatz sequences no obvious structure. The sequences for the first dozen of start values are rather short, but the sequence for 27 suddenly has 112 elements.

References

Collatz Graph

When all Collatz sequences are read backwards, they form the Collatz graph starting with 1, 2, 4, 8 ... . At each node n > 4 in the graph, the path from the root (4) can be continued

  • always to n * 2, and
  • sometimes also to (n - 1) / 3.

When n ≡ 0 mod 3, the path will continue with duplications only, since these maintain the divisibility by 3.

The conjecture claims that the graphs contains all numbers, and that - except for the leading cycle 1 - 2 - 4 - 1 - 2 - 4 ... - it has the form of a tree without cylces.

It is convenient to use abbreviations for the elementary operations which transform a node (element, number) x into y:

Name Mnemonic Distance to 4 Neighbour location Condition
x d y down -1 y = x / 2 x ≡ 0 mod 2
x u y up -1 y = 3 * x + 1 (none)
x δ y divide +1 y = (x - 1) / 3 x ≡ 1 mod 3
x µ y multiply +1 y = x * 2 (none)

When moving towards the root (4) of the graph, d/u operations are used, while δ/µ operations are used to move away from the root.

Segment Construction

We will now construct special portions of paths in the Collatz graph which we call segments. They lead away from the root, and they always start with a node x ≡ 4 mod 6. Then they split into a northern and a southern subsegment by applying the following operations:

  • northern: µ µ δ µ δ µ δ ...
  • southern: δ µ µ δ µ δ µ ...

The two subsegements are built in parallel, and the process is stopped when one of the two new nodes becomes divisible by 3, resp. when a δ operation is not possible.

We will call these segments detailed, and a segment directory can easily be created by a Perl program. We will later come back to more properties of detailed segments.

Compressed Segments

For the moment we will concentrate on the nodes x ≡ 4 mod 6 in the detailed segments (which are highlighted in the directory). For each segment we define a row i in an array C[i,j] as follows:

C[i,1] C[i,2] C[i,3] C[i,4] C[i,5] C[i,6] C[i,7] C[i,8] ...
6*i-2 C[i,1] µµ C[i,1] δµµ C[i,2] δµ C[i,3] δµ C[i,4] δµ C[i,5] δµ C[i,6] δµ ...

The row for the compressed segment is filled as long as the corresponding node in the detailed segment is ≡ 4 mod 6.

The segment directories are obviously very structured. The lengths of the compressed segments follow the pattern

4 2 2 4 2 2 m 2 2 4 2 2 4 2 2 n 2 2 4 2 2 ...

with two fixed lengths 2 and 4 and some variable lengths m, n ... > 4. At the starting values 4, 40, 364, 3280, 29524 (OEIS A191681), the segment lengths have high values 4, 8, 12, 16, 20 which did not occur before. Those starting values are (9n+1 - 1) / 2, or 4 * Sum(9i, i=0..n).

If we interprete the C[i,j] as 6*p - 2, we observe that factors 3 in p are successively replaced by factors 2 for increasing j >= 2.

Connectivity of Segments

We now claim that all numbers of the form 6*p - 2 (C[i,1], the left side ) occur exactly once in the right side C[i,j], j > 1.

If this claim were proven, we could begin with the compressed segment for 4, and therein at every node > 4 we "attach" a unique segment with that starting element. Doing this iteratively we could reach all numbers of the form 6*p - 2.

We find the following sequences in the columns of C:

C[i,2] = 24*(i - 1)   + 16
C[i,3] = 24*(i - 1)/3 +  4    if i ≡ 1 mod 3  
C[i,4] = 48*(i - 1)/3 + 10    if i ≡ 1 mod 3  
C[i,5] = 48*(i - 7)/9 + 34    if i ≡ 7 mod 9  

We thereby cover the highlighted numbers of the form 6*p - 2 < 48:

4',  10,  16,  22,  28,'  34,  40,  46

or - modulo 96 - we miss the numbers:

22, 46, 70, 94

We continue our observations by:

C[i,6] = 96*(i - 7)/9  + 70   if i ≡ 7 mod 9  
C[i,7] = 96*(i - 7)/27 + 22   if i ≡ 7 mod 27  

which leaves us - modulo 192 - with

46, 94, 142, 190

Then

C[i,8] = 192*(i - 7)/27  + 46  if i ≡ 7  mod 27  
C[i,9] = 192*(i - 61)/81 + 94  if i ≡ 61 mod 81