Solar System Live Details
- How did you do that in HTML?
- The HTML documents form only the skeleton of Solar System
Live.
They assemble a request which is sent, using the CGI mechanism, to a
server application written in C. The server, given the viewing
parameters you selected in the HTML file, creates a GIF image of the
requested view, then returns an HTML document which references the
GIF file as an in-line image. Fields in the form of this result
document are initialised to the parameters passed in with the request.
To better understand what's going on, view the source of the result of
a query. Note that since the source is custom-generated for each
query, it will be different every time.
- Okay, I just looked at the source. What's with this
cache
directory?
- Ahhhh.... That's interesting. Since we want to return the result
of the query as an in-line image, it must reference an external GIF
file. (If the query server returned the GIF file directly, we
wouldn't be able to embed it in the form that allows subsequent
queries. Furthermore, Mosaic would spawn an external viewer for the
image rather than show it on the page.) So, having to write a
separate GIF file raises the issue of where it goes and how to keep
the system from being clogged with leftover images. My answer to this
problem is to create GIF files in the
cache
directory with
unique names generated based on the process ID of the server program.
As each file is written, an at
job is queued to delete it
five minutes later. This way the image files are automatically cleaned up.
- How do you calculate the positions of the planets?
- The heliocentric co-ordinates of Mercury through Neptune are calculated using
the algorithms given in Jean Meeus'
Astronomical
Algorithms, based upon the VSOP87 planetary theory of
Bretagnon and Francou, The position of Pluto is calculated, for
dates between 1885 and 2099, using the method given in
Chapter 36 of Astronomical Algorithms. No analytical
theory of the orbit of Pluto exists at present, because Pluto has been
observed over an insufficient portion of its orbit since its
discovery in 1930 to construct one.
- How do you calculate the orbits of comets and
asteroids?
- The specified orbital elements
are used in conjunction with the general solutions for elliptic and
parabolic motion given in Chapters 32 and 33 of
Astronomical Algorithms. The orbit is plotted by
calculating positions before and after the specified epoch until
the orbit either closes (if elliptical) or reaches a preset
distance from the Sun (if parabolic). The time step is calculated
based on the rate of motion of the object, smaller near
perihelion, larger at aphelion.
- How do you draw the orbits in the image?
- Once the orbit has been calculated, in heliocentric co-ordinates,
a viewing transform is established, taking into account the
heliocentric viewpoint and
stereoscopic viewing options. The
transform projects the three-dimensional orbit into the pixel space of
the bitmap. A 64-sided polygon is drawn to approximate the elliptical
orbit, using the Postage Stamp
Rasteriser available by FTP from this site.
- What do the numbers in the "orbital elements" box mean?
- Please see the help for
orbital elements. If you check the "Echo elements" box, the
elements will be listed, individually labeled, below the text box.
- Pluto disappeared! What's going on?
- As mentioned above, Pluto's orbit is not known with sufficient
accuracy to permit analytic extrapolation beyond the period from 1885
through 2099, and I'm not about to perform a numerical integration of
solar system motion, now matter how nicely you
ask. So, if you specify a date
outside that interval, Pluto isn't plotted.
- Wasn't it a lot of work to build this program?
- Actually, only a couple of days; the documentation and on-line
help took much longer than the program itself. Like its sibling
Earth Viewer,
much of Solar System Live is based on code lifted
directly from Home
Planet and, in addition, I was able to stand
on the shoulders of others who developed freely available
code or algorithms the program employs; if I've failed to acknowledge
any contributor, please accept my apologies and let me know of any
lacunĀµ so I can properly cite their contributions.
Home Planet was developed as a title for the Autodesk Science Series,
to follow Cellular Automata Lab and James Gleick's
CHAOS: The Software. When
new management arrived at
Autodesk, one of their first actions was to terminate the Science
Series, along with a number
of other products, some profitable, which did not "meet the business
model". I obtained the rights to Home Planet and decided to place it
in the public domain. Since then, in my spare time, I've been mining
the man-year I invested in its development to build public domain
Windows and Web tools such as
Earth Viewer and the
Sky screen saver for Windows.
This isn't the last; stay tuned.
- My Whatever browser doesn't work with Solar System
Live.
- We're a long web away from total compatibility among browsers.
I've tested Solar System Live with
NCSA Mosaic Version 2.4 and
Netscape
1.0N and had no problems. Your
browser must support
forms
and in-line graphics. I use a few of the
HTML extensions
in Netscape to make things a little prettier and
faster for users of that browser, but they appear, as designed, to cause
no problems to other browsers which simply ignore them per the HTML
spec.
Return to Solar System Live
Help
Credits
by John Walker
kelvin@fourmilab.ch