I. Fluid Dynamics: From Vortex Rings to Rarefied Gas
💨Vortex Ring — Dynamics, Leapfrogging & Reconnection
Shoot a toroidal vortex through a fluid at rest. Control ring radius, core thickness, and circulation. Launch a second ring and watch leapfrogging; bring two counter-rotating rings together and observe reconnection.
A vortex ring is one of the most durable structures in fluid dynamics. Unlike a blob of dye that diffuses away within seconds, a vortex ring can travel metres through still air, maintaining its identity for tens of ring-radii of travel. It is self-propelling: the ring induces a velocity field that advects its own core forward at speed
V_ring = (Gamma / 4*pi*R) * (ln(8R/a) - 1/4)
Gamma : circulation (m^2/s) — integral of vorticity over cross-section
R : ring radius (m)
a : core radius (m, a << R for a thin-core ring)
The Biot–Savart law for a circular filament gives this leading-order result.
The logarithmic term reflects the long-range induction from the ring's own far field. Thin rings (a/R → 0) travel fastest because the self-induction diverges as the core shrinks, yet viscosity always thickens the core over time, gradually slowing the ring. This is why a dolphin's bubble ring eventually stalls and rises rather than shooting forward indefinitely.
Leapfrogging
Launch two co-axial rings of the same sign in tandem and a remarkable dance begins: the trailing ring accelerates (it travels through the converging induced flow of the leader), threads through the leading ring, becomes the new leader, and the cycle repeats. This leapfrogging is periodic and stable when the rings are identical, but breaks down into chaos when they differ slightly in circulation or radius — a beautiful route to turbulence observable in a tank of water with dye injection.
🌀Taylor–Green Vortex — Turbulence Onset & Energy Cascade
Simulate the canonical Taylor–Green initial condition in a periodic box. Watch the initially smooth sinusoidal velocity field break up into small-scale turbulence. Plot kinetic energy, enstrophy, and the Kolmogorov energy spectrum.
The Taylor–Green vortex is the theorist's favourite test case for turbulence. The initial velocity field is a simple trigonometric pattern — smooth, periodic, analytically known — yet within a few turnover times it develops all the hallmarks of fully developed turbulence: a broad inertial range in the energy spectrum, intense vortex tubes, and intermittent dissipation events. The reason is that the Navier–Stokes equations are nonlinear: any smooth initial condition at high Reynolds number will cascade energy from large scales to small scales until viscous dissipation finally absorbs it.
Initial condition (3D, periodic box [0, 2*pi]^3):
u = V_0 * sin(x) * cos(y) * cos(z)
v = -V_0 * cos(x) * sin(y) * cos(z)
w = 0
Kolmogorov energy spectrum (inertial range):
E(k) ~ C * epsilon^(2/3) * k^(-5/3)
epsilon : mean energy dissipation rate (m^2/s^3)
k : wavenumber (rad/m)
C : Kolmogorov constant ~ 1.5
Valid for L^-1 << k << eta^-1 (L = integral scale, eta = Kolmogorov microscale)
The −5/3 slope of the energy spectrum is Kolmogorov's 1941 prediction, and it holds remarkably well in experiments and simulations across many orders of magnitude in Reynolds number. The simulation plots this spectrum in real time, letting you measure the slope and watch it steepen from −2 (the initial large-scale regime) toward −5/3 as turbulence develops, and then flatten again as energy accumulates at the dissipation scale.
🫧Rising Bubble — Rayleigh–Taylor Instability & Deformation
Release a light gas bubble in a dense fluid. Control bubble radius, density ratio, and surface tension. Watch the bubble deform from spherical through oblate to toroidal (donut) as it rises, and observe Rayleigh–Taylor spikes when density stratification is inverted.
A rising bubble is governed by the balance between buoyancy, drag, surface tension, and inertia. For small bubbles, surface tension holds the shape spherical and Stokes drag dominates. For large bubbles, inertia wins: the bubble deforms into an oblate spheroid, then a spherical cap, and — in the right density ratio regime — eventually pinches off its rear to form a toroidal bubble ring. The dimensionless numbers that control this phase diagram are the Eötvös number Eo = gΔρR²/σ (ratio of buoyancy to surface tension) and the Morton number Mo = gμ&sup4;Δρ/(ρ²σ³).
The Rayleigh–Taylor instability occurs when a heavier fluid sits on top of a lighter one (e.g., water above oil, or dense stellar material above a convective zone). Small perturbations at the interface grow exponentially with growth rate γ = sqrt(A·g·k), where A is the Atwood number (ρ&sub2;−ρ&sub1;)/(ρ&sub2;+ρ&sub1;) and k is the wavenumber. The interface rapidly develops “spikes” of heavy fluid falling through “bubbles” of light fluid — a pattern seen in supernova remnants, inertial confinement fusion capsules, and overturned paint tins alike.
Rarefied Gas — DSMC & Knudsen Number Regimes
Simulate gas flow at the molecular scale using the Direct Simulation Monte Carlo (DSMC) method. Vary the Knudsen number from continuum (Kn < 0.001) to free-molecular (Kn > 10). Observe velocity slip, temperature jump, and Knudsen-layer effects that the Navier–Stokes equations miss entirely.
The Navier–Stokes equations assume the fluid is a continuous medium — a valid approximation when the mean free path λ is much smaller than the flow length scale L. The ratio Kn = λ/L, the Knudsen number, tells you when this breaks down. At Kn > 0.01, slip velocity at walls becomes measurable; at Kn > 0.1, the entire velocity profile changes character; at Kn > 10, molecules travel from wall to wall without any collisions (free-molecular flow). This regime is ubiquitous in spacecraft aerodynamics, MEMS devices, and the upper atmosphere above 80 km.
The DSMC (Direct Simulation Monte Carlo) method, developed by Graeme Bird in the 1960s, simulates a representative sample of molecules, computing their trajectories and stochastic collisions at each time step. It converges to the Boltzmann equation rather than Navier–Stokes, and captures effects like velocity distribution functions departing from the Maxwell–Boltzmann equilibrium — effects that no continuum method can reproduce.
🌊Viscoelastic Waves — Maxwell Fluid & Kelvin–Voigt Model
Send a wave pulse through a viscoelastic medium. Switch between Maxwell (spring and dashpot in series) and Kelvin–Voigt (in parallel) models. Observe wave speed dispersion, attenuation, and the crossover from elastic solid to viscous liquid behaviour as frequency changes.
Most real fluids are neither purely viscous (like water) nor purely elastic (like rubber): they are viscoelastic. Mucus, blood, molten polymers, biological gels, and Earth's mantle all flow like liquids at long timescales and rebound like solids at short timescales. The Maxwell model captures this with a single relaxation time τ:
Maxwell constitutive equation:
dσ/dt + σ/τ = G * dε/dt
σ : stress (Pa) ε : strain
G : elastic modulus (Pa) τ = η/G : relaxation time (s)
η : dynamic viscosity (Pa·s)
At timescales t << τ : solid-like (elastic storage)
At timescales t >> τ : liquid-like (viscous flow)
Wave speed in a Maxwell fluid (frequency ω):
c(ω) = sqrt(G/ρ) * |ωτ| / sqrt(1 + ω^2 τ^2)
→ 0 at low frequency (no shear waves in a liquid)
→ sqrt(G/ρ) at high frequency (shear wave speed of solid)
II. Astrophysics: Stellar Interiors, White Dwarfs & Exoplanet Transits
⭐Stellar Interior — Structure Equations & Main-Sequence Stars
Integrate the four stellar structure equations for a star of chosen mass and composition. Visualise radial profiles of pressure, temperature, density, and luminosity. Toggle between radiative and convective zones; shift composition to watch the star move on the HR diagram.
A star is a self-gravitating ball of gas in hydrostatic equilibrium: gravity pulls inward, pressure gradient pushes outward, and nuclear reactions at the centre supply the energy that maintains the temperature gradient. Four coupled differential equations describe the entire structure:
Stellar structure equations:
dM/dr = 4π r^2 ρ (mass continuity)
dP/dr = -G M(r) ρ / r^2 (hydrostatic equilibrium)
dL/dr = 4π r^2 ρ ε(r,T,X) (energy generation)
dT/dr = -(3 κ ρ L) / (64π σ_SB r^2 T^3) (radiative transport)
or -(1 - 1/γ) T/P * dP/dr (adiabatic, if convective)
ρ : density κ : opacity ε : nuclear energy generation rate
X : hydrogen mass fraction γ : adiabatic index
σ_SB : Stefan–Boltzmann constant
The switch between radiative and convective transport is governed by the Schwarzschild criterion: convection sets in wherever the actual temperature gradient steepens beyond the adiabatic gradient. Low-mass stars like the Sun have convective envelopes surrounding a radiative core; massive stars above roughly 1.5 M⊙ flip this arrangement, with convective cores and radiative envelopes. The simulation shows both cases and lets you trace the boundary in real time as you adjust stellar mass.
The pp-chain and CNO cycle
Below about 1.5 solar masses the proton–proton chain dominates nuclear burning: four protons fuse into one helium-4 nucleus, releasing 26.73 MeV (the mass defect converted by E = mc²). Above 1.5 M⊙, the CNO cycle takes over, using carbon, nitrogen, and oxygen as catalysts. Because the CNO rate scales roughly as T^20 versus T^4 for the pp-chain, CNO stars are far more temperature-sensitive: a slight increase in central temperature produces a huge increase in luminosity, explaining why the main sequence steepens sharply above 1.5 M⊙ on the Hertzsprung–Russell diagram.
White Dwarf Cooling — Mestel's Law & Crystallisation
Follow a carbon–oxygen white dwarf as it cools over billions of years. Plot luminosity versus age (Mestel's cooling law). Watch the core crystallise as the ion plasma solidifies, releasing latent heat that temporarily stalls the cooling curve — exactly as observed by Gaia for nearby white dwarfs.
A white dwarf has no nuclear energy source. It is simply a hot ember — a degenerate carbon–oxygen core roughly the size of Earth — radiating stored thermal energy into space. Because electron degeneracy pressure supports it against gravity regardless of temperature, cooling does not trigger contraction: the star just dims. The classical Mestel cooling law gives the luminosity as a function of age:
Mestel cooling law (simplified):
L/L_sun ~ 10^5 * (M/M_sun)^(5/7) * (mu_e / mu_I)^(2/7) * (t / 1 Gyr)^(-7/5)
mu_e : mean molecular weight per electron
mu_I : mean molecular weight per ion
t : cooling age (Gyr)
A 0.6 M_sun CO white dwarf reaches L ~ 10^-4 L_sun at ~5 Gyr
and L ~ 10^-5 L_sun at ~10 Gyr (the faintest nearby white dwarfs)
The cooling law is a powerful cosmochronometer: the coolest white dwarfs in a stellar population give a lower bound on its age. But there is a wrinkle. When the core temperature drops below about 10&sup6; K, the Coulomb coupling parameter Γ (ratio of electrostatic to thermal energy) exceeds 175 and the ion lattice crystallises. The phase transition releases latent heat, temporarily halting the cooling and producing a pile-up of white dwarfs at a specific luminosity — a feature clearly detected by Gaia DR2 in the Hertzsprung–Russell diagram of 260,000 nearby white dwarfs.
White dwarfs are the most common stellar remnant in the Galaxy. About 97% of all stars, including the Sun, will end their lives as white dwarfs. Because they cool monotonically and predictably, a census of white dwarf luminosities is equivalent to a census of stellar ages — the “white dwarf luminosity function” is one of the few model-independent clocks available to Galactic archaeology.
Exoplanet Transit Photometry — Light Curves & Limb Darkening
Configure a star and orbiting planet (radius ratio, orbital inclination, semimajor axis, limb-darkening coefficient). Simulate the transit light curve and recover planetary radius from the depth. Add noise to mimic Kepler or TESS observations and practice fitting the transit model.
When a planet passes in front of its host star, it blocks a tiny fraction of the starlight: the transit depth δ = (R_p/R_*)², where R_p is the planetary radius and R_* is the stellar radius. For an Earth-Sun analogue, δ ~ (6371/696000)² ~ 84 ppm — a dimming of 0.0084%, achievable with space-based photometry from Kepler or TESS but invisible from the ground. For a hot Jupiter (R_p ~ 1.2 R_Jup, R_* ~ 1 R_Sun), δ ~ 1.3%, readily measured with a modest telescope.
Key transit observables:
Transit depth: δ = (R_p / R_*)^2
Transit duration: T_14 = (P / π) * arcsin(sqrt((R_* + R_p)^2 - b^2 R_*^2) / a)
Impact parameter: b = (a/R_*) * cos(i) (i = orbital inclination)
Limb darkening (quadratic law):
I(μ) / I(1) = 1 - u_1*(1-μ) - u_2*(1-μ)^2
μ = cos(θ) θ = angle from disc centre
u_1, u_2 : tabulated from stellar atmosphere models (e.g. ATLAS9)
Limb darkening rounds the flat-bottomed transit into a curved dip
and must be accounted for to recover R_p precisely.
The simulation reproduces the four-contact transit model: first external contact (T1), first internal contact (T2), second internal contact (T3), and second external contact (T4). Between T2 and T3 the planet is fully on the stellar disc and the flux decrement is approximately constant at depth δ; the ingress (T1–T2) and egress (T3–T4) slopes encode the planet-to-star radius ratio and the transit speed. Limb darkening — the fact that the stellar limb is cooler and dimmer than the centre — rounds the flat bottom into a curved bowl, an effect especially pronounced in blue optical bandpasses.
What transits reveal beyond radius
A single transit light curve gives you the planetary radius (from depth), the orbital inclination (from duration), and the limb-darkening profile (from the in-transit curvature). Combine with radial velocity measurements and you get the planet's mass and hence its bulk density — the key to distinguishing rocky super-Earths from water worlds from mini-Neptunes. Transmission spectroscopy, measuring how transit depth varies with wavelength, probes the planetary atmosphere: molecular absorption features of water, carbon dioxide, methane, or sodium inflate the effective radius at specific wavelengths and imprint themselves on the wavelength-dependent depth. It is the primary tool for characterising exoplanet atmospheres with JWST.
Try All Eight Simulations
💨Vortex Ring
Launch rings, trigger leapfrogging, and watch toroidal vortices persist and reconnect.
Taylor–Green Vortex
Watch a smooth sinusoidal field develop into turbulence; observe the Kolmogorov −5/3 energy spectrum emerge.
Rising Bubble
Follow a bubble from spherical to toroidal as buoyancy, surface tension, and inertia compete; trigger Rayleigh–Taylor instability at inverted density gradients.
Rarefied Gas (DSMC)
Vary the Knudsen number and see continuum fluid mechanics break down; observe velocity slip and free-molecular flow at the molecular scale.
Viscoelastic Waves
Send pulses through Maxwell and Kelvin–Voigt media; observe dispersion, attenuation, and the solid–liquid crossover with frequency.
Stellar Interior
Integrate the stellar structure equations for any mass; explore convective versus radiative zones and watch the star move on the HR diagram.
White Dwarf Cooling
Follow Mestel's cooling law over billions of years; observe the crystallisation stall and its signature in the luminosity function.
Exoplanet Transit Photometry
Build a transit light curve from scratch; recover planetary radius and inclination; add noise to simulate Kepler and TESS observations.
Closing Thought
Fluid dynamics and astrophysics share more common ground than is often acknowledged. The same Navier–Stokes equations that govern a smoke ring also describe convection in the solar interior. The same Rayleigh–Taylor instability that breaks up a rising bubble also seeds structure in a supernova remnant. The same viscoelastic rheology that governs polymer flow also controls how Earth's mantle responds to glacial loading over millennia. Wave 110 places these eight simulations side by side so you can see those threads of connection and pull on them yourself — no installation, no dependencies, just physics running in your browser.