Preprint
Article

Solve the 3x+1 Problem by the Multiplication and Division of Binary Numbers

Altmetrics

Downloads

438

Views

205

Comments

2

This version is not peer-reviewed

Submitted:

28 January 2023

Posted:

30 January 2023

Read the latest preprint version here

Alerts
Abstract
The 3x+1 problem asks the following: Suppose we start with a positive integer, and if it is odd then multiply it by 3 and add 1, and if it is even, divide it by 2. Then repeat this process as long as you can. Do you eventually reach the integer 1, no matter what you started with? Collatz conjecture (or 3n+1 problem) has been explored for about 85 years. In this paper, we convert an integer number from decimal to binary number, and convert the Collatz function to binary function, which is multiplication and division of two binary numbers. Finally the iternation of the Collatz function, eventually reach the integer 1, thus we solve the 3x+1 problem completely.
Keywords: 
Subject: Computer Science and Mathematics  -   Algebra and Number Theory

1. Introduction

The 3 x + 1 problem is one of the unsolved problems in mathematics. It is also known as the Collatz conjecture, 3 x + 1 mapping, Ulam conjecture, Kakutani’s problem, Thwaites conjecture, Hasse’s algorithm, or Syracuse problem [1]. Paul Erdos (1913-1996) commented on the intractability of problem 3 n + 1 [2]: "Mathematics is not ready for those problems yet".
The 2 x + 1 problem is that, take any positive integer x, If x is even, divide x by 2. If x is odd, multiply x by 3 and add 1. Repeat this process continuously. The conjecture states that no matter which number you start with, you will always reach 1 eventually.

2. Terminology and Notations

We will use the notations as in [4,7]. we describe a Collatz function as
T ( n ) = 3 n + 1 , if n is odd number , n 2 if n is even number .
Let N denote the set of positive integers. For n N , and k = 0 , 1 , 2 , 3 , , T 0 ( n ) and T k + 1 ( n ) denote n and T ( T k ( n ) , respectively. The 3 x + 1 problem concerns the behavior of the iterates of the Collatz function, for any integer n, there must exist an integer r, so that
T r ( n ) = 1 .

2.1. The Modified Sarkovskii Ordering and Integer Lattice

We remove the last row number to the first column, get an integer lattice[6] of the modified Sarkovskii ordering as
1 , 3 , 5 , 7 , 9 , 11 , 13 , 15 , 17 , 19 , 2 , 2 · 3 , 2 · 5 , 2 · 7 , 2 · 9 , 2 · 11 , 2 · 13 , 2 · 15 , 2 · 17 , 2 · 19 , 2 2 , 2 2 · 3 , 2 2 · 5 , 2 2 · 7 , 2 2 · 9 , 2 2 · 11 , 2 2 · 13 , 2 2 · 15 , 2 2 · 17 , 2 2 · 19 , 2 3 , 2 3 · 3 , 2 3 · 5 , 2 3 · 7 , 2 3 · 9 , 2 3 · 11 , 2 3 · 13 , 2 3 · 15 , 2 3 · 17 , 2 3 · 19 , 2 4 , 2 4 · 3 , 2 4 · 5 , 2 4 · 7 , 2 4 · 9 , 2 4 · 11 , 2 4 · 13 , 2 4 · 15 , 2 4 · 17 , 2 4 · 19 ,
In the first row, its are odd number from left to right, that are 1 , 3 , 5 , 7 , 9 , 11 , 13 , , from the second row, each number is multiplying each number in its previous row by 2, and so on.

2.2. The Algebraic Formula and Collatz Graph

If we draw a line segment of arrow between two digits in the lattice of integer in the modified Sarkovskii ordering, those are the original value x, and its value of Collatz function T ( x ) , and connect T ( x ) to T 2 ( x ) , and so on T 2 ( x ) to T 3 ( x ) , , thus we get a graph, which can be called as Collatz graph. For different integer m, n, besides 1, 4, 2, there is not other common vertices in their Collatz graphs. Using the Collatz function T ( x ) , We obtain an algebraic formula of 1 2 4 , 3 2 7 , 3 2 2 9 , , 3 m 2 r · x . Here r is the number of perpendicular segments, m is the oblique segments in the Collatz graph,
T m + r ( n ) = T ( m , r , n ) = 1 2 4 + 3 2 7 + 3 2 2 9 + + 3 m 2 r · x = 1 ,
For example, n = 7 , 7 22 11 34 17 52 26 13 40 20 10 5 16 8 4 2 1 , the algebraic formula is
T 16 ( 7 ) = T ( 5 , 11 , 7 ) = 1 2 4 + 3 2 7 + 3 2 2 9 + 3 3 2 10 + 3 4 2 11 + 3 5 2 11 · 7 = 1 ,
and the Collatz graph is Figure 1.
And n = 36 , the algebraic formula is
T 21 ( 36 ) = T ( 6 , 15 , 36 ) = 1 2 4 + 3 2 7 + 3 2 2 9 + 3 3 2 10 + 3 4 2 11 + 3 5 2 13 + 3 6 2 15 · 36 = 1
and the Collatz graph is Figure 2.

3. Numerical Example

We propose the following algebraic formulas,
T 20 ( 18 ) = T ( 6 , 14 , 18 ) = 1 2 4 + 3 2 7 + 3 2 2 9 + 3 3 2 10 + 3 4 2 11 + 3 5 2 13 + 3 6 2 14 · 18 = 1 ,
T 15 ( 23 ) = T ( 4 , 11 , 23 ) = 1 2 4 + 3 2 9 + 3 2 2 10 + 3 3 2 11 + 3 4 2 11 · 23 = 1 ,
T 17 ( 15 ) = T ( 5 , 12 , 15 ) = 1 2 4 + 3 2 9 + 3 2 2 10 + 3 3 2 11 + 3 4 2 12 + 3 5 2 12 · 15 = 1 ,
T 12 ( 17 ) = T ( 3 , 9 , 17 ) = 1 2 4 + 3 2 7 + 3 2 2 9 + 3 3 2 9 · 17 = 1 ,
  19 ( 61 ) = T ( 5 , 14 , 61 ) = 1 2 4 + 3 2 9 + 3 2 2 10 + 3 3 2 11 + 3 4 2 14 + 3 5 2 14 · 61 = 1 .
T 16 ( 397 ) = T ( 5 , 11 , 397 ) = 1 2 4 + 3 2 7 + 3 2 2 9 + 3 3 2 10 + 3 4 2 11 + 3 5 2 17 + 3 6 2 20 + 3 7 2 20 · 397 = 1 ,

4. Convert the Integer Number from Decimal to Binary

Be inspired by the above, we use binary to describe the Collatz function (1) an the follows. We denote binary number which is a string of 0s and 1s, n = ( 1 × ) 2 , × is 1 or 0, 3 = ( 11 ) 2 ,
T ( n ) = T ( ( 1 × ) 2 ) = ( 11 ) 2 · ( 1 1 ) 2 + 1 , if n is odd number , ( 1 0 ) 2 ( 10 ) 2 , if n is even number .
T ( n ) = T ( ( 1 × ) 2 ) = ( 1 × × × × 0 0 ) 2 , if n is odd number , ( 1 × × × 1 ) 2 , if n is even number .
Namely, when n is odd number, we multiple it with ( 11 ) 2 and add 1 to the end of the binary number, we give an example, T ( 97 ) = T ( 1100001 ) in Figure 3 in the follows. When n is even number, the division is equal to delete zeros at the end in binary number. We give the iteration of the Collatz function for 7, 97 in binary as the following two tables.
Example 1.
For positive integer 1, we manipulate the iteration of the Collatz function in becimal and binary numbers,
Preprints 67978 i001
Example 2.
For 7=(111)   2 , we manipulate the iteration of the Collatz function in becimal and binary numbers,
Preprints 67978 i002
Example 3.
For 97=(100100)   2 , we manipulate the iteration of the Collatz function in binary as the following table,
Preprints 67978 i003
We can rewrite the Collatz conjecture in binary as the follows, it becomes an easy problem.
Fact 4
For any positive integer, under the Collatz function, the sequence of integer number in binary eventually must reach the integer 1.
Proof. 
For an binary number of odd integer, when we add 1 to the end, and add the shifted binary number one place to the left, finally, the result number must with at least one zero at the end, we delete this zeros. Thus repeat this process as long as we can, eventually we must reach 1.
Remark 5
We can say that 3 x + 1 problem is an converse proposition of period three implies chaos [4] and an example.

References

  1. Jeffrey, C. Lagarias. The 3x + 1 Problem and Its Generalizations. American Mathematical Monthly 1985, 92, 3–23. [Google Scholar]
  2. Jeffrey, C. Lagarias. The 3x+1 Problem: An Overview. arXiv:2111.02635.
  3. Stefan, P. A Theorem of Sarkovshii on the existence of periodic orbits of continuous endomorphisms of the real line. Commun. math. Phys 1977, 54, 237–248. [Google Scholar] [CrossRef]
  4. Li, T.; Yorke, J.A. Period three implies chaos. Am. Mat. Monthly 1975, 82, 985–992. [Google Scholar] [CrossRef]
  5. TERENCE TAO, Almost all orbits of the Collatz map attain almost bounded values. arXiv:1909.03562v5, 2022, arXiv:1909.03562v5, 2022,1,151, 15.
  6. Feng, J.; Wang, X.; Gao, X.; Pan, Z. The research and progress of the enumeration of lattice paths. Frontiers of Mathematics in China 2022, 17, 747–766. [Google Scholar] [CrossRef]
  7. Alf, Kimms. The structure of the 3x+1 problem. Electronic Journal of Graph Theory and Applications 2021, 9, 157–174. [Google Scholar]
Figure 1. The Collatz graph of T 16 ( 7 ) = T ( 5 , 11 , 7 ) = 1 in the lattice of integers in the modified Sarkovskii ordering and the algebraic formula.
Figure 1. The Collatz graph of T 16 ( 7 ) = T ( 5 , 11 , 7 ) = 1 in the lattice of integers in the modified Sarkovskii ordering and the algebraic formula.
Preprints 67978 g001
Figure 2. The Collatz graph of T 21 ( 36 ) = T ( 6 , 15 , 36 ) = 1 in the lattice of integers in the modified Sarkovskii ordering and the algebraic formula.
Figure 2. The Collatz graph of T 21 ( 36 ) = T ( 6 , 15 , 36 ) = 1 in the lattice of integers in the modified Sarkovskii ordering and the algebraic formula.
Preprints 67978 g002
Figure 3. For the Collatz function T ( 97 ) in binary, the first step is the multiplication in left, the second step is division in right bottom.
Figure 3. For the Collatz function T ( 97 ) in binary, the first step is the multiplication in left, the second step is division in right bottom.
Preprints 67978 g003
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.
Copyright: This open access article is published under a Creative Commons CC BY 4.0 license, which permit the free download, distribution, and reuse, provided that the author and preprint are cited in any reuse.
Prerpints.org logo

Preprints.org is a free preprint server supported by MDPI in Basel, Switzerland.

Subscribe

© 2024 MDPI (Basel, Switzerland) unless otherwise stated