Cellular Automata: Complexity from Simple Rules

simulator beginner ~7 min
Loading simulation...
Rule 30 — chaotic pattern from a single cell

Rule 30 is one of the most studied elementary cellular automata. Starting from a single live cell, it generates a chaotic, seemingly random pattern. Stephen Wolfram proved that it passes statistical tests for randomness, and it has been used as a pseudorandom number generator.

Formula

cell(t+1, i) = rule[ cell(t, i-1) · 4 + cell(t, i) · 2 + cell(t, i+1) ]
Rule number = Σ output(k) · 2^k for k = 0..7

Simple Rules, Complex Behavior

Elementary cellular automata are among the simplest possible computational systems: a row of cells, each either on or off, updating simultaneously based on a local rule that looks at only three cells (left neighbor, self, right neighbor). There are exactly 256 possible rules, numbered 0 through 255 by Stephen Wolfram's naming convention. Despite this extreme simplicity, some of these rules generate patterns of extraordinary complexity.

The Wolfram Classification

Wolfram organized the 256 rules into four behavioral classes. Class 1 rules (e.g., Rule 0, Rule 255) quickly collapse to a uniform state. Class 2 rules (e.g., Rule 4, Rule 108) produce simple periodic patterns — stripes, triangles, repeating blocks. Class 3 rules (e.g., Rule 30, Rule 90) generate chaotic, apparently random patterns. Class 4 rules (e.g., Rule 110) sit at the boundary — producing complex, long-lived structures that interact in intricate ways.

Key Rules to Explore

Rule 30 — The poster child for chaos in cellular automata. From a single cell, it generates a pattern that appears random on the left side but has a regular structure on the right. Wolfram used it as a random number generator.

Rule 90 — Produces the Sierpinski triangle, a famous fractal. This is because Rule 90 is equivalent to XOR of the two neighbors, and the binary rows of Pascal's triangle modulo 2 produce the same pattern.

Rule 110 — Proven Turing complete by Matthew Cook in 2004. This means that, in principle, this simple one-dimensional automaton can perform any computation — a profound result connecting the simplest systems to the most powerful.

Emergence and Computation

Cellular automata demonstrate a fundamental principle: complex global behavior can emerge from simple local rules with no central control. This principle underlies phenomena from crystal growth to traffic jams to the development of biological organisms. The fact that Rule 110 is computationally universal suggests that the capacity for complexity is inherent in even the most minimal systems.

FAQ

What is an elementary cellular automaton?

An elementary cellular automaton is a one-dimensional array of cells, each either 0 or 1, that evolves in discrete time steps. Each cell's next state depends on its current state and its two neighbors — a total of 8 possible input patterns. The 'rule number' (0–255) encodes the output for each pattern as an 8-bit binary number.

What is Rule 30?

Rule 30 (binary: 00011110) is an elementary cellular automaton that produces chaotic, aperiodic behavior from a single initial cell. It generates patterns that pass statistical tests for randomness and has been used in Wolfram's Mathematica as a random number generator.

What is Rule 110?

Rule 110 is proven to be Turing complete — meaning it can perform any computation that a universal computer can. This makes it one of the simplest known systems capable of universal computation, as proven by Matthew Cook in 2004.

What are Wolfram's four classes of cellular automata?

Stephen Wolfram classified cellular automata into four classes: Class 1 (evolve to a uniform state), Class 2 (evolve to periodic structures), Class 3 (produce chaotic, random-looking patterns), and Class 4 (produce complex, localized structures — the 'edge of chaos').

Sources

Embed

<iframe src="https://homo-deus.com/lab/chaos-theory/cellular-automaton/embed" width="100%" height="400" frameborder="0"></iframe>
View source on GitHub