Simple tools for everyday life.

Quadratic Equation Solver

Solve ax² + bx + c = 0.

Tip: Formula: x = (−b ± √(b²−4ac)) / 2a. The discriminant b²−4ac determines the number of roots.

Loading tool…

Did this tool help?

About this digital tool

The quadratic equation solver finds the roots of the equation ax² + bx + c = 0. Enter the coefficients a, b and c (a cannot be zero) and get the discriminant, the roots x₁ and x₂, or the note "Complex" when there is no real solution.

The formula is x = (−b ± √D) ÷ (2a), where D = b² − 4ac is the discriminant. For x² − 5x + 6 = 0 we have a = 1, b = −5, c = 6, so D = 25 − 24 = 1 and x = (5 ± 1) ÷ 2, giving x₁ = 3 and x₂ = 2. If D > 0 there are two real roots, if D = 0 there is one double root, and if D < 0 there are no real roots. It is used in algebra, physics and optimisation problems.

How to use

  1. Bring the equation to the form ax² + bx + c = 0.
  2. Enter the coefficients a, b and c in the fields provided (a ≠ 0).
  3. See the discriminant D = b² − 4ac, which shows how many real roots the equation has.
  4. Read the roots x₁ and x₂, or "Complex" when D is negative.

Frequently asked questions

What does the discriminant show?

If b²−4ac > 0: two real roots. If = 0: one double root. If < 0: two complex roots (no real solution).

How do I solve a quadratic equation with the formula?

Bring the equation to the form ax² + bx + c = 0, calculate D = b² − 4ac and substitute into x = (−b ± √D) ÷ (2a). E.g. 2x² − 8x + 6 = 0 has D = 16 and x = (8 ± 4) ÷ 4, so x = 3 and x = 1.

What happens when the discriminant is negative?

There are no real roots, only complex ones. E.g. x² + x + 1 = 0 has D = 1 − 4 = −3, so the graph doesn't cross the x-axis.

What do I do if the coefficient a is zero?

Then the equation is not quadratic but linear (bx + c = 0), with solution x = −c ÷ b. The calculator requires a ≠ 0.