Rocket Simulations 2D: Launch Angle |
Calculating altitude for a vertical launch is a one-dimensional problem, straight up and straight down. There is a single distance, a single velocity, a single thrust force and so on. When launching at an angle, we now have both a vertical and a horizontal component for each of the calculated parameters - distance, velocity, acceleration, thrust and drag. It is helpful to track the flight angle as well - the direction of the velocity vector. Notice I define two angles -- the launch angle, "la", the angle of the launch rod from vertical, which does not change (this is a constant) , and the flight angle, "fa", the angle of the rocket's flight path from vertical, which does change once the rocket is off the launch rod. The basic algorithm is the same as the vertical launch version of the simulation with the difference being that the horizontal and vertical components are found separately for each time increment and then combined to get a new velocity vector for that time point. If you are not familiar with vectors (values with both magnitude and direction) and vector arithmetic, you should study up on that topic so you can understand what's going on here. We'll skip the initial launch for the moment, and take up the algorithm mid-flight.
There's one other trick -- handling the effect of the launch rod during the initial launch. The launch rod only allows forces, like gravity, to act along the axis of the rod. Since the rocket is aligned with the rod, the full thrust is seen along that axis. The component of gravity that is perpendicular to the rod is supported by the rod, so only the component along the axis of rod acts on the rocket during this phase. This would be gc*cos(la), where la is the launch angle. Because this is no longer vertical, there is a horizontal and vertical component, so the horizontal component is gx = gc*cos(la)*sin(la) and the vertical component is gy = gc*cos(la)*cos(la) = gc*cos(la)^2. Then until the rocket reaches the end of the launch rod, I handle this in the spreadsheet by defining gx & gy as above until the rocket's travel exceeds the length of the launch rod, then past that point, gx = 0 and gy = gc. |
My Astrocam Excel Simulation, the 2D version
My MiniMagg Excel Simulation, high power 2D sim using thrust curves, with trial & error launch angle optimizing for wind speed.
Mark Sullivan's Model Rocket Altitude Predictor: an
outstanding, working online rocket simulator
Your questions and comments regarding this page are welcome.
You can e-mail Randy Culp for inquiries,
suggestions, new ideas or just to chat.
Updated 19 July 2009