Collatz conjecture
From Free net encyclopedia
The Collatz conjecture is an unsolved conjecture in mathematics. It is named after Lothar Collatz, who first proposed it in 1937. The conjecture is also known as the 3n + 1 conjecture, the Ulam conjecture (after Stanislaw Ulam), the Syracuse problem, as the hailstone sequence or hailstone numbers, or as Wondrous numbers as per Gödel, Escher, Bach. It asks whether a certain kind of number sequence always ends in the same way, regardless of the starting number.
Paul Erdős said about the Collatz conjecture: "Mathematics is not yet ready for such problems." He offered $500 for its solution.
Contents |
Statement of the problem
Consider the following operation on an arbitrary positive integer:
- If the number is even, divide it by two.
- If the number is odd, triple it and add one.
For example, if this operation is performed on 3, the result is 10; if it is performed on 28, the result is 14.
In mathematical notation, define the function f as follows:
- <math> f(n) = \begin{cases} n/2 &\mbox{if } n \equiv 0 \\ 3n+1 & \mbox{if } n\equiv 1 \end{cases} \pmod{2}. </math>
Now, form a sequence by performing this operation repeatedly, beginning with any positive integer, and taking the result at each step as the input at the next.
In notation:
- <math> a_i = \begin{cases}n & \mbox{for } i = 0 \\ f(a_{i-1}) & \mbox{for } i > 0\end{cases}</math>
The Collatz conjecture is: This process will eventually reach the number 1, regardless of which positive integer is chosen initially. Or, more formally :
- <math> \forall n \isin \mathbb{N} > 0 \ \exists i \isin \mathbb{N}: (a_0 = n \Rightarrow a_i = 1) </math>
If the conjecture is false, it can only be because there is some starting number which gives rise to a sequence which does not contain 1. Such a sequence might enter a repeating cycle that excludes 1, or increase without bound; no such sequence has been found.
Examples
For instance, starting with n = 6, one gets the sequence 6, 3, 10, 5, 16, 8, 4, 2, 1. (The Collatz conjecture says that this process always reaches 1, no matter what the starting value.)
Starting with n = 11, the sequence takes longer to reach 1: 11, 34, 17, 52, 26, 13, 40, 20, 10, 5, 16, 8, 4, 2, 1.
If the starting value n = 27 is chosen, the sequence takes 112 steps, climbing above 9,000 before descending to 1.
Program to calculate Collatz sequences
A specific Collatz sequence can be easily computed, as is shown by this pseudocode example:
function collatz(n) while n > 1 show n if n is odd set n to 3n + 1 else set n to n / 2 show n
This program halts when the sequence reaches 1, in order to avoid printing an endless cycle of 4, 2, 1. If the Collatz conjecture is true, the program will always halt no matter what positive starting integer is given to it. (See Halting problem for a discussion of the relationship between open-ended computer programs and unsolved mathematics problems.)
Supporting arguments
Although the conjecture has not been proven, most mathematicians who have looked into the problem believe intuitively that the conjecture is true. Here are some reasons for expecting this.
Experimental evidence
The conjecture has been checked by computer for all start values up to 413 × 250 = 4.65 × 1017[1]. While impressive, such computer bounds are of very limited evidential value, with several conjectures having turned out to have exceptionally large-valued counterexamples (eg the Pólya Conjecture).
Probabilistic evidence
If one considers only the odd numbers in the sequence generated by the Collatz process, then one can argue that on average the next odd number should be about 3/4 of the previous one, which suggests that they should decrease in the long run.
Other ways of looking at it
In reverse
There is another approach to prove the following conjecture, which considers the bottom-up method of growing the Collatz graph. The Collatz graph is defined by an inverse relation,
<math> R(n) = \begin{cases} 2n & \mbox{if } n\equiv 0,1 \\ 2n, (2n-1)/3 & \mbox{if } n\equiv -1 \end{cases} \pmod{3}. </math>
So, instead of proving that all natural numbers eventually lead to 1, we can prove that 1 leads to all natural numbers. Also, the inverse relation forms a tree except for the 1-2 loop. Note that the relation being inverted here is (3n + 1) / 2 (see Optimizations below).
As rational numbers
The natural numbers can be converted to rational numbers in a certain way. To get the rational version, find the highest power of two less than or equal to the number, use it as the denominator, and subtract it from the original number for the numerator (527 → 15/512). To get the natural version, add the numerator and denominator (255/256 → 511).
The Collatz conjecture then says that the numerator will eventually equal zero. The Collatz function changes to :
- <math> f(n, d) = \begin{cases} (3n + d + 1)/2d & \mbox{if } 3n + d + 1 < 2d \\
(3n - d + 1)/4d & \mbox{if } 3n + d + 1 \ge 2d \end{cases} </math> (n = numerator; d = denominator)
This works because 3x + 1 = 3(d + n) + 1 = (2d) + (3n + d + 1) = (4d) + (3n - d + 1). Reducing a rational before every operation is required to get x as an odd.
As an abstract machine
Repeated applications of the Collatz function can be represented as an abstract machine that handles strings of bits. The machine will perform the following two steps on any odd number until only one "1" remains :
- Add the original with a "1" appended to the end, to the original (interpreting the string as a binary integer), i.e. <math>3n+1 = (2n+1) + n</math>
- Remove all trailing "0"s.
As iterating a real or complex map
The Collatz map can be looked as a restriction to the integers of the smooth real and complex map
- <math>f(z):=\frac 1 2 z \cos^2\left(\frac \pi 2 z\right)+(3z+1)\sin^2\left(\frac \pi 2 z\right)</math>
(Note that the restriction of <math>f</math> to integer values is not the standard Collatz map defined above, it is an "optimization", see "optimizations" below.)
Iterating the map in the complex plane produces the Collatz fractal.
Image:CobwebCollatz2.PNG
Image:CollatzFractal.png
Optimizations
- If n is a multiple of 4, it can be divided by 4.
- Reason: It is initially even. When it is divided by two, it is still even.
- Example: If n = 20, then the sequence goes
- 20 → 10 → 5 (= 20/4).
- More generally, one can write n as the product of its factors, and change the power of 2 to 20.
- Reason: If the power of 2 of the prime factorization is greater than 0, the number is even, and the following step would produce the same factorization with one less power of 2.
- Example: Instead of
- 15, 46, 23, 70, 35, 106, 53, 160, 80, 40, 20, 10, 5, 16, 8, 4, 2, 1 (17 steps),
- one can go
- 15, 46 (21×23), 23, 70 (21×35), 35, 106 (21×53), 53, 160 (25×5), 5, 16 (24), 1 (11 steps).
- If n is odd, one step can be skipped by finding (3n + 1) / 2
- Reason: an odd times an odd is always an odd (neither contributes a factor of 2 and without a 2, it cannot be even), so 3n is odd. Hence after two steps we have (3n + 1) / 2
- Example: Take n = 35. Then the normal Collatz sequence is
- 35 → 3 × 35 + 1 = 106 → 53 (= (3 × 35 + 1)/2).
- If n ≡ 1 mod 4, then we can replace it repeatedly by (n - 1)/4 to obtain an intermediate k not equivalent to 1 modulo 4, and obtain 3k + 1.
- Reason: n = 4m + 1 is always odd, hence becomes 3n + 1 = 12m + 4 = 4(3m + 1), and by the first optimization, we may drop the 4. Note that if m is odd, 3m + 1 is its Collatz successor, so that to continue the Collatz sequence of n, we can instead continue that of m. Hence we have effectively replaced n by m = (n - 1)/4. We may make this reduction repeatedly, until we obtain a number k which is not equivalent to 1 modulo 4. Finally, we are now looking at 3k + 1, as desired. Note that k may be even, so we cannot necessarily divide by 2.
- Example: When n = 405 the optimized sequence is
- 405 → 101 → 25 → 6 → 19.
- The normal Collatz sequence is:
- 405 → 1216 → 608 → 304 → 152 → 76 → 38 → 19.
The above facts can be used to create a new version of the Collatz function :
- <math> f(n) = \begin{cases}
g(n) & \mbox{if } n \equiv 0 \\ 3 h(n) + 1 & \mbox{if } n \equiv 1 \\ n/2 & \mbox{if } n \equiv 2 \\ \frac{1}{2}(3n+1) & \mbox{if } n \equiv 3 \end{cases} \pmod{4} </math>
where
- <math> g(n) = \begin{cases}
g(\frac{n}{2}) & \mbox{if } n \equiv 0 \\ n & \mbox{if } n \equiv 1 \end{cases} \pmod 2 </math>
- <math> h(n) = \begin{cases}
n & \mbox{if } n \;\not\equiv\; 1 \\ h(\frac{n-1}{4}) & \mbox{if } n \equiv 1 \end{cases} \pmod{4}. </math>
Syracuse Function
If k is an odd integer, then 3k + 1 is even, so we can write 3k + 1 = 2ak′, k' odd. We define a function f from the set <math>I</math> of odd integers into itself, called the Syracuse Function, by taking f (k) = k′.
Some properties of the Syracuse function are:
- f (4k + 1) = f (k) for all k in <math>I</math>.
- For all p ≥ 2 and h odd, f p - 1(2 p h - 1) = 2 3 p - 1h - 1 (see here for the notation).
- For all odd h, f (2h - 1) ≤ (3h - 1)/2
The Syracuse Conjecture is that for all k in <math>I</math>, there exists an integer n ≥ 1 such that f n(k) = 1. Equivalently, let E be the set of odd integers k for which there exists an integer n ≥ 1 such that f n(k) = 1. The problem is to show that E = <math>I</math>. The following is the beginning of an attempt at a proof by induction:
We know that 1, 3, 5, 7, and 9 are in E. Let k be an odd integer greater than 9. Suppose that the odd numbers up to and including k - 2 are in E and let us try to prove that k is in E. As k is odd, k + 1 is even, so we can write k + 1 = 2ph for p ≥ 1, h odd, and k = 2ph-1. Now we have:
- If p = 1, then k = 2h - 1. It is easy to check that f (k) < k , so f (k) ∈ E; hence k ∈ E.
- If p ≥ 2 and h is a multiple of 3, we can write h = 3h′. Let k′ = 2p + 1h′ - 1; we have f (k′) = k , and as k′ < k , k′ is in E; therefore k = f (k′) ∈ E.
- If p ≥ 2 and h is not a multiple of 3 but h ≡ (-1)p mod 4, we can still show that k ∈ E. (Cf.)
The problematic case is that where p ≥ 2 , h not multiple of 3 and h ≡ (-1)p+1 mod 4. Here, if we manage to show that for every odd integer k′, 1 ≤ k′ ≤ k-2 ; 3k′ ∈ E we are done. (Cf.).
See also
References and external links
- Jeffrey C. Lagarias. The 3x + 1 problem: An annotated bibliography.
- Jeffrey C. Lagarias. The 3x + 1 problem and its generalizations, American Mathematical Monthly Volume 92, 1985, pp. 3 - 23.
- Günther J. Wirsching. The Dynamical System Generated by the <math>3n+1</math> Function. Number 1681 in Lecture Notes in Mathematics. Springer-Verlag, 1998.
- An ongoing distributed computing project verifies the Collatz conjecture for larger and larger values.
- Collatz Problem on MathWorld
- Hailstone Patterns discusses different resonators along with using important numbers in the problem (like 6 and 3^5) to discover patterns.da:Collatz-formodningen
de:Collatz-Problem es:Conjetura de Collatz fr:Conjecture de Syracuse ko:콜라츠 추측 it:Congettura di Collatz he:השערת קולץ ja:コラッツの問題 pl:Problem Collatza fi:Collatzin konjektuuri sv:Collatz antagande zh:考拉兹猜想