# Questions tagged [cellular-automata]

Puzzles involving cellular automata, such as Conway's Game of Life.

39 questions
Filter by
Sorted by
Tagged with
830 views

### Game of Game of Life

Game of Game of Life Conway's Game of Life is a 0-player game. But that's okay! We can make it a multi-player game. This game is played on the smallest square grid that will accommodate a 6x6 ...
337 views

### Interpreting the Wolfram Code

Introduction An elementary cellular automaton is a cellular automaton that is 1-dimensional and has 2 states, 1 and 0. These cellular automata are categorized based on a simple code: the Wolfram code,...
3k views

### Simulate a 1D Game-of-Life-ish Model

This question just trended over on code-review and I figured you might like it adapted as a codegolf challenge: You are given a non-empty list of x houses represented as booleans. Each day, the ...
778 views

### Binary self-rotation

Given a binary 3D array, for each layer, cyclically rotate up each of its columns as many steps as indicated by the binary encoding of the columns of the layer above it, and then cyclically rotate ...
6k views

### Dig a border trench

Background: Too many illegal immigrants from Blandia are crossing the border to Astan. The emperor of Astan has tasked you with digging a trench to keep them out, and Blandia must pay for the expenses....
359 views

### Golf Paterson's Worms

Paterson's worms are a kind of cellular automaton that exist on an infinite triangular grid and, every step, they turn in some direction and move one unit. Their defining properties are that they can ...
394 views

### Conway's game of life [duplicate]

Description : Given an array of strings representing a grid of cells With the key : 0 = 'dead cell' 1 = 'live cell' write a function that returns the next ...
6k views

### The Quantum Drunkard's Walk

It is well known that a person on a grid under the influence of alcohol has an equal chance of going in any available directions. However, this common-sense statement does not hold in the realm of ...
749 views

### Change the rules of Life

Life-like cellular automaton are cellular automaton that are similar to Conway's Game of Life, in that they operate on a (theoretically) infinitely large square grid, where each cell has exactly 8 ...
771 views

### Implement a strange automaton

I was playing around with cellular automaton and I found one that had some interesting behavior. Here's how it works: It reads a binary string from left to right, if it encounters a ...
702 views

### Game of Life and Fatigue

Stewie's Game of Life and Fatigue is quite similar to the more famous Conway's Game of Life. The universe of the Stewie's Game of Life and Fatigue (GoLF) is an infinite two-dimensional orthogonal ...
769 views

### CCC 2016: Circle of Life

Before I begin, this challenge was not mine originally Credits to The University of Waterloo. This came from the Canadian Computing Competition 2016, Senior Problem 5. Here is a clickable link to the ...
558 views

### Topple the sandpile

(There are related questions about infinite sandpiles, and finding identity elements of sandpiles.) Given a matrix of non-negative integers, return a matrix of the same dimensions, but toppled: If ...
1k views

### Life: Created or Evolved?

Given the state of a square Game of Life grid, determine whether it could have evolved from any previous state, or could only have been created. That is, identify whether the state is a "Garden of ...
459 views

### The Tax Historian

Introduction There is a tax collector that has some trouble managing the taxes of his kingdom: the historical records have burnt down in a great fire. He wants to find out how many possible pasts ...
761 views

### Find a Glider Synthesis (Game of Life)

Challenge Summary In summary, the challenge is to provide the glider synthesis for a Game of Life configuration, which is your input. What does this mean? Well, firstly, let me explain a few terms. ...
1k views

### Find the identity sandpile

This question is about abelian sandpiles. Read this previous challenge and watch this numberphile video to learn more. An abelian sandpile of size n by n is a grid containing the number 0, 1, 2 and 3 ...
5k views

### Build a sandpile

An abelian sandpile, for our purposes, is an infinite grid with integer coordinates, initially empty of sand. After each second, a grain of sand is placed at (0,0). Whenever a grid cell has 4 or more ...
2k views

### Build a digital clock in Wireworld

Inspired by this Game of Life question. Wireworld simulates "electrons" flowing through "wires", simple arrangements of which produce typical logic gate behavior. I challenge you to build a digital ...
1k views

### Stable Game of Life

Challenge: Given a matrix (or 2d array) of 0s and 1s, output the number of steps it takes for Conway's game of life to reach a stable state, or -1 if it never reaches one. A stable state is a state ...
2k views

### The XOROR sequence

Cellular Automata are truly fascinating. The ones that are usually talked about are the binary ones, i.e., the ones representable by a number. However, those, in my opinion, have been done to death. ...
2k views

### Electrons bouncing in a wire

Imagine a "wire" that has n spaces. Imagine further that there are "electrons" in that wire. These electrons only live for one unit of time. Any spaces in the wire ...
722 views

### Plurality Voting with Cellular Automata

There's a really important problem in cellular automata called the Majority problem: The majority problem, or density classification task is the problem of finding one-dimensional cellular ...
2k views

### Bacterial expansion

Colonies of bacteria labelled 1 through 9 live on a segment of equally-spaced cells, with empty cells indicated by ...
1k views

### Digital Cellular Automata

Write a program or function that takes in an odd positive integer N and a string of decimal digits (0123456789). The string represents a ten-state one-dimensional ...
643 views

### Pseudorandom Cellular Automaton

Introduction In this challenge, we will simulate a certain probabilistic cellular automaton using very bad pseudorandom numbers. The cellular automaton is defined on binary strings by the following ...
109 views

### Shortest Wireworld [duplicate]

Wireworld is fun for the whole family! Your goal is to create a Wireworld implementation in the shortest amount of code possible. A Wireworld cell can be in one of four different states, usually ...
304 views

### Identifying Sequences for Cellular Automata

Background For the purposes of this challenge, an n-state cellular automaton is simply a binary function f that takes two ...
794 views

### Emulate Rule 110 with Conway's Game of Life (or vice versa) [closed]

Can you find initial conditions for either Rule 110 or Conway's Game of Life to emulate the other? That is, produce output (in any form, not necessarily the familiar pixel grid) which corresponds ...
1k views

### Create a universal two-dimensional cellular automaton cell using two-way universal logic processors

In Conway's Game of Life, a cell is in a state of either on or off, depending on the on-and-off state of the eight cells surrounding it. We can simulate this using a logic gate network with some sort ...
15k views

### Implement the Game of Life on Anything but a Regular Grid

Conway's Game of Life is (almost) always played on a regular square grid, but it doesn't need to be. Write a program that implements the standard cell neighboring rules from Conway's Game of Life on ...
6k views

### Simulate Rule 110

Rule 110 is a cellular automaton with some interesting properties. Your goal is to simulate a rule 110 in as few characters as possible. For those who don't know, rule 110 is simulated line by line ...
217k views

### Build a working game of Tetris in Conway's Game of Life

Here is a theoretical question - one that doesn't afford an easy answer in any case, not even the trivial one. In Conway's Game of Life, there exist constructs such as the metapixel which allow the ...
2k views

### Simple redstone simulator

Redstone is a material in the game Minecraft, and it is used for many complex contraptions. For this program, you will only need to simulate three items: the redstone wire (noted with R), redstone ...
3k views

### Longest non-repeating Game-of-Life sequence

Given a positive integer N, determine the starting pattern on a N x N-grid that yield the longest non-repeating sequence under Game of Life-rules, and ends with a fixed pattern (cycle of length 1), ...
2k views

### Simulate the Wireworld cellular automaton

Wireworld is a cellular automaton that was designed to be resemble electrons flowing through wires. Its simple mechanics allow the construction of digital circuits. It has even permitted the ...
1k views

### Simulate any 1D cellular automaton

The Challenge You are to write a complete program that takes seven numbers from STDIN, and prints the two dimensional history of the cellular automaton (CA) to STDOUT. This is code golf. Input ...