Langton's ant

Last updated

Langton's ant after 11,000 steps. A red pixel shows the ant's location. LangtonsAnt.svg
Langton's ant after 11,000 steps. A red pixel shows the ant's location.

Langton's ant is a two-dimensional Turing machine with a very simple set of rules but complex emergent behavior. It was invented by Chris Langton in 1986 and runs on a square lattice of black and white cells. [1] The idea has been generalized in several different ways, such as turmites which add more colors and more states.

Contents

Rules

Animation of first 200 steps of Langton's ant LangtonsAntAnimated.gif
Animation of first 200 steps of Langton's ant

Squares on a plane are colored variously either black or white. We arbitrarily identify one square as the "ant". The ant can travel in any of the four cardinal directions at each step it takes. The "ant" moves according to the rules below:

Langton's ant can also be described as a cellular automaton, where the grid is colored black or white and the "ant" square has one of eight different colors assigned to encode the combination of black/white state and the current direction of motion of the ant. [2]

Modes of behavior

These simple rules lead to complex behavior. Three distinct modes of behavior are apparent, [3] when starting on a completely white grid.

  1. Simplicity. During the first few hundred moves it creates very simple patterns which are often symmetric.
  2. Chaos. After a few hundred moves, a large, irregular pattern of black and white squares appears. The ant traces a pseudo-random path until around 10,000 steps.
  3. Emergent order. Finally the ant starts building a recurrent "highway" pattern of 104 steps that repeats indefinitely.

All finite initial configurations tested eventually converge to the same repetitive pattern, suggesting that the "highway" is an attractor of Langton's ant, but no one has been able to prove that this is true for all such initial configurations. It is only known that the ant's trajectory is always unbounded regardless of the initial configuration [4]  – this is known as the Cohen-Kong theorem. [5]

Computational properties

In 2000, Gajardo et al. showed a construction that calculates any boolean circuit using the trajectory of a single instance of Langton's ant. [2]

Extension to multiple colors

Greg Turk and Jim Propp considered a simple extension to Langton's ant where instead of just two colors, more colors are used. [6] The colors are modified in a cyclic fashion. A simple naming scheme is used: for each of the successive colors, a letter "L" or "R" is used to indicate whether a left or right turn should be taken. Langton's ant has the name "RL" in this naming scheme.

Some of these extended Langton's ants produce patterns that become symmetric over and over again. One of the simplest examples is the ant "RLLR". One sufficient condition for this to happen is that the ant's name, seen as a cyclic list, consists of consecutive pairs of identical letters "LL" or "RR". (the term "cyclic list" indicates that the last letter may pair with the first one) The proof involves Truchet tiles.

The hexagonal grid permits up to six different rotations, which are notated here as N (no change), R1 (60° clockwise), R2 (120° clockwise), U (180°), L2 (120° counter-clockwise), L1 (60° counter-clockwise).

Extension to multiple states

A further extension of Langton's ants is to consider multiple states of the Turing machine – as if the ant itself has a color that can change. These ants are called turmites, a contraction of "Turing machine termites". Common behaviours include the production of highways, chaotic growth and spiral growth. [7]

Extension to multiple ants

A colony (as an absolute oscillator) builds a triangle Langton's Ant colony.gif
A colony (as an absolute oscillator) builds a triangle

Multiple Langton's ants can co-exist on the 2D plane, and their interactions give rise to complex, higher-order automata that collectively build a wide variety of organized structures.

There are different ways of modelling their interaction and the results of the simulation may strongly depend on the choices made. [8]

Multiple turmites can co-exist on the 2D plane as long as there is a rule that defines what happens when they meet. Ed Pegg, Jr. considered ants that can turn for example both left and right, splitting in two and annihilating each other when they meet. [9]

See also

Related Research Articles

<span class="mw-page-title-main">Conway's Game of Life</span> Two-dimensional cellular automaton

The Game of Life, also known simply as Life, is a cellular automaton devised by the British mathematician John Horton Conway in 1970. It is a zero-player game, meaning that its evolution is determined by its initial state, requiring no further input. One interacts with the Game of Life by creating an initial configuration and observing how it evolves. It is Turing complete and can simulate a universal constructor or any other Turing machine.

<span class="mw-page-title-main">Cellular automaton</span> Discrete model studied in computer science

A cellular automaton is a discrete model of computation studied in automata theory. Cellular automata are also called cellular spaces, tessellation automata, homogeneous structures, cellular structures, tessellation structures, and iterative arrays. Cellular automata have found application in various areas, including physics, theoretical biology and microstructure modeling.

<span class="mw-page-title-main">Rule 110</span> Elementary cellular automaton

The Rule 110 cellular automaton is an elementary cellular automaton with interesting behavior on the boundary between stability and chaos. In this respect, it is similar to Conway's Game of Life. Like Life, Rule 110 with a particular repeating background pattern is known to be Turing complete. This implies that, in principle, any calculation or computer program can be simulated using this automaton.

A cellular automaton (CA) is Life-like if it meets the following criteria:

<span class="mw-page-title-main">Garden of Eden (cellular automaton)</span> Pattern that has no predecessors

In a cellular automaton, a Garden of Eden is a configuration that has no predecessor. It can be the initial configuration of the automaton but cannot arise in any other way. John Tukey named these configurations after the Garden of Eden in Abrahamic religions, which was created out of nowhere.

<span class="mw-page-title-main">Turmite</span> Turing machine on a two-dimensional grid

In computer science, a turmite is a Turing machine which has an orientation in addition to a current state and a "tape" that consists of an infinite two-dimensional grid of cells. The terms ant and vant are also used. Langton's ant is a well-known type of turmite defined on the cells of a square grid. Paterson's worms are a type of turmite defined on the edges of an isometric grid.

<span class="mw-page-title-main">Wireworld</span> 2D cellular automaton devised by Brian Silverman in 1987

Wireworld, alternatively WireWorld, is a cellular automaton first proposed by Brian Silverman in 1987, as part of his program Phantom Fish Tank. It subsequently became more widely known as a result of an article in the "Computer Recreations" column of Scientific American. Wireworld is particularly suited to simulating transistors, and is Turing-complete.

<span class="mw-page-title-main">Rule 30</span> Elementary cellular automaton

Rule 30 is an elementary cellular automaton introduced by Stephen Wolfram in 1983. Using Wolfram's classification scheme, Rule 30 is a Class III rule, displaying aperiodic, chaotic behaviour.

<span class="mw-page-title-main">Cyclic cellular automaton</span>

A cyclic cellular automaton is a kind of cellular automaton rule developed by David Griffeath and studied by several other cellular automaton researchers. In this system, each cell remains unchanged until some neighboring cell has a modular value exactly one unit larger than that of the cell itself, at which point it copies its neighbor's value. One-dimensional cyclic cellular automata can be interpreted as systems of interacting particles, while cyclic cellular automata in higher dimensions exhibit complex spiraling behavior.

<span class="mw-page-title-main">Langton's loops</span> Self-reproducing cellular automaton patterns

Langton's loops are a particular "species" of artificial life in a cellular automaton created in 1984 by Christopher Langton. They consist of a loop of cells containing genetic information, which flows continuously around the loop and out along an "arm", which will become the daughter loop. The "genes" instruct it to make three left turns, completing the loop, which then disconnects from its parent.

Humans have considered and tried to create non-biological life for at least 3,000 years. As seen in tales ranging from Pygmalion to Frankenstein, humanity has long been intrigued by the concept of artificial life.

<span class="mw-page-title-main">Von Neumann universal constructor</span> Self-replicating cellular automaton

John von Neumann's universal constructor is a self-replicating machine in a cellular automaton (CA) environment. It was designed in the 1940s, without the use of a computer. The fundamental details of the machine were published in von Neumann's book Theory of Self-Reproducing Automata, completed in 1966 by Arthur W. Burks after von Neumann's death. It is regarded as foundational for automata theory, complex systems, and artificial life. Indeed, Nobel Laureate Sydney Brenner considered Von Neumann's work on self-reproducing automata central to biological theory as well, allowing us to "discipline our thoughts about machines, both natural and artificial."

Cellular automata, as with other multi-agent system models, usually treat time as discrete and state updates as occurring synchronously. The state of every cell in the model is updated together, before any of the new states influence other cells. In contrast, an asynchronous cellular automaton is able to update individual cells independently, in such a way that the new state of a cell affects the calculation of states in neighbouring cells.

<span class="mw-page-title-main">Rule 184</span> Elementary cellular automaton

Rule 184 is a one-dimensional binary cellular automaton rule, notable for solving the majority problem as well as for its ability to simultaneously describe several, seemingly quite different, particle systems:

<span class="mw-page-title-main">Lattice gas automaton</span> Type of cellular automaton

Lattice gas automata (LGCA), or lattice gas cellular automata, are a type of cellular automaton used to simulate fluid flows, pioneered by Hardy–Pomeau–de Pazzis and Frisch–Hasslacher–Pomeau. They were the precursor to the lattice Boltzmann methods. From lattice gas automata, it is possible to derive the macroscopic Navier–Stokes equations. Interest in lattice gas automaton methods levelled off in the early 1990s, as the interest in the lattice Boltzmann started to rise. However, an LGCA variant, termed BIO-LGCA, is still widely used to model collective migration in biology.

Paterson's worms are a family of cellular automata devised in 1971 by Mike Paterson and John Horton Conway to model the behaviour and feeding patterns of certain prehistoric worms. In the model, a worm moves between points on a triangular grid along line segments, representing food. Its turnings are determined by the configuration of eaten and uneaten line segments adjacent to the point at which the worm currently is. Despite being governed by simple rules the behaviour of the worms can be extremely complex, and the ultimate fate of one variant is still unknown.

<span class="mw-page-title-main">Life without Death</span> 2D cellular automaton similar to Conways Game of Life

Life without Death is a cellular automaton, similar to Conway's Game of Life and other Life-like cellular automaton rules. In this cellular automaton, an initial seed pattern grows according to the same rule as in Conway's Game of Life; however, unlike Life, patterns never shrink. The rule was originally considered by Toffoli & Margolus (1987), who called it "Inkspot"; it has also been called "Flakes". In contrast to the more complex patterns that exist within Conway's Game of Life, Life without Death commonly features still life patterns, in which no change occurs, and ladder patterns, that grow in a straight line.

<span class="mw-page-title-main">Reversible cellular automaton</span> Cellular automaton that can be run backwards

A reversible cellular automaton is a cellular automaton in which every configuration has a unique predecessor. That is, it is a regular grid of cells, each containing a state drawn from a finite set of states, with a rule for updating all cells simultaneously based on the states of their neighbors, such that the previous state of any cell before an update can be determined uniquely from the updated states of all the cells. The time-reversed dynamics of a reversible cellular automaton can always be described by another cellular automaton rule, possibly on a much larger neighborhood.

The Greenberg–Hastings Cellular Automaton is a three state two dimensional cellular automaton named after James M. Greenberg and Stuart Hastings, designed to model excitable media, One advantage of a CA model is ease of computation. The model can be understood quite well using simple "hand" calculations, not involving a computer. Another advantage is that, at least in this case, one can prove a theorem characterizing those initial conditions which lead to repetitive behavior.

<span class="mw-page-title-main">Ulam–Warburton automaton</span>

The Ulam–Warburton cellular automaton (UWCA) is a 2-dimensional fractal pattern that grows on a regular grid of cells consisting of squares. Starting with one square initially ON and all others OFF, successive iterations are generated by turning ON all squares that share precisely one edge with an ON square. This is the von Neumann neighborhood. The automaton is named after the Polish-American mathematician and scientist Stanislaw Ulam and the Scottish engineer, inventor and amateur mathematician Mike Warburton.

References

  1. Langton, Chris G. (1986). "Studying artificial life with cellular automata" (PDF). Physica D: Nonlinear Phenomena. 22 (1–3): 120–149. Bibcode:1986PhyD...22..120L. doi:10.1016/0167-2789(86)90237-X. hdl: 2027.42/26022 .
  2. 1 2 Gajardo, A.; Moreira, A.; Goles, E. (15 March 2002). "Complexity of Langton's ant" (PDF). Discrete Applied Mathematics. 117 (1–3): 41–50. arXiv: nlin/0306022 . doi:10.1016/S0166-218X(00)00334-6. S2CID   1107883.
  3. Pratchett, Terry; Stewart, Ian; Cohen, Jack (1999). The Science Of Discworld. Ebury Press. ISBN   978-0091865153.
  4. Bunimovich, Leonid A.; Troubetzkoy, Serge E. (1992). "Recurrence properties of Lorentz lattice gas cellular automata". Journal of Statistical Physics. 67 (1–2): 289–302. Bibcode:1992JSP....67..289B. doi:10.1007/BF01049035. S2CID   121346477.
  5. Stewart, I. (1994). "The Ultimate in Anty-Particles" (PDF). Sci. Am. 271 (1): 104–107. Bibcode:1994SciAm.271a.104S. doi:10.1038/scientificamerican0794-104. Archived from the original (PDF) on 3 March 2016. Retrieved 6 May 2013.
  6. Gale, D.; Propp, J.; Sutherland, S.; Troubetzkoy, S. (1995). "Further Travels with My Ant". Mathematical Entertainments Column, Mathematical Intelligencer. 17: 48–56. arXiv: math/9501233 . doi:10.1007/BF03024370. S2CID   123800756.
  7. Pegg, Jr., Ed. "Turmite". From MathWorld--A Wolfram Web Resource, created by Eric W. Weisstein . Retrieved 15 October 2009..
  8. Belgacem, S.; Fatès, N. (2012). "Robustness of Multi-agent Models: The Example of Collaboration between Turmites with Synchronous and Asynchronous Updating" (PDF). Complex Systems. 21 (3): 165–182. doi:10.25088/ComplexSystems.21.3.165.
  9. Pegg, Jr., Ed. "Math Puzzle" . Retrieved 15 October 2009..