Langton's Ant
On an empty grid the ant wanders in a tangle for 9,977 steps, then locks into a cycle of 104 steps that carries it two cells diagonally, for ever. The page watches for that repeat, marks the step it began on the chart, and lets you run the whole thing backwards to an empty grid, try a dozen-letter rule of your own, or drop in up to four ants and watch them interfere.
In 1986 Chris Langton, who would go on to name the field of artificial life, wrote down about the smallest machine that can still surprise you. An ant stands on a grid of white cells. On a white cell it turns right; on a black cell it turns left. Either way it flips the colour of the cell it is leaving and steps forward. There is nothing else: no randomness, no memory, no goal.
For the first few hundred steps it draws small, tidy, often symmetric shapes. Then the shapes dissolve into a tangle that grows in fits and starts with no visible order at all. And at step 9,977, with no change in the rule and no warning, the ant falls into a cycle of exactly 104 steps that moves it two cells diagonally each time and leaves a perfectly regular ribbon behind it. Mathematicians call it the highway. The rule is completely predictable — you can work out every step by hand — and yet nobody knows a way to get from the rule to the number 9,977 except to run it. It is not even proved that the ant reaches a highway from every finite starting pattern; it simply has, every time anyone has tried.
Give the ant more colours and the story changes. Greg Turk and Jim Propp wrote the rule as a string, one letter per colour: on colour n, turn the way letter n says, then advance the cell to colour n + 1. RL is Langton's ant. RLR grows chaos for as long as anyone has watched. LLRR grows a shape that is mirror-perfect every time the ant returns home facing up — all 4,484 times in the first two hundred thousand steps. LRRRRRLLR fills a square, RRLLLRLLLRRR packs a triangle, and LLRRRLRLRLLR wanders for 29,898 steps before it settles into a wide, convoluted road whose cycle is 1,968 steps long. Turmites go one step further and give the ant an internal state as well; the woven turmite here uses two states to lay down a striped spiral with no chaos in it at all.
The ant shows up wherever people want a clean example of how simple local rules make global behaviour that cannot be shortcut. It is Turing-complete when the grid is allowed a suitable starting pattern, and its highway is a favourite example in the study of emergence and of reversible computation — every step of a rule-string ant can be undone exactly — and of how little it takes for a computation to outrun prediction. Add a second ant and the story changes again: the two classic ants in the two-ant layout here interfere their way onto a highway by step 3,599.
No blueprint, just light — a tree grows itself out of a seed in twelve seconds, flowers, burns gold, drops its leaves, holds the snow, and reaches for any light you paint in the sky.