“Where solutions are creatively achieved!”

Solar System

without comments

Solar System Program

ssystem1This Program was written to be a rough simulation of the solar system. Movement is achieved by adding or subtracting from The “X” coordinate of each “Planet” at each ONTIMER event to sweep the “X” coordinate right then left repeatedly.  The “Y” coordinate is computed from the “X” coordinate using the formula for an ellipse.

It features show hints (similar to alt for the <img> tag) which identify what each circle represents. A weakness of the program is that the “planets” goes swiftly around the edges of the “orbit”.  A possible fix would be to increase the ONTIMER interval as the “X” coordinate reaches the edges of the sweep.

download

Written by admin

January 29th, 2009 at 1:46 am

Posted in Uncategorized

Leave a Reply

You must be logged in to post a comment.