The rules of Life
There are four of them. They fit in a tweet. Everything else on this site is a consequence of applying them very, very many times.
The board
Life is played on an infinite square grid. Every square - a cell - is either alive or dead. That is the whole state of the universe: one bit per square, and nothing else. There is no memory of what a cell used to be, no energy, no direction of travel, no identity.
Each cell has eight neighbours: the four it shares an edge with and the four it meets at a corner. This is called the Moore neighbourhood, after Edward F. Moore. The whole of Life is a function of one number: how many of those eight are alive.
The four rules
All cells are updated simultaneously. This matters more than it sounds - every cell looks at the old state of its neighbours, never the partially-updated new one. The transition from one generation to the next is atomic.
- Underpopulation. A live cell with fewer than two live neighbours dies.
- Survival. A live cell with two or three live neighbours survives.
- Overpopulation. A live cell with more than three live neighbours dies.
- Reproduction. A dead cell with exactly three live neighbours becomes alive.
Those four can be compressed to two, which is how Life is normally written:
a cell is born on exactly 3 neighbours and survives
on 2 or 3. Hence the rule string B3/S23. Every other rule you will meet
on this site is a variation on those two digit lists.
Try one generation
Click cells to bring them to life. Turn on the neighbour counts to see the only number that matters, and use Preview to mark which cells are about to be born (green) and which are about to die (red) before you commit to the step.
- Generation
- 0
- Population
- 0
- About to be born
- 0
- About to die
- 0
This grid is bounded - the edges are permanently dead - which is why patterns behave differently here than in the Lab, where the world wraps around.
Why these numbers
Conway did not arrive at B3/S23 by theory. He and his students spent
about eighteen months in 1968 and 1969 testing candidate rules on a Go board,
hunting for a rule with three properties:
- no simple starting pattern should obviously grow without limit;
- some starting patterns should nonetheless appear to grow without limit;
- small starting patterns should be able to run for a long time before anyone could see how they would end.
Rules that were too generous filled the plane with grey mush. Rules that were too
strict killed everything within a few generations. B3/S23 sits
exactly on the boundary - what Chris Langton would later name the
edge of chaos - where structure can persist, move and interact
without either freezing or exploding.
Conway conjectured that no pattern could grow without limit and offered $50 to anyone who could prove him right or wrong. Bill Gosper's team at MIT collected it in November 1970 with the glider gun.
Rule notation
A Life-like rule is written B followed by the neighbour counts that
cause a birth, a slash, then S followed by the counts that allow
survival. Digits may be in any order but are conventionally ascending.
| Rule | Name | What it does |
|---|---|---|
| B3/S23 | Life | The original |
| B36/S23 | HighLife | Adds a self-replicating pattern |
| B2/S | Seeds | Every cell dies every generation; explosive |
| B1357/S1357 | Replicator | Every pattern copies itself |
| B3/S012345678 | Life without Death | Nothing ever dies |
You will occasionally see the older notation 23/3, which lists
survival first and birth second. It means the same thing. The Lab accepts both.
The infinite grid problem
Life is defined on an infinite plane, and no computer has one. Every implementation has to choose a compromise:
- Bounded
- Cells outside the box are permanently dead. Simple and fast, but patterns that reach the edge get mutilated - a glider hitting a wall usually turns into a block.
- Toroidal (wrap-around)
- The left edge is glued to the right, the top to the bottom. Nothing is lost and gliders keep travelling forever - but a pattern can now interfere with itself from the other side. This is what the Lab uses by default.
- Unbounded (hashed)
- Golly's HashLife algorithm memoises repeated regions of space-time and can advance highly regular patterns by billions of generations in seconds. It is genuinely unbounded, at the cost of being useless for chaotic soups.
What happens next
Once you have the rules, the interesting question is what they produce. Almost everything you will see falls into a handful of recurring categories - things that sit still, things that blink, things that move, and things that make more things.