Skip to main content
ilovecalcs logoilovecalcs.

Math · Live

Quadratic, solved on a math notepad.

Type the coefficients of ax² + bx + c = 0 and watch every step appear: substitute, compute the discriminant, isolate the roots, plot the parabola.

Nature of rootsStep-by-step

Inputs

Coefficients

Equation

x² − 5x + 6 = 0

Discriminant Δ
1
Vertex
(2.5, -0.25)
Axis
x = 2.5
y-intercept
(0, 6)

Discriminant is positive, the parabola crosses the x-axis at two distinct points, giving two real roots.

Solution · Two roots

Δ = 1

x₁
3
x₂
2
Discriminant
Δ = 1

Math notepad

Step-by-step from the quadratic formula.

handworked

Quadratic formula:

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

Substitute a = 1, b = -5, c = 6:

x = (−(-5) ± √((-5)² − 4·(1)·(6))) / (2·1)

Compute the discriminant Δ = b² − 4ac:

Δ = (-5)² − 4·(1)·(6) = 25 − 24 = 1

Δ > 0 → two distinct real roots:

x = (−(-5) ± √1) / (2·1) = (5 ± 1) / 2

x₁ = 3 x₂ = 2

Parabola

y = x² − 5x + 6

opens up
Roots
2 real
Vertex
(2.5, -0.25)
Axis
x = 2.5

Field guide

The nature of roots, decided by the discriminant.

Every quadratic equation in the form ax² + bx + c = 0 (with a ≠ 0) is solved by the same compact formula:

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

But the kind of answer you get (two real roots, one repeated root, or a pair of complex conjugates) is decided entirely by the expression under the square root. That expression has its own name: the discriminant, written Δ = b² − 4ac.

Δ > 0: two distinct real roots

When the discriminant is positive, the square root is a real positive number, and the ± in the formula gives two genuinely different answers. Geometrically, the parabola crosses the x-axis at two distinct points. Those two crossings are the roots. This is the case students spend most of their time on.

x₁ = (−b + √Δ) / 2a
x₂ = (−b − √Δ) / 2a

Example: x² − 5x + 6 = 0. Then Δ = 25 − 24 = 1, so x = (5 ± 1) / 2 gives x₁ = 3 and x₂ = 2.

Δ = 0: one repeated real root

When the discriminant is exactly zero, the square root term vanishes and the ± contributes nothing; the two roots collapse into a single repeated value at the vertex. Geometrically, the parabola just kisses the x-axis at one point and turns back. The root is sometimes called a double root or "root of multiplicity 2."

x = −b / 2a

Example: x² − 4x + 4 = 0 factors as (x − 2)². Δ = 16 − 16 = 0, so x = 2 is the only real root, and the parabola touches the x-axis at exactly that point.

Δ < 0: two complex conjugate roots

When the discriminant is negative, the square root of a negative number isn't real. It's imaginary. We write √−1 = i and continue with complex arithmetic. The two roots are complex conjugates: same real part, opposite imaginary parts.

x = −b/2a ± (√|Δ| / 2a) · i

Geometrically, the parabola never crosses the x-axis; it sits entirely above (when a > 0) or entirely below (when a < 0). There are no real x-intercepts to mark, but the equation still has solutions in the complex plane.

Example: x² + x + 1 = 0. Then Δ = 1 − 4 = −3, and the roots are x = −0.5 ± (√3/2) · i, about −0.5 + 0.866i and −0.5 − 0.866i.

The discriminant at a glance

  • Δ > 0: two distinct real roots; parabola crosses x-axis twice.
  • Δ = 0: one real repeated root; parabola touches x-axis at the vertex.
  • Δ < 0: two complex conjugate roots; parabola does not touch the x-axis.

Reading the parabola graph

The parabola y = ax² + bx + c opens upward when a > 0 and downward when a < 0. Its vertex sits at x = −b/2a, which is also the axis of symmetry; the parabola is mirror-symmetric around that vertical line. The y-intercept is always c (just plug in x = 0).

What if a = 0?

Strictly speaking, the equation isn't quadratic anymore; the term has disappeared. The calculator handles it gracefully: when a = 0 and b ≠ 0 it falls back to the linear solution x = −c/b; when both a and b are zero, there's either no equation (if c = 0, every x works) or no solution (if c ≠ 0).

Worked example, on the notepad

Solve 2x² − 4x − 6 = 0:

  1. Coefficients: a = 2, b = −4, c = −6.
  2. Discriminant: Δ = (−4)² − 4·2·(−6) = 16 + 48 = 64. Positive → two real roots.
  3. Square root: √64 = 8.
  4. Plug in: x = (4 ± 8) / 4.
  5. Roots: x₁ = 12/4 = 3, x₂ = −4/4 = −1.
  6. Check by factoring: 2(x − 3)(x + 1) = 2x² − 4x − 6 ✓.

Common mistakes

  • Forgetting the minus in −b. Always negate the coefficient of x first.
  • Squaring b before negating: is always non-negative, regardless of b's sign.
  • Dropping the absolute value when Δ is negative. The square root inside the formula needs a sign-flip and an i tacked on.
  • Dividing only the ±√Δ piece by 2a and forgetting to divide −b too. Both terms are over 2a.

Disclaimer

The calculator solves quadratics with real coefficients. For quadratics with complex coefficients, higher-degree polynomials, or systems of equations, you'll want a CAS like SymPy or WolframAlpha.