Simulations About Profile Home
🧪 Explorer Progress:
Explorer Level 0 0 / 30 simulations explored
🎯 Projectile Motion Beginner
Every object thrown through the air follows a perfect parabola. Launch a ball and discover why 45° maximizes range — and how air resistance changes everything.
Parameters
Air Resistance
Range (m)
Max Height
Flight Time
Impact Speed
Key insight: 45° gives max range with no drag. Add air resistance and the optimal angle drops to ~35°.
The Physics

Projectile motion decomposes velocity into two independent components. The horizontal component is constant (no force); the vertical component accelerates under gravity. They combine to produce a parabolic path.

Key Equations
\[ x(t) = v_0 \cos\theta \cdot t \]
\[ y(t) = v_0 \sin\theta \cdot t - \tfrac{1}{2}g t^2 \]
\[ R = \frac{v_0^2 \sin 2\theta}{g} \]
Why 45° Maximises Range

sin(2θ) is maximised when 2θ = 90°, i.e. θ = 45°. With air drag, the optimal angle shifts lower because higher angles spend more time at altitude where drag accumulates more.

Real-World Applications

Artillery ballistics, sports science (football, javelin), orbital mechanics (re-entry trajectories), and video game physics engines all use this model as a foundation.

〰 Wave Interference Beginner
Two point sources emit circular waves. Where crests meet crests they reinforce; where crests meet troughs they cancel. This underlies Wi-Fi, noise-cancelling headphones, and quantum mechanics.
Parameters
Animate
Bright = constructive. Dark = destructive.

Set phase offset to 180° — the pattern inverts! This is how noise-cancelling headphones work.
The Physics

Each source emits circular waves. At any point in space, the total displacement is the algebraic sum of both waves (superposition principle). Where they arrive in phase, amplitudes add; where out of phase, they cancel.

Constructive vs Destructive
\[ \text{Constructive:} \quad |r_1 - r_2| = n\lambda \quad (n = 0, 1, 2, \ldots) \]
\[ \text{Destructive:} \quad |r_1 - r_2| = \left(n + \tfrac{1}{2}\right)\lambda \]
Real-World Applications

Wi-Fi antennas use phased arrays to steer signals. Active noise cancellation generates the anti-phase wave. Radio telescopes use interferometry to image black holes. Young's double-slit experiment first proved the wave nature of light (1801).

📊 Fourier Series Intermediate
Any repeating signal — any sound, any electrical waveform — is secretly just a stack of sine waves. Add harmonics one by one and watch a perfect square wave emerge from smooth sinusoids.
Parameters
Show Components
Fourier's theorem: any periodic function can be decomposed into sine waves of different frequencies and amplitudes.

This is why your phone can compress audio, an MRI scanner can see your brain, and JPEG images work.
Fourier's Theorem

Any periodic function f(x) with period T can be written as an infinite sum of sines and cosines. The Fourier series converges to f(x) everywhere the function is continuous.

Square Wave Series
\[ f(x) = \frac{4}{\pi} \sum_{n=1}^{\infty} \frac{\sin\bigl((2n-1)x\bigr)}{2n-1} \]

Only odd harmonics appear; amplitudes fall as 1/n. This is why a square wave sounds harsher than a sine — it contains all those higher harmonics.

Applications

MP3/AAC audio compression (drop imperceptible harmonics). JPEG image encoding (discrete cosine transform, a close relative). MRI reconstruction. Signal processing in every radio, phone, and scientific instrument.

⚡ Electric Field Lines Intermediate
Place charges and watch the invisible electric field draw itself in space. Field lines show the direction a positive test charge would move. The density shows the field's strength.
Place Charges
Click the canvas to place a charge of the selected type.
Field lines run from + to −.

Notice how they never cross — each point in space has only one field direction.

This geometry underpins how capacitors, transistors, and electric motors work.
Coulomb's Law
\[ F = k\frac{q_1 q_2}{r^2} \qquad k = 8.99\times10^9\ \tfrac{\text{N·m}^2}{\text{C}^2} \]

The force between charges falls as the square of distance — the same inverse-square law as gravity, but ~10³⁶ times stronger.

Electric Field
\[ \mathbf{E} = \frac{F}{q} = k\frac{Q}{r^2} \quad \bigl[\text{N/C} = \text{V/m}\bigr] \]

The field at a point is the force per unit positive test charge. Field lines are tangent to this field vector at every point — which is why they never cross.

Gauss's Law
\[ \oint \mathbf{E} \cdot d\mathbf{A} = \frac{Q_{\text{enc}}}{\varepsilon_0} \]

The total electric flux through any closed surface equals the enclosed charge divided by ε₀. This is one of Maxwell's four equations that describe all of classical electromagnetism.

⚛ Quantum Double Slit Advanced
The most profound experiment in physics. A single particle passes through two slits simultaneously — and interferes with itself. One particle at a time, a wave-like pattern builds up on the detector.
Parameters
🔍 Which-slit Detector
0
Particles
Quantum
Mode
Toggle the detector — measuring which slit the particle uses destroys the interference pattern. The act of observation changes physical reality.
Wave-Particle Duality

Quantum mechanics describes every particle as a probability amplitude — a complex wave function ψ. The probability of detecting a particle at position x is |ψ(x)|². Particles don't have definite positions until measured.

Interference Pattern
\[ I(\theta) \propto \cos^2\!\left(\frac{\pi d \sin\theta}{\lambda}\right) \cdot \operatorname{sinc}^2\!\left(\frac{\pi w \sin\theta}{\lambda}\right) \]

d = slit separation, w = slit width, λ = de Broglie wavelength. The cos² term gives fringes; the sinc² envelope narrows them for wider slits.

The Measurement Problem

When a which-slit detector is turned on, the particle must interact with it — this entangles the particle with the detector and collapses its wave function. The interference requires the particle to take both paths simultaneously. Knowing the path prevents that.

de Broglie Wavelength
\[ \lambda = \frac{h}{p} = \frac{h}{mv} \]

Every massive particle has a wavelength. For an electron, λ ≈ 1 Å — the size of an atom. This is why electron microscopes can see atoms but light microscopes can't.

🕰 Special Relativity — Time Dilation Intermediate
A "light clock" bounces a photon between two mirrors. When the clock moves, the photon must travel a longer diagonal path — so the clock ticks slower. This isn't an illusion: time genuinely runs slower for moving objects.
Parameters
1.00
γ (Lorentz factor)
1.00
Time ratio
0
Rest ticks
0
Moving ticks
γ = 1/√(1−v²/c²)

At v=0.87c: γ≈2, time runs at half speed.
At v=0.99c: γ≈7, time runs 7× slower.

GPS satellites must correct for this or your maps drift by 11km/day.
The Lorentz Factor
\[ \gamma = \frac{1}{\sqrt{1 - v^2/c^2}} \]

γ equals 1 at rest and grows toward infinity as v → c. Time intervals measured by a moving clock are dilated by γ relative to a stationary observer.

Time Dilation
\[ \Delta t' = \gamma \, \Delta t_0 \]

A clock moving at 0.87c ticks at half speed (γ ≈ 2). This is not an illusion — muons created at the top of the atmosphere by cosmic rays survive long enough to reach the Earth's surface only because of time dilation.

Length Contraction
\[ L = \frac{L_0}{\gamma} \]

Objects moving at relativistic speeds appear shorter along their direction of motion. The faster they go, the more contracted.

GPS Correction

GPS satellites orbit at ~14,000 km/h (special relativity slows their clocks by 7 μs/day) and at high altitude (general relativity speeds them up by 45 μs/day). Net: +38 μs/day. Without correction, GPS would drift ~11 km per day.

🦋 Lorenz Attractor — Chaos Theory Intermediate
Two trajectories starting 0.00001 apart diverge completely. This is the butterfly effect: deterministic equations producing unpredictable behavior. It's why weather forecasting beyond ~2 weeks is fundamentally impossible.
Parameters
Show 2nd trajectory
Cyan & red start 0.00001 apart. Watch them diverge. This is deterministic chaos: knowing the rules perfectly doesn't let you predict the future.
The Lorenz Equations
\[ \frac{dx}{dt} = \sigma(y - x) \]
\[ \frac{dy}{dt} = x(\rho - z) - y \]
\[ \frac{dz}{dt} = xy - \beta z \]

σ (sigma) = Prandtl number, ρ (rho) = Rayleigh number, β (beta) = geometric factor. The classic parameters σ=10, ρ=28, β=8/3 produce the famous butterfly-shaped attractor.

Deterministic Chaos

The equations are completely deterministic — no randomness at all. Yet tiny differences in initial conditions grow exponentially (Lyapunov exponent λ ≈ 0.9 for classic parameters). This is why weather forecasting beyond ~10 days is a fundamental physical limit, not an engineering problem.

Strange Attractors

The Lorenz attractor has fractal dimension ≈ 2.06. Trajectories are confined to a bounded region (the attractor) but never repeat — they trace out an infinitely complex fractal structure. This is characteristic of all chaotic systems.

🔀 Double Pendulum — Chaos in Motion Advanced
Add a single joint to a pendulum and all predictability vanishes. Two nearly identical starting angles lead to completely different paths within seconds — a vivid demonstration of classical chaos.
Parameters
Show Chaos Twin
Two pendulums (cyan & red) start 0.001° apart. Watch how quickly they diverge — the hallmark of chaotic systems. Even a tiny measurement error makes long-term prediction impossible.
Equations of Motion (Lagrangian)
\[ \alpha_1 = \frac{-g(2m)\sin\theta_1 - mg\sin(\theta_1 - 2\theta_2) - 2m\sin(\theta_1-\theta_2)\bigl(\omega_2^2 L + \omega_1^2 L\cos(\theta_1-\theta_2)\bigr)}{2L\bigl(2m - m\cos^2(\theta_1-\theta_2)\bigr)} \]

The equations are nonlinear and coupled — θ₁ and θ₂ appear in each other's equations via trigonometric terms. This coupling is what produces the chaotic behaviour. The simulation uses RK4 integration for accuracy.

Lyapunov Exponent

For most initial conditions, the Lyapunov exponent of the double pendulum is positive — meaning nearby trajectories diverge exponentially. The system is unpredictable beyond a few seconds of simulation time regardless of computational precision.

Poincaré Sections

Slicing the 4-dimensional phase space (θ₁, θ₂, ω₁, ω₂) reveals the fractal structure of chaos. For small angles, the pendulum is regular; past a critical energy, it transitions suddenly to chaos — a phase transition visible in the Poincaré map.

🔗 Coupled Oscillators & Normal Modes Advanced
Two pendulums connected by a spring. Push one and the energy gradually transfers to the other — completely — then back again. The "normal modes" here underlie molecular bonds, phonons in crystals, and quantum field theory.
Parameters
Energy bar shows which pendulum currently holds the energy. In single-push mode it flows completely back and forth — like quantum tunneling made visible.
Normal Modes

Two coupled pendulums have exactly two normal modes — patterns of motion where every part oscillates at the same frequency. In the symmetric mode both pendulums swing together (spring unstretched); in the antisymmetric mode they swing in opposite directions (spring maximally stretched).

Beat Frequencies
\[ \omega_1 = \sqrt{\frac{g}{L}} \quad \text{(symmetric mode)} \]
\[ \omega_2 = \sqrt{\frac{g}{L} + \frac{2k}{m}} \quad \text{(antisymmetric mode)} \]
\[ T_{\text{beat}} = \frac{2\pi}{\omega_2 - \omega_1} \]
Why This Matters

Normal modes are the foundation of molecular spectroscopy (CO₂ has 4 normal modes). Phonons in crystalline solids are quantised normal modes. In quantum field theory, every particle is an excitation of a normal mode of a quantum field.

🌡 Brownian Motion & Statistical Mechanics Intermediate
In 1827, Robert Brown noticed pollen grains jiggling randomly in water. Einstein explained it in 1905: invisible molecules were constantly bombarding them. This simulation makes that thermal energy visible.
Parameters
Show Pollen Trails
Avg Speed
Temp (a.u.)
Large pollen grains (bright) do a random walk driven by impacts from tiny gas molecules. The speed distribution that emerges is the Maxwell-Boltzmann distribution — a cornerstone of thermodynamics.
Einstein's 1905 Derivation

Einstein showed that the mean square displacement of a Brownian particle grows linearly with time — a result that allowed Jean Perrin to measure Avogadro's number experimentally in 1908 and definitively prove that atoms exist.

Mean Square Displacement
\[ \langle r^2 \rangle = 2d \cdot D \cdot t \]
\[ D = \frac{k_B T}{6\pi\eta r} \quad \text{(Stokes–Einstein)} \]

d = dimensions, D = diffusion coefficient, k_B = Boltzmann constant, T = temperature, η = viscosity, r = particle radius. Higher temperature → faster diffusion.

Maxwell-Boltzmann Distribution
\[ f(v) \propto v^2 \exp\!\left(-\frac{mv^2}{2k_B T}\right) \]

The probability distribution of particle speeds in a gas. Its peak gives the most probable speed; its mean gives the average kinetic energy ½mv² = 3/2·k_BT. This links temperature directly to molecular motion.

Modern Applications

Brownian motion models stock price fluctuations (Black-Scholes equation). It explains diffusion in biological cells. It's used to simulate protein folding. And it underpins the entire field of stochastic calculus.

🌊 Quantum Harmonic Oscillator Advanced
The most important model in all of quantum mechanics. Every quantum field is a collection of harmonic oscillators. See the wave functions ψₙ(x), probability densities, and energy levels — and watch a coherent state orbit like a classical particle.
Parameters
Show |ψ|² (probability)
Show ψ (wave function)
Coherent state animation
½ħω
Energy Eₙ
0
Nodes
Zero-point energy: Even n=0 has E = ½ħω — the quantum vacuum is never truly at rest.
The Physics

The quantum harmonic oscillator describes any system with a restoring force proportional to displacement — from vibrating atoms to the Higgs field. Unlike the classical oscillator, energy is quantised: only discrete levels E_n = ℏω(n + ½) are allowed.

Schrödinger Equation
\[ \hat{H}\psi_n = E_n\psi_n,\quad \hat{H} = -\frac{\hbar^2}{2m}\frac{d^2}{dx^2} + \frac{1}{2}m\omega^2 x^2 \]
\[ E_n = \hbar\omega\!\left(n + \tfrac{1}{2}\right),\quad n = 0,1,2,\ldots \]
\[ \psi_n(x) = \frac{1}{\sqrt{2^n n!}}\left(\frac{m\omega}{\pi\hbar}\right)^{1/4} H_n\!\left(\sqrt{\frac{m\omega}{\hbar}}\,x\right) e^{-m\omega x^2/2\hbar} \]
Hermite Polynomials

H₀=1, H₁=2x, H₂=4x²−2, H₃=8x³−12x. Each higher level has one extra node (zero crossing). The probability density |ψₙ|² has n+1 peaks — a quantum particle is most likely found where a classical particle moves slowest.

Coherent States

A coherent state is a superposition of eigenstates that mimics classical motion — a Gaussian wave packet that oscillates back and forth without spreading. This is the quantum state produced by a laser and the closest thing to a classical oscillator in quantum mechanics.

Real-World Applications

Molecular vibrations, phonons in crystals, laser photon modes, the Higgs mechanism, and quantum field theory — every quantum field is fundamentally a collection of harmonic oscillators. The ground state of each field gives the vacuum zero-point energy.

🪐 N-Body Gravitational Simulation Advanced
Watch masses interact under gravity. A two-body system is perfectly solvable — add a third body and deterministic chaos emerges. Discover stable orbits, figure-8 solutions, and gravitational slingshots.
Configuration
Show trails
3
Bodies
Total Energy
Figure-8: A beautiful periodic 3-body solution discovered in 1993. It's unstable — tiny perturbations will break it apart.
Newton's Law of Gravitation
\[ \mathbf{F}_{ij} = \frac{G m_i m_j}{|\mathbf{r}_j - \mathbf{r}_i|^2}\,\hat{r}_{ij} \]
\[ \ddot{\mathbf{r}}_i = \sum_{j \neq i} \frac{G m_j (\mathbf{r}_j - \mathbf{r}_i)}{|\mathbf{r}_j - \mathbf{r}_i|^3} \]
The Three-Body Problem

Poincaré proved in 1890 that there is no general closed-form solution to the three-body problem. The system is chaotic — small changes in initial conditions produce wildly different long-term trajectories. This was one of the first discoveries of deterministic chaos.

Figure-8 Orbit

In 1993, Cris Moore discovered that three equal masses can follow a stable figure-8 path under gravity. It requires exquisitely precise initial conditions and is unstable under perturbations — but it exists. Hundreds of choreographic solutions have since been found.

Conservation Laws

Total energy E = KE + PE and total momentum p = Σmᵢvᵢ are conserved. Angular momentum L = Σmᵢ(rᵢ × vᵢ) is also conserved. These are monitored in real time — watch for numerical drift, which exposes the limits of any integration scheme.

Real-World Applications

Galaxy formation, spacecraft trajectory design (gravitational slingshots), binary star evolution, and planet formation all require N-body simulation. Modern simulations handle billions of particles using tree codes and GPU parallelisation.

🧲 Ising Model — Phase Transitions Advanced
A lattice of magnetic spins — each either up or down. Below a critical temperature, they spontaneously align. Above it, thermal chaos wins. Watch a phase transition unfold in real time, and see how order emerges from randomness.
Parameters
Running
Magnetisation
Energy/spin
Critical temp Tc ≈ 2.27 J/k — below this, the magnet orders spontaneously. The slider starts right at the phase transition.
The Ising Hamiltonian
\[ H = -J\sum_{\langle i,j\rangle} s_i s_j - h\sum_i s_i,\quad s_i \in \{-1,+1\} \]

Each spin sᵢ interacts with its nearest neighbours. J > 0 makes parallel alignment energetically favourable (ferromagnet). The external field h biases spins to align with it.

Metropolis Algorithm (Monte Carlo)
\[ P(\text{flip}) = \min\!\left(1,\, e^{-\Delta E / kT}\right) \]

Pick a random spin, compute the energy change ΔE if flipped. Accept the flip with probability min(1, e^(-ΔE/kT)). At low T, only energy-lowering flips are accepted. At high T, random flips are accepted freely.

Critical Temperature (Onsager, 1944)
\[ T_c = \frac{2J}{k_B \ln(1+\sqrt{2})} \approx 2.269\,\frac{J}{k_B} \]

Lars Onsager solved the 2D Ising model exactly in 1944 — one of the great achievements of theoretical physics. Near Tc, the correlation length diverges and the system shows scale-free behaviour (fractal domain patterns).

Spontaneous Symmetry Breaking

Above Tc: average magnetisation ⟨M⟩ = 0 (disordered). Below Tc: ⟨M⟩ ≠ 0 even with no external field — the system spontaneously picks a direction. This is the simplest example of spontaneous symmetry breaking, the same mechanism behind the Higgs field giving mass to particles.

Universal Critical Exponents

Near Tc, M ∝ (Tc-T)^β with β = 1/8 in 2D. The same exponents appear in completely different systems (liquid-gas, superconductors, superfluids) — universality classes mean that wildly different physical systems have identical critical behaviour.

🔮 Aharonov–Bohm Effect Advanced
A charged quantum particle accumulates a phase shift from a magnetic field it never touches. This experiment proves the vector potential is physically real — one of the strangest predictions of quantum mechanics.
Controls
Φ₀ = h/e is the magnetic flux quantum (~2.07×10⁻¹⁵ Wb). One flux quantum shifts the interference pattern by exactly one fringe.
0.00π
AB Phase
0.0
Fringe Shift
The Aharonov–Bohm Phase
\[ \Delta\phi_{AB} = \frac{q}{\hbar}\oint \mathbf{A}\cdot d\mathbf{l} = \frac{q\Phi}{\hbar} = 2\pi\frac{\Phi}{\Phi_0} \]

A particle moving through a field-free region still picks up a phase if a solenoid encloses magnetic flux Φ. The particle never enters the field — yet the interference pattern shifts.

Why It's Profound

In classical physics, only the fields E and B matter. In quantum mechanics, the vector potential A is physical — it affects particles even in regions where B=0. This demonstrates gauge fields have direct physical reality.

Flux Quantum
\[ \Phi_0 = \frac{h}{e} \approx 2.068 \times 10^{-15}\,\text{Wb} \]

When Φ = Φ₀, the phase shift is exactly 2π — one full fringe shift. This flux quantization appears in superconductors and is the basis of SQUID magnetometers.

⚫ Black Hole Lensing Advanced
Light doesn't travel in straight lines near a black hole. Trace photon geodesics in Schwarzschild spacetime — from gentle bending to circular orbits at the photon sphere to capture.
Controls
Show Photon Sphere
Show Event Horizon
Photon sphere at r = 1.5r_s: photons orbit indefinitely. Event horizon at r = r_s = 2GM/c². Rays near the photon sphere loop completely around!
2.96
r_s (km)
4.44
r_ps (km)
Schwarzschild Metric
\[ ds^2 = -\!\left(1-\frac{r_s}{r}\right)c^2 dt^2 + \frac{dr^2}{1-r_s/r} + r^2 d\Omega^2 \]

The geometry of spacetime around a non-rotating mass M. The Schwarzschild radius r_s = 2GM/c² defines the event horizon — a one-way membrane where escape velocity equals c.

Photon Orbit Equation
\[ \frac{d^2u}{d\phi^2} + u = \frac{3r_s}{2} u^2, \quad u = \frac{1}{r} \]

Null geodesics (light paths) satisfy this nonlinear ODE. Without the r_s term it's simple Kepler — the GR correction causes photon deflection. Light grazing the Sun bends by 1.75 arcseconds.

Critical Impact Parameter
\[ b_\text{crit} = \frac{3\sqrt{3}}{2} r_s \approx 2.598\,r_s \]

Photons with impact parameter b < b_crit spiral into the black hole. At b = b_crit they orbit the photon sphere at r = 1.5r_s. This creates the "black hole shadow" — a dark disk surrounded by an Einstein ring.

🌌 CMB Power Spectrum Advanced
The oldest light in the universe — a snapshot of quantum fluctuations 380,000 years after the Big Bang. Left: temperature map (hot/cold spots). Right: the power spectrum with characteristic acoustic peaks that encode the composition of the universe.
Controls
Show temperature map
220
1st Peak ℓ
ΔT (μK)
Peaks: 1st = first compression of baryon-photon fluid. 2nd = rarefaction. 3rd = 2nd compression. Silk damping suppresses small scales (ℓ>1000).
What are the acoustic peaks?
\[ D_\ell = \frac{\ell(\ell+1)}{2\pi} C_\ell \cdot T_0^2 \]

Before recombination, photons and baryons formed a tightly-coupled fluid. Pressure waves (sound) oscillated in this fluid. At recombination (z≈1100), the pattern was frozen into the CMB. Each acoustic peak corresponds to a mode that was at a maximum or minimum at that moment.

Peak positions encode geometry

The first peak at ℓ≈220 tells us the universe is flat (Ω_total≈1). Higher baryon density Ω_b boosts odd peaks (compressions) relative to even peaks (rarefactions). Dark matter Ω_c suppresses all peaks by increasing the gravitational potential at horizon entry.

Silk Damping
\[ C_\ell \propto e^{-(\ell/\ell_D)^2} \quad \ell_D \approx 1500 \]

At high ℓ (small scales), photon diffusion smooths out fluctuations — "Silk damping". This exponential suppression tells us the thickness of the last-scattering surface.

⚛ Standard Model Advanced
The most precisely tested theory in science — it describes all known particles and three of the four fundamental forces. Explore the particle zoo and watch fundamental interactions.
Interaction
The Standard Model has 17 fundamental particles: 6 quarks, 6 leptons, 4 gauge bosons, and the Higgs. It correctly predicts the electron anomalous magnetic moment to 10 significant figures.
The SM Lagrangian (schematic)
\[ \mathcal{L}_{SM} = -\tfrac{1}{4}F_{\mu\nu}F^{\mu\nu} + i\bar{\psi}\!\not\!D\psi + y_{ij}\bar{\psi}_i\phi\psi_j + |D_\mu\phi|^2 - V(\phi) \]

Four terms: gauge kinetic energy (photons, W, Z, gluons), fermion kinetic energy + interactions, Yukawa couplings (masses via Higgs), and the Higgs potential that drives symmetry breaking.

The Three Generations

Matter comes in three identical generations of increasing mass: (u,d,e,νe), (c,s,μ,νμ), (t,b,τ,ντ). Why three? We don't know. The top quark at 173 GeV/c² is heavier than a gold atom.

Running Coupling Constants
\[ \alpha_s(Q^2) = \frac{12\pi}{(33-2n_f)\ln(Q^2/\Lambda^2_{QCD})} \]

The strong coupling α_s decreases at high energy (asymptotic freedom) — quarks inside a proton barely interact. But at low energy, α_s→1, and quarks are permanently confined (confinement). This was Nobel Prize 2004.

🌊 Fluid Flow Advanced
Incompressible 2D flow simulated with a simplified lattice-Boltzmann method. Watch streamlines form around obstacles. Draw obstacles with your mouse. Pressure is shown as a color map.
Parameters
Drag canvas to draw/erase obstacles. Use Rect mode to drag a rectangular block. Watch vortices shed from cylinders at high Re!
Navier-Stokes (Incompressible)
\[ \rho\!\left(\frac{\partial \mathbf{u}}{\partial t}+\mathbf{u}\cdot\nabla\mathbf{u}\right)=-\nabla p+\eta\,\nabla^2\mathbf{u} \]
\[ \nabla\cdot\mathbf{u}=0 \]

The first equation is Newton's second law for a fluid parcel. The second enforces incompressibility — what flows in must flow out. These equations are unsolved analytically in the general case; the Clay Millennium Prize offers $1M for a proof of smooth solutions.

Reynolds Number
\[ Re = \frac{\rho v L}{\eta} \]

Re < 1: creeping flow (honey). Re ~ 100: laminar with wake. Re > 1000: turbulent. The transition to chaos in fluids is one of the great unsolved problems of physics.

⏱ Simple Pendulum Beginner
A pendulum solved with the full nonlinear ODE — not the small-angle approximation. Watch how large amplitudes change the period, and explore the phase-space portrait (θ vs ω).
Parameters
Period (s)
Energy
Large angles take longer than the small-angle formula predicts. At 90° the real period is ~18% longer. At 175° it diverges to infinity!
Equation of Motion
\[ \ddot{\theta} = -\frac{g}{L}\sin\theta - b\,\dot{\theta} \]

For small angles sin θ ≈ θ, giving simple harmonic motion. For large angles the full nonlinear equation must be integrated numerically.

Period Formulas
\[ T_0 = 2\pi\sqrt{\frac{L}{g}} \qquad \text{(small angle)} \]
\[ T = T_0\left(1 + \frac{1}{16}\theta_0^2 + \frac{11}{3072}\theta_0^4 + \cdots\right) \]

The correction terms grow rapidly near 180°, where the pendulum can balance upright indefinitely — an unstable equilibrium.

🔄 Spring-Mass System Intermediate
A mass on a spring with configurable damping. Watch underdamped oscillations decay, find critical damping (fastest return), or overdamped creep. Live displacement vs time plot alongside the animation.
Parameters
Regime
ω' (rad/s)
Critical damping: b = 2√(km). This gives the fastest return to equilibrium without oscillating — used in car suspensions and door closers.
General Solution
\[ m\ddot{x} + b\dot{x} + kx = 0 \]
\[ x(t) = A e^{-\gamma t}\cos(\omega' t + \phi),\quad \omega' = \sqrt{\frac{k}{m}-\gamma^2},\quad \gamma=\frac{b}{2m} \]
Three Regimes

Underdamped (b² < 4km): oscillates with decaying amplitude. Critically damped (b² = 4km): returns fastest without oscillating. Overdamped (b² > 4km): creeps to equilibrium slowly.

🧲 Magnetic Field Lines Intermediate
Click to place magnetic dipoles and watch the field lines form. See how dipoles attract, repel, and organise. The field geometry is identical to electric dipoles — but with no monopoles.
Place Dipoles
Click canvas to place a dipole. Right-click to remove nearest.
Show strength
Dipole Field
\[ \mathbf{B} = \frac{\mu_0}{4\pi}\frac{3(\mathbf{m}\cdot\hat{r})\hat{r}-\mathbf{m}}{r^3} \]

The field of a magnetic dipole falls as 1/r³ — faster than a monopole (1/r²). This means magnetic effects become negligible quickly with distance.

No Magnetic Monopoles
\[ \nabla\cdot\mathbf{B} = 0 \]

Unlike electric fields, magnetic field lines always close on themselves. There is no magnetic equivalent of a lone charge. This is one of Maxwell's equations. Magnetic monopoles are predicted by some GUT theories but have never been observed.

🔭 Geometric Optics Intermediate
Trace light rays through convex and concave lenses. Watch how lenses focus or diverge a beam. See real vs virtual image formation. Click lenses to select and drag them.
Optics Setup
Drag lenses to reposition. Real images form where rays converge; virtual images form where backwards-extended rays meet.
Thin Lens Equation
\[ \frac{1}{f} = \frac{1}{d_o} + \frac{1}{d_i} \]

f is focal length (positive for converging, negative for diverging). d_o is object distance, d_i is image distance. Negative d_i means a virtual image on the same side as the object.

Snell's Law
\[ n_1\sin\theta_1 = n_2\sin\theta_2 \]

Light bends toward the normal when entering a denser medium. Glass (n≈1.5) bends light enough to focus it. The critical angle for total internal reflection is θ_c = arcsin(n₂/n₁).

〰 Single-Slit Diffraction Intermediate
Fraunhofer diffraction from a single slit. The wavelength slider changes the color of the pattern in real time. Explore how slit width determines resolution — the Rayleigh criterion limits every telescope and microscope.
Parameters
1st min (mm)
Rayleigh (mrad)
Fraunhofer Intensity
\[ I(\theta) = I_0 \left(\frac{\sin\alpha}{\alpha}\right)^2, \quad \alpha = \frac{\pi a\sin\theta}{\lambda} \]

The intensity pattern is the square of the Fourier transform of the aperture. The sinc² envelope sets the locations of zeros at a·sinθ = mλ for integer m ≠ 0.

Rayleigh Criterion
\[ \theta_{min} = 1.22\frac{\lambda}{D} \]

Two point sources can just be resolved when the central maximum of one falls on the first minimum of the other. The Hubble Space Telescope's 2.4m mirror gives θ_min ≈ 0.05 arcseconds at 500nm.

🌡 Ideal Gas — PV = nRT Intermediate
Particle simulation of an ideal gas. Compress or expand using the piston. Particles are colored by speed (Maxwell-Boltzmann distribution). Watch pressure, volume, and temperature change in real time with a live PV diagram.
Parameters
Pressure
Volume %
Temp K
v_rms
Ideal Gas Law
\[ PV = nRT \]

Pressure × Volume = amount × gas constant × temperature. This is an approximation that treats molecules as point particles with no interactions — excellent for dilute gases.

Maxwell-Boltzmann Distribution
\[ f(v) = 4\pi\!\left(\frac{m}{2\pi k_B T}\right)^{3/2}v^2\,e^{-mv^2/2k_BT} \]

Most probable speed: v_p = √(2k_BT/m). Root-mean-square: v_rms = √(3k_BT/m). Mean: v̄ = √(8k_BT/πm). The tail of the distribution determines evaporation rates and chemical reaction rates.

🌐 2D Wave Equation Intermediate
Waves propagating on a 2D membrane, solved numerically with finite differences. Click to create pulses and watch interference patterns form. The color shows displacement height from blue (trough) to red (crest).
Parameters
Click canvas to create a pulse. Try multiple pulses and watch them interfere!
2D Wave Equation
\[ \frac{\partial^2 u}{\partial t^2} = c^2\!\left(\frac{\partial^2 u}{\partial x^2}+\frac{\partial^2 u}{\partial y^2}\right) \]

c is the wave speed. For a drum membrane, c = √(T/σ) where T is tension and σ is surface density. The simulation uses an explicit finite-difference scheme with stability condition c·dt/dx < 1/√2.

Normal Modes of a Square Drum
\[ f_{mn} = \frac{c}{2L}\sqrt{m^2+n^2}, \quad m,n=1,2,3,\ldots \]

Unlike a 1D string, the modes are not harmonically related — which is why drums sound less "musical" than strings. Chladni patterns visualize these modes with sand on vibrating plates.

🔀 Logistic Map & Bifurcation Advanced
The bifurcation diagram of x→rx(1−x): period 2, period 4, period 8, then chaos. Drag the r slider to trace your way through period-doubling to the edge of chaos. The Feigenbaum constant δ ≈ 4.669 is universal.
Parameters
Show cobweb
Key values: r=3 (first split), r=3.449 (period 4), r=3.544 (period 8), r=3.57 (onset of chaos). Feigenbaum δ ≈ 4.669.
The Map
\[ x_{n+1} = r\,x_n(1-x_n), \quad x\in[0,1],\; r\in[0,4] \]

Originally a model for population dynamics (r = growth rate, x = fraction of max population). Despite its simplicity, it displays the full route from order to chaos.

Feigenbaum Universality
\[ \delta = \lim_{n\to\infty}\frac{r_n - r_{n-1}}{r_{n+1}-r_n} \approx 4.6692\ldots \]

The ratio of successive bifurcation widths converges to δ. Remarkably, this constant is the same for any smooth unimodal map — it is a universal constant of chaos theory, analogous to π or e.

🪐 Kepler Orbits Intermediate
Animate a planet orbiting a star. Kepler's 2nd law — equal areas in equal times — is shown by shading swept sectors. Adjust eccentricity to go from circular orbit to near-parabolic escape.
Parameters
Show swept areas
Period (s)
Speed (px/s)
Notice: the planet moves fastest at perihelion (closest to star) and slowest at aphelion. This is Kepler's 2nd law.
Kepler's Three Laws

1st: Orbits are ellipses with the star at one focus. 2nd: Equal areas are swept in equal times (conservation of angular momentum). 3rd: T² ∝ a³.

\[ T^2 = \frac{4\pi^2}{GM}\,a^3 \]
Vis-Viva Equation
\[ v^2 = GM\!\left(\frac{2}{r}-\frac{1}{a}\right) \]

Gives orbital speed at any point. At perihelion r is smallest so v is largest. At aphelion they swap. If v exceeds √(2GM/r) the object escapes — escape velocity.

⚛ Schrödinger Equation (1D) Advanced
Watch a Gaussian wave packet evolve through a potential barrier. Quantum tunneling: part of the packet passes through even though classically it shouldn't have enough energy. Shows |ψ|² and Re(ψ).
Parameters
Transmission
Reflection
Energy < barrier: classical particle would bounce back. Quantum packet partially tunnels through — probability decreases exponentially with barrier width.
Time-Dependent Schrödinger Equation
\[ i\hbar\frac{\partial\psi}{\partial t} = -\frac{\hbar^2}{2m}\frac{\partial^2\psi}{\partial x^2} + V(x)\psi \]

The wave function ψ(x,t) contains all information about the particle. |ψ|² is the probability density. The simulation uses a split-operator method: propagate kinetic and potential parts alternately in Fourier space.

Transmission Coefficient
\[ T \approx e^{-2\kappa d},\quad \kappa = \sqrt{\frac{2m(V_0-E)}{\hbar^2}} \]

Tunneling probability falls exponentially with barrier width d and the square root of the energy deficit. This underpins tunnel diodes, STM microscopes, nuclear fusion in the Sun, and radioactive α-decay.

⚡ Charged Particle in EM Fields Intermediate
Animate a charged particle in configurable E and B fields. See circular motion in pure B, straight acceleration in pure E, and the famous E×B drift in crossed fields. The trajectory is traced in real time.
Field Settings
Cyclotron r
ω_c (rad/s)
Lorentz Force
\[ \mathbf{F} = q(\mathbf{E} + \mathbf{v}\times\mathbf{B}) \]

The magnetic force is always perpendicular to velocity — it does no work, only curves the trajectory. This is why magnetic fields can steer but not accelerate charged particles (particle accelerators need electric fields for the acceleration).

Cyclotron Frequency & E×B Drift
\[ \omega_c = \frac{qB}{m}, \quad v_d = \frac{E}{B} \]

In crossed E and B fields the particle drifts perpendicular to both, at speed E/B — independent of the particle's charge or mass. This E×B drift is used in plasma confinement and Hall-effect thrusters.

🎵 Vibrating String — Normal Modes Beginner
A glowing vibrating string with selectable harmonics n = 1…8. Add and remove harmonics to build up a superposition. See how musical timbre is just a mixture of standing waves. Visually striking animations with thick glowing strings.
Harmonics
Show modes
n=1 is the fundamental. n=2 is an octave up. Each mode has n half-wavelengths fitting the string length.
Standing Wave Solution
\[ y(x,t) = \sum_{n=1}^{N} A_n \sin\!\left(\frac{n\pi x}{L}\right)\cos(n\omega_0 t) \]

Each mode has n half-wavelengths fitting the string length L. The modes are harmonically related (f_n = n·f₀) which is why strings produce musical tones. Drums have inharmonic modes, which is why they sound "thumpy".

Wave Speed on a String
\[ v = \sqrt{\frac{T}{\mu}},\quad f_n = \frac{n}{2L}\sqrt{\frac{T}{\mu}} \]

T is tension, μ is linear mass density. Guitarists change pitch by fretting (changing L) or tuning (changing T). Thicker strings (larger μ) vibrate lower — hence bass strings are wound with metal wire.

💡 Suggest a Simulation

What physics topic would you love to explore interactively? Every suggestion is read.

✓ Thanks! We'll consider it for the roadmap.