Pick any positive whole number. If it is even, halve it; if it is odd, multiply it by 3 and add 1. Repeat. The Collatz conjecture claims that you always end up at 1 — and despite its simplicity, nobody has been able to prove it. This calculator runs the sequence for numbers as long as 60 digits, counts the steps, finds the highest point the sequence reaches, and charts the whole hailstone path.
How to use the Collatz sequence calculator
- Type a starting number n of at least 1. Very large values are fine; the calculator uses exact big-integer arithmetic.
- Read the number of steps to reach 1 on the tape, along with the highest value, the step where it occurs, the counts of odd and even steps, and the first step at which the sequence drops below its start.
- Look below for a chart of the value at each step and the complete sequence written out.
The Collatz rule
Some useful terms:
- Total stopping time — the number of steps to reach 1.
- Stopping time — the number of steps until the value first falls below the starting number. If every number had a finite stopping time, the conjecture would follow.
- Peak — the largest value reached along the way.
Worked examples
Starting at 6: 6 → 3 → 10 → 5 → 16 → 8 → 4 → 2 → 1. That is 8 steps, with a peak of 16 at step 4: 2 odd steps (3 → 10 and 5 → 16) and 6 even steps.
Starting at 27: the sequence wanders for 111 steps, made up of 41 odd steps and 70 even steps. It climbs to 9,232 at step 77 — more than 340 times the starting value — and first drops below 27 at step 96.
The contrast between 26 (10 steps) and 27 (111 steps) is typical: neighboring numbers can behave completely differently, which is part of what makes the problem so hard.
Why the problem is hard
On average, an odd step multiplies the value by about 3 and the following even steps divide it by about 4, so the sequence tends to shrink by a factor of roughly 3/4 per round. That heuristic explains why sequences usually come down, but it doesn’t rule out a rare starting number whose path climbs forever or falls into a different loop. Proving that no such number exists requires controlling every case at once.
Mathematicians have made partial progress. In 2019 Terence Tao showed that almost all starting numbers (in a precise density sense) eventually reach values that are almost bounded, which is among the strongest results so far. Computer searches have verified the conjecture for every starting number below 268, about 2.95 × 1020.
Patterns worth exploring
- Powers of 2 fall straight to 1: 2k takes exactly k steps.
- Numbers of the form (4k − 1)/3, such as 5, 21 and 85, jump to a power of 2 in one odd step.
- Long climbers — 27, 97, 871 and 6,171 each set records for the number of steps among smaller starting values.
- Big starting values often finish surprisingly quickly; a 60-digit number typically takes only a few hundred to a couple of thousand steps.
Try a few in the calculator and watch the peak-to-start ratio — it is a quick way to spot the dramatic climbers.
Related tools
Other famous integer sequences live in the Fibonacci calculator. The perfect number checker explores a different ancient open question, and the prime number checker and modulo calculator are handy for testing the odd and even steps by hand.
Frequently asked questions
What is the Collatz conjecture?
It says that if you start with any positive whole number and repeatedly halve it when even or triple it and add 1 when odd, you always reach 1 eventually. It was posed by Lothar Collatz in 1937 and remains unproven.
Has the conjecture been checked by computer?
Yes. Distributed computer searches have confirmed it for every starting number below 2⁶⁸ (about 2.95 × 10²⁰), with no counterexample. A check like that is strong evidence but not a proof, because there are infinitely many numbers left.
Why is it called a hailstone sequence?
The values rise and fall repeatedly, like hailstones tossed up and down inside a storm cloud, before finally dropping to 1. Starting at 27, the sequence climbs as high as 9,232 before coming down.
What happens after the sequence reaches 1?
It would loop forever: 1 → 4 → 2 → 1. That is why the count stops at the first 1. No other loop has ever been found among positive integers.