itslabtime.com

Information · Computing · Artificial Intelligence Fundamentals

Cellular automata and local rules

Cell automata update the state of each cell based on its neighboring states and predefined rules. Even with simple rules, complex overall patterns can emerge.

Related experiment: Cellular automata →
Cellular automata
Cellular automata: simulation view →

Meaning and mechanism

Each cell in the grid has a finite state, and the next visual state is determined by the current state of its surroundings. Typically, all cells in a single generation are calculated simultaneously from the same previous generation.

Even if the rules are the same, a different pattern emerges when the initial state is different. This changes the long-term changes in the pattern regarding whether or not the grid is connected to 0 on one side or the other.

Relationships and conditions

The three neighbors in a one-dimensional binary model have 8 possible input combinations; the rule number specifies the next state for each. Life’s B3/S23 specifies the neighbor counts for birth and survival.

If you immediately overwrite the cells in sequence, it results in a different outcome compared to simultaneous updating. It does not expand the effect of a finite grid into the general properties of an infinite space.

What to observe in the simulation

One rule can generate different patterns from different initial states.

1D boundaries are zero; Life uses a 16×16 torus. Finite boundaries affect long-term patterns.

Key relationships and symbols

next = (rule >> (4L + 2C + R)) & 1 · Life B3/S23

Symbols and units used in the formulas
SymbolMeaningUnit
L, C, RPrevious states of the left, current, and right cells0 or 1
B3/S23Born in 3 neighborhood, survived in 2·3 neighborhood.Update rule

Worked example

What does a Life glider do after four generations?

One diagonal cell · One rule can generate different patterns from different initial states.

Common misconceptions

  • The name “cellular” does not mean that the model calculates every process in a real biological cell.

Explore this concept through experiments

References

OpenStax · Introduction to Computer Science (English)