Center of Ellipse Calculator

Enter the coefficients of an ellipse's general equation, A x² + C y² + D x + E y + F = 0, to find its center point (h, k) and its semi-major and semi-minor axis lengths.

Quick Facts

Center formula
h = −D/(2A), k = −E/(2C)
Found by completing the square on A x² + Dx and C y² + Ey.
Ellipse condition
A and C must be positive
If A = C (no xy term) the "ellipse" is a circle.

Your Results

Calculated
Center X (h)
-
x-coordinate of the center
Center Y (k)
-
y-coordinate of the center
Semi-major axis (a)
-
Half the length of the longer axis
Semi-minor axis (b)
-
Half the length of the shorter axis

Ready

Enter the five coefficients A, C, D, E, F, then press Calculate.

Finding the Center of an Ellipse

Every ellipse that is aligned with the x- and y-axes can be written as a general second-degree equation, A x² + C y² + D x + E y + F = 0, where A and C are both positive. This calculator recovers the ellipse's center point (h, k) and its semi-major and semi-minor axis lengths directly from those five coefficients, using the same algebra you would use to convert the equation into standard form by hand.

The general equation and its assumptions

The general form above has no xy term, which means the ellipse's axes run parallel to the coordinate axes (no rotation). For it to describe a real ellipse, A and C must both be positive. If A equals C, the shape is a circle — a special case of an ellipse where the two axis lengths are equal. If A and C have opposite signs, the equation describes a hyperbola instead, and the calculator will flag it as invalid.

Completing the square

To find the center, group the x-terms and y-terms and complete the square on each:

  • A(x² + (D/A)x) + C(y² + (E/C)y) + F = 0
  • A(x − h)² + C(y − k)² = N, where h = −D / (2A) and k = −E / (2C)
  • The right-hand side works out to N = D²/(4A) + E²/(4C) − F

The point (h, k) is the center of the ellipse — it is the point where the equation's partial derivatives with respect to x and y are both zero, which geometrically is the midpoint of both the major and minor axes.

Semi-major and semi-minor axes

Dividing both sides of A(x − h)² + C(y − k)² = N by N puts the equation into standard form, (x − h)²/a² + (y − k)²/b² = 1, where a² = N/A and b² = N/C. Taking square roots gives the two semi-axis lengths: whichever of a or b is larger is the semi-major axis (half the long diameter), and the smaller is the semi-minor axis (half the short diameter). For N to produce real axis lengths, N must be positive; if it is not, the coefficients do not correspond to an actual ellipse.

Worked example

For 4x² + 9y² − 8x − 36y + 4 = 0 (the calculator's default values): h = −(−8)/(2·4) = 1 and k = −(−36)/(2·9) = 2, so the center is (1, 2). Then N = 64/16 + 1296/36 − 4 = 4 + 36 − 4 = 36, giving a² = 36/4 = 9 and b² = 36/9 = 4 — so a = 3 and b = 2. The standard-form equation is (x − 1)²/9 + (y − 2)²/4 = 1, an ellipse centered at (1, 2) with a horizontal semi-major axis of 3 and a vertical semi-minor axis of 2.

Frequently Asked Questions

What equation does this calculator use?
It uses the general equation of an axis-aligned ellipse, A x² + C y² + D x + E y + F = 0, where A and C are both positive. This form has no xy term, so the ellipse's major and minor axes are parallel to the x- and y-axes.
How is the center (h, k) calculated?
The center comes from completing the square on each variable: h = −D / (2A) and k = −E / (2C). These are the values of x and y where the partial derivatives of the equation are both zero, which is the vertex of each squared term.
What do the semi-major and semi-minor axes mean?
After moving the equation into standard form (x − h)²/a² + (y − k)²/b² = 1, a and b are the semi-major and semi-minor axis lengths: the distances from the center to the ellipse's edge along each axis. The larger of the two is the semi-major axis; the smaller is the semi-minor axis.
What if A equals C?
If A equals C (and there is no xy term), the ellipse is a circle, a special case where the semi-major and semi-minor axes are equal. The same center formula, h = −D/(2A) and k = −E/(2C), still applies.