Jason Cawley
Wolfram Science Group
Phoenix, AZ USA
Registered: Aug 2003
Posts: 712 |
totalistic 3 color, range 1/2 CAs
An email asked about this managable rule space. It is interesting, with a few examples of behavior as complicated as seen in any rule class, along with many cases of nesting or particle-like class 2 behavior.
First to explain the rules and the size of the rule space. Range 1/2 means a cell and its immediate left-hand neighbor matter, while the cell on the right does not. This means the pattern can grow only to the right, at a maximum speed of one cell per step.
Totalistic means that all patterns with the same total of the 2 cells must behave the same. Since each can be {0, 1, 2}, the total ranges from 0 to 4, thus there are 5 distinguishable patterns on the prior step. Since each of these could go to any of {0, 1, 2} again, the total number of rules is 3 ^ 5 = 243. Making it slightly smaller than the ECA rule space. There are also symmetries of color rotation which reduce the effective rule space size somewhat further.
The rule form needed to specify one of these in Mathematica is e.g. -
CellularAutomaton[{38, {3, 1}, 1/2}, {{1}, 0}, {50, All}]
- where 38 is the rule number, {3,1} says 3 color totalistic, and 1/2 specifies the range. The {{1}, 0} part says start with an initial condition of a single "1" on a background of "0"s, and the {50, All} says run this rule-init pair for 50 steps and show the results at all space locations that might have been reached in that number of steps.
The two most interesting behaviors are seen in rules 38 and 61. Because of color rotations, there are other rules with the same basic behaviors. You can see the basic behaviors from simple and random initial conditions by asking for -
rules = {38, 61}; inits = {{{1}, 0}, RandomInteger[{0, 2}, 200]}; Grid[Table[ ArrayPlot[ CellularAutomaton[{rules[[j]], {3, 1}, 1/2}, inits[[i]], {200, All}], ColorRules -> {2 -> Black, 1 -> Red, 0 -> Yellow}, PixelConstrained -> 2, PlotLabel -> "Rule " <> ToString[rules[[j]]]], {j, 2}, {i, 2}]]
Clear class 3 randomness in the random initial case. That in an interior region with some simpler bands in the simple case for one, uniform class 3 for the other.
A Manipulate interface to scan through the behavior from simple initials for all 243 rules is - Manipulate[ ArrayPlot[ CellularAutomaton[{rulenumber, {3, 1}, 1/2}, {{1}, 0}, {100, All}], ColorRules -> {2 -> Black, 1 -> Red, 0 -> Yellow}, PixelConstrained -> 4], {rulenumber, 0, 242, 1}]
I hope this is interesting...
Report this post to a moderator | IP: Logged
|