Quadratic equation
Solve a quadratic equation using the discriminant, with a parabola graph.
Enter coefficients a, b, c – the solution, graph and steps appear instantly.
How to solve a quadratic equation
A quadratic equation has the form ax² + bx + c = 0 (a ≠ 0). It is solved using the discriminant D, which determines how many real roots the equation has:
D = b² − 4ac • x₁,₂ = (−b ± √D) / (2a)
What the discriminant means
- D > 0 two distinct real roots (the parabola crosses the x-axis at two points)
- D = 0 one repeated root (the parabola touches the x-axis at its vertex)
- D < 0 no real root (the parabola does not cross the x-axis)
Step-by-step example
x² − 5x + 6 = 0: D = (−5)² − 4·1·6 = 25 − 24 = 1. Since D > 0, there are two roots: x₁,₂ = (5 ± 1) / 2, i.e. x₁ = 3 and x₂ = 2. On the graph, the parabola crosses the x-axis at 2 and 3.
When a = 0
If a = 0, it's not a quadratic equation but a linear one (bx + c = 0). The calculator recognises this and solves it as linear – see the linear equation calculator.
Tip: Vieta's formulas – the sum of the roots is −b/a and the product is c/a. A quick check of the result.