Computing accurate approximations to the perimeter of an ellipse is a favorite problem of mathematicians, attracting luminaries such as Ramanujan [1, 2, 3]. As is well known, the perimeter of an ellipse with semimajor axis and semiminor axis can be expressed exactly as a complete elliptic integral of the second kind.

What is less well known is that the various exact forms attributed to Maclaurin, Gauss-Kummer, and Euler are related via quadratic hypergeometric transformations. These transformations lead to additional identities, including a particularly elegant formula symmetric in and .

Approximate formulas can, of course, be obtained by truncating the series representations of exact formulas. For example, Kepler used the geometric mean, , as a lower bound for the perimeter. In this article, we examine the properties of a number of approximate formulas, using series methods, polynomial interpolation, rational polynomial approximants, and minimax methods.

### Introduction

The well-known formula for the perimeter of an ellipse with semimajor axis and semiminor axis can be expressed exactly as a complete elliptic integral of the second kind, which can also be written as a Gaussian hypergeometric function,

The quadratic hypergeometric transformations [4, 5] lead to additional identities, including a particularly elegant formula, symmetric in and ,

where is a Legendre function.

### Cartesian Equation

The Cartesian equation for an ellipse with center at , semimajor axis , and semiminor axis reads

Introducing the parameter into the Cartesian coordinates, as , we verify that the ellipse equation is satisfied.

### Arclength

In general, the parametric arclength is defined by

(1) |

The arclength of an ellipse as a function of the parameter is an (incomplete) elliptic integral of the second kind.

Since

the arclength of the ellipse is

(2) |

where the eccentricity is defined by

### Perimeter

Since the parameter ranges over for one quarter of the ellipse, the perimeter of the ellipse is

That is, , where is the complete elliptic integral of the second kind.

#### Alternative Expressions for the Perimeter

The given expression for the perimeter of the ellipse is *unsymmetrical* with respect to the parameters and . This is “unphysical” in that both parameters, being lengths of the (major and minor) axes, should be on the same footing. We can expect that a *symmetric* formula, when truncated, will more accurately approximate the perimeter for both and .

Noting that the complete elliptic integral is a Gaussian hypergeometric function,

we obtain Maclaurin’s 1742 formula [2]

Equivalent alternative expressions for the perimeter of the ellipse can be obtained from quadratic transformation formulas for Gaussian hypergeometric functions. For example, using functions.wolfram.com/07.23.17.0106.01,

and noting that

we obtain the following symmetric formula

first obtained by Ivory in 1796, but known as the Gauss-Kummer series [2].

Introducing the homogeneous symmetric parameter , we have (cf. mathworld.wolfram.com/Ellipse.html)

Explicitly, the Gauss-Kummer series reads

Instead, using functions.wolfram.com/07.23.17.0103.01, we obtain Euler’s 1773 formula (see also [2])

The hidden symmetry with respect to the interchange is revealed.

Defining

we can directly check the formula.

#### Other Identities

There are many other possible transformation formulas that can be applied to obtain alternative expressions for the perimeter. For example, using functions.wolfram.com/07.23.17.0054.01 we obtain the following formula

The perimeter can also be expressed in terms of Legendre functions (see Sections 8.13 and 15.4 of [6]). For example, using 15.4.15 of [6] we obtain the elegant and simple symmetric formula

Alternatively, this result follows directly from 8.13.6 of [6] with . This form can be used to prove that the perimeter of an ellipse is a homogenous mean (cf. [7]), extending the arithmetic-geometric mean (AGM) already used as a tool for computing elliptic integrals [8].

Using functions.wolfram.com/07.07.26.0001.01 gives yet another formula involving complete elliptic integrals.

#### Comparisons

Here we compare the seven formulas for ,

and for .

### Numerical Approximation

At www.ebyte.it/library/docs/math05a/EllipsePerimeterApprox05.html [1] we are encouraged to search for “…an efficient formula using only the four algebraic operations (if possible, avoiding even square-root) with a maximum error below 10 ppm. It would also be nice if such a formula were exact for both the circle and the degenerate flat ellipse”.

The Gauss-Kummer series expressed as a function of the homogeneous variable , reads

#### Series Expansions

The series expansion about is useful for small .

Around , terms in arise.

Using functions.wolfram.com/07.23.06.0015.0, we obtain the general term of this series (c.f. 17.3.33 through 17.3.36 of [6]),

#### Polynomial Approximants

##### Linear Approximant

From the exact values at ,

and at ,

we construct the linear *extreme perfect* approximant.

##### Quadratic Approximant

The quadratic approximant, exact at ,

has a maximum absolute relative error less than .

##### -order Polynomial Approximant

Here is the -order “even-tempered” polynomial approximant, exact at for .

The -order approximant has a maximum absolute relative error less than .

##### Chebyshev Polynomial Approximant

Sampling the Gauss-Kummer function at the zeros of , which are at , yields a Chebyshev polynomial approximant.

The -order approximant has a maximum absolute relative error less than .

#### Rational Approximation

After loading the Function Approximations Package,

we obtain a family of rational polynomial minimax approximations.

For example, the minimax approximation,

has (absolute) relative error at most , but is not “extreme perfect”.

Using the linear approximant and noting that vanishes at both and leads to an optimal extreme perfect approximant of the form

where the parameters , , and need to be determined. Implementation of the approximant is immediate.

After uniformly sampling the Gauss-Kummer function,

we can use NMinimize and the -norm to obtain the accurate approximants. For example, the (almost) optimal approximant is computed using

leading to

This simple approximant has (absolute) relative error less than .

### Conclusions

Computing the perimeter of an ellipse using a simple set of approximants demonstrates that *Mathematica* is an ideal tool for developing accurate approximants to a special function. In particular:

- All special functions of mathematical physics are built in and can be evaluated to arbitrary precision for general complex parameters and variables.
- Standard analytical methods—such as symbolic integration, summation, series and asymptotic expansions, and polynomial interpolation—are available.
- Properties of special functions—such as identities and transformations—are available at
*MathWorld*[8] and The Wolfram Functions Site [9] and, because these properties are expressed in*Mathematica*syntax, they can be used directly. - Relevant built-in numerical methods include rational polynomial approximants, minimax methods, and numerical optimization for arbitrary norms.
- Visualization of approximants can be used to estimate the quality of approximants.
- Combining these approaches is straightforward and naturally leads to optimal approximants.

### References

[1] | S. Sykora. “Approximations of Ellipse Perimeters and of the Complete Elliptic Integral E(x).” (Aug 8, 2007) www.ebyte.it/library/docs/math05a/EllipsePerimeterApprox05.html. |

[2] | G. P. Michon. “Final Answers: Perimeter of an Ellipse.” (Nov 16, 2007) www.numericana.com/answer/ellipse.htm. |

[3] | R. R. Simha, “Perimeter of Ellipse and Beyond” (lecture, Indian Institute of Technology, Bombay, February 2, 2000). www.alumni.iitb.ac.in/mathslecture.htm. |

[4] | G. Almkvist and B. Berndt, “Gauss, Landen, Ramanujan, the Arithmetic-Geometric Mean, Ellipses, , and the Ladies Diary,” The American Mathematical Monthly, 95(7),1988 pp. 585-608. |

[5] | R. W. Barnard, K. Pearce, and L. Schovanec, “Inequalities for the Perimeter of an Ellipse.” www.math.ttu.edu/~pearce/papers/schov.pdf. |

[6] | M. Abramowitz and I. A. Stegun, eds., Handbook of Mathematical Functions with Formulas, Graphs, and Mathematical Tables (AMS55), 10th ed., Washington, D.C.: United States Department of Commerce, National Bureau of Standards, 1972. www.convertit.com/Go/ConvertIt/Reference/AMS55.ASP. |

[7] | P. Kahlig, “A New Elliptic Mean,” Sitzungsber. Abt. II, 211, 2002 pp. 137-142.hw.oeaw.ac.at/?arp=x-coll7178b/2003-7.pdf. |

[8] | E. W. Weisstein, “Arithmetic-Geometric Mean” from Wolfram MathWorld—A Wolfram Web Resource. mathworld.wolfram.com/Arithmetic-GeometricMean.html. |

[9] | M. Trott, The Wolfram Functions Site—A Wolfram Web Resource. functions.wolfram.com. |

P. Abbot, “On the Perimeter of an Ellipse,” The Mathematica Journal, 2011. dx.doi.org/doi:10.3888/tmj.11.2-4. |

### About the Author

**Paul Abbott**

*School of Physics, M013
The University of Western Australia
35 Stirling Highway
Crawley WA 6009, Australia
*

*tmj@physics.uwa.edu.au*

*physics.uwa.edu.au/~paul*