home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Fish 'n' More 2
/
fishmore-publicdomainlibraryvol.ii1991xetec.iso
/
fish
/
science
/
gravity
/
gravity.doc
< prev
next >
Wrap
Text File
|
1990-12-31
|
4KB
|
97 lines
Gravity V1.0
------------
a nice toy to simulate the movements of astronomic objects
written in 1990 by Guido Burkard
1. How to start Gravity
-----------------------
Start Gravity by typing its name followed by the path/name of the object
description file. The object description file is an ASCII format file
containing the information about the objects which you want to simulate
(see also chapt.3). There should be at least three demonstration object
description files on this disk: - "sun_earth"
- "sun_inner_planets"
- "sun_outer_planets"
These are file that I made using the data of our solar system. So you
can try to start Gravity by typing "Gravity sun_earth".
Note: - Gravity cannot be started by clicking on an icon on the Workbench,
because it uses the CLI-window as a data screen. So if you want to
start it anyway from the Workbench, click at the CLI-icon and start
it from there.
- Gravity can only be started when an object file is indicated.
That's because you can't edit object data using the program itself.
(see also chapt.3)
2. How to control Gravity
-------------------------
The Gravity data screen shows you following informations:
- the name of the object file you've chosen
- how many objects the file contains
- the gravity constant (which you can change in this program!!)
- the time-interval (delta-time) from one computing step to another (sec)
- the absolute simulating time (seconds)
- the distance from the center of the screen to the borders (zoom)
- whether the tracks of the objects are deleted or not
And you can choose following functions:
- r runs the simulation on a different screen
(hit backspace to return)
- rt shows you the simulation time while running the simulation
- w watch the simulation screen without running the simulation
- g change the gravity constant !!
- G set the gravity constant back to the "real" value
- t change time interval (larger number->simulation becomes faster)
note: - if you enter too small time intervals, you won't see
any movement, because the animation is too slow;
- if you enter too large time intervals, the calculation
gets more and more inaccurate;
- m change margins - with this function you can change the zoom
factor by entering the distance represented by the line from
the center to every of the borders
- a auto-set margins; after this operation every object is inside the
margins
- d toggle delete mode on/off
- l show a list of the object data
- x terminate the program
Note: Numbers are always entered as man*10^exp (or manEexp)
The computer asks you e.g. for G.man and G.exp when you want
to change gravity constant. Just enter them as scientific numbers!
3. How to write own object files
--------------------------------
To write an object file you need a usual text-editor like the ed from
the Workbench. Further you must know all the coordinates, starting
speeds and masses of the objects.
The first line of the file has to look as follows:
GRAVITY n
where n is the number of objects.
Then there should be an empty line. After that you enumerate the object
data as scientific numbers:
1.3 6 <-- x position: 1.3E6 m (1.3*10^6 m)
-8.5 3 <-- y position: -8.5E3 m
0 0 <-- velocity in x-direction: 0
2.5 -1 <-- velocity in y-direction: 2.5E-1 m/s
1 25 <-- mass: 1E25 kg
2.1 9 <-- next object
1 7
... ...
^ ^ ^
| | |_________exponent
| |_______1 tabulator
|_______number (normally between 1 and 9.999)
I hope you have fun with Gravity!
If you have any questions or contributions, write to:
Guido Burkard, Stockfeldstr. 230, CH-5243 Muelligen, Switzerland (Europe)