Math

Quadratic Equation Solver

Enter the coefficients a, b and c to solve ax² + bx + c = 0 — get the roots, discriminant, vertex and a plotted parabola, with the working shown.

Calculator

Equation
1x² − 5x + 6 = 0
Roots
x₁ = 3, x₂ = 2
The parabola crosses the x-axis at two points.
Vertex
(2.5, -0.25)
Axis of symmetry
x = 2.5
y-intercept
6

Worked solution

Discriminant: D = b² − 4ac = (-5)² − 4·(1)·(6) = 1

x = (−b ± √D) / 2a = (5 ± √1) / 2

How the quadratic formula works

Every quadratic ax² + bx + c = 0 (with a ≠ 0) is solved by x = (−b ± √(b² − 4ac)) / 2a. The quantity under the root, D = b² − 4ac, is the discriminant: when D > 0 there are two real roots, when D = 0 there is one repeated root, and when D < 0 the roots are a pair of complex conjugates.

The graph of the equation is a parabola. Its vertex sits at x = −b/2a, which is also the axis of symmetry, and the constant term c is where it meets the y-axis. Real roots are exactly the points where the parabola crosses the x-axis.

What does the discriminant tell me?

The discriminant D = b² − 4ac decides the nature of the roots without solving fully: positive means two distinct real roots, zero means a single repeated root, and negative means two complex roots.

Can it handle complex roots?

Yes. When the discriminant is negative the calculator returns the roots in the form p ± qi, where p = −b/2a and q = √(−D)/2a.

Why must a not be zero?

If a = 0 the x² term disappears and the equation is linear, not quadratic, so the quadratic formula no longer applies. Use a line/slope calculator for that case.

Results are estimates. Verify with a professional for important decisions.

About this calculator

This calculator solves any quadratic equation of the form ax²+bx+c=0, finding real or complex roots via the quadratic formula. Enter the three coefficients and instantly see the roots, discriminant, vertex, axis of symmetry, and a plotted parabola.

How to read your results

The result card shows the roots at the top — either two distinct real values, one repeated root, or a complex conjugate pair. Below the roots you will find the discriminant (which tells you the root type), the vertex coordinates, the axis of symmetry, and the y-intercept. A small parabola chart plots the curve, marking real x-intercepts as filled dots and the vertex as an open circle. The step-by-step breakdown underneath shows each stage of the quadratic formula.

Worked example

Enter a = 1, b = −5, c = 6 (solving x² − 5x + 6 = 0).

The discriminant is 1 (positive), so there are two distinct real roots: x₁ = 3 and x₂ = 2. The vertex sits at (2.5, −0.25) and the axis of symmetry is x = 2.5. The parabola crosses the x-axis at both roots.

Frequently asked questions

What does the discriminant tell me?

The discriminant D = b²−4ac determines how many real roots the equation has. When D is positive the parabola crosses the x-axis twice; when D equals zero it just touches it at one repeated root; when D is negative the roots are complex numbers and the parabola never crosses the x-axis.

What are complex roots and when do they appear?

Complex roots appear when the discriminant is negative. They come in conjugate pairs of the form p ± qi, where i is the imaginary unit. Although they are not visible as x-intercepts on the real plane, they are still valid solutions to the equation.

Can I use this for equations where a is not 1?

Yes. Enter any non-zero value for a. The calculator applies the full quadratic formula x = (−b ± √(b²−4ac)) / (2a), so coefficients like 2, −3, or 0.5 work just as well as 1.

How it's calculated

The roots are found using the quadratic formula x = (−b ± √(b²−4ac)) / (2a), as documented by Wolfram MathWorld and Khan Academy. The discriminant D = b²−4ac is computed first; its sign determines whether the square root is real or imaginary. The vertex is (−b/2a, f(−b/2a)), and the axis of symmetry is x = −b/2a. The y-intercept is always c, and real x-intercepts are reported only when D ≥ 0.

Spot a translation issue, a calculation issue, or have a suggestion? Let us know.

200 more like this. Pick the next one.