Exercise_04 Realistic Projectile Motion

Abstract

Use the Euler method to calculate the realistic projectile motion.

Backgroud

Caculate the trajectory of our cannon shell including both air drag and the reduced air density at high altitudes so that you can reproduce the results in Figure 2.5. Perform your calculation for different firing angles and determine the value of the angle that gives the maximum range.

Analysis

When ignore the air drag, according to the Newton's Second Law, the dynamic equation of our cannon shell is that:

4.1
4.2

If we consider the air drag, there will be a another force that given by

4.3

Now use the Euler method,we have

4.4
4.5
4.6
4.7

And

4.8
4.9

Now,consider the change of air density at different altitudes.The desctription of the air drag at different altitudes is given by

4.10
4.11

And

4.12
4.13

The Code

According to the analysis above, the code will be like below.

Exercise_04 Realistic Projectile Motion_第1张图片
The Code

The Result

Exercise_04 Realistic Projectile Motion_第2张图片
theta=45

Discuss

If I change the angle, see what is the result.

Exercise_04 Realistic Projectile Motion_第3张图片
theta=30
Exercise_04 Realistic Projectile Motion_第4张图片
theta=60
Exercise_04 Realistic Projectile Motion_第5张图片
theta=75

From the four pictures,we find that:(1)When theta=75,the height that the cannon can reach is the highest;(2)When theta=45,the distance that the cannon can get is the longest;(3)When theta=30,the height that the cannon can reach is the lowest;(4)When theta=75,the distance that the cannon can get is the shortest.

Thanks to Jingyi Zhou.

你可能感兴趣的:(Exercise_04 Realistic Projectile Motion)