Tutorials › Calculus III › Classifying Quadrics by Completing Squares and Standard Forms

Coordinates and Quadric Surfaces · Tutorial 22 of 999

Classifying Quadrics by Completing Squares and Standard Forms

Rewrite a diagonal quadratic equation by completing squares, then use its standard form to identify and locate the resulting surface.

Beginner 10 min read

What You'll Learn

  • Complete squares in each variable of a three-dimensional quadratic equation with no mixed terms
  • Find the translated coordinates and constant that determine the resulting standard form
  • Classify ellipsoids, hyperboloids, and cones from their normalized equations
  • Read a paraboloid’s vertex and opening direction from its completed-square form
  • Recognize when a missing quadratic term leads to a cylinder or a linear-variable form

Why Complete Squares?

A quadratic equation in \(x\), \(y\), and \(z\) may not immediately reveal what surface it describes. Linear terms can hide the location of the surface, and different coefficients can obscure its shape. Completing the square separates these features: it moves the equation to a suitable center or vertex and puts the equation into a form that can be classified.

This method applies to equations with no mixed terms such as \(xy\), \(xz\), or \(yz\). The goal is not only to name the surface. The completed equation also tells us where its center or vertex is, and which coordinate directions determine its axes.

Definition: A diagonal quadratic equation in three variables has the form \(Ax^2+By^2+Cz^2+Dx+Ey+Fz+G=0\), with no products of distinct variables. Completing the square rewrites its quadratic and linear terms as translated squares plus constants.

The Completing-Squares Formula

For a nonzero coefficient \(A\), the quadratic and linear terms in \(x\) combine according to this identity:

$$ Ax^2+Dx = A\left(x+\frac{D}{2A}\right)^2-\frac{D^2}{4A}. $$

The square is centered at \(x=-D/(2A)\). Apply the same identity to each variable whose quadratic coefficient is nonzero. If \(A\), \(B\), and \(C\) are all nonzero, the equation becomes

$$ A\left(x+\frac{D}{2A}\right)^2+ B\left(y+\frac{E}{2B}\right)^2+ C\left(z+\frac{F}{2C}\right)^2=H, $$

where

$$ H=\frac{D^2}{4A}+\frac{E^2}{4B}+\frac{F^2}{4C}-G. $$

Thus the translation coordinates are \(x_0=-D/(2A)\), \(y_0=-E/(2B)\), and \(z_0=-F/(2C)\). In translated coordinates \(X=x-x_0\), \(Y=y-y_0\), and \(Z=z-z_0\), the equation is \(AX^2+BY^2+CZ^2=H\). These coordinates identify the center for a centered surface such as an ellipsoid or hyperboloid.

Why the formula works: Expanding the right side gives \(A(x^2+(D/A)x+D^2/(4A^2))-D^2/(4A)=Ax^2+Dx\). The added constant inside the square is exactly canceled by the subtracted constant outside it. Applying this identity variable by variable changes only the equation’s arrangement, not the set of points satisfying it.

Classifying the Centered Forms

After completing squares, divide by the nonzero right-hand side or by the absolute values of the coefficients to obtain standard form. The squared terms’ signs determine the broad type of surface; their denominators determine the scale along each coordinate direction.

Standard formClassification and location
\(\frac{X^2}{a^2}+\frac{Y^2}{b^2}+\frac{Z^2}{c^2}=1\)Ellipsoid centered at the translated origin \((x_0,y_0,z_0)\).
\(\frac{X^2}{a^2}+\frac{Y^2}{b^2}-\frac{Z^2}{c^2}=1\)Hyperboloid of one sheet, centered at \((x_0,y_0,z_0)\); the negative term’s direction is the axis direction.
\(-\frac{X^2}{a^2}-\frac{Y^2}{b^2}+\frac{Z^2}{c^2}=1\)Hyperboloid of two sheets, centered at \((x_0,y_0,z_0)\); the positive term’s direction is the axis direction.
\(\frac{X^2}{a^2}+\frac{Y^2}{b^2}-\frac{Z^2}{c^2}=0\)Elliptic cone with vertex at \((x_0,y_0,z_0)\).

Here \(a\), \(b\), and \(c\) are positive. The coordinate directions of the translated variables are the principal directions in these forms. If all three squared terms have the same sign before normalization, the right-hand side determines whether the surface is an ellipsoid, a single point, or empty. For example, a sum of nonnegative squares can equal zero only when every square is zero; it cannot equal a negative number.

For a mixed-sign equation, first multiply the entire equation by \(-1\), if needed, so that two squared terms are positive and one is negative. Then compare the resulting right-hand side with zero. A positive right-hand side gives the one-sheet form; a negative right-hand side can be multiplied through by \(-1\) to give the two-sheet form; a zero right-hand side gives a cone.

Worked Example: A Translated Ellipsoid

Worked Example: A Translated Ellipsoid

Classify \(2x^2+y^2+4z^2-8x+6y-16z+21=0\), and find its center and axis lengths.

Group the terms by variable, including the constant:

$$ (2x^2-8x)+(y^2+6y)+(4z^2-16z)+21=0. $$

Complete each square. For \(x\), factor out \(2\), then use half of \(-4\); for \(y\), use half of \(6\); for \(z\), factor out \(4\), then use half of \(-2\):

$$ 2\bigl((x-2)^2-4\bigr) +\bigl((y+3)^2-9\bigr) +4\bigl((z-2)^2-4\bigr)+21=0. $$

Evaluate the constants: \(2(-4)=-8\), \(-9\), and \(4(-4)=-16\). Their sum with \(21\) is \(-12\). Therefore,

$$ 2(x-2)^2+(y+3)^2+4(z-2)^2=12. $$

Divide by \(12\) and write each term with denominator one:

$$ \frac{(x-2)^2}{6}+\frac{(y+3)^2}{12}+\frac{(z-2)^2}{3}=1. $$

All three terms are positive, so this is an ellipsoid. Its center is \((2,-3,2)\); its semi-axis lengths along the \(x\)-, \(y\)-, and \(z\)-directions are \(\sqrt{6}\), \(\sqrt{12}\), and \(\sqrt{3}\), respectively.

To check, expand the completed equation: \(2(x-2)^2=2x^2-8x+8\), \((y+3)^2=y^2+6y+9\), and \(4(z-2)^2=4z^2-16z+16\). Setting their sum equal to \(12\) and subtracting \(12\) gives \(2x^2+y^2+4z^2-8x+6y-16z+21=0\), the original equation.

Worked Example: A Hyperboloid of One Sheet

Worked Example: A Hyperboloid of One Sheet

Classify \(x^2+4y^2-z^2-2x+8y+4z=0\), and locate its center and axis direction.

Complete the square in each variable:

$$ (x^2-2x)+4(y^2+2y)-(z^2-4z)=0. $$

The first group is \((x-1)^2-1\). The second is \(4((y+1)^2-1)=4(y+1)^2-4\). Since \(-(z^2-4z)=-((z-2)^2-4)=-(z-2)^2+4\). Substituting gives

$$ (x-1)^2-1+4(y+1)^2-4-(z-2)^2+4=0. $$

The constant terms sum to \(-1\), so

$$ (x-1)^2+4(y+1)^2-(z-2)^2=1, $$

or, in standard form,

$$ \frac{(x-1)^2}{1}+\frac{(y+1)^2}{1/4} -\frac{(z-2)^2}{1}=1. $$

There are two positive terms and one negative term, with right-hand side \(1\), so this is a hyperboloid of one sheet. Its center is \((1,-1,2)\), and its axis direction is the \(z\)-direction, corresponding to the negative squared term.

For a check, expand the completed equation’s left side: \((x-1)^2=x^2-2x+1\), \(4(y+1)^2=4y^2+8y+4\), and \(-(z-2)^2=-z^2+4z-4\). Subtracting the right-hand side \(1\) leaves \(x^2+4y^2-z^2-2x+8y+4z=0\), as required.

When a Variable Is Linear

Completing a square requires a nonzero quadratic coefficient. If, for example, the equation contains \(-z\) but no \(z^2\), do not try to complete a square in \(z\). Complete squares in the variables that have quadratic terms, then isolate \(z\). A standard form such as \(z=(x-x_0)^2/a^2+(y-y_0)^2/b^2+z_0\) describes an elliptic paraboloid with vertex \((x_0,y_0,z_0)\) opening in the positive \(z\)-direction. Reversing the sign on the right reverses the opening direction.

If a variable appears in neither a square nor a linear term, the equation does not depend on that coordinate. The surface extends along that coordinate direction, as in a cylinder. These observations are useful when the initial equation has missing quadratic terms; the completion method applies only to the terms that are present.

Worked Example: Finding a Paraboloid’s Vertex

Worked Example: Finding a Paraboloid’s Vertex

Rewrite \(2x^2+2y^2-8x+4y-z+10=0\) in standard form, then identify its vertex and opening direction.

Group the quadratic and linear terms in \(x\) and \(y\). Complete their squares:

$$ 2(x^2-4x)+2(y^2+2y)-z+10=0, $$
$$ 2\bigl((x-2)^2-4\bigr) +2\bigl((y+1)^2-1\bigr)-z+10=0. $$

The constant contributions are \(2(-4)=-8\) and \(2(-1)=-2\), which sum with \(10\) to zero. Thus

$$ 2(x-2)^2+2(y+1)^2-z=0, \qquad z=2(x-2)^2+2(y+1)^2. $$

Equivalently, \(\frac{(x-2)^2}{1/2}+\frac{(y+1)^2}{1/2}=z\). This is an elliptic paraboloid with vertex \((2,-1,0)\), opening in the positive \(z\)-direction because \(z\) is a sum of nonnegative terms.

Check by expansion: \(2(x-2)^2=2x^2-8x+8\) and \(2(y+1)^2=2y^2+4y+2\). The equation \(z=2(x-2)^2+2(y+1)^2\) becomes \(2x^2+2y^2-8x+4y-z+10=0\), matching the original.

A Reliable Classification Procedure

For an equation with no mixed terms, organize the calculation so the translation and the classification remain distinct. This makes it easier to check both the algebra and the geometric conclusion.

1
Group terms by variable.
Keep each quadratic term with its corresponding linear term, and retain the original constant.
2
Complete every available square.
For each nonzero quadratic coefficient, use half the linear coefficient after factoring out the quadratic coefficient.
3
Collect constants and isolate the squared terms.
Move constants carefully to obtain a translated equation with a single right-hand side.
4
Normalize and classify.
Compare the signs of the squared terms and the right-hand side with the standard forms.
5
Read off the location and directions.
The shifts give the center or vertex; the squared-term denominators and signs identify the principal directions.

A Common Pitfall: Losing the Constant

When completing a square, the constant created inside the square must be balanced outside it. For example, \(x^2-6x\) is not \((x-3)^2\): expanding that incorrect expression gives \(x^2-6x+9\), which differs by \(9\). The correct identity is

$$ x^2-6x=(x-3)^2-9. $$

Omitting the \(-9\) changes the equation and can change the classification. A practical check is to expand the completed form and verify that every original quadratic, linear, and constant term reappears.

Why Standard Form Matters

Completing squares turns an algebraic equation into a geometric description. The shifts locate the surface, while the signs distinguish the ways its principal cross-sections behave. The denominators show how far the surface extends in each coordinate direction. This is why the algebra is not merely a rearrangement: it provides a direct route from the coefficients in an equation to a location and a recognizable shape.

Check Your Understanding

Use completing squares and standard forms to answer the following questions.

  1. In \(x^2+4y^2+z^2-6x+8y-2z+G=0\), what translation centers the three squared terms?
  2. What type of centered surface has two positive squared terms and one negative squared term equal to a positive constant?
  3. What geometric location is indicated by the shifts in \(\frac{(x+2)^2}{4}+\frac{(y-1)^2}{9}-\frac{(z+3)^2}{16}=1\)?
  4. Why is it invalid to complete a square in a variable that appears only linearly?
  5. What should be done to check that a completed-square equation is algebraically equivalent to the original?