Dec 282017
 
Interesting display of various shapes with gravational intersection.
File GUTS.ZIP from The Programmer’s Corner in
Category Printer + Display Graphics
Interesting display of various shapes with gravational intersection.
File Name File Size Zip Size Zip Type
GUTS.DOC 1150 569 deflated
GUTS.EXE 11552 6682 deflated

Download File GUTS.ZIP Here

Contents of the GUTS.DOC file


Program: Guts.exe (windows application)
Author : Wes Cherry (wesc) 3.1147
Release: Beta


EQUATIONS OF MOTION:
--------------------

Force & Acceleration:
---------------------

Uses a modified version of the uniform graviatitional formula:
(Inverse rather than inverse squared)

m * m m * m
F = G ----- rather than F = G -----
r r*r

This is done becuase the patterns are more interesting and it avoids having
to compute a square root when converting F to it's component vectors.

Derivation:

m2
|\
| \ Given:
^ | \ m1*m2
y | \ F = G -------
|___0\m1 r

x>

(0 = theta)


Fy = F Sin 0; Sin 0 = y/r

m1*m2 y
Fy = G ----- * -
r r

Ay = Fy / m1

So:

m1 * y
Ay = G --------
r * r


For x & z the equations are the same.

Since each body attracts each other, the acceleration is computed for each
body to all other bodies.



Velocity & Position:
--------------------

Since

dV/dt = A, dV = Adt
& dX/dt = V, dX = Vdt


 December 28, 2017  Add comments

Leave a Reply