The problem of finding an arc length of an ellipse is the origin of the name of the elliptic integrals. The equation of an ellipse with semi-major axis, a, and semi-minor axis, b, may be written in parametric form as x=asinϕy=bcosϕ The element of length along the ellipse's perimeter, ds=√dx2+dy2=√a2cos2ϕ+b2sin2ϕdϕ=a√1−e2sin2ϕdϕ, where e=√1−b2/a2 is the eccentricity. The arc length may therefore be written in terms of incomplete elliptic integrals of the second kind: ∫ds=a∫ϕ2ϕ1√1−e2sin2ϕdϕ=a[E(e;ϕ2)−E(e;ϕ1)].
Earth's orbit is an ellipse with semi-major axis 149,598,261 km and eccentricity 0.01671123. We will find the distance travelled by the Earth in one orbit, and compare it with that obtained assuming a circular orbit of radius 1AU≡149597870.7km.
The perimeter of an ellipse may be written using the above expression with ϕ1=0,ϕ2=2π:
P=a[E(e,2π)−E(e,0)]=4aE(e),
since the entire perimeter is four times the quarter-perimeters which may be written in terms of the complete elliptic integral of the second kind. Noting that SciPy's ellipe
function actually takes m=e2 as its argument, we have:
In [x]: import numpy as np
In [x]: from scipy.special import ellipe
In [x]: a, e = 149598261, 0.01671123 # semi-major axis (km), eccentricity
In [x]: pe = 4 * a * ellipe(e*e)
In [x]: print(pe)
939887967.974 # "exact" answer
In [x]: AU = 149597870.7 # mean orbit radius, km
In [x]: pc = 2 * np.pi * AU
In [x]: print(pc)
939951143.1675915 # assuming circular orbit
In [x]: (pc - pe) / pe * 100
0.0067215663638305143
That is, the percentage error in the perimeter in treating the orbit as circular is about 0.0067%.