Wolfram code

A numbering system for one-dimensional CA rules, introduced by Stephen Wolfram.

For a CA with states and neighborhood size , each cell’s next state is determined by one of possible neighborhood configurations. A rule maps each configuration to a next state, giving possible rules total.

The Wolfram code uniquely identifies each rule by encoding its complete transition function as an -ary number:

where is the next state for configuration .

Algorithm

  1. List all neighborhood configurations in descending numerical order
  2. For each configuration, determine the next state according to the rule
  3. Interpret the sequence of next states as an -ary number, convert to decimal

See elementary CA (1D) for the most common case (, , giving 256 possible rules) with detailed examples and visualizations.