User Tools

Site Tools


gibson:teaching:fall-2012:math445:lab12

Math 445: Projectile motion

It is easy to determine the trajectory of a projectile subject to gravity if you neglect air resistance. using elementary physics and calculus, you can show that a projectile will travel farthest across a flat surface if you shoot it at an angle $\theta = \pi/4$ above the horizontal. In this problem you will determine the optimal angle and the maximum range of a projectile subject to air resistance. Use the following equations of motion, developed during class

$ dx/dt = v_x $

$ dy/dt = v_y $

$ dv_x/dt = -\mu v_x \sqrt{v_x^2 + v_y^2}$

$ dv_y/dt = -g - \mu v_y \sqrt{v_x^2 + v_y^2}$

The constant $g = 9.81 m/s^2$ is the acceleration due to gravity. The constant $\mu = 1/2 \rho_{air} C_D A/m$ in the air resistance term depends on physical characteristics of the projectile and the air. We will solve the problem for an iron cannonball 20cm in diameter. The following code will calculate $\mu$ correctly given appropriate physical constants

rho_air  = 1.28; % kg/m^3, density of air
rho_iron = 7870; % kg/m^3, density of iron 7.87 gm/cm^3 == 0.00787 kg/(0.01m)^3 = 7870 kg/m^3
C_D = 1;         % drag coefficient for sphere
g = 9.81;        % m/s^2, acceleration due to gravity
r = 0.10;        % m, radius of cannonball
A = pi*r^2;      % cross-sectional area of cannonball
m = rho_iron*4/3*pi*r^3; % mass of cannonball

mu = rho_air*C_D*A/(2*m); % coefficient of nonlinear v|v| term, in mks units

Write a Matlab script to plot the trajectory of a cannonball subject to the above equations of motion and shot with an initial speed of 100 m/s at an angle $\theta$ above the horizontal. In the same plot, show the trajectory in the (x,y) plane of the cannonball with and without air resistance. Use your script to answer the following questions:

(a) How far does the cannonball go in x with and without air resistance, if you shoot it at $\theta = \pi/4$?

(b) What initial angle gives the farthest range with air resistance?

(c) If $\theta = \pi/4$, how much do you have to increase the initial velocity so the x distance is as large as it is without air resistance?

Answering these questions with any precision will require some cleverness and a number of Matlab programming concepts you've learned through the semester.

gibson/teaching/fall-2012/math445/lab12.txt · Last modified: 2012/12/04 06:03 by gibson