OpenSim.zip
Open Simulation Library
Explore simulations. Inspect the model. Run the code. Download the files.
- Points
- 10,000
- Estimate
- 3.1464
- Error
- 0.0048
Flagship simulations
All 38 simulations- 01Monte Carlo πEstimate π from random points in a unit square and watch the error shrink like 1/√n.
- 02Random walkCoin-flip steps on a line or grid: distance grows like √n, and in 1-D and 2-D every walker comes back.
- 03Markov chainA process that remembers only its current state: stationary distribution, mixing and absorption, live.
- 04M/M/1 queueOne server, random arrivals, random service: why waits explode as utilization ρ = λ/μ approaches 1.
- 05SIR modelSusceptible, infected, recovered: the three-compartment ODE behind epidemic curves and R₀.
- 06Game of LifeTwo rules on a grid of cells: gliders, guns, oscillators and soups that settle or keep going.
- 07Brownian motionParticles jiggle with Gaussian steps; their mean squared displacement grows as 4Dt, as Einstein predicted.
- 08Predator–preyWolves, sheep and grass on a grid: noisy population cycles, a phase loop and the risk of extinction.
Explore by field
Every model, four ways in
- Explore
Change the parameters and watch the model respond. Stochastic models take a seed, so a run you like can be repeated exactly.
- Inspect
Each page states the model: variables, equations or update rules, and what it deliberately leaves out.
- Run
The code on the page is the code the page runs. The Python port uses the same generator and gives the same numbers.
- Download
A
.zipper model: README,model.json,simulation.js,simulation.py, example output, MIT license. Browse packages.
Methods behind the models
Learn- Euler vs Runge–Kutta: Time Stepping in SimulationsWhy a spring simulated with Euler’s method gains energy, and what RK4 buys for four evaluations a step.
- How Accurate Is a Monte Carlo Estimate?Standard errors, confidence intervals, the 1/√n rule, and what changes when samples are correlated.
- Pseudo-Random Numbers and Seeds in SimulationWhere simulation randomness comes from, why seeds matter, and one generator in two languages.
- SimPy Examples: Queues in PythonDiscrete-event simulation with Python’s SimPy: four short programs, checked against queueing theory.