Vlad
Game Of Life

Game of Life

Conway's Game of Life is a classic example of cellular automata, with incredibly simple rules giving rise to surprising levels of complexity. It takes place on a grid, where each cell has a live and a dead state. The behavior of a cell each tick is determined by the following rules:

Beyond this, the game can be expanded to include coloured cells, which requires additional rules and states.

Migration (2-color)

The basic case involves giving all living cells two colors. In order to keep behavior consistent with the basic game of life, the rules for living and dying remain the same, with new rules for color being added.

Quad (4-color)

Extending the 2-color rule-set into 4 colors is straightforward. The only difference is that majority color is no longer guaranteed, since a 3-way tie can occur. In this case, the tie is resolved by setting the color of the new cell to the one that is not currently present among the three neighbors.

Multicolor

This is a generalization of the previous rule-sets into a continuous color space. Each cell has a color determined by a hue, which can be interpreted as an angle on the color wheel. When a new cell is born, it takes on the average color of all its neighbors. Since each color is essentially an angle, in practice this means averaging the angles of the neighbors. In the simulation below, dead cells also keep their last color when they were alive, although dimmed. This produces a good aesthetic effect, and gives a sense of the amount of space cell interaction cover.

Demo

The initial state is generated by setting a random number of cells to a living state, and optionally giving them a random color if necessary. The board wraps on the x and y axes, which topologically produces a toroid.

x-wrap:
y-wrap:
Mode:
World Size: 100
Live %: 50
Info: