Wolfram code
From Wikipedia, the free encyclopedia
Wolfram code is a name often used for the method of enumerating elementary cellular automaton rules used by Stephen Wolfram in his book A New Kind of Science.[1]
The code is based on the observation that a sequence of n cells, each having one of m possible states, may be interpreted as an n-digit m-ary number. The Wolfram code for a particular rule is a number in the range from 0 to mmn−1 (where n is the size of the neighbourhood), usually expressed in decimal notation, which may be calculated as follows:
- List all the mn possible state configurations of the neighbourhood of a given cell.
- Interpreting each configuration as a number as described above, sort them in descending numerical order.
- For each configuration, list the state which the given cell will have, according to this rule, on the next iteration.
- Interpret the resulting list of states again as a number. This number is the Wolfram code.
The Wolfram code does not specify the size (nor shape) of the neighbourhood, nor the number of states — these are assumed to be known from context. When used on their own without such context, the codes are often assumed to refer to the class of two-state one-dimensional cellular automata with a (contiguous) three-cell neighbourhood, which Wolfram extensively investigates in his book. Notable rules in this class include rule 30 and rule 110.
While in a strict sense every Wolfram code in the valid range defines a different rule, some of these rules are isomorphic and usually considered equivalent. For example, rule 110 above is isomorphic with the rules 124, 137 and 193, which can be obtained from the original by left-right reflection and by renumbering the states. By convention, each such isomorphism class is represented by the rule with the lowest code number in it. A disadvantage of the Wolfram notation, and the use of decimal notation in particular, is that it makes such isomorphisms harder to see than some alternative notations. Despite this, it has become the de facto standard way of referring to one-dimensional cellular automata.
[edit] References
- ^ Wolfram, Stephen, A New Kind of Science. Wolfram Media, Inc., May 14, 2002. ISBN 1-57955-008-8