No ads, no sign-upChecked 2026-08-29

Quadratic Formula

Result

x₁ = 3, x₂ = 2

Result: x₁ = 3, x₂ = 2

Enter a, b and c. The discriminant D = b² − 4ac decides everything: D above zero gives two real roots, D = 0 one repeated root, D below zero a pair of complex conjugates. For x² − 5x + 6 = 0 the roots are x₁ = 3 and x₂ = 2.

The numbers at a glance

Held fixed: Coefficient a (before x²) 1.0000, Coefficient b (before x) -5.0000.

Constant cResult
0.00005.000000
2.00004.561553
4.00004.000000
6.0000Your value3.000000
8.00002.500000
10.00002.500000
12.00002.500000

Worked examples

Case 1
Coefficient a (before x²)
1
Coefficient b (before x)
-5
Constant c
6

x₁ = 3, x₂ = 2

Open with these values
Case 2
Coefficient a (before x²)
2
Coefficient b (before x)
-7
Constant c
3

x₁ = 3, x₂ = 0.5

Open with these values
Case 3
Coefficient a (before x²)
1
Coefficient b (before x)
2
Constant c
5

x₁ = −1 + 2i, x₂ = −1 − 2i (no real root)

Open with these values

How it's calculated

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

  1. StepWrite the equation as ax² + bx + c = 0 and enter all three coefficients with their signs.
  2. StepCompute the discriminant D = b² − 4ac — its sign decides how many real roots exist.
  3. ResultApply both signs: x = (−b + √D) ÷ 2a and x = (−b − √D) ÷ 2a.

What this number means

The quadratic formula solves every equation of the form ax² + bx + c = 0 in which a is not zero. It returns the values of x that make the expression zero — the points where the parabola meets the x-axis. Everything hinges on the discriminant D = b² − 4ac, the part under the square root. A positive D means the parabola crosses the axis twice, so there are two distinct real roots. A D of exactly zero means it only touches the axis, and the two roots collapse into a single repeated value. A negative D means the parabola never reaches the axis: there is no real root, and the two solutions are a pair of complex conjugates. This page still answers in that case and reports the pair as p ± qi, where p = −b ÷ 2a is the real part both share. The large number above is the larger of the two real roots — or that shared real part when no real root exists. Because the formula works for every quadratic, it succeeds where factoring stalls: awkward decimals, large numbers and equations without neat factors all yield to it at once.

a must not be zero

With a = 0 there is no x² term and the equation is linear, not quadratic. The page then solves bx + c = 0 instead and says so; with a = 0 and b = 0 nothing is left to solve.

A negative discriminant is still an answer

When D is below zero the two solutions are complex conjugates p ± qi. The page prints both and marks that there is no real root.

Check by substituting

Put each root back into ax² + bx + c and the result should be zero. A second check: the two roots add up to −b ÷ a and multiply to c ÷ a.

Commonly misread

A negative discriminant means the equation has no solution.

It has no REAL solution. The two solutions are complex conjugates, shown here as p ± qi.

For x² − 5x + 6 = 0 the coefficient b is 5.

It is −5 — the sign belongs to the coefficient. A misplaced minus changes both roots completely.

The larger root is always (−b + √D) ÷ 2a.

Only while a is positive. With a negative a that expression is the smaller root.

Reference table

a, b, cD = b² − 4acRoots
1, −5, 61x₁ = 3, x₂ = 2
1, −4, 40x₁ = x₂ = 2
1, 0, −936x₁ = 3, x₂ = −3
2, −7, 325x₁ = 3, x₂ = 0.5
1, 2, 5−16−1 ± 2i (no real root)

Questions

How do I use the quadratic formula?

Write your equation as ax² + bx + c = 0, then enter the three coefficients a, b and c. The formula x = (−b ± √(b² − 4ac)) ÷ 2a produces both roots — for x² − 5x + 6 = 0 that is x₁ = 3 and x₂ = 2.

What is the discriminant and what does it tell me?

The discriminant is the part under the square root, D = b² − 4ac. Its sign decides how many real roots exist: above zero gives two distinct real roots, exactly zero gives one repeated root, below zero gives none.

What happens when there are no real roots?

The square root of a negative number has no real value, so the parabola never crosses the x-axis. The two solutions are then complex conjugates, and this page reports them as p ± qi — for x² + 2x + 5 = 0 that is −1 ± 2i.

Why can't coefficient a be zero?

Without an x² term the equation is linear, bx + c = 0, and the formula would divide by zero in its 2a denominator. This page falls back to the single linear solution x = −c ÷ b and labels it as such.

Can I enter negative coefficients?

Yes, any of a, b and c may be negative, positive or — for b and c — zero. For 2x² − 7x + 3 = 0 you enter a = 2, b = −7, c = 3, which gives x₁ = 3 and x₂ = 0.5.

Sources and last check

  1. mathworld.wolfram.com

Information, not professional advice.