Thirteen interactive simulations of classic models in spatial ecology and evolutionary game theory, all running locally in your browser — no installation needed. Pick a demo below.
On-lattice logistic model (1D)
The classic birth-death interacting particle system on a ring of sites.
Classic interacting-particle-system model
Off-lattice logistic model
A birth-death process with density-dependent competition among individuals in continuous space. Choose between Gaussian and top-hat competition kernels and watch clustering vs. regularity emerge.
Surendran, Pinto-Ramos, Menezes & Martinez-Garcia, Physica D 477 (2025)
Spatial pattern formation (IBM vs. mean-field)
A 1D individual-based birth-death model with Gaussian dispersal and top-hat competition, run side-by-side with its mean-field density-equation approximation. Watch a periodic clustering pattern emerge from the individual-based dynamics and compare it to the deterministic prediction in real time.
Surendran, Pinto-Ramos, Menezes & Martinez-Garcia, Physica D 477 (2025)
Colicin allelopathy (non-spatial)
The mean-field limit of the colicin lattice model: a phase portrait of producer vs. sensitive frequencies. Drag the cost and toxicity sliders to flip between monostable dominance and bistability, and click anywhere to launch a new trajectory.
Producer vs. sensitive cells on a lattice. Producers poison their neighbors — watch clumps of producers take over, or lose, depending on toxicity.
Durrett & Levin, J. Theor. Biol. 185 (1997)
Local vs. global dispersal
The E. coli C-S-R rock-paper-scissors game. Flip between local (Moore neighborhood) and well-mixed interaction and see biodiversity collapse under global dispersal.
Spatial rock-paper-scissors with selection, reproduction, and mobility (exchange). Cross the critical mobility and watch spiral waves collapse into a single surviving species.
Reichenbach, Mobilia & Frey, Nature 448 (2007)
Random walk → diffusion equation
Watch discrete random walkers fan out into a Gaussian, then compare the same walk against a finite-difference solution of the drift-diffusion PDE it converges to.
Classic random-walk / diffusion-limit demo
Habitat selection via movement
Beetles moving along a line of patches of varying quality. Compare a quality-aware Markov chain against a passive-diffusion null model and see habitat selection emerge from movement rates alone.
Kareiva, Ecological Monographs 52 (1982)
Step-selection functions
Simulate an animal's movement through habitat, then try to recover its hidden habitat-preference weights from the simulated steps.
Step-Selection Functions for Modeling Animal Movement
Semiarid vegetation patterning
A reaction-diffusion-advection model of water and plant biomass on a hillslope. Tune rainfall, advection, and diffusion to grow banded or spotted vegetation patterns, tracked live on a bifurcation diagram.
Klausmeier, Science 284 (1999)
Semiarid vegetation — find the tipping point
Flat-terrain variant (no slope, no fixed-point curves shown). Step rainfall by fixed increments; each step kicks the vegetation field with a small perturbation so you can discover the tipping point and hysteresis empirically.
Klausmeier, Science 284 (1999)
Diffusion vs. Fisher-KPP: front propagation
The same initial pulse evolved under the plain diffusion equation and under Fisher-KPP. Diffusion spreads and flattens with no fixed height; FKPP holds at u=1 behind a traveling front. Toggle each solution on/off and tune the diffusion coefficients and the growth rate r independently.
Fisher, Ann. Eugenics 7 (1937); Kolmogorov, Petrovsky & Piskunov (1937)
N_h = (b−d)/g·L² is the non-spatial (mean-field) equilibrium prediction, shown as the dashed red line.
Plants: 0
Total population vs. time
Pair correlation function C(r)
C(r) = 1 for a fully random pattern; C(r) > 1 at small r indicates clustering, C(r) < 1 indicates regularity/self-thinning.
On-lattice logistic model
Event-driven birth-death process on a ring of N sites.
Occupied fraction ρ(t) vs. sweep
Space-time raster (newest at top)
Colicin allelopathy lattice model
RED = colicin producer BLUE = sensitive (non-producer) white = vacant. Durrett & Levin, J. theor. Biol. 185 (1997).
Densities vs. time
Mobility & biodiversity (rock-paper-scissors)
RED = A BLUE = B GOLD = C (A beats B beats C beats A) black = vacant. Reichenbach, Mobilia & Frey, Nature 448 (2007).
Species densities vs. time
Local vs. global dispersal (C-S-R model)
RED = C (producer) BLUE = S (sensitive) GREEN = R (resistant) white = vacant. Kerr, Riley, Feldman & Bohannan, Nature 418 (2002).
Strain densities vs. time
Colicin allelopathy — non-spatial (mean-field) model
Phase portrait of the complete-mixing limit of the colicin lattice model. Iwasa, Nakamaru & Levin, Evolutionary Ecology 12 (1998), Eq. 4.
Fixed: β1=3.0, δ1=δ2=1.0.
Click anywhere inside the phase portrait to launch a new trajectory from that starting point (ρ1+ρ2<1).
Phase portrait (ρ1 vs. ρ2)
stable nodeunstable nodesaddle
Population dynamics for the trajectories at left
ρ1 (C, producer)ρ2 (S, sensitive)
Semiarid vegetation patterning
Water-biomass reaction-diffusion-advection model on a periodic hillslope. Klausmeier, "Regular and Irregular Patterns in Semiarid Vegetation", Science 284 (1999).
Reset field reseeds the domain near the current homogeneous equilibrium (plus small noise) so a fresh pattern can develop. The red dot on the bifurcation diagram tracks the spatial average of N over the whole domain.
Semiarid vegetation patterning — find the tipping point
Flat-terrain variant (v = 0, no slope): short-range plant self-activation vs. long-range water inhibition self-organizes into patches. No fixed-point curves are shown — step rainfall with the buttons below to kick the field and discover the tipping point and hysteresis empirically. Klausmeier, Science 284 (1999).
t = 0.0
Plant biomass N(X,Y,t) — flat terrain
Rainfall vs. mean vegetation
trajectory as rainfall is steppedcurrent state
Random walk → diffusion equation
A discrete random walk, and the drift-diffusion PDE it converges to in the continuum limit.
Sample trajectories
Histogram of positions at this step
Random walk histogram vs. diffusion PDE
random walk histogramdiffusion PDE (finite-difference)closed-form Gaussian
Habitat selection via movement
A linear array of patches; movement rate depends on local patch quality. Kareiva, "Experimental and Mathematical Analyses of Herbivore Movement", Ecological Monographs 52 (1982).
ratei = k/distance × (1 − α·qualityi)
Spatial pattern formation: IBM vs. mean-field density equation
1D individual-based birth-death model with Gaussian dispersal and top-hat competition, periodic domain, alongside its mean-field (density-field) PDE approximation. Surendran, Pinto-Ramos, Menezes & Martinez-Garcia, Physica D 477 (2025), Section 3.2.
Both the IBM and the PDE start from the same random lattice configuration (Poisson-distributed near the homogeneous mean-field density) so you can watch them diverge or converge as a pattern forms. Changing b, d, s, or r_c reseeds the lattice; the speed slider only changes how many steps run per frame.
Lattice state
IBM (individuals per cell)mean-field PDE
Space-time (kymograph) of the IBM density, newest at top
Diffusion equation vs. Fisher-KPP: front propagation
Same initial pulse u(x,0), evolved under ∂u/∂t = D ∂²u/∂x² (plain diffusion) and under ∂u/∂t = D ∂²u/∂x² + r u(1−u) (Fisher-KPP), periodic domain. Diffusion spreads and decays with no floor; FKPP holds at u=1 behind a traveling front moving at speed ≈ 2√(rD).
Both equations start from the same localized pulse. Reset reseeds that pulse and restarts time; the sliders and checkboxes act live on the running simulation without resetting it.
u(x,t)
initial conditiondiffusion equationFisher-KPP
Step-selection function simulator
Embedded unmodified — identical to the standalone version.