Quadratic Solver
Solve ax² + bx + c = 0 — real or complex roots, discriminant, and vertex, step by step.
1x² − 3x + 2 = 0
Vertex: (1.5, -0.25)
Solve ax² + bx + c = 0 with the quadratic formula x = (−b ± √(b² − 4ac)) ÷ 2a. For x² − 3x + 2 = 0, the discriminant is (−3)² − 4×1×2 = 1, so x = (3 ± 1) ÷ 2, giving the two roots x = 2 and x = 1.
The quadratic formula
Any equation in the form ax² + bx + c = 0 (with a ≠ 0) is solved by the same formula. It comes from completing the square on the general equation, so it works every time — whether the roots are tidy integers or messy irrationals.
the ± gives the two roots; b² − 4ac is the discriminant
Worked example
Solve x² − 3x + 2 = 0, so a = 1, b = −3, c = 2:
- 1 Compute the discriminant. b² − 4ac = (−3)² − 4×1×2 = 9 − 8 = 1. It is positive, so expect two real roots.
- 2 Take the square root and apply ±. √1 = 1, so x = (3 ± 1) ÷ 2.
- 3 Read off both roots. x = (3 + 1) ÷ 2 = 2 and x = (3 − 1) ÷ 2 = 1. Check: (x − 1)(x − 2) = x² − 3x + 2. ✓
What the discriminant tells you
b² − 4ac decides the nature of the roots before you compute them.
| Discriminant b² − 4ac | Roots | Graph crosses x-axis |
|---|---|---|
| Positive (> 0) | Two distinct real roots | At two points |
| Zero (= 0) | One repeated real root | Touches at one point |
| Negative (< 0) | Two complex conjugate roots | Never |
Vertex, symmetry, and complex roots
The vertex sits at x = −b ÷ 2a — the axis of symmetry. For x² − 3x + 2 that is x = 1.5, and the lowest point is (1.5, −0.25). The two roots, 1 and 2, are mirror-symmetric about that line.
When a = 0 the equation is no longer quadratic but linear (bx + c = 0); the tool detects this and solves it directly. For cubics and beyond, the polynomial roots calculator finds every real and complex root.
Complex roots appear when the discriminant is negative — they come as a conjugate pair, re ± im·i, and the parabola never touches the x-axis.