An ellipse is the set of points whose distances to two fixed points, the foci, add up to the same constant. Planet orbits, elliptical tables, arches, gears, the cross-section of a tilted cylinder and the shadow of a ball on a slanted surface are all ellipses, which is why the same handful of quantities keeps coming back: the area, the perimeter, how stretched the shape is, and where the foci sit.
This calculator gives all of them at once. Enter the two semi-axes — or the semi-major axis with either the focal distance or the eccentricity — and, if you like, the centre . You get the area , the perimeter computed exactly with the arithmetic-geometric mean, the Ramanujan approximation with its error, the eccentricity, the linear eccentricity , the coordinates of the foci, vertices and co-vertices, the latus rectum, the directrices, the flattening and the standard equation of the ellipse.
Lengths can be in any unit, as long as you use the same one for every input: results come back in that unit, and the area in that unit squared. For a quick perimeter of many shapes side by side, the perimeter calculator also covers ellipses; this page goes further with the focal geometry and the equation.
How to use this calculator
- Choose what you know: Semi-axes (half-width and half-height), a + focal distance c, or a + eccentricity e.
- Type the values. With semi-axes, the larger one automatically becomes the semi-major axis and decides whether the ellipse is wide or tall. In the other two modes, pick whether the major axis is horizontal or vertical.
- Optionally enter the centre . It only moves the ellipse, so it changes the equation, foci, vertices and directrices but not the area, perimeter or eccentricity.
- Read the area first, then the perimeter, the standard equation and the focal properties. The steps show every substitution.
If you have the full axes (the whole width and height), halve them first: and are always semi-axes.
The formula
For semi-major axis and semi-minor axis (), centred at with a horizontal major axis:
For a vertical major axis, goes under the term instead.
The foci are at , the vertices at , the co-vertices at and the directrices are the lines .
Perimeter. There is no elementary formula: the exact value is , where is the complete elliptic integral of the second kind. The calculator evaluates it with the arithmetic-geometric mean (AGM) of and , which converges in a handful of steps to full machine precision:
Ramanujan’s second approximation, published in 1914, is shown alongside:
Worked example
Semi-axes 5 and 3, centred at the origin. Area: . Linear eccentricity: , so the foci are at and the eccentricity is . Latus rectum: . Directrices: . Equation: .
The exact perimeter is , and Ramanujan’s formula gives — identical to six decimals.
A very flat ellipse, a = 10 and b = 1. Exact perimeter ; Ramanujan , an error of only 0.0012 %. The naive circle-like guess is noticeably off.
From the eccentricity: and give , , area and perimeter .
Eccentricity, foci and the shape of an ellipse
The eccentricity measures how far the foci are from the centre relative to the size of the ellipse. It goes from 0 for a circle (both foci at the centre, ) towards 1 for a needle-thin ellipse. Some reference values:
| Eccentricity | Ratio b/a | What it looks like |
|---|---|---|
| 0 | 1 | Circle |
| 0.0167 | 0.99986 | Earth’s orbit: indistinguishable from a circle by eye |
| 0.5 | 0.866 | Clearly oval |
| 0.8 | 0.6 | The 5 × 3 example above |
| 0.967 | 0.255 | Halley’s comet orbit |
Because , the shape depends on alone; only scales it. The flattening is the same idea used by geodesists to describe the Earth’s ellipsoid (about 1/298).
The reflective property follows from the definition: a ray leaving one focus bounces off the ellipse straight into the other focus. Whispering galleries and kidney-stone lithotripters use exactly this.
How accurate is Ramanujan’s perimeter formula?
Ramanujan’s second formula is astonishingly good: its relative error grows roughly like , so it is exact to about nine significant digits for ordinary ellipses and stays below 0.04 % even when the ellipse collapses into a segment (where the true perimeter is ). Simpler formulas you may meet, such as or , are off by several percent for elongated ellipses. Since the AGM gives the exact value instantly, the calculator uses it as the main result and shows Ramanujan’s value so you can see how close it comes.
Frequently asked questions
What is the formula for the area of an ellipse?
Area = π × a × b, where a and b are the semi-axes (half the length and half the width). A circle is the special case a = b = r, which gives πr². An ellipse with semi-axes 5 and 3 has an area of 15π ≈ 47.12 square units.
Why is there no simple exact formula for the perimeter?
The arc length of an ellipse leads to an elliptic integral that cannot be written with elementary functions. It can still be computed to any precision, and the arithmetic-geometric mean does so in just a few iterations, which is what this calculator uses.
How do I find the foci of an ellipse?
Compute c = √(a² − b²). The foci lie on the major axis, at distance c on each side of the centre: (h ± c, k) for a horizontal ellipse, (h, k ± c) for a vertical one. For a = 5 and b = 3, c = 4.
What is the latus rectum of an ellipse?
It is the chord through a focus perpendicular to the major axis. Its length is 2b²/a; half of it, b²/a, is the semi-latus rectum, the parameter p used in the polar equation r = p / (1 + e·cos θ) of orbits.
Can I get the ellipse from its eccentricity?
Yes. Choose a + eccentricity e: the calculator finds b = a√(1 − e²) and c = a·e, then everything else. The eccentricity must be at least 0 and strictly less than 1.
What is the difference between the major axis and the semi-major axis?
The major axis is the longest diameter, 2a; the semi-major axis is half of it, a. All formulas on this page use the semi-axes a and b.
Sources
- OpenStax — Precalculus 2e, §10.1 The Ellipse
- Ramanujan, S. (1914) — Modular equations and approximations to π, Quart. J. Math. 45:350–372
- Abramowitz & Stegun — Handbook of Mathematical Functions, §17.6 (AGM)
- NIST DLMF §19.9 — Inequalities and approximations for the perimeter of an ellipse
Last updated: