Quadratic equation calculator

How it works

Enter a, b and c for ax² + bx + c = 0 to get the roots.

The formula

x = (−b ± √(b² − 4ac)) ÷ 2a. The discriminant b² − 4ac decides: positive two roots, zero one root, negative complex roots.

Worked example

x² − 5x + 6 = 0: discriminant 25 − 24 = 1, so x = (5 ± 1) ÷ 2, giving x = 3 and x = 2.

Good to know