Collatz conjecture


The Collatz conjecture is one of the most famous unsolved problems in mathematics. The conjecture asks whether repeating two simple arithmetic operations will eventually transform every positive integer into 1. It concerns sequences of integers in which each term is obtained from the previous term as follows: if a term is even, the next term is one half of it. If a term is odd, the next term is 3 times the previous term plus 1. The conjecture is that these sequences always reach 1, no matter which positive integer is chosen to start the sequence. The conjecture has been shown to hold for all positive integers up to, but no general proof has been found.
It is named after the mathematician Lothar Collatz, who introduced the idea in 1937, two years after receiving his doctorate. The sequence of numbers involved is sometimes referred to as the hailstone sequence, hailstone numbers or hailstone numerals, or as wondrous numbers.
Paul Erdős said about the Collatz conjecture: "Mathematics may not be ready for such problems." Jeffrey Lagarias stated in 2010 that the Collatz conjecture "is an extraordinarily difficult problem, completely out of reach of present day mathematics". However, though the Collatz conjecture itself remains open, efforts to solve the problem have led to new techniques and many partial results.

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.
In modular arithmetic notation, define the function as follows:
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:
.
The Collatz conjecture is: This process will eventually reach the number 1, regardless of which positive integer is chosen initially. That is, for each, there is some with.
If the conjecture is false, it can only be because there is some starting number which gives rise to a sequence that does not contain 1. Such a sequence would either enter a repeating cycle that excludes 1, or increase without bound. No such sequence has been found.
The smallest such that is called the stopping time of. Similarly, the smallest such that is called the total stopping time of. If one of the indexes or does not exist, we say that the stopping time or the total stopping time, respectively, is infinite.
The Collatz conjecture asserts that the total stopping time of every is finite. It is also equivalent to saying that every has a finite stopping time.
Since is even whenever is odd, one may instead use the "shortcut" form of the Collatz function:
This definition yields smaller values for the stopping time and total stopping time without changing the overall dynamics of the process.

Empirical data

For instance, starting with and applying the function without "shortcut", one gets the sequence.
The number takes longer to reach 1:.
The sequence for, listed and graphed below, takes 111 steps, climbing as high as 9232 before descending to 1.
Numbers with a total stopping time longer than that of any smaller starting value form a sequence beginning with:
The starting values whose maximum trajectory point is greater than that of any smaller starting value are as follows:
Number of steps for to reach 1 are
The starting value having the largest total stopping time while being
These numbers are the lowest ones with the indicated step count, but not necessarily the only ones below the given limit. As an example, has 1132 steps, as does.
The starting values having the smallest total stopping time with respect to their number of digits are the powers of two, since is halved times to reach 1, and it is never increased.

Visualizations

Supporting arguments

Although the conjecture has not been proven, most mathematicians who have looked into the problem think the conjecture is true because experimental evidence and heuristic arguments support it.

Experimental evidence

The conjecture has been checked by computer for all starting values up to 271 ≈. All values tested so far converge to 1.
This computer evidence is still not rigorous proof that the conjecture is true for all starting values, as counterexamples may be found when considering very large positive integers, as in the case of the disproven Pólya conjecture and Mertens conjecture.
However, such verifications may have other implications. Certain constraints on any non-trivial cycle, such as lower bounds on the length of the cycle, can be proven based on the value of the lowest term in the cycle. Therefore, computer searches to rule out cycles that have a small lowest term can strengthen these constraints.

A probabilistic heuristic

If one considers only the odd numbers in the sequence generated by the Collatz process, then each odd number is on average of the previous one. This yields a heuristic argument that every Hailstone sequence should decrease in the long run, although this is not evidence against other cycles, only against divergence. The argument is not a proof, however, because it assumes that Hailstone sequences are assembled from uncorrelated probabilistic events.

Stopping times

As proven by Riho Terras, almost every positive integer has a finite stopping time. In other words, almost every Collatz sequence reaches a point that is strictly below its initial value. The proof is based on the distribution of [|parity vectors] and uses the central limit theorem.
In 2019, Terence Tao improved this result by showing, using logarithmic density, that almost all Collatz orbits descend below any given function of the starting point, provided that this function diverges to infinity, no matter how slowly. Responding to this work, Quanta Magazine wrote that Tao "came away with one of the most significant results on the Collatz conjecture in decades".

Lower bounds

In a computer-aided proof, Krasikov and Lagarias showed that the number of integers in the interval that eventually reach 1 is at least equal to for all sufficiently large.

Cycles

In this part, consider the shortcut form of the Collatz function
A cycle is a sequence of distinct positive integers where,,..., and.
The only known cycle is of period 2, called the trivial cycle.

Cycle length

As of 2025, the best known bound on cycle length is . In 1993, Eliahou proved that the period of any non-trivial cycle is of the form
where, and are non-negative integers, and. This result is based on the simple continued fraction expansion of.

-cycles

A -cycle is a cycle that can be partitioned into contiguous subsequences, each consisting of an increasing sequence of odd numbers, followed by a decreasing sequence of even numbers. For instance, if the cycle consists of a single increasing sequence of odd numbers followed by a decreasing sequence of even numbers, it is called a 1-cycle.
Steiner proved that there is no 1-cycle other than the trivial. Simons used Steiner's method to prove that there is no 2-cycle. Simons and de Weger extended this proof up to 68-cycles; there is no -cycle up to. Hercher extended the method further and proved that there exists no k-cycle with. As exhaustive computer searches continue, larger values may be ruled out. To state the argument more intuitively; we do not have to search for cycles that have less than 92 subsequences, where each subsequence consists of consecutive ups followed by consecutive downs.

Other formulations of the conjecture

In reverse

There is another approach to prove the conjecture, which considers the bottom-up
method of growing the so-called Collatz graph. The Collatz graph is a graph defined by the inverse relation
So, instead of proving that all positive integers eventually lead to 1, we can try to prove that 1 leads backwards to all positive integers. For any integer, if and only if. Equivalently, if and only if. Conjecturally, this inverse relation forms a tree for positive integers except for the 1–2–4 loop.
When the relation of the function is replaced by the common substitute "shortcut" relation, the Collatz graph is defined by the inverse relation,
For any integer, if and only if. Equivalently, if and only if. Conjecturally, this inverse relation forms a tree for positive integers except for a 1–2 loop.
Alternatively, replace the with where and is the highest power of 2 that divides . The resulting function maps from odd numbers to odd numbers. Now suppose that for some odd number, applying this operation times yields the number 1. Then in binary, the number can be written as the concatenation of strings where each is a finite and contiguous extract from the representation of. The representation of therefore holds the repetends of, where each repetend is optionally rotated and then replicated up to a finite number of bits. It is only in binary that this occurs. Conjecturally, every binary string that ends with a '1' can be reached by a representation of this form.

As an abstract machine that computes in base two

Repeated applications of the Collatz function can be represented as an abstract machine that handles strings of bits. The machine will perform the following three steps on any odd number until only one remains:
  1. Append to the end of the number in binary ;
  2. Add this to the original number by binary addition ;
  3. Remove all trailing s.

    Example

The starting number 7 is written in base two as. The resulting Collatz sequence is:

111
1111
10110
10111
100010
100011
110100
11011
101000
1011
10000