Animate Game of Life
Interactive Conway's Game of Life simulator with drawing, presets, speed control, and real-time animation. Create, edit, and watch cellular automata evolve.
About
Conway's Game of Life is a zero-player cellular automaton devised by mathematician John Conway in 1970. The system operates on a two-dimensional grid where each cell exists in one of two states: alive (1) or dead (0). The next generation is computed by applying three deterministic rules based on the count of live neighbors N within the Moore neighborhood (8 adjacent cells). Miscounting neighbors or misapplying rules produces divergent evolution paths. A single misplaced cell can collapse a stable structure or prevent an oscillator from cycling. This tool implements the standard B3/S23 ruleset with toroidal boundary conditions, meaning the grid wraps around edges. It approximates an infinite plane within a finite buffer.
The simulation supports drawing cells directly onto the grid, inserting classic patterns, and controlling generation speed from 1 to 60 generations per second. Grid states persist across browser sessions via LocalStorage. Note: patterns near grid boundaries interact with the toroidal wrap. Structures that require unbounded space (e.g., infinite-growth patterns) will behave differently on a finite wrapped grid. Pro Tip: use the Step button to debug oscillator periods one generation at a time.
Formulas
Each cell Cx,y at position (x, y) transitions between generations according to its neighbor count N. The Moore neighborhood counts all 8 adjacent cells (horizontal, vertical, diagonal).
The transition function under the standard B3/S23 ruleset:
Where Cx,yt is the state of cell at position (x, y) at generation t, N is the count of alive neighbors in the Moore neighborhood, and boundary conditions are toroidal: indices wrap modulo grid dimensions W and H.
Reference Data
| Pattern | Type | Period | Cells | Bounding Box | Discovered |
|---|---|---|---|---|---|
| Block | Still Life | 1 | 4 | 2×2 | - |
| Beehive | Still Life | 1 | 6 | 4×3 | - |
| Loaf | Still Life | 1 | 7 | 4×4 | - |
| Boat | Still Life | 1 | 5 | 3×3 | - |
| Tub | Still Life | 1 | 5 | 3×3 | - |
| Blinker | Oscillator | 2 | 3 | 3×1 | - |
| Toad | Oscillator | 2 | 6 | 4×2 | - |
| Beacon | Oscillator | 2 | 6 | 4×4 | - |
| Pulsar | Oscillator | 3 | 48 | 13×13 | 1970 |
| Pentadecathlon | Oscillator | 15 | 12 | 10×3 | 1970 |
| Glider | Spaceship | 4 | 5 | 3×3 | 1970 (R. Gosper) |
| LWSS | Spaceship | 4 | 9 | 5×4 | 1970 |
| MWSS | Spaceship | 4 | 11 | 6×5 | 1970 |
| HWSS | Spaceship | 4 | 13 | 7×5 | 1970 |
| Gosper Glider Gun | Gun | 30 | 36 | 36×9 | 1970 (B. Gosper) |
| R-pentomino | Methuselah | 1103 (stabilizes) | 5 | 3×3 | 1970 |
| Diehard | Methuselah | 130 (dies) | 7 | 8×3 | 1971 |
| Acorn | Methuselah | 5206 (stabilizes) | 7 | 7×3 | 1971 (C. Corderman) |
| Infinite Growth 1 | Infinite Growth | ∞ | 10 | 39×1 | 1971 |
| Spaceship Flotilla | Composite | 4 | ~30 | Variable | Various |