Skip to content
K Knidox Search…
Math · Algebra

Quadratic Solver

Solve ax² + bx + c = 0 — real or complex roots, discriminant, and vertex, step by step.

1 3x + 2 = 0

Example equations — tap to load
Roots (x)
2, 1Two real roots

Vertex: (1.5, -0.25)

The parabola y = ax² + bx + c — it crosses the x-axis at the real roots
Parabola y = 1x² − 3x + 2, with vertex at (1.5, -0.25)3.75-0.2483x = -0.5x = 3.5

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.

x = (−b ± √(b² − 4ac)) ÷ 2a

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. 1
    Compute the discriminant. b² − 4ac = (−3)² − 4×1×2 = 9 − 8 = 1. It is positive, so expect two real roots.
  2. 2
    Take the square root and apply ±. √1 = 1, so x = (3 ± 1) ÷ 2.
  3. 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² − 4acRootsGraph crosses x-axis
Positive (> 0)Two distinct real rootsAt two points
Zero (= 0)One repeated real rootTouches at one point
Negative (< 0)Two complex conjugate rootsNever

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.

What if a = 0?
Then it isn’t quadratic — it’s linear. The tool flags this and solves bx + c = 0 instead.
What does the discriminant tell me?
b² − 4ac: positive gives two real roots, zero gives one repeated root, and negative gives two complex roots — all before you finish the calculation.
What are complex roots?
When the discriminant is negative, the roots involve the imaginary unit i and are shown as a conjugate pair, re ± im·i.
What is the vertex?
The turning point of the parabola, at x = −b ÷ 2a, which is also the axis of symmetry. The tool reports both coordinates.
Why use the formula instead of factoring?
Factoring is faster when the roots are simple integers, but the quadratic formula works for every quadratic, including irrational and complex roots.
How do I read off both roots from the formula?
The ± gives two values: use +√(b² − 4ac) for one root and −√(b² − 4ac) for the other, each over 2a. For x² − 3x + 2 = 0 that is (3 + 1) ÷ 2 = 2 and (3 − 1) ÷ 2 = 1.