|
Further Examples: CellularAutomaton
This defines the function RasterGraphics.
In[1]:= 
This gives the array of values obtained by running rule 30 for 3 steps, starting from an initial condition consisting of a single 1 surrounded by 0's.
In[2]:= 
Out[2]= 
This runs rule 30 for 50 steps and makes a picture of the result.
In[3]:= 

If all values in the initial condition are given explicitly, they are in effect assumed to continue cyclically. This runs rule 30 with 5 cells for 3 steps.
In[4]:= 
Out[4]= 
This starts from {1, 1} on an infinite background of repeating {1, 0, 1, 1} blocks. By default, only the region of the pattern affected by {1, 1} is given.
In[5]:= 

This gives all cells that could possibly be affected, whether or not they are.
In[6]:= 

This places blocks in the initial conditions at offsets -10 and 20.
In[7]:= 

This gives only the last row after running for 10 steps.
In[8]:= 
Out[8]= 
This runs for 5 steps, giving the cells on the 3 center columns at each step.
In[9]:= 
Out[9]= 
This picks out every other cell in space and time, starting 200 cells to the left.
In[10]:= 

This runs the general k = 3, r = 1 rule with rule number 921408.
In[11]:= 

This runs the totalistic k = 3, r = 1 rule with code 867.
In[12]:= 

This uses a rule based on applying a function to each neighborhood of cells.
In[13]:= 

This runs the 2D 9-neighbor totalistic code 630 for 25 steps, giving the results for the last 5 steps.
In[14]:= 

This runs the 2D 9-neighbor outer totalistic code 746 for 200 steps, starting from a block of 7 black cells, giving the result for the last step.
In[15]:= 

This runs the 2D 5-neighbor outer totalistic code 481 for 50 steps, giving the result for the last step.
In[16]:= 

|