Grow Turing patterns (spots, stripes, coral, worms, waves) from the Gray-Scott model in real time, tune the feed and kill rates, paint with chemicals, and download the pattern.
See the codeTuring patterns, grown live: two chemicals and two lines of math make the spots of a leopard, the stripes of a zebra, the branches of coral, worms that crawl apart and waves that never settle. Tune the feed and kill rates, paint with chemical B, explore the parameter map, and download the pattern as PNG. No sign-up and no libraries.
The ten named patterns, after a few thousand steps (click one to grow it live):
The dish is a 512 × 512 grid, wrapped at the edges, kept in two floating-point textures on the GPU (WebGL 2). Each frame, a fragment shader applies the Gray-Scott update to every cell several times over, reading the cell's eight neighbors for the diffusion (a 3 × 3 Laplacian with weights 0.2 to the sides and 0.05 to the corners), with diffusion rates of 1 for A and 0.5 for B:
A' = A + Da ∇²A − AB² + f (1 − A)
B' = B + Db ∇²B + AB² − (k + f) B
A second shader turns the amount of B into colors, with optional lighting from the slope of the pattern. The brush drops B as small speckles rather than a solid blot, since a large uniform patch dies out in the spot regimes while small seeds grow.
Plain HTML, CSS and JavaScript, with no dependencies and no build step. Just open index.html. The three color themes (dark, light and blue) are shared with my other projects (copied from omg-themes).
In 1952 Alan Turing published The Chemical Basis of Morphogenesis, proposing that two substances reacting and diffusing at different speeds could break a uniform tissue into spots and stripes. The Gray-Scott model (1984) is a simple chemical system of that kind; John Pearson's Complex Patterns in a Simple System (Science, 1993) mapped its patterns over the feed and kill rates. Reaction-diffusion has since been observed in the stripes of zebrafish, the spacing of hair follicles and feathers, and the forming of the digits.
Reaction-Diffusion is open source at GitHub with MIT license.
Had fun browsing the app? Buy me a coffee by becoming a sponsor.
You may also be interested in my other projects Cymatics (demo), Infinite-Coastlines (demo) and Sunflower-Golden-Angle (demo).
Copyright (c) 2026 Olivier Giulieri.
Grow Turing patterns (spots, stripes, coral, worms, waves) from the Gray-Scott model in real time, tune the feed and kill rates, paint with chemicals, and download the pattern.
See the codeTuring patterns, grown live: two chemicals and two lines of math make the spots of a leopard, the stripes of a zebra, the branches of coral, worms that crawl apart and waves that never settle. Tune the feed and kill rates, paint with chemical B, explore the parameter map, and download the pattern as PNG. No sign-up and no libraries.
The ten named patterns, after a few thousand steps (click one to grow it live):
The dish is a 512 × 512 grid, wrapped at the edges, kept in two floating-point textures on the GPU (WebGL 2). Each frame, a fragment shader applies the Gray-Scott update to every cell several times over, reading the cell's eight neighbors for the diffusion (a 3 × 3 Laplacian with weights 0.2 to the sides and 0.05 to the corners), with diffusion rates of 1 for A and 0.5 for B:
A' = A + Da ∇²A − AB² + f (1 − A)
B' = B + Db ∇²B + AB² − (k + f) B
A second shader turns the amount of B into colors, with optional lighting from the slope of the pattern. The brush drops B as small speckles rather than a solid blot, since a large uniform patch dies out in the spot regimes while small seeds grow.
Plain HTML, CSS and JavaScript, with no dependencies and no build step. Just open index.html. The three color themes (dark, light and blue) are shared with my other projects (copied from omg-themes).
In 1952 Alan Turing published The Chemical Basis of Morphogenesis, proposing that two substances reacting and diffusing at different speeds could break a uniform tissue into spots and stripes. The Gray-Scott model (1984) is a simple chemical system of that kind; John Pearson's Complex Patterns in a Simple System (Science, 1993) mapped its patterns over the feed and kill rates. Reaction-diffusion has since been observed in the stripes of zebrafish, the spacing of hair follicles and feathers, and the forming of the digits.
Reaction-Diffusion is open source at GitHub with MIT license.
Had fun browsing the app? Buy me a coffee by becoming a sponsor.
You may also be interested in my other projects Cymatics (demo), Infinite-Coastlines (demo) and Sunflower-Golden-Angle (demo).
Copyright (c) 2026 Olivier Giulieri.