Simulation
Starship Launch Trajectory and Control
A two-phase trajectory optimization followed by a forward dynamic launch simulation of SpaceX Starship, showing how a basic PID attitude control loop maintains stability against realistic wind, combustion and engine vibration disturbances from pad to LEO.
Links & Resources
Engineering Question
A multi-kilotonne rocket lifts off like an inverted pendulum, then accelerates through the atmosphere to supersonic speed while chaotic aerodynamic forces try to tip it over. Intuitively, that should not be stable. This project uses dynamic simulation and trajectory optimization to understand why it is — and to test whether a deliberately simple controller is enough to hold the vehicle on course from the launch pad to low Earth orbit.
Model and Assumptions
The model is built from a small set of accepted physical facts: each Raptor engine produces over 2 MN of thrust on methane–oxygen combustion; 13 of the 33 Super Heavy engines are gimballed, with actuators slewing at 5° per second; low-latency IMUs and GPS provide attitude estimates accurate to within 0.01°; and the control system is assumed to be no better than a basic 10 Hz PID loop. A 2D flat-Earth formulation is sufficient to capture the trajectory physics.
The analysis runs in two steps. First, a two-phase trajectory optimization finds the fuel-optimal path for direct insertion into LEO — "two-phase" because the Super Heavy booster separates from the Starship upper stage at Main Engine Cut-Off (MECO). The resulting trajectory comprises four segments — vertical ascent, turn-over manoeuvre, and gravity turns before and after MECO — with engine throttle and gimbal angle as the control variables.
Second, a forward dynamic simulation flies the full vehicle along that optimized reference while a realistic disturbance environment acts on it: turbulent wind from a Von Karman power spectral density, thrust fluctuations from combustion instabilities, and engine vibrations — the latter two represented by stochastic models. The PID attitude controller works against these disturbances, with the optimized trajectory as its target.
Results
For realistic disturbance amplitudes, even the simple 10 Hz PID loop keeps the rocket on target from liftoff to orbit without difficulty. The physics cooperates once the trajectory is well designed and the actuators are fast enough: the apparent instability of the inverted-pendulum ascent sits comfortably within the authority of a modest control system.
Significance
The instructive result is not that Starship can be stabilized — that turns out to be tractable — but where the real engineering difficulty lies. Keeping a vehicle of this scale controllable reliably enough to be recovered and reused, repeatedly and at an increasing flight rate, is the achievement that a clean stability simulation cannot fully capture.
Related work