Interactive models · 14 small simulations that run in the browser
Some of the simulations on this site, shrunk so your browser can run them. None starts on its own. Each one counts its own operations, so you can compare what your device manages with the computing a serious run of the same kind needs.
John Conway’s cellular automaton of 1970. Each cell is alive or dead, and at every step it looks at its eight neighbours: a dead cell with exactly three comes alive, a live cell with two or three survives, and everything else dies. That's all the rules there are. Click the grid to add cells.
This device: press Run to measure measured · A serious run of cellular automata: about 1012 FLOPS rough · The entry ▸
Random points land in a square that holds a quarter circle. The fraction that land inside is π/4. This is Monte Carlo estimation at its simplest. The error shrinks only as the square root of the number of samples, so each extra correct digit takes a hundred times more samples.
This device: press Run to measure measured · A serious run of monte carlo estimation of constants: about 109 FLOPS rough · The entry ▸
Craig Reynolds’ three rules from 1987: separation, alignment and cohesion. No bird knows the shape of the flock, and there's no leader.
This device: press Run to measure measured · A serious run of flocking and schooling: about 1013 FLOPS rough · The entry ▸
280 agents move at random in a box. Three begin infected. An agent who passes close to an infected one may catch it, and recovers after a fixed time. You can change how many people stay at home. Press Reset to apply it. This is the agent-based formulation. The compartmental formulation models the same dynamics with a few differential equations.
This device: press Run to measure measured · A serious run of agent-based epidemics: about 1016 FLOPS rough · The entry ▸
Each pixel is a grain. At each step a grain falls if the space below is empty, or slides diagonally if it can. Piles, slopes and avalanches emerge from this single rule. Draw on the canvas to add grains.
This device: press Run to measure measured · A serious run of falling-sand games: about 1012 FLOPS rough · The entry ▸
A single-lane ring road, drawn as a strip of time: each row is one moment, newest at the bottom, and each coloured dot is a car (red stopped, gold slow, green at the limit). Each driver speeds up when there's room, brakes for the car ahead, and sometimes slows down at random. That's the whole model, from Kai Nagel and Michael Schreckenberg (1992). Above a density of about 15%, jams appear with no outside cause and drift backwards against the traffic.
This device: press Run to measure measured · A serious run of traffic flow: about 1013 FLOPS rough · The entry ▸
Two hundred ants leave the gold nest and wander. Each one deposits pheromone as it moves and steers towards the strongest pheromone ahead. One kind leads back to the nest, the other to food. No ant knows where anything is, yet within a minute the colony has laid trails between the nest and the pink food. Jean-Louis Deneubourg studied this in his ant experiments of 1990, and Marco Dorigo built it into his ant colony algorithms. Click to drop more food.
This device: press Run to measure measured · A serious run of ant colony foraging: about 1011 FLOPS rough · The entry ▸
Two chemicals in a dish. One is fed in at a steady rate. The other eats it, makes more of itself, and slowly decays. Both spread out, at different speeds. Turing (1952) showed that a system like this can turn an even mixture into spots and stripes. This is the Gray–Scott reaction, mapped by John Pearson (1993). Change the settings and you get coral, dividing-cell, fingerprint and worm patterns. Click to give it a nudge.
This device: press Run to measure measured · A serious run of pattern formation: about 1012 FLOPS rough · The entry ▸
Drop sand on a table one grain at a time. Any square holding four grains topples and passes one to each neighbour, and those may topple in turn. Grains that fall off the edge are gone. Per Bak, Chao Tang and Kurt Wiesenfeld used this model in 1987 to show how a system can organise itself into a critical state. Most grains do nothing. A few set off avalanches across the whole pile. Avalanche sizes have no typical scale. Click to drop a grain at another site.
This device: press Run to measure measured · A serious run of self-organised criticality: about 1011 FLOPS rough · The entry ▸
Two kinds of household, cyan and pink, are placed at random. A household is content if enough of its eight neighbours are its own kind. If not, it moves to a random empty spot. Schelling (1971) did this with coins on a chessboard. Even when households are happy to be in a minority, you still get sharp segregation. You can change the share of like neighbours they need.
This device: press Run to measure measured · A serious run of residential sorting: about 109 FLOPS rough · The entry ▸
Three masses and Newton’s law of gravity. Two bodies can orbit forever. Three have no general exact solution, as Henri Poincaré showed in the 1890s, and from most starting points one body gets thrown out. The figure-eight orbit is one of the rare stable repeating solutions. Cris Moore found it in 1993, and Alain Chenciner and Richard Montgomery proved it exists in 2000. The Pythagorean start has three bodies at rest, with masses 3, 4 and 5. Carl Burrau posed it in 1913. The readout shows how well the numerical method conserves total energy. An exact solution would conserve it perfectly.
This device: press Run to measure measured · A serious run of orbital dynamics: about 1013 FLOPS rough · The entry ▸
Empty ground slowly grows trees. Lightning sometimes sets a tree alight, and the fire spreads to nearby trees before burning out. Barbara Drossel and Franz Schwabl studied this model in 1992. The forest never settles down, and fires of every size keep thinning it, just like the sandpile. Click a tree to ignite it.
This device: press Run to measure measured · A serious run of wildfire spread: about 1013 FLOPS rough · The entry ▸
Each pixel is a spin pointing up or down. Each one tends to line up with its four neighbours, and heat jostles them out of line. Ernst Ising solved the one-dimensional line in 1925; Lars Onsager solved this flat grid exactly in 1944 and found a sharp critical temperature, about 2.27 in these units. Below it, regions merge into big domains and the grid becomes magnetised. Above it, the pattern stays disordered. You can change the temperature while it runs.
This device: press Run to measure measured · A serious run of magnetism and phase transitions: about 1012 FLOPS rough · The entry ▸
A sea of fish (cyan) and sharks (pink). Fish move at random and breed. Sharks eat adjacent fish, breed more slowly, and starve if they go too long without food. A. K. Dewdney named this world Wa-Tor in 1984. The plot below shows the two populations, each on its own scale. Fish increase, sharks follow, fish collapse, sharks starve, and the cycle repeats. Alfred Lotka and Vito Volterra got the same swing from their equations in the 1920s. Here it comes from individual agents.
This device: press Run to measure measured · A serious run of predator–prey dynamics: about 109 FLOPS rough · The entry ▸