An ant sits on a grid. Each cell has a colour. The ant reads its cell, turns left or right as the rule says, bumps the colour up by one, and steps forward. That is the whole program.
A rule is a string like RL: the letter at position k is the turn taken on colour k. I ran every rule up to 12 letters (4,094 of them, after dropping mirror images) for three million steps each, looking for the moment chaos gives up and the ant starts building a highway, a repeating pattern that marches off forever.
The simulator here runs in your browser. Type any rule, or pick a preset.
of 4,094 rules built a highway within 3,000,000 steps. That is 11%. Another 279 got stuck in a tiny loop.
steps of chaos before RRRLRLLLRLRL finally started its highway. The latest onset in the census.
steps per repeat for the longest highway found, by RRRLLLRRLL. Classic Langton's ant repeats every 104.
highways travel at an odd angle, like a chess knight. For example RLRRLRLRLRRR moves 3 across and 11 down per cycle. Only 3 go straight along an axis. The other 441 are exact diagonals.
different rules produce the identical highway (period 18, starting at step 38). They all begin RRLRRL, and the ant escapes using only the first six colours, so the letters after that never matter.
distinct highways in total. Many rules are twins: a doubled rule like RLRL behaves exactly like RL.
| Rule length | Rules | Highway | No highway yet | Stuck | Share |
|---|
The share of rules that find a highway stays roughly flat around 10% as rules get longer, but absolute numbers climb. Note that many “no highway yet” rules may simply be slow: onsets past two million steps showed up often enough that a longer run would surely catch more.
Rendered offline from the C survey. Click a plate to load that rule into the simulator above; the slow ones need the “Very fast” setting and still won't reach their highway in a small browser grid.
A C program simulated each rule on a 4096 × 4096 grid starting from all colour 0, for up to 3,000,000 steps or until the ant reached the edge. It recorded every position, then searched the tail for a period p where the ant's displacement over p steps is constant and non-zero, and walked backwards to find where that periodicity starts. As a check, it recovers the textbook result for RL: a 104-step highway starting near step 10,000. The whole survey took 90 seconds on a laptop.
Rules starting with L were skipped because they are mirror images of rules starting with R. “Stuck” means the ant's path never spanned more than 50 cells.