Rule 90
Add the two neighbours, take the remainder mod 2, and get a fractal
Each cell becomes the sum of its two neighbours, modulo 2. From one starting cell it draws an exact Sierpiński triangle.
How it works
In plain English, before the notation
This rule ignores the cell itself entirely. It looks at the two neighbours on the row above and outputs 1 if exactly one of them is 1. That is addition modulo 2. From a single starting cell it draws an exact Sierpiński triangle, because the same arithmetic that generates the rule also generates Pascal’s triangle.
Draw a Sierpiński triangle
- Open Presets and load “Rule 90 Sierpiński Triangle”, or press 1-Seed.
- Press Play. The nested triangles are exact: every level of the pattern has the same structure as the whole.
- Press 3-Seed to start from three cells instead. The three triangles overlap by exclusive-or, so where two overlap you get a hole.
Starting configurations
Loads straight into the simulatorLoading interactive view…
Where it came from
Rule 90 is the standard example of an additive cellular automaton, and its connection to Pascal’s triangle predates the cellular automaton framing: colouring the odd entries of Pascal’s triangle produces the Sierpiński pattern, a fact known long before 1983. Wolfram’s numbering gave it a name in this setting.
The rule, precisely
What each cell looks at
The two neighbours on the previous row: (x−1, x+1). The centre is ignored.
What a cell can be
Two states per cell on a single row
The update
x(t+1) = (x(t, left) + x(t, right)) mod 2 = x(t, left) XOR x(t, right)
Rule 90 is 01011010 in binary. Because the operation is addition, the rule is linear: running it on the sum of two patterns gives the sum of the two results.
Linearity, and what it buys you
Almost everything interesting about this rule follows from the fact that it is addition:
- From a single cell it produces the Sierpiński triangle, whose fractal dimension is log₂3 ≈ 1.585.
- Patterns superpose: the result for A plus B is the exclusive-or of the result for A and the result for B. Nothing interferes non-linearly.
- Row t of the pattern is exactly row t of Pascal’s triangle with the even numbers set to 0.
- Because it is linear, the state at any time can be computed directly rather than by stepping, unusual among these rules.
Linear, and therefore limited
Linearity is what makes Rule 90 analysable and also what rules out universality: everything it can do is predictable in closed form.
Where the same arithmetic turns up
Addition modulo 2 over a line of bits is the operation behind CRC checksums, the error checks run on files and network data, and behind sequence generators built from linear feedback shift registers (LFSRs). Rule 90 is that operation drawn out in space and time, which is why the same triangular patterns appear in unrelated corners of engineering.
Things to try
- Press 3-Seed and look at where two triangles overlap. Exclusive-or means overlap cancels, so you get a hole rather than a brighter region.
- Use the Seed Row tool to draw an arbitrary pattern on the top row and see the superposition principle directly.
- Compare with Rule 150, which is the same idea but includes the centre cell in the sum.
