A cell looks at its two neighbours. Together they pick the next colour of the middle cell. That is the whole machine.

No global plan. No memory of yesterday beyond the current row. Yet from that tiny contract you get triangles, tunnels, noise that never repeats, and — in at least one case — a system rich enough to compute anything a computer can.

Stephen Wolfram catalogued the 256 elementary rules. A few became famous: Rule 30 for its unpredictable stripe, Rule 90 for Sierpiński triangles, Rule 110 for sitting on the edge of chaos. Below is a small laboratory. Change the rule. Watch the pattern decide what it wants to be.

Experiment

Elementary cellular automata

Pick a rule. Seed a single cell or a random row. Let the grid grow.

Generation
0
Alive cells
1
Binary rule
00011110

Three neighbours, eight cases

Each step, a cell’s next state depends on the triple left · self · right. There are eight possible triples, from 111 down to 000. A rule is just an eight-bit answer: for each triple, live or die.

Rule 30 is binary 00011110. Read it against those eight cases and you have the entire behaviour — including patterns that look random enough to seed early versions of Wolfram’s Mathematica.

Why this matters for software

Most systems we ship are local rules in disguise: a cache invalidation policy, a retry backoff, a state machine in a checkout flow. The global shape — the bug report, the outage, the delightful cascade — emerges from how those neighbours interact.

Cellular automata are a reminder to design the contract between parts carefully. Simple is not the same as predictable. Small rules can still surprise you — which is either a feature or a midnight page, depending on whether you ran the experiment first.

What to try

  • Rule 90 from a single seed: triangles all the way down.
  • Rule 30 from a single seed: structure on the left, turbulence on the right.
  • Rule 110: look for the “particles” that slide through the background — the hint of computation.
  • Rule 184: traffic flow. Dense packs stall; gaps move left like empty road.

When you are done playing, the lesson travels: complexity does not always need a complicated author. Sometimes it only needs a clear neighbourhood and a rule you can write in eight bits.