I found a formula for calculating the distance to the sun for any given day of the year. The formula uses the cosine function and I am not able to calculate the distances correctly. I fear it is my misunderstanding of the formula or cosine. I need help determining where my math is incorrect.
r = a(1-e*e)/(1+e cos(θ))
a = Semi Major Axis of Orbit = 149.6 kilometers
e = eccentricity of Earth orbit is .01672
θ = Theta = # of days since last perihelion * 365.25/360
Solved for May 22, 2002. Perihelion was on Jan 2, 2002. (140 days.)
I know the answer should be around 151 million kilometers for that day.
And that is about 1.3% farther than the mean of 149.6.
r = 149.6(1-.01672 * .01672) / (1 + e * cos(140 * (365.25/360))
r = 149.6 * (.98328 * .01672) / (1.01672 * cos(140 * (1.01583))
r = 149.6 * (.01644) / (1.01672 * cos(142.2162))
r = 2.459424 / (1.01672 * .79033)
r = 2.459424 / .8035443176
r = 3.0607
???? Where is my misunderstanding?
Great Answer AugSB! I was overlooking the radians conversion. It works great now. Thank you so much. For anyone else needing similar calculations here is the Excel formula developed by AugSB:
- where column "B" holds the number of days since last perihelion.
- it should also be noted that this formula assumes the Earth's orbit is a perfect circle in which the Earth travels the same amount each day. The orbit is actually oblong and travels slightly faster in orbit when nearer to the Sun. So these numbers are not exact. Another Method to account for Kepler's theory can be used, but it is way over my head. NASA has an applet that can get exact distances at the following link.