Contents of the ORBIT.DOC file
ORBITAL MECHANICS PROGRAM
Version 1.0 2-16-86
By Don Thayer
This program will calculate the major orbital parameters
associated with two astronomical objects when one orbits around
When the program is first started, the GRAVITATIONAL PARAMETER
(GP) will be requested.
Whenever this parameter is required, you can either enter it
directly or press the key to get a list of possible choices.
Selections 1 through 11 are common solar system objects.
Selection 12 lets you enter the parameter directly. With
selection 13 you can combine any two of the choices from 1 to 11
and selection 14 will show the GPs for black holes.
Once the GP is entered, you will be required to enter the
object's diameter. Again you can either enter the diameter
directly or press the key to get a listing. If you selected
a GP for a black hole, the option 13 will select a diameter
equivalent to the EVENT HORIZON diameter. Selecting option 13
when a black hole GP was not chosen will enter a very small value
which will force any major astronomical object to simulate a
After initially entering the GP and diameter a menu of input
options will be displayed. Before the orbital parameters can be
computed, you must select option <2>, <3>, <4>, <5> or <6> to
enter final necessary information.
Selecting option <2> from this menu will allow you to input
the SEMIMAJOR AXIS and the ECCENTRICITY of the orbit. Both of
these options can be either entered directly or from a list
provided when the key is pressed in lieu of entering a
NOTE: Only selections <1> and <2> will give you the option of
selecting from a list. Selection numbers <3>, <4>, <5> and <6>
will require direct input of the values. Option <7> when
available, will give a range that can be used.
Selecting option <3> will allow you to input the RADIUS at
APOGEE and the RADIUS at PERIGEE.
VELOCITY at APOGEE and PERIGEE are the orbital velocities and
can be entered from option <4> on the main menu.
The PERIOD of ROTATION in option <5> is the time in seconds
required for the orbiting object to revolve around the main
Selecting option <6> will allow you to define an orbit given
your PRESENT RADIUS (or distance to the object), your VELOCITY
and the ATTACK ANGLE. An angle of 90 degrees will define an
orbit at a right angle to your velocity vector and the main
object. Selecting an angle of "0" degrees may be disastrous to
both you and the program as it will direct you straight at the
main object. Choosing too high of a velocity may exceed the
escape velocity and a warning will be shown at the bottom of the
screen. No orbit can be computed if this happens. If the
velocity is too small, your orbit will intersect the object.
Option <7> will not be available until after an orbit has been
calculated. This option allows you to enter the distance you are
from the object (orbital radius) and show data relative to your
position on the orbit.
Option will toggle between full scientific notation and
mixed notation where only large numeric values above 1x10E6 and
very small numbers will be shown in scientific notation.
quits the program.
Once data has been entered by using options <2>, <3>, <4>, <5>
or <6>, the orbital data will be displayed and you will be given
a chance to print the data on a printer. Type a "Y" or "y" if
you want a printout otherwise type "N" or "n" for no printout.
A command line will appear at the bottom of the screen that
will allow you change any of the input sets of data. You can
enter options 1, 2, 3, 4, 5, 6, 7, 8, X, Q which are the same as
those on main menu or you can select option "M" to display the
main menu again. You can see a graphic representation of the
orbit by selecting the "G" option if you have an IBM or
equivalent graphics card.
If you change the GP & diameter by selection option <1>, the
new orbit data will be computed from the existing semimajor axis
When you select options <6> or <7> from either the command
line or the main menu, data in addition to the normal orbital
statistics will be shown on the screen.
THE GRAPHIC SCREEN
When you choose then graphic display your orbit will shown.
If the eccentricity is near 1.0000, then the orbit will appear as
a straight line and if the eccentricity was 0.000, a circle will
be displayed as the orbit. Values in between will produce orbits
of varying ellipses.
A small cross will mark the center of the main object at the
focal point of the orbital ellipse. If possible, the relative
size of the main object will also be shown as a solid circle
about the objects center. This will occur if the relative
diameter of the object is more than four pixles across and if it
is not greater than size of the screen.
If a black hole was selected from the GP & diameter option, it
will be shown as broken line orbit if its relative size can be
shown on the screen.
When options <6> or <7> are selected, the graphic screen will
also show your relative position on the orbit in the form of a
Sometimes when a number is entered, the data will be requested
again or the computer will beep and display another question
mark. When this happens, you have either entered an illegal
string of characters such as 3q23 or the value you entered is not
acceptable for the input such as trying to enter 0.00 for the
Many times the value you are to enter is very large or very
small, for example: 200000000 (2 with eight zeros following it).
This number can be entered as 2.0E8 or 2.0E+8 in scientific
notation. Very small number such as 0.00000123 should be entered
as 1.23E-6 in the scientific format.
Gravitational Parameter: This is the gravitational attraction
between two objects and is the result of the gravitation
constant multiplied by the mass of the object and is measured
in miles cubed per second squared.
Diameter of Object: The diameter of the main object in miles.
Event Horizon: The radius of a black hole at which the escape
velocity is equal to the speed of light. This is measured in
Semimajor Axis: The greatest distance from the center of the
orbital ellipse to the orbit and is measured in miles.
Eccentricity: A measure of the out of roundness of the orbit. An
eccentricity of "0" will produce a perfect circular orbit
while a value of 0.9999 will produce a very flattened
Radius at Apogee: The greatest distance between the orbiting
object and the center of the main object as measured in miles.
Radius at Perigee: The closest distance between the centers of
two objects in miles.
Velocity at Apogee: The orbital velocity in miles per second at
the furthest distance between the two objects.
Velocity at Perigee: The velocity at the nearest point between
the objects in miles per second.
Period of Rotation: The time in seconds for an object to
complete one orbital revolution.
Escape Velocity: The minimum velocity for which no orbit will
exist at a given orbital position.
Gravitational Force: The force in gee's exerted on the orbiting
object by the main object. Note: This is also the centrifugal
force induced by the orbiting object thus canceling the
gravitational force and results in "free fall" if the orbiting
object is a space vessel.
Tidal Force: The force in gee's at one foot from the orbital
path. In normal orbital mechanics this value is too small to
bother with, however, if a space vessel should approach a
black hole or neutron star, this can become very great. This
is how a space vessel too close to such an object can be torn
Many objects have been placed in a stationary orbit around the
earth in order for them to remain in one relative position above
our planet. These satellites are in what is called an earth-
synchronous orbit. Since the earth rotates about its axis every
24 hours, this means that a satellite must also make its orbital
rotation in 24 hours.
To determine a earth-synchronous orbit for a satellite, either
start the program or if already started, select option <1> from
the main menu.
When asked for the Gravitational Parameter, press the key
to get a listing and select item #4 for the earth.
The program will now ask for a diameter, press the key
again and select item #4 on that list.
Now select option <5> to enter the period of rotation and
eccentricity. When the program prompts you for the Period Of
Rotation, enter 86400 (24 hrs * 3600 sec/hr).
When asked for the eccentricity, enter a small value such as
0.01 since we want the satellite's orbit to nearly round.
The program will now show you the orbital statistics for an
earth-synchronous orbit. Answer the printout question appro-
priately and if you have a graphics board select option "G" for a
graphic display of the orbit.
Once the data is back on the screen, try experimenting with
different orbital parameters or select option <7> and see some of
the other orbital data.
Another Example: On October 4, 1957 the Soviet Union launched
the first artificial satellite. It's orbit ranged between 584
miles and 143.5 miles. Add these values to the radius of the
earth to get the approximate values of 4540 miles and 4100 miles
respectively. Select the GP and Diameter for the earth if you
haven't already done so and then select option <3>. Enter 4540
for the Radius at Apogee and then enter 4100 for the Radius at
ABOUT THIS PROGRAM
The initial idea started out as a mere curiosity when I ran
across some interesting equations on black holes. This led to
more in-depth studying of orbital mechanics. The first program
was written for a Hewlett-Packard 67 programable calculator.
When more memory came available in form of an HP-41CV, the
program was expanded. Boy, this was really great! A whole 3K of
Then came the PC with its free basic and later a compiler to
speed things up a bit. This final(?) version has been written
with Borland's Turbo Pascal with thanks to Michael Covington for
his movable window procedure.
The formulas used in this program are mostly basic orbital
mechanics methods and cannot possible give exact results. Also
in orbital systems, there are many massive objects that also
influence the orbit. Our own solar system contains at least 10
major bodies all interacting with each other while this program
only deals with the "two-body problem".
Every precaution I can think of has been taken to keep this
program on-line, however, when dealing with astronomical values,
the figures themselves become astronomical and can cause floating
point overflow which will abort the program. I wouldn't try
determining the data for orbiting galaxies.