Collatz Orbits, Explained
After reading this you can compute any Collatz hailstone sequence by hand, predict how high it flies before it falls, and understand why thousands of these paths overlaid draw a coral-like tree.
What the Collatz rule is
Pick a positive integer. If it is even, halve it. If it is odd, triple it and add one. Repeat. That is the whole rule, and it is the reason the Collatz conjecture is often called the simplest unsolved problem in mathematics.
Start at 6. It is even, so halve it to 3. Now 3 is odd, so 3 \times 3 + 1 = 10. Then 10 \to 5 \to 16 \to 8 \to 4 \to 2 \to 1. Eight steps, and you land on 1. Once you reach 1 the rule sends you into the loop 1 \to 4 \to 2 \to 1 forever, so the tradition is to stop at 1.
The values along the way rise and fall like a stone tossed inside a hailstorm, carried up by odd steps and dropped by even ones, which is why the lists are called hailstone sequences. Every starting number ever tested reaches 1. Nobody has proved every number must.
When this model is useful, and when it is not
Use the Collatz tool to build intuition about how a deterministic rule can produce wildly irregular trajectories from a one-line definition. It is a clean example of a discrete dynamical system: no randomness, no parameters to tune, yet the output looks chaotic. That makes it a good companion to the Logistic map bifurcation, where a single tuning knob drives order into chaos, and to the Elementary cellular automata, where a tiny rule table generates complex patterns.
Do not use it as evidence about the conjecture itself. Checking that 27, or 10^12, or every number up into the quintillions reaches 1 proves nothing about the numbers you have not checked. A single counterexample, either a number that grows without bound or one that falls into a loop other than 1 \to 4 \to 2 \to 1, would settle the question, and none has appeared. Absence of a counterexample in a finite search is not a proof.
The tree drawing is beautiful, but its shape depends entirely on how much you rotate at each step and which direction odd and even turns take. Two people using different turn angles get different-looking coral from the exact same sequences. The picture is a visualization choice, not a mathematical fact about the numbers.
The rule as a formula
Write the sequence as a_0, a_1, a_2, \ldots where a_0 is your starting number. The update is a piecewise map.
Here a_k is the current value and a_{k+1} is the next one. The total stopping time is the number of steps until you first reach 1. For 6 that stopping time is 8.
A useful shortcut collapses each odd step with the halving that must follow it. An odd number times three plus one is always even, so you can go straight from an odd a_k to (3a_k + 1)/2 in one accelerated step.
This shortcut map T reaches 1 in fewer steps and is the version most researchers analyze. The intuition for why sequences tend to fall: each even step divides by 2, while each accelerated odd step multiplies by about 3/2. Since even numbers appear at least as often as odd ones over the long run, division tends to win, and the sequence drifts down.
A worked example: the number 27
Following 27 all the way to 1
The tool's default starting value is 27, the small number famous for its long, high flight. Apply the plain rule step by step.
27is odd: 3 \times 27 + 1 = 82.82is even: 82 / 2 = 41.41is odd: 3 \times 41 + 1 = 124.124 \to 62 \to 31, two halvings then an odd value.31is odd: 3 \times 31 + 1 = 94, and the climb continues.
The sequence keeps bouncing upward. Its peak is 9232, reached at step 77, more than 340 times the starting value. It finally lands on 1 after 111 plain steps. The chart below traces the whole flight.
Reading the two views
The hailstone plot shows one number's fate over time. Read three things from it: the peak height, the step at which the peak occurs, and the total stopping time. For 27 those are 9232, step 77, and 111. Compare that with 26, which reaches 1 in only 10 steps and never exceeds 40. Neighboring starting values can behave completely differently, which is a hallmark of sensitive, irregular systems.
The tree view stacks the paths of many numbers. Every sequence ends at 1, so all paths share their final segment. Draw the path backwards from 1 and those shared tails merge into a single trunk. Where sequences diverge earlier, the drawing forks. Thousands of overlaid paths turn shared tails into thick trunks and rare, individual detours into thin outer branches, so the density of the drawing tells you how many numbers pass through each segment.
The tree is the same object as the hailstone plot, just organized differently. The plot answers "where does one number go?" The tree answers "which numbers share a route?" Both are drawn from the identical rule.
Explore how turn angle reshapes the coral
The most instructive knob in the tree view is the turn angle. Each step bends the drawing a little: one way on an even step, the other on an odd step. Small angles keep paths nearly straight and the structure looks like tall grass. Large angles curl the paths and the structure tightens into a dense, coral-like blob. The numbers never change; only the geometry does.
Common mistakes
Watch for a handful of errors that trip people up when they compute or interpret these sequences.
- Forgetting the odd step is followed by an even value
- For any odd
n, 3n+1 is always even. If your next step after an odd number is another odd number, you made an arithmetic slip. - Counting stopping time inconsistently
- Decide once whether you count the step that produces
1or the arrival at1, and whether you use the plain rule or the accelerated map T. The plain rule gives27a stopping time of111; the accelerated map gives a smaller count. Both are correct under their own definition. - Treating a big search as a proof
- Verifying billions of starting values reaches
1is strong evidence and nothing more. The conjecture is open precisely because no argument covers all integers at once. - Reading meaning into the coral's exact shape
- The branching form is set by your turn angles and the number of paths drawn. Do not claim the plant "reveals structure in the primes" or similar. It reveals the turn rule you chose.
Related tools to explore next
If the irregular flight of a hailstone sequence interests you, the Lorenz attractor shows the continuous-time cousin: a smooth system whose trajectories never repeat and never diverge. For more branching growth from simple rules, the Phyllotaxis tool grows a sunflower head from a single fixed angle, much as the Collatz tree grows from a single turn rule.
To see complexity emerge from other minimal rules, try Conway's Game of Life for a two-dimensional automaton, the Mandelbrot explorer for infinite fractal detail from one quadratic map, and the Chaos game, where random halfway jumps assemble a precise triangle. The Ulam prime spiral pairs well too, since it also hunts for pattern in the raw integers.
Frequently asked questions
Has anyone proved the Collatz conjecture?
No. It has been checked by computer for every starting value up into the quintillions, and all reach 1, but no proof covers all positive integers. It remains open after more than eighty years.
Why does 27 climb so high when nearby numbers do not?
Because odd steps multiply by about 3 and 27 happens to hit a long run of odd-heavy values before the halvings catch up. It peaks at 9232 after 77 plain steps. Its neighbor 26 reaches 1 in just 10 steps. Small changes in the start can produce very different flights.
What number gives the longest sequence?
It grows as you allow larger starting values. Among numbers under 100, the value 97 takes 118 plain steps and 27 takes 111. There is no known formula for the stopping time; you have to run the rule.
Could a number never reach 1?
That is exactly what the conjecture forbids and what no one can rule out. A counterexample would either grow forever or fall into a repeating loop other than 1 \to 4 \to 2 \to 1. None has ever been found.
Why draw the sequences as a tree instead of a graph?
Because every sequence ends at 1, the paths share their tails. Tracing them backward from 1 merges those shared tails into a trunk and splits earlier divergences into branches, so the drawing shows at a glance which numbers travel together.