Skip to content
CalcHub

Quadratic Formula Calculator

Solve any quadratic equation ax² + bx + c = 0 with real or complex roots, and get the discriminant, vertex, axis of symmetry, and factored form.

Quadratic Formula CalculatorLive

How to use this calculator

  1. 1Write your equation in the standard form ax² + bx + c = 0, moving every term to one side.
  2. 2Enter a, b, and c — including their signs. A missing x term means b = 0.
  3. 3Read the roots, and check the discriminant to understand why you got real or complex answers.

How it works

The quadratic formula

x = (−b ± √(b² − 4ac)) ÷ 2a
Discriminant: Δ = b² − 4ac
Vertex: x = −b ÷ 2a,  y = f(−b ÷ 2a)
Sum of roots = −b ÷ a,  Product of roots = c ÷ a

The formula comes from completing the square on ax² + bx + c = 0. The term −b ÷ 2a is the axis of symmetry — the midpoint between the two roots — and the square-root term is how far each root sits from that midpoint. When the discriminant is negative that distance is imaginary, which is why the roots become complex conjugates.

Worked example

For x² − 5x + 6 = 0: the discriminant is (−5)² − 4(1)(6) = 1, so √1 = 1 and the roots are (5 ± 1) ÷ 2, giving x = 3 and x = 2. The factored form is (x − 3)(x − 2), and the vertex sits at (2.5, −0.25).

Quadratic Formula Calculator: the complete guide

What the discriminant tells you before you solve

The discriminant b² − 4ac is worth computing first, because it answers the shape of the problem in one number. Positive means the parabola crosses the x-axis twice and there are two distinct real solutions. Zero means it touches the axis at exactly one point — a repeated root, and the vertex sits on the axis. Negative means the parabola never reaches the axis, so there are no real solutions and the roots are a complex conjugate pair.

A discriminant that is a perfect square carries extra information: it means the quadratic factors cleanly over the rationals, so factoring by inspection will work and you did not need the formula at all.

Three ways to solve, and when each is fastest

Factoring is fastest when it works — if you can spot two numbers that multiply to ac and add to b, you are done in seconds. It only works when the roots are rational.

Completing the square is slower but it is where the quadratic formula comes from, and it is the method that converts a quadratic into vertex form a(x − h)² + k, which is what you want for graphing or optimisation.

The quadratic formula always works. It handles irrational roots, complex roots, and ugly decimal coefficients identically, which is why it is the method to reach for when the numbers are not friendly.

Reading the vertex and the parabola

The vertex is the turning point. Its x-coordinate is always −b ÷ 2a, sitting exactly halfway between the two roots because a parabola is symmetric about that line. Substituting that x back into the equation gives the y-coordinate.

The sign of a decides which way the curve opens: positive opens upward so the vertex is the minimum, negative opens downward so the vertex is the maximum. This is the whole basis of quadratic optimisation problems — maximum profit, maximum projectile height, minimum material cost all reduce to finding a vertex.

Vieta's formulas as a check

For any quadratic, the two roots must sum to −b ÷ a and multiply to c ÷ a. These are Vieta's formulas, and they give a free five-second check on any answer.

For x² − 5x + 6 = 0, the roots 3 and 2 sum to 5 (which is −(−5) ÷ 1) and multiply to 6 (which is 6 ÷ 1). If your roots fail either check, you have made an arithmetic slip. The check also works for complex roots, where the imaginary parts cancel in the sum and combine in the product.

Frequently asked questions

What does it mean when the discriminant is negative?

The parabola never crosses the x-axis, so there is no real number that satisfies the equation. The solutions still exist as a pair of complex conjugates of the form p ± qi, which this calculator shows. In an applied problem — a projectile that never reaches a given height, for example — complex roots usually mean the scenario is impossible as stated.

Can I use this if my equation isn't in standard form?

Rearrange it first so that everything is on one side and the other side is zero. For 2x² + 3x = 5, subtract 5 from both sides to get 2x² + 3x − 5 = 0, then enter a = 2, b = 3, c = −5.

Why can't a be zero?

With a = 0 the x² term disappears and the equation becomes the linear equation bx + c = 0, which has the single solution x = −c ÷ b. The quadratic formula would also divide by 2a = 0, which is undefined.

How do I find the vertex from the roots?

Average them. The vertex sits exactly halfway between the two roots because the parabola is symmetric, so the axis of symmetry is (x₁ + x₂) ÷ 2 — which is the same as −b ÷ 2a. This works even when the roots are complex, using their real parts.