Examples
llms.txtSelect an example to explore it in the playground.
Beginner - Introductory Models
Fishery Simulation
A fishery simulation of stocks, flows, and feedback loops managing fish populations.
Level: Beginner
Antifragile System
The same adaptive loop, two fates: with one knob negative each failure makes the system stronger; flip its sign and failures spiral to certain breakdown.
Level: Beginner
Bathtub Fill and Drain
Bathtub stock and flow simulation: water volume rises and falls with inflow and outflow. Change the rates and watch the stock respond.
Level: Beginner
Elementary Cellular Automata
Elementary cellular automata rule table for all 256 rules. See how each 8-neighbourhood maps to the next state, and try rules 30, 90, and 110.
Level: Beginner
Gacha Box
Same 50 pulls, same spend, one setting apart: a pity timer guarantees the 1%-odds ultra after a dry streak, while turning it off can leave you empty-handed.
Level: Beginner
Game of Life
Conway's Game of Life: a random soup self-organizes into still-lifes, blinkers, and gliders — global order from one local rule.
Level: Beginner
Goal-Seeking Decay
A goal-seeking decay simulation modeling exponential approach toward a target.
Level: Beginner
Inventory Oscillation
Naive reordering that ignores in-transit stock makes inventory swing; counting the pipeline flattens it.
Level: Beginner
Logistic Growth
Grow a population too fast and it overshoots its carrying capacity before settling; grow it gently and it glides up to the same limit.
Level: Beginner
Nested Hierarchy Workflow
A nested hierarchy simulation where tasks flow across company departments.
Level: Beginner
Queue Simulation
A single-server queue at the edge of overload: nudge utilization past 1 and the backlog diverges.
Level: Beginner
Savings vs Credit-Card Debt
Same card, same income - one number decides everything: pay just under the interest and the debt runs away; pay just over it and the balance marches to zero.
Level: Beginner
Success to the Successful
Funding by last period's output turns a 5% productivity edge into a budget Gini of 0.84. Redistributing 30% of the pool holds that gap near 0.057.
Level: Beginner
Thermostat Simulation
A bang-bang thermostat reading a delayed sensor overshoots and rings; shorten the delay and it settles.
Level: Beginner
Intermediate - Classic Dynamics
First-Price vs. Vickrey Auctions
Repeated sealed-bid auctions comparing first-price and Vickrey rules with learning agents.
Level: Intermediate
Bank Renege Simulation
Bank queue simulation of reneging: impatient customers leave before a line forms, while patient ones wait and nearly all get served.
Level: Intermediate
Atmospheric CO₂ Bathtub
CO₂ rises while emissions exceed the sink: the same cut turns the bathtub around, but waiting until year 50 leaves a higher peak and a higher year-120 level.
Level: Intermediate
Dynamic Difficulty Adjustment
Dynamic difficulty simulation that tracks win rate and adapts encounters so players stay challenged. See the feedback loop that tunes the challenge.
Level: Intermediate
Hospital ER Patient Flow
Hospital ER queue simulation of patient flow through an emergency department. See how arrival rate, treatment time, and capacity change the wait.
Level: Intermediate
Inspection Game
A ranger who patrols just 40% of sites can still stop poaching - but only if the penalty is harsh enough. Soften it and the same patrols let crime pay.
Level: Intermediate
Inventory–Workforce Oscillator
A hire delay swings seasonal backlog amplitude from 60 down to 7. Workforce turns 14 times in both: amplified seasonality, not an unforced oscillator.
Level: Intermediate
Predator-Prey (Lotka–Volterra, SciPy)
Lotka-Volterra predator-prey simulation of oscillating populations. Change growth and predation rates and watch the classic cycle appear.
Level: Intermediate
Predator-Prey (Lotka–Volterra, SimPy)
Lotka-Volterra predator-prey model in discrete-time SimPy. Compare this simulation with the continuous equations and see the same oscillation.
Level: Intermediate
Matchmaking Queue
Simulates skill-based matchmaking with adjustable buckets, skill delta and max wait.
Level: Intermediate
Token Bucket vs Leaky Bucket Rate Limiting
Rate limiting compared: a token bucket allows a burst then drops traffic, while a leaky bucket smooths the same burst into a steady queue.
Level: Intermediate
Ride-Share Surge Control
Dynamic pricing stabilises rider waits—until high gain and delay turn it into surge whiplash.
Level: Intermediate
Rumor vs Counterwave
Competing rumor and fact-check messages racing across a social network.
Level: Intermediate
SIR Model with Vaccination
An SIR epidemic at the threshold: vaccinating past the herd-immunity line pushes effective R0 below 1 and the outbreak fizzles.
Level: Intermediate
Sleep Debt Simulation
A sleep debt simulation tracking caffeine, sleep patterns, and debt buildup.
Level: Intermediate
War of Attrition
Two-player waiting game exploring mixed strategies and the option value of waiting.
Level: Intermediate
Water Heater PID Control
PID control keeps a domestic hot water tank near its setpoint while balancing heater power and losses.
Level: Intermediate
Advanced - Complex Simulations
Beer Game: The Bullwhip Effect
A Beer Game simulation of the bullwhip effect: one demand step whips factory orders from a surge to zero unless each tier counts stock already in transit.
Level: Advanced
Car Service Simulation - SimPy Tutorial
A car service simulation showing priority washing with features like interrupts.
Level: Advanced
Hawk-Dove Game: When Does Fighting Pay?
Hawk-Dove game simulation of when fighting pays. When a fight costs more than the prize, hawks and doves settle; cheapen the fight and conflict spreads.
Level: Advanced
Logistic Map
A logistic map simulation that iterates x_{n+1}=r*x_n*(1-x_n) to illustrate chaos.
Level: Advanced
Machines Simulation
Machines simulation of resource allocation and reliability. See how breakdowns and repairs change throughput when capacity is shared.
Level: Advanced
Phantom Traffic Jam
Why a highway jams with no crash and no bottleneck: past a critical reaction time, one brake tap becomes a phantom stop-and-go wave that creeps backward.
Level: Advanced
Prisoner's Dilemma: Noise, Tit-for-Tat, and Forgiveness
One accidental defection turns unforgiving tit-for-tat into a prisoner's dilemma revenge spiral. Forgive some of those slips and cooperation holds.
Level: Advanced