100 Simulations Milestone: Rocket Launch & Atmospheric Re-entry

Simulation #99 and #100 were always going to be special. I picked two aerospace classics — a two-stage rocket powered by Tsiolkovsky's equation and a physically-accurate re-entry heatshield model — and used them to cross the 100-simulation line. Here's how both were built and what reaching that number actually felt like.

🎉 100 SIMULATIONS MILESTONE

Why 100 Matters

Numbers are arbitrary. A hundred simulations isn't fundamentally different from ninety-nine. But milestones give you a moment to pause, look back at how far you've come, and plan the next leg. When I counted up to 98 finished simulations, I deliberately saved two aerospace subjects I'd been wanting to build for months — so the milestone itself would feel earned.

The aerospace category was already at four completed simulations (orbital mechanics, star evolution, atmospheric optics, solar system). Adding rocket launch and re-entry brought it to six — all ready, all with full EN + UK versions, SEO packages and sitemap entries.

Simulation #99 — Rocket Launch (Tsiolkovsky)

The physics

Konstantin Tsiolkovsky's rocket equation is one of the most consequential formulas in engineering:

Δv = v_e · ln(m₀ / m_f)

where v_e is the effective exhaust velocity, m₀ is the initial (wet) mass including propellant, and m_f is the final (dry) mass. The logarithm is the killer: to double your Δv you don't double your fuel — you square your mass ratio. That's why multi-stage rockets exist.

What the simulation shows

The sim implements a two-stage rocket with a live Δv budget readout. Each stage has configurable thrust, specific impulse (Isp), dry mass and propellant mass. As fuel burns, mass drops and acceleration climbs — you can watch the staging event as the first-stage mass is jettisoned and a second Tsiolkovsky budget starts fresh.

The gravity turn is modelled by a simple pitch programme — the rocket starts vertical, then follows a smooth curve toward horizon as velocity builds. Once orbital velocity is achieved, a flash confirms "orbit inserted" and the Δv budget remaining is shown.

// Tsiolkovsky integration step
const thrust = stage.thrust;          // N
const mdot   = thrust / (stage.isp * 9.80665);  // kg/s
const acc    = thrust / mass - g(altitude);
mass   -= mdot * dt;
vSpeed += acc * Math.sin(pitchAngle) * dt;
hSpeed += acc * Math.cos(pitchAngle) * dt;

The tricky part: gravity turn

Getting the pitch programme right took more iteration than expected. Too aggressive and the rocket tips over before it has enough velocity; too slow and the Δv budget gets eaten by gravity losses. The final implementation uses a linear pitch-over starting at 2 km altitude, rotating from 90° (vertical) to 0° (horizontal) as vertical velocity approaches orbital target. It's simplified compared to a real vehicle but it teaches the concept perfectly.

Simulation #100 — Atmospheric Re-entry

The physics

Atmospheric re-entry is a thermal engineering problem as much as a flight dynamics one. The heating rate on a blunt-body heatshield is given by the Sutton–Graves approximation:

q = k · √(ρ/R_n) · V³

where ρ is local air density, R_n is nose radius, V is velocity, and k is approximately 1.83 × 10⁻⁴ (SI units). Velocity enters as a cube — so the difference between a shallow, slow entry and a steep, fast one is dramatic in terms of heat load.

What the simulation shows

The vehicle starts at 120 km altitude on a user-defined re-entry trajectory. Drag coefficient, nose radius and vehicle mass are all configurable. As it descends through the atmosphere model (exponential density scale height), the simulation tracks:

The four-outcome system was fun to design. A very shallow angle produces a skip-out (the vehicle bounces off the atmosphere like a smooth stone on water). Too steep and the heat rate exceeds the heatshield limit — the vehicle is marked as destroyed. The Goldilocks corridor that produces a safe landing is much narrower than most people expect: typically just a few degrees.

// Re-entry outcome logic
if (altitude > 120_000 && flightPathAngle > -1) {
  outcome = 'skipout';
} else if (skinTemp > heatshieldLimit) {
  outcome = 'destroyed';
} else if (altitude < 10_000 && speed < 200) {
  outcome = 'parachute';
} else if (altitude <= 0) {
  outcome = speed < landingSpeed ? 'safe' : 'crash';
}

The Aerospace Category — Complete at Six

With these two additions, the aerospace category reached six simulations with zero "coming soon" placeholders:

Reflections on 100

The first simulation — a fluid SPH experiment — was built in a weekend in January 2024 just to see if Three.js could handle it in the browser. That was Devlog #1. Two years and two months later, there are a hundred of them, covering everything from quantum computing to cardiac action potentials to galaxy formation to traffic jams.

The biggest surprise has been how many of these work beautifully in pure Canvas 2D. When I started I assumed most serious simulations would require WebGL. It turns out requestAnimationFrame + a well-optimised particle loop + ImageData for per-pixel rendering covers an enormous amount of ground. Three.js is reserved for genuine 3D — everything else runs comfortably in 2D canvas at 60 FPS.

Milestone stats (simulation #100): 6 aerospace simulations · all EN + UK · full SEO + sitemap · zero "coming soon" placeholders in the category.

What Came Next

Building past 100 felt natural rather than anti-climactic. Immediately after the milestone two more simulations landed — Earth Energy Balance (a zero-dimensional climate model) and the Carbon Cycle (a four-box ocean-atmosphere model). The library had momentum, and there was no reason to slow down.

The sessions after 100 brought complete new categories: Molecular Biology, Perception, Machine Learning, Decision Trees, Robotics, Nuclear Physics, Sports Science, Cryptography, Quantum Computing — each one reaching zero "coming soon" cards before the next began. By the time this post is published the count stands at 212 simulations.