Quadratic Formula Calculator

Solve real roots of ax² + bx + c = 0 from three coefficients and inspect the discriminant used to classify the result.

Solve a quadratic equation

x = 2Second root: 1Discriminant: 1

How this tool works

A quadratic equation has a non-zero squared-term coefficient and may have two, one, or no real roots. This calculator evaluates the discriminant first and then applies the quadratic formula when real solutions exist.

The discriminant is b²−4ac. Real roots are (−b ± √discriminant)/(2a); a positive discriminant gives two roots, zero gives one repeated root, and negative gives none in the real numbers.

How to use it

  1. Enter coefficients a, b, and c from ax² + bx + c = 0.
  2. Ensure coefficient a is not zero.
  3. Review the real roots and discriminant classification.

Worked examples

Two distinct roots

Input
a=1, b=-3, c=2
Output
Roots 2 and 1

The discriminant is one. Substituting plus and minus its square root into the quadratic formula produces the two real roots two and one.

No real roots

Input
a=1, b=0, c=1
Output
No real roots

The discriminant is negative four, so its square root is not real. The current calculator reports that classification rather than complex-number roots.

Limitations

  • The current output does not express complex-number roots.
  • Floating-point rounding may slightly approximate irrational solutions.