Kepler's 2nd law of planetary motion

13,862
0
Published 2013-07-08
The differential equations used follow the Wikipedia description.

r=orbitSize/(1+eccentricity cos(angle))
angularSpeed= speed*sqrt(1-eccentricity^2)/r^2

r is the distance to the sun. The 'eccentricity' is the eccentricity of the ellipse. When the eccentricity is 0, the ellipse is a circle. 'orbitSize' and 'angularSpeed' are bundles of other numbers that I don't need.