Some Basic Cellular Automa

This is just a little exercise I did to practice JavaScript and HTML5 canvas manipulations. It is a port of an earlier Perl project I had to do in school.

As this is HTML5 canvas based, you have to use a HTML5 compliant browser (most modern ones are ok).

Cellular Automa generate images row by row, with the state of cells in each consecutive row dependant on the states of the three cells directly above it. Different Rule-Sets (ranging from 0-255) change what states constitute a cell being "dead or alive," and lead to different patterns. Some patterns are pretty cool (like the ones to the right), while others (rule 3 for example) are quite boring.

Click here For some more information on Cellular Automa (courtesy of Wolfram MathWorld).

Just a few things to keep in mind before hitting generate:
  • For many patterns, having the row number equal to a power of 2 (like 64 or 128) gives a more "complete" image
  • Generating a massive number of rows can (and will) put some strain on your device, and the browser may crash

- Daniel Prilik 2014

Some examples of cool automa that can be generated with one initial cell

Enter Parameters: Rule: Rows: Random First Row: