Math 326, Feb 19 - Planetary Motion
If medieval europeans and
central americans can model the motion of planets, so
can we. Well, we better stick to a simplified version since those
astronomers keep track of an astounding number of factors. We are
assuming a heliocentric system, so the sun is at the origin and doesn't
move. Acceleration due to gravity is proportional to the inverse square
of the distance between the planet and the sun, in the direction toward the
sun. After working out the algebra, this means a
is given by a = -(c/r3)(x,y).
Rather than use typical units like meters and seconds (for which orbits would
contain huge numbers), we set the gravitational constant c=100, initial
position to be (x,y)=(100,
0), initial velocity to be (vx,vy)=(0,1)
and time steps increasing by 1 each step. Run your model for 2600 time
steps.
Additional
Questions
- The Half-Step Fix: Instead of computing the new velocities using
the previous acceleration as we always have in the past, instead use the
current acceleration. By using the newer acceleration to find
velocity we are effectively improving the accuracy of velocity by a half timestep (instead of using v(t)
from t to t+1, we it's like we're using v(t+0.5)).
- Who Needs Ellipses: Make scroll bars for initial x and
initial vy. For initial
radii 25, 100 and 400 find the initial velocity which will give a circular
orbit. You know the orbit is circular if the maximum x
coordinate equals the minimum x coordinate. Guess a formula
for the velocity of a circular orbit in terms of radius, then check it with some other radii.
- Those stars are moving...: Make a second
copy of everything on the same spreadsheet, which we will use to represent
a second planet. Set the initial distance and velocity for the first
planet to 50 and 1.2 respectively (this will be our Earth). Set the
initial distance and velocity for the second planet to 100 and 0.9 (this
is Mars). Make an animated graph which shows the position of Mars as
viewed from Earth, as time passes (Hint: (xm-xe,
ym-ye)). In the old days, astronomers deduced
the elliptical orbits of planets from observations like this. Less than
this, in fact, since they could only watch the planets passing through the
sky instead in a birds-eye view like we have here.
- The Happiest Place Orbiting Earth: Let's add the
moon's path to our picture. Find the length of one year for our
planet (have Excel detect the first time when the planet's y-coordinate
changes from negative to non-negative). The moon's orbital period
should be (Year length)/(# of months). Now
choose a radius for the moon's orbit. The moon radius should be some
fraction of the planet's orbital radius; start with (Moon Radius)=(0.33)*(Planet Radius). Now we set coordinates
so that the moon circles around the planet with the appropriate frequency:
xmoon(t) = xplanet
+ (Moon Radius)*COS( 2*PI()*T / (Moon Period) )
ymoon(t) = yplanet + (Moon Radius)*SIN( 2*PI()*T / (Moon
Period) )