#### Archived

This topic is now archived and is closed to further replies.

# Projectile Simulation Formula

This topic is 5460 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

## Recommended Posts

Hi, would somebody be able to help me find a math formula so I can work out the path of a travelling bullet/missle, from a tank. Ive been trying but it wasn't accuracte. I need it to be able to be affected by the projectiles weight, gravity, wind, etc. If anyone can help it would be greatly appreciated. Thx for anyhelp you can provide . [edited by - Razza2003 on March 4, 2003 2:45:37 AM]

##### Share on other sites
well the formulas are independant of weight

heres a simple one for working out the x and y positions of the projectile(doesnt include wind)

if you fire a projectile with some initial velocity at some angle.. then you can calculate the x and y position of it like this

1st you need the x and y components of the initial velocity

vx = velocity*cos(angle)
vy = velocity*sin(angle)

at any time t the x and y positions of it will be

x=(initial x velocity)*time

y=(initial y velocity)*time+0.5*gravity*(time)^2

those formula will give you the position at any given time..

an easy way to add wind would be too add an acceleration term onto the x position

x=vx*time + 0.5*(acceleration due to wind)*time^2

make the acceleration negative or positive depending on the wind direction.. but be careful not to make it too big.. or you will end up with particles flying all over the place! 0_o

If you simple want air resistence.. then u could use a similar equation as for wind.. but you will need to make the acceleration of it velocity dependant(because things that arnt moving dont experience air resistance).. which means you will have to continuosly calculate its velocity.. but the equation would look something like this

x=vx*time + 0.5*(acc of air*(current velocity))*time^2

[edited by - quant on March 4, 2003 12:14:34 PM]

##### Share on other sites
Weight do depend. A table-tennis ball behaves diffrently compared to a iron ball of the same size.

But, if you''d care about the weight you''d probably be so picky about the physics that you''d never finnish the physics-code for the ball :-)

##### Share on other sites
Weight doesnt effect the motion of the ball at all

Everything falls to earth at the same speed

##### Share on other sites
Lol, you got a very good point there, why didn''t I think of that, lol.

##### Share on other sites
If the shape of the object is the same, the wind resistance force is the same... If the mass of the object is greater, the gravitational force is larger.

Sum those forces, then divide by the object''s mass, and the more dense object will have a greater downward acceleration.

##### Share on other sites
assume for one minute that there is no wind resistance or anything.. just gravity

Newtons 2nd law

F=ma

Law of gravity

F=G*M*m/r^2

where M is the mass of the earth.. m is the object falling to the earth

ma=G*M*m/r^2

m''s cancel

a=G*M/r^2

simple physics really.. everything falls at the same speed

##### Share on other sites
right, but if you''re going for reality, there is wind resistance in reality so mass matters.

-me

##### Share on other sites
well air resistance is generally mass independant also..

although more massive objects take longer to reach terminal velocity.. and so would fall faster than less massive objects

##### Share on other sites
quote:
Original post by Anonymous Poster
well air resistance is generally mass independant also..

Mass independant? I've learned and read that it's proportionnal to speed (sometimes squared) and there is a friction coefficient, which depends on the shape of the object and the turbulence that it causes in the air.

Cédric

EDIT; Correction: The force caused by air resistance is mass independant, but the acceleration it creates isn't, whereas the gravity force is mass dependendant, but its acceleration isn't.

[edited by - cedricl on March 7, 2003 11:47:02 AM]

##### Share on other sites
True, gravitational pull is mass independent, acceleration isn''t. Although, the mass of a projectile does play it''s roll, but only at time of launch and impact.
The bigger the mass of the projectile, the larger the charge to launch it has to be, so the velocity of the projectile depends on mass/charge. Also, the greater the speed and mass of the projectile, the harder the impact will be.
So well, mass DOES play a role in this scenario, just not for the path it travels when fired with a specific velocity.

--
MFC is sorta like the swedish police... It''''s full of crap, and nothing can communicate with anything else.

##### Share on other sites
quote:
Original post by quant
Weight doesnt effect the motion of the ball at all

Everything falls to earth at the same speed

Weight is only a measure of Earth''s gravitational pull on mass...but objects of differing mass do in fact fall at different rates, its just that the difference is very small.

Brian

##### Share on other sites
ive just proved they dont fall at different rates.. but ill do it again

F=ma

F=GmM/r^2

ma=GmM/r^2

a=GM/r^2

Thus its only depends on the mass of the earth.. or other planet

ANd yes air resistence acceleration does depend on mass .. the force doesnt

##### Share on other sites
The gravititional pull is greater on objects with greater masses. Acceleration is the same though.

Also, I don''t like you saying you proved it. You uses someone else''s prove. You have proved to us...

##### Share on other sites
no.. I proved it

started from 2 equations.. and did the working myself

hardly difficult

##### Share on other sites
quote:
Original post by bjmumblingmiles
Weight is only a measure of Earth''s gravitational pull on mass...but objects of differing mass do in fact fall at different rates, its just that the difference is very small.

Brian

Welcome to 2300 years ago. You are Aristotle. You make up laws of nature without actually checking if they''re right. Please faster forward to 500 years ago when Galileo proved you knew jack.

##### Share on other sites
quote:
Original post by quant
no.. I proved it

Do you honestly think that you have come up with something new?

##### Share on other sites
i didnt prove it FIRST

But i proved it..

lol.. by your logic..everything in the world that uses c++ was made by stroustrup..

every game with directx in it was made by microsoft!

whether or not i did it 1st is pointless.. i did it

end of story

##### Share on other sites
Oh well, I''m a game programmer wannabe, so I''ll let you be a physician wannabe.

##### Share on other sites
quote:
Original post by Razza2003
Hi, would somebody be able to help me find a math formula so I can work out the path of a travelling bullet/missle, from a tank.

Below is an old post I got from Compuserve''s graphics forums a while back.

-cb

=============================
How a ballistics program works
-or how to calculate a trjectory chart-

by: R White

Up front I should say that this information is based on how The
Shootist, version 2.21, works, and there are other ways of obtaining the
information contained in a firing table. I should also set up some
definitions to keep the confusion down.
A ballistic table generally does not contain information about a
particular projectile''s trajectory, but rather general information on the
flight of projectiles. The table is then used in conjunction with a set of
formulas to produce the trajectory information. Generally, a trajectory chart
is computed in the following way:
1] Find the remaining velocity and time of flight to the range in
question.
2] Find the drop of the projectile using this information.
3] Correct for the zero of the firearm in question.

All other information, such as kinetic energy or energy transfer, may
be found using the information from these calculations.

Part I: Remaining velocity and time of flight.

A table and formulea for using it are included in the file Ingall.txt
which may be printed out for convenience in use. This table and its
formulea are derived from the Ingall''s ballistic tables. These tables were
founded upon the test firing of some ''standard'' projectiles, and the resulting
calculations must be corrected with ''ballistic coefficients.'' This is simply
a measure of the difference in air resistance between the ''standard projectile''
used in compiling the table and an ordinary, common, bullet.
Why is a table used instead of a straight formula? Because it was
found by many scientist doing ballistics test that a bullet does not lose
speed uniformly. The rate of velocity loss is dependant upon a combination
of many factors making the formulea for computing velocity loss very
difficult and complicated. The main factor is the sound barrier; bullets
lose velocity at a different rate above and below it.

Part II: Find the drop of the bullet.

This is done also on a table, but can be accomplished with formulas.
The table used in The Shootist is once again included in the file Ingall.txt.
It is based upon the premise that all objects fall at a given rate:

2
Drop (inches) = 193 x (time of flight)

Inherent inaccuracies occur, however, in the formula because of
wind resistance, which actually works to slow down the fall of the bullet.
The action of the air has already been computed into the table. Instructions
on the tables usage are also included. An explination of the formulea
involved in calculating the effect of the air resistance can be found in
"Exterior Ballistics" by McShane (and others). The table The Shootist
uses is one shown in "Hatcher''s Notebook," which is derived from the one in
"Exterior Ballistics. To show how much difference there is when the air
resistance is figured in, the following comparison is made:

Yards 100 200 300 400

With 1.8 7.5 17.7 33.6
Without 1.93 7.72 19.76 37.36

This is based on a bullet beginning at 3200 fps with a ballistic coefficient
of .44. The ''With'' row was calculated using the table provided in Ingall.txt,
while the ''Without'' was calculated with the formula given above.

Part III: Correct for the sighting in of the firearm.

This involves a bit of trigonometry that will not even feel like
trigonometry:

H is the height of the sight above the bore
D is the drop in inches of the bullet at sight-in range
S is the sight in range in inches
R is the range in question in inches
I is the drop from the bore at the range in question
T is the difference in inches from the line of sight

If the range in question is less than the sight in range
T = (D-I) - ((S-R) x ((D+H)/S)

If the range in question is more than the sight in range
T = (D-I) + ((R-S) x ((D+H)/S)

The sight in range is not covered by either of the two formulea
becuase it is known to be 0.

For example:
A bullet fired from a gun sighted in at 200 yards drops 4.2 inches
in its first 100 yards of travel. How many inches is it above the line of
sight? The drop from the bore at the sight in range is 7.5 inches (these
are calculated from the tables).

T = (D-I) - ((S-R) x ((D+H)/S)
T = (7.5-1.8) - ((7200-3600) x ((7.5+1.5)/7200)
T = 5.7 - (3600 x .00125)
T = 5.7 - 4.5
T = 1.2 inches (above the line of sight)

Another:
The same bullet drops 17.7 inches by 300 feet. How far off the line
of sight is it now?

T = (D-I) + ((R-S) x ((D+H)/S)
T = (7.5-17.7) + ((10800-7200) x ((7.5+1.5)/7200)
T = -10.2 + (3600 x .00125)
T = -10.2 + 4.5
T = -5.7 inches (below the line of sight)

Other Formulas:

2
Kinetic Energy = ((Bullet wght/225218) x Velocity )/2

Energy Transfer = Kinetic Energy x Caliber

3 2
Optimum Game Weight = Velocity x Bullet Weight x 1.5012 x 10e-13

Mach = Velocity/1127

Miles per hour = (Velocity x 3600)/5280

Wind drift:
t = time of flight in seconds
s = wind speed in mph
a = angle of wind off trajectory path
v = muzzle velocity in feet per second
r = range in yards

Wind drift = (s x sin(a)) x (t - (v/r)

I know all this is a bit complicated, but with a little practice it
becomes rather easy to make the computations necessary. For further
information read "Hatcher''s Notebook," which covers a lot of other
interesting territory besides exterior ballistics. If you have any questions,
leave me a message on CompuServe''s NRA forum.

Russ White
ID No: 73737,670

##### Share on other sites
quote:
Original post by Enselic
so I''ll let you be a physician wannabe.

lol.. i dont know anything about healing sports injuries..

If you have nothing better to do here than spam posts by insulting me, u should be banned.

All i was doing posting here was trying to help, all you have done is insult me.

Guess you should learn something from this post, dont try to answer topics which you have no clue about

##### Share on other sites
I really want to stop insulting you, but I''ve still got some of my childhood in me so I can''t stop while you keep on picking.

No, I''ll control myself. Here was a nice list of insults but I changed my mind...

Peace to the world.

##### Share on other sites
If we model the projectime as a sphere moving in a fluid (or gas), the accelleration on it is graviy+(drag+upthrust)/mass

Drag is 6*pi*r*n*v where r is radius, v is the relative velocity to the flow of the fluid (vel-flow) and n is the coefficient of viscosity which you can search for and is known for water/air etc.

I forget the formula for upthrust but it''s fairly simple. If you want to be fancy you can include turbulence from spin but it''s hardly worth it.

Be sure to apply forces in all directions, it may be tempting to forget you''re not only dealing with gravity anymore

********

A Problem Worthy of Attack
Proves It''s Worth by Fighting Back

##### Share on other sites
I was also thinking that mass matters in projectile calculations probably in figuring out the trajectory of something that''s "fired" like from a cannon. See, a cannon will use a certain amount of energy to fire its projectile. For the same amount of energy, a tennis ball will move faster than an iron cannonball.

E = 1/2*m*v^2, ne?

That allows the initial x and y velocities to be found, which acceleration and force can then be applied to.

This isn''''t life in the fast lane, it''''s life in the oncoming traffic.
-- Terry Pratchett