The quadratic formula
For ax² + bx + c = 0 with a ≠ 0:
x = (−b ± √(b² − 4ac)) ÷ 2a
It works for every quadratic, which is why it is worth memorizing even though factoring is faster when it works.
A worked example
2x² + 5x − 3 = 0, so a = 2, b = 5, c = −3.
- b² − 4ac = 25 − 4(2)(−3) = 25 + 24 = 49.
- √49 = 7.
- x = (−5 + 7) ÷ 4 = 0.5, and x = (−5 − 7) ÷ 4 = −3.
Check one: 2(0.25) + 2.5 − 3 = 0. ✓
The discriminant tells you what to expect
b² − 4ac is called the discriminant.
- Positive: two different real roots, and the parabola crosses the x-axis twice.
- Zero: one repeated root at x = −b/2a, where the parabola just touches the axis.
- Negative: no real roots. The two solutions are a complex conjugate pair, (−b ± i√(4ac − b²)) ÷ 2a.
A perfect square discriminant also means the equation factors over the integers, which is useful to know before trying.
Factoring, when it works
For x² + 7x + 12, find two numbers that multiply to 12 and add to 7: 3 and 4. So (x + 3)(x + 4) = 0 and x = −3 or −4. With a leading coefficient the search is longer, and if the discriminant is not a perfect square there is nothing to find. Try factoring for a few seconds, then use the formula.
Completing the square
x² + 6x + 5 = 0 → (x + 3)² − 9 + 5 = 0 → (x + 3)² = 4 → x = −3 ± 2, so −1 or −5. This is slower than the formula for solving, but it is how the formula is derived, and it gives the vertex directly: (x + 3)² − 4 means the minimum is at (−3, −4).
Vertex, sum and product
- Vertex at x = −b/2a, the midpoint of the two roots.
- The roots sum to −b/a and multiply to c/a, which is a quick check on any answer.
For the example above: sum = −5/2 = −2.5, and 0.5 + (−3) = −2.5. ✓
Tools
The Quadratic Equation Solver gives both roots, real or complex, along with the discriminant and the vertex.