Equations of motion. A planar point mass in an inertial frame centred on the Earth: m dv/dt = T u − D v̂rel − (μm/r²) r̂, with μ = 3.986×1014 m³/s², gravity falling as 1/r² with altitude, drag D = ½ ρ vrel² Cd(M) A on the velocity relative to the rotating air, and the Earth-rotation bonus Ω R cosφ (0.465 km/s at the equator, × cosφ) included as the pad's initial inertial speed. Integrated with RK4 (0.02–0.05 s).
Atmosphere and drag. International Standard Atmosphere to 86 km (layers with lapse rates), a tabulated density above; the drag coefficient is a Mach-dependent table with the transonic peak near Mach 1.05. Thrust depends on ambient pressure, Isp = Ispvac − (Ispvac − Ispsl) p/p0.
Pitch programme and the gravity turn. Vertical rise, then a small kick; afterwards the thrust is held along the air-relative velocity (zero angle of attack, so no lateral aerodynamic load). The flight-path angle then changes by gravity alone: dγ/dt = −(g − v²/r) cosγ / v. A bigger or earlier kick turns the trajectory over lower in the dense air (more drag, higher q); a small or late kick keeps the rocket climbing vertically for longer (more gravity loss).
Dynamic pressure and max-Q. q = ½ ρ v² rises with speed and falls with density; its peak ("max-Q", typically Mach 1–1.5, 10–13 km for real launchers) sets the structural load. A throttle bucket lowers thrust through the transonic window so the vehicle is still slower when the air is still dense, at the price of some delta-v.
Tsiolkovsky and staging. Δv = Isp g0 ln(m0/mf) per burn; dropping the empty first stage and the fairing increases the mass ratio of the upper stage. Stage 2 uses a closed-loop altitude-ceiling guidance chosen by predicting the burn (the simulator tries many ceilings and keeps the one using least propellant).
The delta-v budget. For a launch to ~250 km the engines must supply roughly Δvideal ≈ 9.1–9.5 km/s = 7.8 km/s (orbital speed) − 0.41 (Earth rotation bonus at 28.5°) + gravity loss (∫ g sinγrel dt, 1.2–1.6) + drag loss (∫ D/m dt, 0.05–0.3; this heavy, slender vehicle sits at the low end) + steering loss (∫ (T/m)(1 − cosα) dt, thrust not aligned with velocity) + a small Earth-rotation geometry term. The simulator integrates all of these live; the identity holds to numerical precision (see Experiment 2).
Orbit check. From the final state the vis-viva equation v² = μ(2/r − 1/a) gives a, the eccentricity and the periapsis; the flight succeeds only if periapsis is above 150 km (otherwise drag brings the stage down within a few orbits). A lofted first burn ends with apogee at the target altitude, the vehicle coasts to apogee and a short prograde burn circularises.
Reusability. Landing the booster means leaving propellant in its tanks (the landing reserve slider). That mass is carried through the burn, reducing the first-stage mass ratio; Experiment 3 measures the resulting loss of payload.
Model and assumptions. Planar (2-D) motion due east, so the orbit inclination equals the launch latitude and out-of-plane effects are ignored; the atmosphere co-rotates rigidly; constant engine mass flow with throttling, no engine start-up transients, no wind or lift, no attitude dynamics (the attitude is commanded and instantaneous); stage and fairing masses are round textbook-style numbers; the spent booster and the fairing halves are drawn as ballistic free-flight bodies (the return and landing burns are not simulated: their cost enters only through the landing-reserve propellant). The reference scenario is a generic vehicle with a first stage of nine sea-level engines and one vacuum-optimised upper-stage engine; the numbers are illustrative, not those of any real vehicle. For background see Sutton and Biblarz, Rocket Propulsion Elements; Wiesel, Spaceflight Dynamics; Braeunig's rocket and space technology pages; the ISA tables (ISO 2533).
Civil, educational launch dynamics only: a generic launcher carrying a scientific or communications satellite to low Earth orbit. No real vehicle, brand, logo or livery is depicted.