Ellipse Perimeter Calculator

Calculate the perimeter of an ellipse from its semi-major and semi-minor axes with Ramanujan's accurate approximation. Compare five methods against the exact value, with area, eccentricity, foci, and unit conversion.

https://hexacalculator.com/calculators/mathematics/geometry/ellipse-perimeter-calculator

Mathematics

Geometry

Ellipse Perimeter Calculator

Calculate the perimeter of an ellipse from its semi-major and semi-minor axes with Ramanujan's accurate approximation. Compare five methods against the exact value, with area, eccentricity, foci, and unit conversion.

Ellipse Perimeter Calculator

Unit
Unit

Compare all five perimeter approximations

Show the simple, root-mean-square, and Ramanujan approximations side by side with the numerically exact perimeter, so you can see how closely they agree.

Find the total distance around several times

Treat the ellipse as a track or path and multiply its perimeter by a number of laps to get the total distance travelled.

Enter the semi-major axis and the semi-minor axis, and the calculator works out the perimeter along with the area, eccentricity, and focus distance. It converts between units like centimetres, inches, and feet for you.

Perimeter

cm
Equal-perimeter circle radius
cm

Was this calculator helpful?

It takes one click and shapes what we fix next.

Add as preferred on Google

Show how the perimeter grows with the axes

A bar chart comparing what happens to the perimeter when you scale the whole ellipse versus stretching only its long axis.

This ellipse circumference calculator computes the length of a path that goes around an ellipse once, based on its major and minor axes. By entering the major and minor axes, you can instantly determine not only the circumference but also the area, eccentricity, and focal distance.

Ellipse Perimeter - Introduction
Ellipse Perimeter - Introduction

The tool converts units, so for example, you can enter centimeters and get the circumference in inches or feet. Since there is no exact elementary formula for the circumference of an ellipse, this calculator shows five different approximations along with their numerical values, so that you can check the accuracy of each method yourself.

Why is the circumference of an ellipse special?

Calculating the circumference of an ellipse is notoriously more difficult than for a circle. While a circle has the simple formula 2 pi r, an ellipse does not have an exact short formula. The actual circumference is expressed by an elliptic integral, and such expressions cannot be represented using the usual functions learned in school.

Ellipse Perimeter - Actual Formula
Ellipse Perimeter - Actual Formula

So all tools for calculating the circumference of an ellipse, including this one, use approximations. Fortunately there are some that are astonishingly accurate. This tool shows the second of two formulas proposed by Ramanujan as being particularly good at giving results. The accuracy of this formula for a general ellipse is about one part in 100,000, which is much more accurate than any conventional measuring device.

What is an ellipse?

An ellipse is an elongated circle with a distinct oval shape. It has two axes that are perpendicular to each other; the longer axis is called major and the shorter one minor. Half of each axis, measured from the center, are the semi-major a and semi-minor b axes, and these two values determine the size and shape of the ellipse.

Ellipse Perimeter - Explainer
Ellipse Perimeter - Explainer

Within each ellipse are two special points called foci (singular focus). The sum of the distances from any point on the curve to the two foci is always constant. This explains why an ellipse can be drawn using two thumbtacks and a piece of string. When the two foci coincide at the center, the two axes become equal in length and the ellipse becomes virtually circular.

The formula for calculating the circumference of an ellipse.

The following are the formulas used in this tool, listed from least to most accurate. In each formula, "a" is the major semiaxis and "b" is the minor semiaxis.

Arithmetic mean.

The fastest method to estimate the circumference of an ellipse is to calculate the circumference of a circle whose radius is the average of the lengths of the two semi-axes of the ellipse.

P≈π(a+b)P \approx \pi (a + b)

Square root of the average.

In a second simplified method the average of both axes is not used but rather the square root of the mean value. In elongated ellipses this often leads to an overestimation of the circumference.

P≈π2(a2+b2)P \approx \pi \sqrt{2 (a^2 + b^2)}

A closer approximation:

The combination of both approaches above yields significantly better results.

P≈π[32(a+b)−a b ]P \approx \pi \left[\tfrac{3}{2}(a + b) - \sqrt{a\,b}\,\right]

Ramanujan's first approximation formula.

For most ellipses, the error of Ramanujan's first formula is already in the range of less than one hundredth.

P≈π[ 3(a+b)−(3a+b)(a+3b) ]P \approx \pi \left[\, 3(a + b) - \sqrt{(3a + b)(a + 3b)} \,\right]

Here, Ramanujan's second approximation formula is used.

The second formula of Ramanujan is the one that appears as a highlighted result in this tool. First it calculates an auxiliary value h which then gets substituted into the formula.

h=(a−b)2(a+b)2h = \frac{(a - b)^2}{(a + b)^2}
P≈π(a+b)(1+3h10+4−3h)P \approx \pi (a + b)\left(1 + \frac{3h}{10 + \sqrt{4 - 3h}}\right)

How accurate are these estimates?

The following table shows all five formulas and the numerical approximation for ellipses with major axis 10 and minor axis 5.

Ellipse Perimeter - Example
Ellipse Perimeter - Example

The Integral answer turns out to be:

Ellipse Perimeter - Calculation
Ellipse Perimeter - Calculation

Notice that the rough approximations differ from each other, while the two Ramanujan formulas are nearly identical in accuracy.

Method

Formula

Result (a = 10, b = 5)

Simple average

pi (a + b)

47.12

Root mean square

pi sqrt(2(a sq + b sq))

49.67

Closer approximation

pi [1.5(a + b) - sqrt(a b)]

48.47

Ramanujan I

pi [3(a + b) - sqrt((3a + b)(a + 3b))]

48.4421

Ramanujan II (used here)

pi (a + b)(1 + 3h / (10 + sqrt(4 - 3h)))

48.4422

Exact (elliptic integral)

numerical integration

48.4422

Ellipse Perimeter - Approximation
Ellipse Perimeter - Approximation

If you enable the Compare option in the tool, it will show all of these results for each ellipse so that you can see how they gradually approach a value.

Ellipse Perimeter - Explainer
Ellipse Perimeter - Explainer

Here's how to use this calculator tool:

Enter the major and minor axes. Once both fields are filled in, the tool will display the circumference as a highlighted result, while also outputting the area, eccentricity, distance between foci, and radius of a circle with the same circumference. If you change the unit for any one of these values, all other numerical values will automatically be converted. By enabling the "Comparison" option, you can compare the five approximation methods. Enabling the "Number of Revolutions" option multiplies the circumference by the number of revolutions, which may be useful for applications such as orbits or tracks.

Use the full length of both major and minor axes, not just half.

In some cases instead of the half-axes measured from the center, the whole width of the ellipse is given, i.e. the major and minor axes. Since the half-axis is always half of the full axis, divide the respective measurements by two before entering them. If the length of the major axis is 14 and the length of the minor axis is 6, then the half-length of the major axis is 7 and the half-length of the minor axis is 3.

Example calculation:

Assume that half the major axis of an ellipse is 7 centimeters and half the minor axis is 4 centimeters. Use Ramanujan's second approximation to first calculate h.

h=(7−4)2(7+4)2=9121≈0.0744h = \frac{(7 - 4)^2}{(7 + 4)^2} = \frac{9}{121} \approx 0.0744

Plug this value into the formula for circumference.

P≈π(11)(1+3(0.0744)10+4−3(0.0744))≈35.0 cmP \approx \pi (11)\left(1 + \frac{3(0.0744)}{10 + \sqrt{4 - 3(0.0744)}}\right) \approx 35.0 \ \text{cm}

This tool allows you to simply enter the lengths of both axes and display the circumference in the top area of the result section without having to do any manual calculations.

Circumferences of some ellipses

The following table shows the perimeters of Ramanujan II for various combinations of semi-axes, rounded to two decimal places. Note that an ellipse with a greater eccentricity has a larger perimeter than one which is more circular, given the same area, because its contour must extend further to enclose the same space.

Semi-major a

Semi-minor b

Perimeter

10 cm

10 cm

62.83 cm

10 cm

5 cm

48.44 cm

7 cm

4 cm

35.20 cm

7 cm

3 cm

32.69 cm

8 cm

2 cm

34.31 cm

Eccentricity and foci

Eccentricity is a single value that indicates how stretched an ellipse is. It ranges from a perfect circle (0) to a long, thin stretch (1). It's the ratio between the distance from center to focus and the semi-major axis.

e=ca,c=a2−b2e = \frac{c}{a}, \qquad c = \sqrt{a^2 - b^2}

Here c is the distance from the center of the ellipse to each focus, which is shown in the tool as the focal length. The orbits of planets are elliptical with the sun at one of the foci. Eccentricity measures how much an orbit deviates from a circular shape. Earth's orbit has an eccentricity of about 0.017 and so it is nearly circular. Comets can have eccentricities over 0.9, creating long orbits that are much longer than they are wide.

circles with equal circumference

It can be useful to replace an ellipse with a circle of equal circumference. This is the case for example when comparing elliptical and circular orbits. The circumference of a circle with radius r is 2*pi*r, so the corresponding radius for the ellipse is obtained by dividing its circumference by 2*pi.

r=P2πr = \frac{P}{2\pi}

The tool shows this as the radius of a circle with an equal circumference. This is a circle that has the same circumference as the ellipse and corresponds to the circle of equal area which can be found using the ellipse area calculator.

Applications of the scope for elliptical shapes

Ellipses are common in sports, design and science. Tracks consist of two straight lines connected by curves that approximate an ellipse. The circumference is the length of one lap around the track. When you enable the "Number of laps" option in the tool, the circumference is multiplied by the number of laps to calculate the total distance.

Designers and manufacturers need the circumference to attach frames, trim or borders for oval mirrors, tables, rugs or swimming pools. Engineers use it to determine the dimensions of seams on elliptical pipes or tanks while gardeners measure the perimeter of flower beds. In astronomy, dividing the circumference of an orbit by the orbital period gives the average speed of a planet or satellite as it moves in an elliptical path.

Tips for accurate results

Measure the exact center and curve to determine each axis, or measure the entire horizontal width and use half of that for the tool. Make sure units match or let the tool convert them, and note that the major axis is the longer of the two axes. Reversing the two axes does not change either circumference or area since they are symmetrical with respect to one another. Regardless of input order, eccentricity and focal length will be displayed based on the longer axis.

Frequently asked questions

What is the formula for the circumference of an ellipse?

There is no simple exact formula. The actual circumference is an elliptic integral that cannot be expressed in terms of elementary functions. Instead the tool uses a highly accurate approximation. This tool uses Ramanujan's second approximation: P is approximately pi times (a + b), multiplied by the quantity 1 plus 3h divided by (10 plus the square root of (4 minus 3h)). Here h is the square of (a - b), divided by the square of (a + b). For a typical ellipse, the error will be about one part in 100,000.

How accurate is Ramanujan's approximation?

It is astonishingly accurate. For ellipses that are not extremely elongated, Ramanujan's second approximation agrees with the exact circumference to five or six decimal places, with an error of about one in 100,000. The closer the ellipse is to a circle, the more accurate it becomes. Even for very eccentric ellipses, the error is minimal. You can check that the numerical values agree exactly by enabling the compare option.

How to calculate the perimeter from the full length of major and minor axes?

To get the semi-major and semi-minor axes, enter half of the total length for each axis. The semi-major axis is half of the total length of the major axis, and the semi-minor axis is half of the total length of the minor axis. For example, if the total length of the major axis is 14 and the total length of the minor axis is 6, then the semi-major axis is 7 and the semi-minor axis is 3.

Why is there no exact formula for the perimeter of an ellipse?

The calculation of the length of a curve leads to elliptic integrals, and it is these integrals that inspired the name for this family of functions. Unlike the circle whose circumference is simply 2πr, ellipses have two different axes which means that elementary functions cannot provide a closed-form solution for their perimeter. Mathematicians either calculate this integral numerically or use Ramanujan's approximation.

What is the eccentricity of an ellipse?

The eccentricity indicates how stretched an ellipse is. It is calculated as the ratio of focal length to semi-major axis, so e = c / a. Here c is the square root of (a² - b²). A circular shape 0 gradually approaches a very elongated ellipse 1. For the same area, an ellipse with larger eccentricity also has a larger circumference.

How is the circumference of an ellipse different than that of a circle?

A circle is a special ellipse with both axes the same length. Its circumference is exactly 2πr. Since an ellipse has one long axis and one short axis, its circumference will be between that of a circle with the short axis as diameter and that of a circle with the long axis as diameter. Also, the circumference of an ellipse cannot be written down exactly but can only be calculated approximately. When both axes are equal in length, all these approximations lead to 2πr.

Related calculators

Disclaimer: This calculator is provided for general informational and educational purposes only. Our calculators are under active development, and results may be inaccurate, incomplete, or unsuitable for your situation. Always verify the figures independently and seek advice from a qualified professional before relying on them. We make no warranties and accept no liability for any loss or decision arising from use of this tool.

References

  1. Wikipedia: Ellipse (Circumference)

    Why the perimeter has no elementary formula and the approximations used, including Ramanujan's.

  2. Wikipedia: Srinivasa Ramanujan

    The mathematician behind the two highly accurate ellipse perimeter approximations.

  3. Math is Fun: Ellipse

    Plain-language explanation of the axes, foci, perimeter, and the string method.