Cellular Automaton: Math Comes Alive

The Desire to Mimic Creation

From golems to Frankenstein, we try to create, to bring into existence, to model life with something that is beautiful, fluid, and independent. Our cellular automaton does just this: a beautiful mathematical system with a visual output that creates on its own.

These systems exist within boundaries we define. In this case, we will look at four elements: the cells themselves, the states they can hold, the neighborhood they live in, and the rule that governs how they change.

Though the idea seems simple, the question is rooted in a classic problem. Can a machine build a copy of itself? In the 1940s, Stanislaw Ulam invented the cellular automaton framework, and John von Neumann used it to design a theoretical 29-state automaton that could, in principle, self-replicate. They had no way to test it; the configuration would have required millions of cells, but the concept held: self-replication was possible if the rules were followed correctly and systematically.

In the 1970s, Conway’s Game of Life took the idea further, deliberately seeking the edge between order and chaos. From just two states and a handful of rules, it produced a system capable of universal computation, a Turing machine hiding inside a deceptively simple grid.

Penrose Cyclic Automaton
Greenberg–Hastings waves on an aperiodic substrate
generation 0

A Dynamic System

And like life, our cellular automaton system is unpredictable until put into motion. It is unlike simple math, where if you know the equation, you know the output; in our natural system, the final product is unknowable until it occurs. A bouncing ball, a falling weight, and wheels rolling down a ramp are calculable, but natural phenomena like bubbles popping in soda or eddies in water cannot be predicted until the system runs.

This leads to the second point: adjust any one of those four elements, and the outcome changes dramatically. Small shifts snowball, tipping the system toward order or chaos.

It is this unpredictability that drives our tool. Until we run it, we do not know what will happen, even though math underlies it.

We start with a grid of cells, all assigned a particular color, and then, life! We start the math in motion. Each cell can only change based on its neighbors’ colors, and at first everything seems frozen in stasis.

As the turns iterate, small color changes begin to occur, most fizzle, but a few begin to create spirals, and then, like a flash, those spirals beget other spirals, and the field is alive with new forms.

How do these spirals move? In our system, they exist in three states.

In the first, beginning state, the cell is quiet, ready to be triggered; it has not yet turned a different color.

In the middle state, the cell is firing and can trigger its neighbors to change.

And finally, in the refractory state, the cell has fired and is recovering, temporarily immune to triggering.

As it turns out, this mirrors the way many natural systems work: the firing of heart muscles, the excitability of nerve impulses. These systems share the same logic: quiet until stimulated, fire, recover, then ready again. The wave moving across your screen is the same mathematics crossing your own heart with every beat.

One last note on what you are seeing. The grid beneath the cells is not a simple square or hexagonal grid but a [Penrose tiling], a pattern that never repeats yet locks together perfectly. Its geometry shapes how the waves travel, and gives the spirals places to anchor themselves.

Using the Cellular Automaton

What you see

A field of colored rhombs in two shapes — fatter ones (72°/108°) and slimmer ones (36°/144°). Together they tile the entire disc without ever falling into a repeating pattern. Colors cycle through the spectrum as each rhomb advances through its states. Wave-fronts ripple across the field; spiral cores form where waves meet at angles and pin themselves to the geometry.

The controls

States. How many color values does each rhomb cycle through before returning to rest? More states means wider color bands and longer wavelengths — the waves look slower and more saturated. Fewer states mean tighter, faster bands. The default of 16 is a good starting point; try 8 for compressed energy, 28 for a slower meditative drift.

Tempo. Speed of the simulation in generations per second. Slow it down to watch a single wavefront travel; speed it up to see large-scale behavior emerge.

The four buttons

Pause / Resume. Freezes the simulation. Useful for looking carefully at a particular moment or for taking a screenshot.

Step. Advances exactly one generation. Most useful when paused, it lets you watch the rules operate one move at a time.

Reseed. Throws fresh random noise across the existing tiling and resets the generation counter. The tiling stays the same; only the cell states change. Each reseed produces a different pattern even on the same tiling because the initial noise determines where wave cores nucleate.

New Tiling. Generates a completely new Penrose P3 tiling using random pentagrid offsets, then reseeds. Each tiling has its own personality — some have regions dominated by fat rhombs (waves flow cleanly through them), others have veins of slim rhombs that act as wave guides.

What to watch for

The first thirty seconds after a reseed is the most interesting phase. The field begins as colored noise. Within ten or twenty generations, local clumps of synchronized color form — the “debris” phase. Then somewhere between generation 50 and 200, the first stable wave cores appear and start consuming the surrounding debris. Once the field is mostly waves, it stays in dynamic equilibrium more or less forever.

Try to find a wave core and watch it. It will be a tight spiral, usually pinned to a vertex where several rhombs meet in a near-five-fold arrangement. The arms of the spiral rotate continuously; they do not move outward like ripples on a pond.

Watch what happens when two wavefronts collide. They annihilate, leaving a trail of refractory cells that must finish their cycle before new waves can cross.

Generate a few new tilings and notice how the wave patterns differ between them. The substrate’s local geometry determines where spirals can form. The same rule applied to a new tiling yields a new form.