Skip to main content
Sandbox Physics

M003 · Projectile motion and inverse design

Projectile Flight Designer

How do you aim a launch to hit a target through drag and crosswind? Aim with a flight simulation that includes drag; vacuum formulas will miss. Drag opposes the projectile's motion relative to the air, so a crosswind pushes it sideways too. Adjust the launch until the simulated path lands on target, and check the sideways miss from above, not just the range.

Launch from a platform toward a target you can move on the ground, and follow the flight in a side view, a view from above, the velocity components and the energy balance. Compare a vacuum with linear and quadratic drag, correct for a crosswind, or search for the elevation that gives the longest range at a fixed launch speed.

Interactive modelProjectile Flight Designer
Inspection cursor0 s0\,\mathrm{s}
Air-relative speed0 m s−10\,\mathrm{m\,s^{-1}}
Drag magnitude0 N0\,\mathrm{N}
Magnus force magnitude0 N0\,\mathrm{N}
Magnus translational power0 W0\,\mathrm{W}
Amber ruler span0 m0\,\mathrm{m}
Elapsed time0 s0\,\mathrm{s}
Velocity: downrange, vertical, crossrange[000] ms\begin{bmatrix}0\\0\\0\end{bmatrix}\,\frac{\mathrm{m}}{\mathrm{s}}
Acceleration: downrange, vertical, crossrange[000] ms2\begin{bmatrix}0\\0\\0\end{bmatrix}\,\frac{\mathrm{m}}{\mathrm{s}^{2}}
Landing time0 s0\,\mathrm{s}
Downrange landing0 m0\,\mathrm{m}
Crossrange landing0 m0\,\mathrm{m}
Ground target miss0 m0\,\mathrm{m}
Trajectory curvature0 m−10\,\mathrm{m^{-1}}
Mechanical energy0 J0\,\mathrm{J}
Work done by air0 J0\,\mathrm{J}
Energy balance defect0 J0\,\mathrm{J}
Landing change with half step0 mm0\,\mathrm{mm}
Design resultAdjust the launch or drag the target

Physics tutorial

From a trajectory to a launch design

BackgroundWhen you know the launch, projectile motion is an initial-value problem: you find where the projectile goes. When you know the target, it becomes an inverse design problem: you find how to launch. Here one three-dimensional trajectory feeds the side view, the sideways drift seen from above, the velocity components and the energy balance. The target sits on flat ground, and the run ends the first time the projectile comes down through the ground.

Why it mattersOpenStax University Physics, Volume 1, covers motion in a vacuum in section 4.3 and the quadratic drag force in section 6.4. This Lab adds a separate linear-drag model, drag based on velocity relative to the air, and a numerical search for a launch within set limits, so every change you make has a measurable effect.

Start with the essentials

Focus question
Can a launch chosen in vacuum still hit the target after a crosswind and drag are added?
One-sentence intuition
Gravity acts straight down, but drag depends on the full velocity relative to the air, u=v−w\boldsymbol u=\boldsymbol v-\boldsymbol w. A side view can hide a large sideways miss; the view from above shows it.

Core mathematical model

Three-dimensional equation of motion

r˙=v,mv˙=−mgey+FD\dot{\boldsymbol r}=\boldsymbol v,\qquad m\dot{\boldsymbol v}=-mg\boldsymbol e_y+\boldsymbol F_D

The three coordinates are downrange, vertical and crossrange. The launch elevation and bearing set all three starting velocity components. An RK4 integrator steps the point particle forward and uses a smaller maximum step when drag is strong.

Three air models

FD={0vacuum,−bulinear,−k∥u∥uquadratic,u=v−w\boldsymbol F_D=\begin{cases}\boldsymbol 0&\text{vacuum},\\-b\boldsymbol u&\text{linear},\\-k\lVert\boldsymbol u\rVert\boldsymbol u&\text{quadratic},\end{cases}\qquad\boldsymbol u=\boldsymbol v-\boldsymbol w

The multiplier scales a reference coefficient: 0.08 kg per second for linear drag or 0.003 kg per metre for quadratic drag. These are empirical coefficients that you set directly. The Lab does not compute a Reynolds number or a drag coefficient for a particular object.

Landing time and range in a vacuum

timpact=v0sin⁡θ+v02sin⁡2θ+2gh0g,ximpact=v0cos⁡θcos⁡ϕ timpactt_{\mathrm{impact}}=\frac{v_0\sin\theta+\sqrt{v_0^2\sin^2\theta+2gh_0}}{g},\qquad x_{\mathrm{impact}}=v_0\cos\theta\cos\phi\,t_{\mathrm{impact}}

For a launch from ground level with zero bearing and no air, the range is greatest at 45 degrees. Launch height and air forces shift that best angle. Mass cancels out only in a vacuum, and changing the wind leaves a vacuum trajectory unchanged.

Energy, air work and curvature

E=12m∥v∥2+mgy,Wair=∫FD⋅v dt,κ=∥v×a∥∥v∥3E=\tfrac12m\lVert\boldsymbol v\rVert^2+mgy,\quad W_{\mathrm{air}}=\int\boldsymbol F_D\cdot\boldsymbol v\,dt,\quad\kappa=\frac{\lVert\boldsymbol v\times\boldsymbol a\rVert}{\lVert\boldsymbol v\rVert^3}

In the ground frame, the change in mechanical energy equals the work done by the air. A wind can push energy in, so positive air work does not by itself mean the numbers are wrong. Curvature measures how sharply the path turns per unit length, and speed alone does not set it.

Common difficulties

Wind is not an extra constant force

Typical misconceptionA wind simply adds a fixed sideways acceleration, even in vacuum.

Better mental modelThe air force depends on the velocity relative to the moving air, and it vanishes in a vacuum. With the drag coefficients held fixed, changing the mass changes the acceleration, because the force is divided by the mass.

The search cannot reach every target

Typical misconceptionA computer search can always find a launch that hits the target.

Better mental modelThe search keeps the launch speed and every other setting fixed, and only tries elevations and bearings within their limits. If the closest shot still lands more than 2 m from the target, the Lab reports a miss and leaves the target where it is.

Halving the step checks convergence; it does not bound the error

Typical misconceptionThe half-step landing difference is the exact error in the trajectory.

Better mental modelIt shows how much the landing point moves when the step gets finer. The exact vacuum solution and the linear-drag tests are separate checks. Still, neither a small difference nor a good energy balance shows that a physical effect left out of the model is negligible.

Run the experiment

  1. 01

    Reproduce the vacuum result

    Choose Vacuum range, set Platform height and Launch bearing to zero, then press Maximize downrange. Change Particle mass and both wind speeds.

    What to observe: The best angle comes out close to 45 degrees, and mass and wind do not change the vacuum result. The landing time, located inside the final step, matches the exact formula.
  2. 02

    See what the air does

    Compare the Linear drag and Crosswind challenge presets. Pause near the top of the flight and look at the view from above, the velocity components and the work done by air.

    What to observe: The two air models give different trajectories. A crosswind pushes the projectile sideways, and the side view cannot show that drift.
  3. 03

    Design a launch for a target

    Drag the gold target in the view from above, then press Find target launch. Move the target far out of reach and try again.

    What to observe: The search changes elevation and bearing but keeps the speed fixed. It hits reachable targets within the tolerance; for a target out of range, the best shot still visibly misses.
  4. 04

    Check launch height and step size

    Choose Cliff launch, press Maximize downrange, and try different maximum step sizes while watching the landing change with half step.

    What to observe: The best angle need not be 45 degrees. Strong drag forces smaller steps to keep the integration stable, and the landing moment is located inside the last integration step.
FeedbackSomething broken, confusing, or missing on this page?Tell us
What kind of feedback?

Sent with this page’s address, its Lab ID, the site language and your device type. Please leave out personal details. Feedback is kept for up to 12 months.Privacy policy