Factoring only works when a quadratic has friendly roots. The quadratic formula works every time – for whole-number roots, messy decimals and even equations with no real solution. Here is what it says, where it comes from and how to use it without sign errors.
What the quadratic formula says
For any equation ax² + bx + c = 0 with a ≠ 0, the solutions are x = (−b ± √(b² − 4ac)) ÷ 2a. The ± means there are two answers: one using +, one using −.
Step-by-step method
- Rearrange the equation so one side is 0.
- Read off a, b and c with their signs.
- Calculate the discriminant D = b² − 4ac.
- Substitute into the formula and simplify both roots.
- Check by substituting each root back into the equation.

Three worked examples
| Equation | a, b, c | D | Roots |
|---|---|---|---|
| x² − 5x + 6 = 0 | 1, −5, 6 | 1 | 3 and 2 |
| 2x² + 4x − 3 = 0 | 2, 4, −3 | 40 | 0.581 and -2.581 |
| x² + 2x + 5 = 0 | 1, 2, 5 | −16 | −1 ± 2i |
| x² − 6x + 9 = 0 | 1, −6, 9 | 0 | 3 (repeated) |
Second row in full: D = 4² − 4(2)(−3) = 16 + 24 = 40. x = (−4 ± √40) ÷ 4. Since √40 ≈ 6.325, x ≈ 0.581 or x ≈ -2.581.
What the discriminant tells you
- D > 0: two different real roots – the parabola crosses the x-axis twice.
- D = 0: one repeated root – the parabola just touches the axis.
- D < 0: no real roots; two complex roots – the parabola never reaches the axis.
Checking D first saves work: if it is a perfect square, the equation factors neatly.
Where the formula comes from
It is what you get by completing the square on the general equation. Divide by a, move c/a across, add (b/2a)² to both sides to make a perfect square, take the square root, and solve for x. Every quadratic can be solved this way, which is why the formula never fails.
Common sign mistakes
- −b when b is negative: if b = −5, then −b = +5.
- b² is always positive: (−5)² = 25, not −25.
- −4ac when c is negative becomes a plus.
- The whole numerator is divided by 2a, not just the square root.
When to use something else
If the equation factors at a glance, factoring is quicker. If you need the turning point of the parabola, completing the square gives the vertex directly. For everything else, use the formula.
A word problem from start to finish
A rectangular garden is 3 m longer than it is wide and has an area of 40 m². Let the width be x: x(x + 3) = 40, so x² + 3x − 40 = 0. Here a = 1, b = 3, c = −40. D = 9 + 160 = 169 and √169 = 13, so x = (−3 ± 13) ÷ 2, giving x = 5 or x = −8. A width cannot be negative, so the garden is 5 m by 8 m. Real problems often produce one root that makes no physical sense – always check both against the context.
Exact answers and decimals
When the discriminant is not a perfect square, leave the answer in surd form for exactness: for 2x² + 4x − 3 = 0, x = (−4 ± √40) ÷ 4 simplifies to (−2 ± √10) ÷ 2. Convert to decimals only at the end, and round to the precision the question asks for.
Sum and product of the roots
Without solving, you can tell that the two roots add to −b/a and multiply to c/a. For x² − 5x + 6 = 0 the roots must add to 5 and multiply to 6 – which fits 2 and 3. This is a fast way to check your answers.
Frequently asked questions
Finding the solutions (roots) of any quadratic equation.
b² − 4ac, the part under the square root; it tells you how many real roots there are.
Yes, when the discriminant is negative.
A parabola can cross the x-axis at two points.
Yes – just use 0 for that coefficient.

