Every colony carries a health value H ∈ [0,1]. Thermal stress is tracked with a simplified version of NOAA Coral Reef Watch's Degree Heating Weeks index: each simulated week accumulates max(0, anomaly − 1 °C) into a rolling 12-week sum. Once DHW crosses roughly 4 °C-weeks, colonies start bleaching; past ~8 they face serious mortality risk.
DHW(t) = Σ over last 12 weeks of max(0, SST_anomaly − 1)
bleach = clamp(DHW/8, 0, 1) · (1 + pollution·0.6)
dH/dt = recover·(1 − pollution·0.5)·(1 + protection·0.4)·(1 − H)
− bleach·(0.35 + eventPulse)·H
K_fish = reefCover (carrying capacity tracks live coral)
dF/dt = r·F·(1 − F/K_fish) − harvest·(1 − protection)·F
Water pollution lowers the thermal-tolerance margin and slows recovery (excess nutrients favour algae over coral larvae); marine-protection enforcement raises the recovery rate and cuts fishing pressure on the coupled fish population, whose carrying capacity tracks live coral cover — the classic habitat-collapse feedback loop. The heatwave button injects a one-off thermal pulse on top of the slider's steady-state anomaly, the way a real marine heatwave stacks on background warming.
- Coral cover — colony-average health across the reef, weighted by colony size.
- DHW — the rolling thermal-stress accumulator; the reef only recovers once it drops back near zero.
- Fish population — logistic growth against a coral-dependent carrying capacity, reduced by unprotected fishing pressure.