Solving by completing the square
Not every quadratic equation factorises nicely with whole numbers. Try : no pair of integers multiplies to and adds to , so the cross-multiplication method that worked so well for stalls completely. Completing the square is the technique that never stalls — it rewrites any quadratic as a perfect square equal to a constant, , which is then solved by the one operation a perfect square invites: taking a square root. The method matters for a second reason too. Push through the same steps on the general equation , keeping letters instead of numbers, and out falls the quadratic formula itself. Completing the square is not a rival to the formula you will meet next — it is the derivation behind it, the reason and appear exactly where they do. This article builds on factorisation, the first solving technique in the same chapter, and leads directly into the quadratic formula, the third and final technique. Between them, the three methods give a complete toolkit: try factorisation first for speed, fall back to completing the square (or the formula it produces) whenever factors are not obvious.
Adding to both sides of turns the left side into a perfect square , so the equation can be solved by taking square roots.
The core idea
A perfect square trinomial such as factors as because its constant term, , is the square of half the coefficient of — here, . This pattern always holds: expanding gives , so the constant term is always the square of half the middle coefficient. Completing the square exploits this pattern in reverse: given , add the missing constant to make it a perfect square. Since an equation must stay balanced, whatever is added to the left must also be added to the right — this is the same balancing rule used whenever a term is moved across an equation, applied here to a term that is added rather than simply moved. For the general equation this pattern needs one extra step first. If , every term is divided by so the equation starts in the form before the "add half the middle coefficient, squared" trick can be applied:
where: , , are the coefficients of the quadratic (), and is the term added to both sides — half the coefficient of (after dividing by ), squared. The left side is now guaranteed to be a perfect square, , no matter what , , are. Once the equation reads , two cases follow. If , take square roots of both sides — remembering both the positive and negative root — to get , then solve for . If , no real number squares to a negative value, so the equation has no real roots; this is stated as a conclusion, not worked around. Carrying the same steps through with letters instead of numbers, as the derivation below shows, produces the quadratic formula met in the next topic — nothing new is introduced there; it is exactly this method, done once in general. The quantity that appears under the root is called the discriminant: it is the same that must stay non-negative for real roots to exist.
The goal is to take the general quadratic equation , with and , any real numbers, and carry it through exactly the same completing-the-square steps used on number equations above, so that the perfect-square form appears with letters in place of numbers and the quadratic formula falls out as its direct consequence.
Step 1. Divide every term of by , which is allowed since , to make the coefficient of equal to : .
Step 2. Move the constant term to the right side by subtracting from both sides: .
Step 3. Identify half the coefficient of , namely , and add its square, , to both sides to complete the square: .
Step 4. Write the left side as a perfect square and simplify the right side over a common denominator : .
Step 5. Take the square root of both sides, keeping both signs, and subtract to isolate : , so — the quadratic formula, valid whenever .
Worked example
Solve by completing the square, and identify the value of and in . This example needs a full walk-through because it must show, in one continuous chain, how moving the constant across, adding the completing term to both sides, and finally taking a signed square root each contribute a necessary piece to reaching both roots correctly — skipping or mishandling any single step below produces a wrong or incomplete answer.
Step 1. The coefficient of is already , so no division by is needed. Move the constant term to the right side: .
Step 2. Half the coefficient of is , so the completing term is . Add it to both sides: , which simplifies to .
Step 3. The left side is now the perfect square , so the equation reads — here and .
Step 4. Take square roots of both sides, keeping the : .
Step 5. Solve the two cases separately: or .
The roots are and . Checking both in the original equation: and , so both satisfy the equation.
Competitive stretch
For , the coefficient of is , not , so the division step from Step 1 above is essential this time. Dividing every term by first gives , so . Half of is , squared is , so , giving . Taking roots, — two irrational roots left exactly in surd form rather than rounded, since is not a perfect square. Notice that skipping the division and instead adding directly to would have produced a wrong, non-perfect-square left side — a direct instance of the first common trap below.
Common traps
- Adding instead of when — the equation must be divided by first, or the completing term is wrong.
- Adding the completing term to only one side. It must go on both sides of the equals sign to keep the equation balanced.
- Dropping the when taking a square root, which silently discards one of the two valid roots.
- Trying to take the square root of a negative . If has , the correct conclusion is "no real roots," not an invented answer.
- Rounding a surd answer too early. When is not a perfect square, leave the roots as in exact form unless the question explicitly asks for a decimal approximation.
Ask the tutor: Stuck on which constant to add for a particular equation, or want completing the square worked line by line for one you are practising? Ask the AI tutor to walk through it with you.
Why bother completing the square if factorisation is faster whenever it works?
Factorisation is quicker, but it only works when the quadratic happens to split into nice integer or simple fractional factors — many equations, like , never do, because no pair of factors of the constant term adds up to the middle coefficient. Completing the square works on every quadratic equation without exception, whether the roots are integers, fractions, surds, or the equation has no real roots at all, so it is the reliable fallback method. It also builds the reasoning behind the quadratic formula, which is why the syllabus places it right before that formula rather than skipping straight to it — understanding this method makes the formula feel derived rather than memorised.
Do I always have to divide by a, even when a is already 1?
No — the division step is only needed when the coefficient of is not already . If , as in , you go straight to moving the constant across and adding the completing term. The division is there purely so the "add half the middle coefficient, squared" trick applies correctly; skipping it when changes nothing because dividing by does nothing anyway.
My answer came out as a surd like 2 plus root 2.5 — did I make a mistake?
No, that is a perfectly valid final answer. Not every quadratic has whole-number or even rational roots; when in is not a perfect square, the roots are irrational and should be left in exact surd form, such as , rather than rounded to a decimal. Rounding early loses precision and is generally not accepted as the exact answer.