Algebra
Completing the Square: A Step-by-Step Guide
By MathSolver Pro Editorial Team · Published
Completing the square rewrites as a perfect square minus a constant. It solves any quadratic, gives the vertex of a parabola, produces the quadratic formula, and reappears in circles and calculus.
The idea behind the method
A perfect square trinomial is the expansion of a squared binomial. Expanding gives : the constant term is the square of half the coefficient of . Completing the square means adding exactly that constant so an expression becomes a perfect square.
For example, half of 6 is 3 and , so . Expanding the right side gives , which confirms it. Geometrically, is an by square plus two by strips, and the missing corner is a by square of area 9.
The same pattern works with a minus sign. Half of is and , so . The constant you add is always positive, because it is a square, while the sign inside the bracket matches the sign of . Keeping these two facts separate prevents most errors in the steps that follow.
Solving a quadratic equation by completing the square
- If the coefficient of is not 1, divide every term by it.
- Move the constant term to the right side.
- Add to both sides.
- Write the left side as and simplify the right side.
- Take the square root of both sides, remembering , and solve for .
Example 1:
- Move the constant: .
- Half of 6 is 3, and . Add 9 to both sides: .
- Factor: .
- Square root: , so or .
- Check : . Check : .
When the leading coefficient is not 1
Example 2:
- Divide by 2: .
- Move the constant: .
- Half of is , and . Add 4: .
- Square root: .
- So , approximately and .
The quadratic formula agrees: . With an odd middle coefficient the fractions are unavoidable but manageable. For , half of 5 is , so and .
Complex solutions
If the right side ends up negative, there are no real solutions, but the method still gives the complex ones.
Check: , and .
Vertex form of a parabola
The most common use of completing the square in graphing is converting into vertex form , where is the vertex. Since a square is never negative, the vertex is the minimum point when and the maximum point when .
Example 3:
- Complete the square on : .
- Substitute: .
- Vertex , a minimum; the parabola never goes below , so it has no x-intercepts.
Example 4:
- Factor out of the terms only: .
- Complete the square inside: .
- Distribute carefully: .
- Vertex , a maximum. Check: at , .
The most frequent error in Example 4 is forgetting to multiply the subtracted 9 by the factored-out . Expanding your vertex form back out is a quick check.
The shortcut gives the same vertex x-coordinate; completing the square shows where that formula comes from. The quadratic calculator reports the vertex alongside the roots.
Deriving the quadratic formula
Completing the square on the general equation with produces the quadratic formula, which is why the formula always works.
The middle step comes from adding to both sides and writing as . The guide on how to solve quadratic equations explains when to use the formula, factoring or this method.
Circles and other applications
Completing the square in both and turns a general circle equation into centre-radius form.
Example 5:
- Group and move the constant: .
- Add 9 for and 4 for to both sides: .
- Centre , radius 5.
In calculus, the same step prepares integrals such as : writing the denominator as gives . The integral calculator uses this substitution when it applies.
Common mistakes
- Adding to one side only.
- Completing the square before dividing by a leading coefficient other than 1.
- Forgetting when taking the square root, which loses a solution.
- Using or instead of .
- Reading the vertex sign wrong: has , and has .
Try your own example in the completing the square calculator, which shows each of the steps above.
Reading information from the completed square
Once a quadratic is written as , a lot of information can be read off without further calculation. The vertex is and the axis of symmetry is the vertical line . The range follows directly: if , the smallest value is and the range is ; if , the largest value is and the range is .
The number of x-intercepts also follows. Setting gives . If is positive there are two intercepts, if it is zero the vertex touches the axis, and if it is negative the parabola never crosses the axis. In Example 3, has no real solution, which matches the vertex at height 3 on an upward parabola. In Example 4, gives , so the intercepts are and .
Optimisation problems use the same idea. If the profit from selling at price is in hundreds of dollars, Example 4 shows the maximum profit is 8 hundred dollars at . No calculus is needed, because the square term can only reduce the value below the vertex height.
Practice problems with answers
Try these before looking at the answers. Each one uses a step from the examples above.
- Solve . Answer: , so or .
- Solve . Answer: , so .
- Write in vertex form. Answer: , vertex .
- Write in vertex form. Answer: , vertex .
- Find the centre and radius of . Answer: , centre , radius 3.
If an answer does not match, expand your completed square and compare it with the original line by line; the difference usually shows exactly which constant was added or subtracted incorrectly.
Why the method is worth learning
With the quadratic formula available, it is fair to ask why completing the square is still taught. The answer is that it is a transformation, not just a solving trick. It rewrites an expression so that the variable appears in only one place, inside a square. Once that happens, the expression is easy to analyse: its smallest or largest value, its symmetry and its zeros are all visible at once.
This idea recurs across mathematics. Conic sections such as circles, ellipses and hyperbolas are identified by completing the square in two variables. In statistics, the normal distribution's density involves a completed square in its exponent, and deriving many of its properties relies on the same algebra. In calculus, integrals with a quadratic under a square root or in a denominator become standard forms after this step. Physics uses it to find equilibrium points of energy functions.
Practising it on simple quadratics therefore builds a skill that later topics assume you have. If you can do Examples 1 to 5 without notes, you are well prepared for those uses, and for exam questions that ask you to show the method rather than just state roots.
Frequently asked questions
Why add (b/2) squared?
Because . Matching with gives , so the constant that makes a perfect square is .
Should I complete the square or just use the formula?
For solving, the formula is usually faster. Completing the square is the better tool for vertex form, circle equations and some integrals, and it explains where the formula comes from.
Does completing the square work for every quadratic?
Yes. Every quadratic with can be rewritten this way, including those with irrational or complex solutions.
How do I complete the square when b is odd?
Use fractions rather than decimals. Half of is , and you add . For , add to get .
What do I do if the coefficient of x squared is negative?
Factor the negative coefficient out of the and terms, complete the square inside the bracket, and then multiply the subtracted constant by that coefficient when you remove the bracket, as in Example 4.