Cellular Tapestry (2D)

Weave any of the 256 elementary cellular automata, design your own rule, flip cells, and measure density, entropy and damage spreading.

Switch to 3D

Presets

Playback

Rule

Pick the rule number or click the eight table entries.

Start and edges

Initial row and boundary condition.

Look

Thread colours (cosmetic).

Layers

Model checks

The science

Elementary cellular automata

A row of cells each holds 0 or 1. Every generation, each cell looks at itself and its two neighbours (left L, centre C, right R), reads the three bits as a number n = 4L + 2C + R (0 to 7) and takes the n-th bit of the rule number as its new state. Eight bits make 256 possible rules. The rule table in the controls shows them; clicking one of the eight buttons flips that entry.

si(t+1) = (Rule >> (4 si−1(t) + 2 si(t) + si+1(t))) & 1

Stacking the generations top to bottom gives the "tapestry". Rule 90 is linear: si(t+1) = si−1 XOR si+1. From a single live cell it draws Pascal's triangle modulo 2 (the Sierpinski triangle), and the number of live cells in generation n is exactly 2popcount(n). Rule 30 is si(t+1) = si−1 XOR (si OR si+1); its centre column looks random and was used as a random-number generator. Rule 110 is complex enough to be Turing-universal (Cook, 2004). Rule 184 moves particles to the right when the cell ahead is free, a simple traffic model that conserves the number of live cells.

What the graphs measure

  • Live-cell fraction is the density of ones in the current row.
  • Block entropy is the Shannon entropy H = −∑ pk log2 pk of the eight three-cell blocks along the row (0 bits = uniform, 3 bits = all blocks equally likely).
  • Damage spreading runs a second copy with one cell flipped and counts how many cells differ. Because a cell sees only its neighbours, a change can spread by at most one cell per generation (the automaton's "light cone"). Chaotic rules fill the cone, regular rules keep the damage small or thin.
  • The bar chart shows how often each of the eight neighbourhood patterns occurs; gold bars are patterns the rule turns into a live cell.

Honest simplifications

  • Finite width: on a ring the pattern wraps around and eventually becomes periodic (at most 2width states); with dead or live edges the boundary changes the pattern near the edges.
  • The Wolfram class labels are the usual textbook classes for a handful of famous rules. For other rules the page only guesses from the block entropy, which is not a proof of the class.
  • Only the 256 elementary rules (two states, radius 1) are modelled. Thread colours and the weave overlay are cosmetic.
What to try
  • Press Rule 90 with One live cell and watch the Sierpinski triangle. The second check confirms the count 2popcount(n).
  • Switch to Rule 30, enable the damage twin and see the red damage fill the light cone: one flipped cell changes everything inside it.
  • Run Rule 184 on a random soup with ring edges and see traffic jams move backwards while the live-cell fraction stays constant.
  • Click the eight rule-table buttons to design your own rule and try to find a new complex rule next to 110.
  • Switch edges to Live edges with rule 30 and compare the left and right sides.
Live-cell fraction against generation
Block entropy against generation
Damage spreading: cells that differ from the twin
How often each neighbourhood pattern occurs