Calculate analemma for Mars from SSC file
Posted: 28.10.2008, 04:03
I would like to calculate and draw the analemma for Mars from data contained in the solar system SSC file, with the goal of adapting the techniques for other planets. For drawing diagrams, Keplerian orbits have sufficient accuracy. Which parameters in the SSC file are important, and how do I go about it?
The values from the SSC file that I think may be needed are:
(The above formula is the dot product of the vectors described by these two pairs of angles.)
We will need to derive the following formulae:
From Meeus, I have the following formula for equation of time E:
The values from the SSC file that I think may be needed are:
- EllipticalOrbit.Eccentricity
- EllipticalOrbit.Inclination
- EllipticalOrbit.AscendingNode
- EllipticalOrbit.LongOfPericenter
- EllipticalOrbit.MeanLongitude (probably not needed for an analemma diagram but may be needed for equation of time as a function of time T)
- Obliquity
- EquatorAscendingNode
- Axial tilt of the planet (equal to Obliquity if EllipticalOrbit.Inclination is zero)
- Equator ascending Node in relation to orbit of planet (equal to EquatorAscendingNode if EllipticalOrbit.Inclination is zero)
Code: Select all
Axial tilt = arccos(cos(AscendingNode)*sin(Inclination)*cos(EquatorAscendingNode)*sin(Obliquity) + sin(AscendingNode)*sin(Inclination)*sin(EquatorAscendingNode)*sin(Obliquity) + cos(Inclination)*cos(Obliquity))
(The above formula is the dot product of the vectors described by these two pairs of angles.)
We will need to derive the following formulae:
- Equation of time
- Declination of the sun (or star) in relation to the equator of the planet
From Meeus, I have the following formula for equation of time E:
Code: Select all
E = y sin 2L0 - 2e sin M + 4ey sin M cos 2L0 - (1/2)y^2 sin 4L0 - (5/4) e^2 sin 2M
- E = equation of time
- y = tan^2 (axial tilt/2)
- L0 = Sun's mean longitude
- e = eccentricity
- M = sun's mean anomaly