A' = ΔA − AB² + F·(1 − A) · B' = ½·ΔB + AB² − (F + k)·BTwo chemicals, A and B, share a grid of 324 × 264 cells whose edges wrap around. In every cell, every step, three things happen:
Both chemicals also spread to the neighbouring cells, A twice as fast as B. That's the Gray–Scott model of reaction and diffusion.
One drop
The grid starts full of A, with one small 10 × 10 drop of B in the middle (random strengths, seeded). With F = 0.055 and k = 0.062 the drop grows, splits and folds into a coral maze of stripes that keeps spreading until it fills the whole frame. That takes 17,000 steps. The colour shows when the coral reached each cell, teal at the drop and violet at the far edges; the brightness is the amount of B.
Stripes break into spots
Then the settings move a hair: the feed rate drops to F = 0.050 and the kill rate rises to k = 0.0655. In 2,000 more steps the stripes can't hold together any more: they pinch off and break into spots, which is where the video ends.
Nothing in the rule mentions stripes or spots. They come from the balance between how fast B grows, how fast it dies and how much more slowly it spreads than A. Alan Turing first suggested in 1952 that patterns like the stripes and spots on animal skins could form this way.
The equations
A' = ΔA − AB² + F·(1 − A) B' = ½·ΔB + AB² − (F + k)·B
ΔA is how much A differs from the average of its neighbours (the spreading), AB² is the reaction, and the last terms are the feed and the die-off. Each step moves time on by 1.
Part of Reaction–diffusion: Chemicals that feed, react and spread on a grid, and the patterns they grow by themselves.
Use this picture
Free to reuse, also commercially, under CC BY 4.0. Credit “What Math Means” with a link to whatmathmeans.dev/v/one-drop-grows-into-coral.







