Physics Simulation: This simulation updates the rocket's state using basic physics equations that account for thrust, gravity, and air resistance.
Equations:
$$\displaystyle \mathbf{v} = \mathbf{v} + \mathbf{a} \cdot dt - \text{drag} \cdot \mathbf{v} $$
$$\displaystyle \text{pos} = \text{pos} + \mathbf{v} \cdot dt $$
Here, \( \mathbf{v} \) is the velocity vector, \( \mathbf{a} \) is the acceleration vector (including thrust and gravity), drag
is the air resistance coefficient, and \( dt \) is the time step (approximately \( \frac{1}{60} \) sec). When the space key is pressed, an upward thrust is applied.
Control Instructions: