Quadratic Equation Calculator

Enter the coefficients a, b and c and this calculator solves ax² + bx + c = 0 — real or complex roots, the discriminant, and the parabola's vertex, axis and y-intercept, with every step shown.

Your equation

Enter values for a, b and c in ax² + bx + c = 0. Positive, negative and decimal values are all fine; a cannot be zero.

x² − 5x + 6 = 0
  • Standard form: ax² + bx + c = 0
First solution
x = 3
Second solution
x = 2

Two distinct real solutions

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

Discriminant (Δ)
1
Opens
Upward
Vertex
(2.5, −0.25)
Axis of symmetry
x = 2.5
Y-intercept
(0, 6)

The parabola opens upward, so the vertex is a minimum.

How the solution is worked out
StepValue
Equationx² − 5x + 6 = 0
a1
b−5
c6
Discriminant formulab² − 4ac
Discriminant(−5)² − 4 × 1 × 6 = 1
Quadratic formulax = (−b ± √(b² − 4ac)) ÷ 2a
First solution(5 + √1) ÷ 2 = 3
Second solution(5 − √1) ÷ 2 = 2

How to use this calculator

  1. Enter the three coefficients from ax² + bx + c = 0. Use a for the number in front of x², b for the number in front of x, and cfor the constant. Negative and decimal values are fine; a cannot be zero.
  2. Check the tidied equation shown below the inputs matches what you meant.
  3. Read the result: the solutions are the large figures, with the discriminant and the parabola's vertex, axis of symmetry and y-intercept beside them, and the full working in the calculation table.

The calculation runs in the page as you type — nothing is sent to a server. This is a mathematical tool, not a substitute for showing your own method in an exam.

What is standard quadratic form?

A quadratic equation is any equation that can be written with a single squared term and no higher power:

ax² + bx + c = 0
  • a — the coefficient of x², which must not be zero
  • b — the coefficient of x, which may be zero
  • c — the constant term, which may be zero

If a were zero the x² term would vanish and the equation would be linear, so a non-zeroa is what makes an equation quadratic.

How is a quadratic equation solved?

Every quadratic in standard form is solved by the quadratic formula:

x = (−b ± √(b² − 4ac)) ÷ 2a
  • The ± sign gives the two solutions — one using +, one using −
  • b² − 4ac is the discriminant, Δ
  • When Δ = 0 the formula simplifies to x = −b ÷ 2a

The discriminant decides how many real solutions there are before you finish solving:

Δ = b² − 4ac
  • Δ > 0 — two distinct real solutions
  • Δ = 0 — one repeated real solution
  • Δ < 0 — two complex solutions (a conjugate pair)

What the discriminant tells you

How the sign of the discriminant determines the solutions
DiscriminantSolutionsExample
Δ > 0 (positive)Two distinct real solutionsx² − 5x + 6 = 0 → x = 3, x = 2
Δ = 0 (zero)One repeated real solutionx² − 4x + 4 = 0 → x = 2
Δ < 0 (negative)Two complex solutionsx² + 2x + 5 = 0 → x = −1 ± 2i

Worked example: two real solutions

Solve x² − 5x + 6 = 0, where a = 1, b = −5 and c = 6.

Solving x squared minus 5x plus 6 equals 0
StepValue
Equationx² − 5x + 6 = 0
a1
b−5
c6
Discriminant formulab² − 4ac
Discriminant(−5)² − 4 × 1 × 6 = 1
Quadratic formulax = (−b ± √(b² − 4ac)) ÷ 2a
First solution(5 + √1) ÷ 2 = 3
Second solution(5 − √1) ÷ 2 = 2

The discriminant is positive, so there are two real solutions: x = 3 and x = 2. The parabola opens upward, its axis of symmetry is x = 2.5, its vertex is (2.5, −0.25) and its y-intercept is (0, 6).

Worked example: two complex solutions

Solve x² + 2x + 5 = 0, where a = 1, b = 2 and c = 5.

Solving x squared plus 2x plus 5 equals 0
StepValue
Equationx² + 2x + 5 = 0
a1
b2
c5
Discriminant2² − 4 × 1 × 5 = −16
Result typeNegative discriminant: complex solutions
Quadratic formulax = (−b ± √(b² − 4ac)) ÷ 2a
Real part−2 ÷ 2 = −1
Imaginary part√16 ÷ 2 = 2
Solutions−1 ± 2i

The discriminant is −16, which is negative, so there are no real solutions. The solutions are the complex conjugate pair −1 + 2i and −1 − 2i. The parabola still has a vertex at (−1, 4), an axis of symmetry of x = −1 and a y-intercept of (0, 5) — it simply never crosses the x-axis.

How to find the vertex and axis of symmetry

The graph of y = ax² + bx + c is a parabola, symmetric about a vertical line through its turning point. That line is the axis of symmetry and the turning point is the vertex.

Axis of symmetry: x = −b ÷ 2a
  • Vertex x-coordinate: h = −b ÷ 2a
  • Vertex y-coordinate: k = ah² + bh + c
  • Y-intercept: (0, c)
  • a > 0 opens upward (vertex is a minimum); a < 0 opens downward (vertex is a maximum)

Results are shown to at most six decimal places with trailing zeroes removed, so an exact solution reads 3 and an irrational one reads 1.414214. Values within rounding distance of zero are shown as 0, never −0.

Frequently asked questions

How do I solve a quadratic equation?

Write the equation in the form ax² + bx + c = 0, then apply the quadratic formula x = (−b ± √(b² − 4ac)) ÷ 2a. Work out the discriminant b² − 4ac first: if it is positive there are two real solutions, if it is zero there is one repeated solution, and if it is negative there are two complex solutions. For x² − 5x + 6 = 0, the discriminant is 1, so x = (5 ± 1) ÷ 2, giving x = 3 and x = 2.

What is the discriminant?

The discriminant is the part of the quadratic formula under the square root, Δ = b² − 4ac. Its sign tells you how many real solutions the equation has without solving it in full: positive means two real solutions, zero means one repeated real solution, and negative means no real solutions — the two solutions are complex conjugates.

Why can a not be zero?

If a is zero the x² term disappears and the equation becomes bx + c = 0, which is linear, not quadratic. The quadratic formula also divides by 2a, so a = 0 would divide by zero. This calculator rejects a = 0 and asks for a non-zero value.

What are complex solutions?

When the discriminant is negative, the square root of a negative number has no real value, so the solutions are written using the imaginary unit i, where i² = −1. They come as a conjugate pair, a + bi and a − bi. For x² + 2x + 5 = 0 the solutions are −1 + 2i and −1 − 2i. The parabola still has a vertex, an axis of symmetry and a y-intercept — it just never crosses the x-axis.

How do I find the vertex of a parabola?

The vertex is the turning point of the parabola y = ax² + bx + c. Its x-coordinate is h = −b ÷ 2a, the same as the axis of symmetry. Substitute h back into the equation to get the y-coordinate: k = ah² + bh + c. For x² − 5x + 6 the vertex is at (2.5, −0.25).

Which way does the parabola open?

The sign of a decides it. When a is positive the parabola opens upward and the vertex is the lowest point (a minimum). When a is negative it opens downward and the vertex is the highest point (a maximum).

What is the y-intercept of a quadratic?

The y-intercept is where the curve crosses the y-axis, at x = 0. Setting x = 0 in y = ax² + bx + c leaves y = c, so the y-intercept is always the point (0, c).

How are the solutions ordered?

When there are two real solutions this calculator lists them in descending order, so the larger value is shown first. A repeated solution is shown once. Complex solutions are shown as the conjugate pair, with the + bi form first.