1D Cellular Automaton

What is it

This model demonstrates the simplest class of 1D Cellular Automata. In a neighbourhood of 3 cells, the center cell turns either black or white, depending on the state of its neighbours and which of 256 possible rules has been selected. For example, when applying Rule #30 in a given a neighbourhood configuration of 111, the center cell will turn white, yielding a new configuration of 101.

Since a neighbourhood is made up of 3 cells, it has 2^3=8 possible states, which then allows for 2^8=256 possible rules, each of which over an arbitrary number of steps will produce a deterministic pattern of black and white cells. The rules are numbered according to Wolfram notation, where each of the 8 possible states for a neighbourhood produces a unique configuration of possible states for the center cell. This binary result is then converted to decimal form for convenience, for example Rule #30 is the new center cell configuration 0001 1110 = 30. See http://en.wikipedia.org/wiki/Cellular_automaton for a brief outline on cellular automata or http://www.wolframscience.com/nksonline/toc.html (Chapter 3) for a more in-depth exploration of the subject.

Simple Cellular Automata - Rule #30

The Xholon CA application can handle all 256 of these rules.

How to use it

Run it:

  1. Run the Java application through the Xhn GUI (org.primordion.xholon.app.Xhn.java), and select File --> Open --> ca --> 1dSimple --> 1dSimple_xhn.xml.
  2. A grid viewer and the Xholon GUI will appear. The grid viewer will display the initial pattern, with only the top centre cell black.
  3. Expand the Controller node in the GUI.
  4. Press the Start node.

Pause and Step the model:

  1. Press Pause to pause and resume the executing model. Press Step to advance the paused model by one time step. Press Start to resume the paused model.

Things to notice

There are 4 interesting behaviours that can be seen by applying the various rules; repetition, nesting, randomness, and the creation of localized structures.

Things to try

Edit 1dSimple_xhn.xml (param name="CaRuleNumber" value="30"/>) and view the graphical results of applying different rules.

Alter the visual aspect of the graph by changing the cell size and the grid size. To change the cell size, edit the number of pixels per cell (by default 3) in 1dSimple_xhn.xml (param name="GridViewerParams" value="descendant::Row/..,3,Xholon - 1D CA Simple".) Change the grid size by increasing the number of rows and columns in CompositeStructureHierarchy.xml to, for example, 200 and 400.

Change the number of time steps the application will run for by editing 1dSimple_xhn.xml (param name="MaxProcessLoops" value="99"/>.) Setting it to -1 will cause the application to run forever.

Extending the model

Xholon features

Each cell in this cellular automata application is a xholon and communicates with the other cells (xholons) via ports.

Credits and references