Quadratic Equation Solver

Solve quadratic equations ax² + bx + c = 0. Get real and complex roots with step-by-step solution.

ax² + bx + c = 0

About this calculator

This solver shows the working: it writes out the discriminant, names the nature of the roots (two distinct real, one repeated, or complex) and substitutes into the quadratic formula so you can follow every step.

It handles negative and decimal coefficients and returns complex roots in a ± bi form when the discriminant is negative.

How to use it

  1. Enter the coefficients a, b and c.
  2. Press Solve.
  3. Read the discriminant, the nature of the roots, the roots and the steps.

Quadratic formula

For ax² + bx + c = 0, the roots are x = (−b ± √(b² − 4ac)) ÷ 2a. The discriminant Δ = b² − 4ac decides the type: Δ > 0 gives two real roots, Δ = 0 one repeated root, Δ < 0 two complex roots. The sum of roots is −b/a and the product is c/a. The vertex is at x = −b ÷ 2a.

Worked example

x² − 5x + 6 = 0

Discriminant25 − 24 = 1
Rootsx₁ = 3, x₂ = 2
Sum / Product5 / 6
Vertex(2.5, −0.25)

Other cases: x² − 2x + 1 = 0 has a repeated root 1, and x² + 1 = 0 has complex roots ±i.

Tips and common mistakes

  • If Δ is a perfect square, the roots are rational and the equation factorises.
  • Check roots by substituting them back.
  • If a = 0 the equation is linear, not quadratic.
  • Divide through by a common factor first to keep numbers small.
  • The graph is a parabola; real roots are where it crosses the x-axis.

Frequently asked questions

What is the quadratic formula?

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

What is the discriminant?

b² − 4ac, which tells you the number and type of roots.

What if the discriminant is negative?

The roots are complex and come as a conjugate pair.

How do I find the vertex?

x = −b/2a, then substitute to find y.

What do the roots mean on a graph?

The x-values where the parabola crosses the x-axis.

Can a be zero?

No. The equation would not be quadratic.

Related tools