Some months ago I have been reading a bit about Turmites. This term is used to describe Turing machines that use a two-dimensional grid of cells as a tape. The term was coined because these Turing machines operating on the grid look like insects.
There’s an interesting turmite named “Langton’s Ant“, which is also a Cellular Automata. It consists of a two-dimensional grid of cells; each cell has two possible states: black or white. There’s also an ant involved, which moves along the grid. When the ant leaves a cell, it inverts the color of the cell. In this post we’ll see how to implement the Langton’s Ant in Python using Pyglet.