🧪 Explorer Progress:
Explorer Level 0 0 / 33 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
Distance (m)
vₓ (m/s)
vᵧ (m/s)
|v| (m/s)
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 grid of magnetic spins (white = up, black = down), each flipped probabilistically via the Metropolis algorithm. Drag the temperature slider down past kT/J ≈ 2.27 (the exact 2D critical point) and watch the lattice spontaneously order into large domains — a second-order phase transition. Above Tc: spins are disordered, net magnetisation ≈ 0. Below Tc: long-range order appears from nothing, magnetisation jumps. At exactly Tc, fluctuations occur at every length scale (scale invariance), and the same critical exponents appear in completely different systems — liquid-gas transitions, superconductors, protein folding. This universality is one of the deepest ideas in physics.
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 particle travels around a solenoid (the dark disk) via two paths that never enter the magnetic field region. Yet the interference pattern on the screen shifts as you increase the magnetic flux — the particle "feels" a field it never touches. This is only possible because the vector potential A (not just B) is the physically real quantity in quantum mechanics. At Φ/Φ₀ = 0 the two paths interfere constructively in the centre; at Φ/Φ₀ = 0.5 the pattern inverts completely. Each full unit of flux Φ₀ = h/e ≈ 2.07×10⁻¹⁵ Wb returns the pattern to its starting state.
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 frozen 380,000 years after the Big Bang. The top panel shows the temperature map of the sky (tiny hot/cold spots at ±200 μK). The bottom panel is the power spectrum: how much temperature variation exists at each angular scale ℓ. The peaks are the ringing of sound waves in the early universe — and their positions encode the age, geometry, and composition of the cosmos.
Explore ℓ Modes
Show temperature map
220
1st Peak ℓ
D (μK²)
ℓ = angular wavenumber — larger ℓ means smaller angular scale. ℓ=1 is the dipole (half the sky); ℓ=220 is about 1°. The first acoustic peak at ℓ≈220 is the sound that fit exactly once into the sound horizon before recombination.
What is the CMB?

For the first 380,000 years after the Big Bang, the universe was a hot, opaque plasma — photons and baryons (protons + electrons) were tightly coupled. As the universe expanded and cooled to ~3000 K, electrons combined with protons (recombination). The universe became transparent, and the photons last scattered. We observe this "last scattering surface" today as microwave radiation at T₀ = 2.725 K — redshifted by a factor of 1100.

Multipoles ℓ and Angular Scale
\[ \theta \approx \frac{180°}{\ell} \]

The CMB temperature field is expanded in spherical harmonics Y_ℓm(θ,φ). The multipole ℓ describes the angular scale:
• ℓ=1: dipole — one hemisphere hot, one cold (our motion through space)
• ℓ=2: quadrupole — four patches, 90° scale
• ℓ=10: ~18° patches — galaxy supercluster scales
• ℓ=220: ~1° patches — the "sound horizon", largest possible acoustic feature
• ℓ=1000: ~0.2° patches — galaxy cluster scales, entering Silk damping

The Power Spectrum
\[ D_\ell = \frac{\ell(\ell+1)}{2\pi} C_\ell \cdot T_0^2 \]

C_ℓ = ⟨|a_ℓm|²⟩ is the average power at multipole ℓ. The factor ℓ(ℓ+1)/2π gives the "flat" Sachs-Wolfe plateau at low ℓ a constant value, making the acoustic peaks clearly visible above it. D_ℓ is plotted in μK².

Acoustic Peaks: Frozen Sound

Before recombination, the baryon-photon fluid supported sound waves — pressure oscillations driven by gravity (dark matter clumps pulling baryons in) and radiation pressure (photons pushing back out). Modes that completed exactly 1, 2, 3... half-oscillations before recombination show up as peaks in D_ℓ:
Peak 1 (ℓ≈220): compressed once — the fundamental "note" of the universe
Peak 2 (ℓ≈540): compressed and rarefied — the octave. Weaker because baryons resist rarefaction
Peak 3 (ℓ≈800): compressed again — ratio of peak 1 to peak 2 measures baryon density

What the Peaks Tell Us

Peak 1 position (ℓ≈220): universe is spatially flat — Ω_total = 1.000 ± 0.002
Peak 1/2 height ratio: baryon density Ω_b h² ≈ 0.0224 — only 4.9% of universe is ordinary matter
Peak heights overall: dark matter Ω_c h² ≈ 0.120 — 26.4% is dark matter
Damping tail slope: thickness of last-scattering surface, photon diffusion length
The remaining ~68.7% is dark energy — causing the universe to accelerate its expansion.

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

At small angular scales (ℓ ≳ 1000), photons random-walk between scattering events during recombination, diffusing across the structures they pass through. This "Silk damping" (or diffusion damping) exponentially suppresses the acoustic peaks. The damping scale encodes the duration of recombination and the photon mean free path — measuring the effective "blur" of the last-scattering surface.

Inflation & the Plateau
\[ P(k) \propto k^{n_s - 1},\quad n_s \approx 0.965 \]

The large-angle plateau (ℓ < 30) is the Sachs-Wolfe plateau from inflationary perturbations — nearly scale-invariant quantum fluctuations stretched to cosmic scales during inflation. The spectral index n_s ≈ 0.965 (slightly less than 1, "red-tilted") matches inflationary predictions. Measuring n_s ≠ 1 is one of the strongest observational confirmations of inflation.

⚛ Standard Model Advanced
The most precisely tested theory in science. The Particle Table shows all 17 fundamental particles: 6 quarks (building blocks of protons and neutrons), 6 leptons (including the electron and neutrinos), 4 force-carrying gauge bosons (photon, W±, Z, gluon), and the Higgs boson that gives them mass. Switch to an interaction mode to see animated Feynman diagrams — e⁺e⁻ annihilation, Compton scattering, beta decay (n→p via a W boson), and quark confinement by colour flux tubes. Each diagram shows a real quantum process that happens billions of times per second inside matter.
Interaction
The Standard Model predicts the electron magnetic moment to 10 significant figures — the most accurate prediction in science. Select an interaction above to see animated Feynman diagrams of real quantum processes.
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.

What the Feynman Diagrams Show

e⁺e⁻ → γ → μ⁺μ⁻: An electron and positron annihilate into a virtual photon, which materialises as a muon pair. This is the process used in colliders like LEP.
Compton Scattering: A photon bounces off an electron, exchanging energy and momentum. The wavelength shift is given by Δλ = (h/mₑc)(1−cosθ).
Beta Decay: A down quark in the neutron emits a W⁻ boson, flipping to an up quark (neutron → proton). The W then decays into an electron and antineutrino.
Quark Confinement: As two quarks separate, the colour field narrows into a flux tube. When its energy equals 2mq, it snaps and creates a new quark-antiquark pair — quarks can never be isolated.

🌊 Fluid Flow (Lattice-Boltzmann) Advanced
Incompressible 2D flow solved with a lattice-Boltzmann method — a grid-based technique that simulates the statistical motion of fluid molecules. Try the Cylinder preset: at low speed the flow is smooth and symmetric; increase speed and the wake destabilises into a Kármán vortex street — alternating vortices that shed periodically. This same pattern causes bridge cables to hum, submarine periscopes to vibrate, and chimneys to sway. The colour map shows fluid speed (blue = slow, red = fast). Draw any obstacle and watch stagnation points, recirculation zones, and pressure gradients form in real time.
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
One equation. Infinite complexity. xn+1 = rxn(1−xn) — a feedback loop where today's population shapes tomorrow's. Below r=3: stable. Above r=3: oscillates between 2 values. At r≈3.57: chaos. The cobweb diagram (left) shows one trajectory; the bifurcation diagram (right) shows all long-term behaviours at once. Drag r and watch order collapse into chaos, one doubling at a time.
Parameters
Show cobweb
Route to chaos: r<3 → fixed point. r=3.0 → period 2 (flip-flop). r=3.449 → period 4. r=3.544 → period 8. r≈3.57 → chaos begins. r=3.82 → period-3 window (order in chaos!). Each bifurcation is 4.669× narrower than the last.
The Map
\[ x_{n+1} = r\,x_n(1-x_n), \quad x\in[0,1],\; r\in[0,4] \]

Introduced by biologist Robert May in 1976 as a model for population dynamics: x is the population as a fraction of its maximum, r is the growth rate. The (1−x) factor represents resource competition — the fuller the environment, the slower the growth. Despite its simplicity (one parameter, one variable), it encodes the full journey from order to chaos.

Fixed Points & Stability
\[ x^* = 1 - \tfrac{1}{r} \quad \text{(non-trivial fixed point)} \]

A fixed point satisfies x* = rx*(1−x*). The non-trivial solution x*=1−1/r is stable when |f'(x*)|=|r(1−2x*)|<1, which gives r<3. At r=3 the derivative equals −1 exactly, and the fixed point destabilises: the system bifurcates into a period-2 cycle.

Period Doubling: The Road to Chaos
\[ r_1=3,\; r_2\approx3.449,\; r_3\approx3.544,\; r_4\approx3.5644,\; \ldots \]

Each bifurcation doubles the period: 1→2→4→8→16→... This cascade of doublings accumulates at r∞≈3.5699. Beyond this point the system is chaotic — its long-term behaviour is sensitively dependent on initial conditions. Mathematically, the Lyapunov exponent λ changes sign from negative (order) to positive (chaos) at r∞.

Sensitive Dependence on Initial Conditions
\[ |x_n - y_n| \approx |x_0 - y_0|\, e^{\lambda n},\quad \lambda > 0 \text{ in chaos} \]

In the chaotic regime, two trajectories starting a distance ε apart diverge exponentially. After ~20 iterations with ε=10⁻¹⁰, they are completely uncorrelated. Try changing x₀ by 0.01 in the cobweb and observe: same map, wildly different trajectory after 50 steps. This is deterministic chaos — not random, but unpredictable in practice.

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

The ratio of successive bifurcation interval widths converges to δ. Feigenbaum (1978) discovered this constant is universal — identical for any smooth unimodal map (quadratic, sinusoidal, etc.). It has been observed experimentally in turbulence, dripping faucets, and electronic circuits. Like π or e, δ is a fundamental constant of mathematics, not of any particular physical system.

Windows of Order in Chaos

The chaotic region is not uniformly chaotic — periodic windows appear (period-3 at r≈3.82, period-5 at r≈3.74, etc.). By the Sharkovskii theorem, period 3 implies periods of every order exist. The period-3 window is visible as a bright gap in the bifurcation diagram — order emerging spontaneously from chaos before dissolving again.

🪐 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
A Gaussian wave packet (a localised quantum particle) propagates and hits a potential barrier, solved in real time with the split-step FFT method. The white curve is Re(ψ), and the filled area is |ψ|² — the probability of finding the particle. Quantum tunnelling: even when the packet's average energy is below the barrier height, part of the wavefunction leaks through. This is not a trick — it's how nuclear fusion ignites stars, how scanning tunnelling microscopes image individual atoms, and how transistors switch in modern CPUs. Raise the barrier height until tunnelling nearly vanishes, then try a very thin barrier — transmission depends exponentially on barrier width.
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.

🚀 Artemis 2 — Free-Return Trajectory Intermediate
Artemis 2 will send four astronauts around the Moon — the first humans in lunar distance since Apollo 17. This simulation shows the free-return trajectory: the spacecraft uses the Moon's gravity to loop back to Earth with no extra burn. Adjust the Moon's phase at launch and the TLI boost to find the sweet spot where the spacecraft swings around the Moon and returns home.
Launch Parameters
Ready
Status
Distance (px)
Speed (px/s)
Free-return preset: Moon Phase ≈ 11°, TLI Boost ≈ 32%. The spacecraft arcs to the Moon, swings behind it, and returns to Earth — no extra burn. Change Moon Phase to see misses and captures.
Trans-Lunar Injection (TLI)

From LEO (~400 km), the SLS upper stage fires to boost the Orion capsule onto a trajectory that reaches the Moon's distance (~384,400 km). The minimum-energy path is a Hohmann-like ellipse; boosting slightly above this gives a hyperbolic encounter needed for a free-return.

\[ v_{\text{TLI}} = v_{\text{circ}} \cdot (1 + \delta),\quad \delta \approx 31\text{–}35\% \]
Three-Body Equations of Motion

The spacecraft is governed by gravity from both Earth and Moon simultaneously. There is no closed-form solution — the trajectory must be numerically integrated.

\[ \ddot{\vec{r}} = -\frac{GM_E}{|\vec{r}|^3}\vec{r} - \frac{GM_M}{|\vec{r}-\vec{r}_M|^3}(\vec{r}-\vec{r}_M) \]
Free-Return vs Direct Return

A free-return trajectory is intrinsically safe: if the engine fails, the Moon's gravity automatically sends the crew home. Apollo 13 used this property after its oxygen tank exploded. Artemis 2 will fly a "hybrid free-return" — a slight variant that allows a closer lunar approach than the pure free-return geometry.

🔴 Mars Mission — Hohmann Transfer Intermediate
The fuel-optimal path from Earth to Mars is the Hohmann transfer orbit — an ellipse touching both planets' orbits. But timing is everything: Mars must be exactly 44° ahead of Earth at launch. Miss the window by even a few days and the spacecraft misses Mars entirely. The next chance comes 26 months later — the synodic period of Earth and Mars.
Parameters
Awaiting launch
Status
Transit (s)
Arrival (s)
Optimal window: Mars Phase = 44°, press Launch right away. The phase indicator changes green when the geometry is right. Drag Mars Phase away and see what happens to the trajectory.
Hohmann Transfer Delta-V

Two burns are needed: one at Earth to enter the transfer ellipse, one at Mars to enter orbit. The total Δv is the minimum possible for an impulsive transfer between coplanar circular orbits.

\[ \Delta v_1 = \sqrt{\tfrac{GM_\odot}{r_E}}\!\left(\sqrt{\tfrac{2r_M}{r_E+r_M}}-1\right),\quad \Delta v_2 = \sqrt{\tfrac{GM_\odot}{r_M}}\!\left(1-\sqrt{\tfrac{2r_E}{r_E+r_M}}\right) \]
Optimal Phase Angle & Synodic Period

Mars must be ahead of Earth at launch by the angle Mars covers during the ~259-day transit. The synodic period is how long until Earth and Mars return to the same relative alignment — about 780 days (26 months).

\[ \phi_{\text{opt}} = \pi - \omega_M T_{\text{trans}},\quad T_{\text{syn}} = \frac{T_E T_M}{T_M - T_E} \approx 780\text{ days} \]
Real Mission Numbers

Earth–Mars distance varies from 54 million km (closest approach) to 401 million km. Every Mars mission (Curiosity, Perseverance, MAVEN, InSight) launched in narrow windows. A crewed mission would require ~6–9 months one-way, meaning astronauts would spend ~3 years total — requiring radiation shielding and closed-loop life support.

💻 Qubit — Bloch Sphere Advanced
A quantum bit (qubit) can be in any superposition of |0⟩ and |1⟩ — visualized as a point on the Bloch sphere. The north pole is |0⟩, south pole is |1⟩, and the entire equator is 50/50 superpositions distinguished only by phase. Quantum gates are rotations of this sphere — apply H, X, Y, Z, S, and T and watch the state vector sweep across the sphere. This is the geometric heart of quantum computation.
Qubit State
Single-Qubit Gates
50%
P(|0⟩)
50%
P(|1⟩)
H gate: |0⟩ → |+⟩ (superposition). X gate: flips |0⟩ ↔ |1⟩. Z gate: phase flip — classically invisible, but detectable via interference. Start at |0⟩ (θ=0°) and apply H then Z then H — you get |1⟩!
Qubit State on the Bloch Sphere
\[ |\psi\rangle = \cos\!\tfrac{\theta}{2}|0\rangle + e^{i\phi}\sin\!\tfrac{\theta}{2}|1\rangle \]

Every pure qubit state corresponds to a unique point on the Bloch sphere surface. The angles θ (colatitude) and φ (longitude) parameterise all possible states. The global phase is unobservable — so the sphere surface, not a 4D complex space, captures everything measurable.

Pauli Matrices & Single-Qubit Gates
\[ X=\begin{pmatrix}0&1\\1&0\end{pmatrix},\; Y=\begin{pmatrix}0&{-i}\\i&0\end{pmatrix},\; Z=\begin{pmatrix}1&0\\0&{-1}\end{pmatrix},\; H=\frac{1}{\sqrt{2}}\begin{pmatrix}1&1\\1&{-1}\end{pmatrix} \]

Every single-qubit gate is a rotation of the Bloch sphere. X rotates π around the X-axis (|0⟩↔|1⟩). Z rotates π around Z (phase flip). H exchanges the X and Z axes, creating superposition. S and T are fractional Z rotations used in fault-tolerant quantum error correction.

Measurement Probabilities
\[ P(|0\rangle) = \cos^2\!\tfrac{\theta}{2},\quad P(|1\rangle) = \sin^2\!\tfrac{\theta}{2} \]

Measuring in the Z-basis only reveals the Z-component of the Bloch vector. The X and Y components (encoded in phase φ) are invisible to a single Z-measurement — they require interference experiments. This is why phase gates like Z and T are "classically invisible" but crucial for quantum algorithms (Deutsch-Jozsa, Grover, Shor).

💡 Suggest a Simulation

What physics topic would you love to explore interactively? Every suggestion is read — the most requested ones get built next.

🗳️ User-suggested simulations are already shaping the roadmap. Past suggestions that made it in: Logistic Map, Fluid Flow, Aharonov–Bohm Effect.
✓ Thanks! We'll consider it for the roadmap.