Collatz Conjecture Calculator
Compute the Collatz conjecture online — free and step by step. Show the 3n+1 sequence down to 1, the stopping time, and the peak value reached.
Enter values — get full working
Compute the Collatz sequence — step by step
- 1Step 1 of 4
Pick a starting number
Begin with any positive whole number, e.g. 6.
- 2Step 2 of 4
Check even or odd
If even, divide by 2: 6 → 3. If odd, compute 3n + 1: 3 → 10.
- 3Step 3 of 4
Repeat the steps
Apply the rule again and again: 10 → 5 → 16 → 8 → 4 → 2 → 1.
- 4Step 4 of 4
Count the steps
Stop at 1. The number of steps is the stopping time — for 6 that's 8 steps.
Collatz conjecture — worked examples
The Collatz conjecture — the 3n+1 problem
The Collatz conjecture, also called the 3n+1 problem or Ulam conjecture, is one of the most famous unsolved problems in mathematics. The rule could not be simpler: start with a positive whole number. If it's even, divide by 2; if it's odd, multiply by 3 and add 1. Repeat. The conjecture, stated by Lothar Collatz in 1937, claims that this sequence eventually reaches 1 for every starting number (then settling into the cycle 4 → 2 → 1). Despite its simple statement it remains unproven to this day — though it has been verified by computer for every starting number well beyond 2⁶⁸. Two quantities are of interest: the stopping time (the number of steps to reach 1) and the peak value (the largest value the sequence reaches along the way). Both fluctuate chaotically: 26 takes only 10 steps, yet its neighbour 27 takes 111 and climbs to 9232. The sequence shows how a trivial rule can produce highly complex behaviour — a favourite example of chaos in number theory.
Common misunderstandings
Rule swapped
Confusing stopping time and peak
Expecting it to fall steadily
Starting with 0 or a negative number
Frequently asked questions about the Collatz conjecture
Glossary — key terms explained simply
- Collatz conjecture
- Conjecture that the 3n+1 sequence always ends at 1.
- Stopping time
- Number of steps to reach 1.
- Peak value
- The largest value the sequence reaches along the way.
- 3n+1 rule
- Odd number → multiply by 3 and add 1.
- Iteration
- Repeatedly applying the same rule.
- Cycle 4→2→1
- The final loop every sequence settles into.