The images at bottom left are screen shots from an Open Inventor program written
to simulate 3D scattering of particles. It is a fairly straight forward
simulation where a volume of particles with equal radii and mass are
deflected by another particle. The simulation assumes the collisions
will by elastic, momentum will be conserved, angular momentum is zero,
and that all objects are smooth homogeneous spheres.
At first, Calculating the final velocities of two colliding homogeneous spheres
(given their
initial velocities) seemed like a simple physics problem. However,
tracking down the below equations took much longer than expected.
Apparently the problem isn't as simple as it sounds because the solution
was skipped in every introductory physics book I could find. After a few
hours of researching the topic I discovered the solution in the book
Encyclopedia of Physics, Principles of Classical Mechanics and Field
Theory, Vol III/1, Berlin:Springer-Verlag, 1956-1962. It is an old
book, but it had everything. Below are the equations used to simulate
the collisions.
v1i = the initial velocity of object 1
v2i = the initial velocity of object 2
m1 = the mass of object 1
m2 = the mass of object 2
e = the coefficient of restitution (e = 1 for elastic collision)
n = normal unit vector drawn form object 1 to object 2
c = n . (v1i - v2i)
v1f = v1i - ((m2c)/(m1 +
m2))(1 + e)n
v2f = v2i + ((m1c)/(m1 +
m2))(1 + e)n
The program was written with a GUI around out to control some of the
parameters. This is my first attempt to incorporate X Motif with
anything so it may be (probably is) a little buggy, so take caution.
Below I have provided the source code used to for this program as well as
a binary executable for Irix 6.5. THIS CODE HAS NOT BEEN COMMENTED
YET, SO BEWARE.
|