How it Works
The model tracks three coupled populations — kelp K (a producer, expressed as percentage cover up to a maximum of 100), sea urchins U (a grazer that eats kelp) and sea otters O (a keystone predator that eats urchins). Kelp regrows logistically toward its carrying capacity when ungrazed, but loses cover to urchin grazing. Urchins convert grazed kelp into new urchin biomass, die off naturally, and are hunted by otters through a saturating (Holling type II) predation term so that predation pressure levels off at high urchin density. Otters themselves grow logistically toward their own carrying capacity, but only when urchin prey is available — with no otters present, the otter population cannot regrow on its own.
Every animation frame runs several small Euler integration steps (the Simulation Speed slider sets how many) so the three coupled differential equations update smoothly. The top strip of the canvas plots all three populations as a live time-series line chart, while the bottom strip renders a spatial "kelp forest" grid whose cells shift from lush green to bare grey as local kelp cover falls, with urchin and otter dots layered on top. Clicking "Remove Keystone Predator" sets the otter population straight to zero — watch urchins boom and kelp collapse into a barren over the next several seconds — and "Reintroduce Otters" seeds a small recovering population so you can see how much of the kelp forest returns.
Urchin: dU/dt = 0.3·g·U·(K/100) − 0.05·U − p·O·U/(U+20)
Otter: dO/dt = 0.02·O·(1−O/25)·U/(U+10)
Euler step: X(t+dt) = X(t) + (dX/dt)·dt, dt = 0.05 per sub-step, sub-steps/frame = Simulation Speed
Frequently Asked Questions
What is a keystone species?
A keystone species is an organism whose impact on its ecosystem is disproportionately large relative to its abundance; removing it triggers cascading changes throughout the food web, as sea otters do for kelp forests.
Why do sea otters control the health of a kelp forest?
Sea otters prey heavily on sea urchins, keeping urchin numbers low enough that urchins cannot graze kelp faster than it regrows; without otters, urchin populations explode and strip the kelp forest bare.
What is a trophic cascade?
A trophic cascade is a chain reaction that runs down a food web when a predator population changes, altering the abundance of the species it eats and, in turn, the species those prey eat, here otters, then urchins, then kelp.
What happens when I click 'Remove Keystone Predator'?
The otter population is set to zero, removing predation pressure on urchins; over the following seconds urchins boom, graze down the kelp, and the spatial map shifts from lush green kelp forest to a bare grey urchin barren.
Can the kelp forest recover after otters are reintroduced?
Reintroducing a small seed population of otters lets predation resume, gradually suppressing the urchin population and allowing kelp regrowth, though recovery is slower than the original collapse and depends on the otter predation rate, urchin grazing rate and kelp regrowth rate sliders.