|
Posted by rob on December 5, 2006, 9:56 pm
Please log in for more thread options I still have a couple of dumb questions to ask (not being a scientist) with
regards to how to calculate the initial positions of the planets in the
solar system in order to "kick start" the simulation.
What I am trying to do is place each planet at either it's perihelion or
aphelion as the initial position.
I know the planet's semi-major axis and its eccentricity and want to use
this to calculate the X and Y position (2d simulation), its velocity and
angle of motion.
I have calculated the distance of the perihelion / aphelion from the centre
of the ellipse using the following:
distPeri = SemiMajor * (1 - eccentricity)
distAphelion = SemiMajor * (1 + eccentricity)
I have calculated the velocity at the perihelion / aphelion using the
following:
velPeri = Sqrt(G * SunMass * (2 / distPeri - 1 / SemiMajor))
velAphelion = Sqrt(G * SunMass * (2 / distAphelion - 1 / SemiMajor))
The part that I am not sure about is where to place the planet relative to
the sun. I assume the sun is not at the centre of the ellipse but rather at
one of the ellipse's foci. If so, which foci do I use - the one furthest
from the aphelion or the one closest?
If furthest from the Aphelion then the initial distance from the sun (when
at the aphelion) is intialDistance = distAphelion + distFoci
Other formula I have used are as follows:
distance to focus from centre of ellipse is distFoci = semiMinor *
eccentricity
lenght of semiminor axis is semiMinor = SemiMajor * Sqrt(1 - eccentricity
^2)
Can anyone help me with this - have I got it right and which foci should the
sun be position at?
Cheers
Rob
> Hi
>
> I created a program for calucalting the orbits of planets in any solar
> system. You can define your own solar system and the program calculates
> and
> displays the orbits of the planets. The problem is that I dont know if I
> have got it right. Fundamentally, the program is based upon the universal
> law of gravitation, but I would very much appreciate a second opinion as
> to
> whether or nor it is correctly calculating the orbits of the planets.
>
> The program can be downloaded from the following web site:
>
> http://members.optusnet.com.au/rob_tink/
>
> Any comments would be greatly appreciated.
>
> I have tested this by putting in data for our solar system. I have
> calculated the planets starting position and velocity as if the planets
> travel in a circle around the sun. They do seem to do the right thing ie.
> the earth travels around in approx 365 days and follows a circular path.
>
> What I really need is a way to calculate the planet's starting position
> and velocity for the eliptical path that they actually follow. So what I
> need to do (and have not yet worked out how to do) is determine the
> planets velocity at the apogee and their distance from the sun at this
> point. Dont suppose anyone has a simple formula to work that out?
>
> Cheers
> Rob
>
>
|