The Quadratic Formula, Explained

After reading this you will be able to solve any equation of the form ax^2 + bx + c = 0 by hand, read its discriminant to predict the number and type of roots, and find the vertex, axis of symmetry and factored form.

What a quadratic equation is

A quadratic equation is any equation you can write as ax^2 + bx + c = 0 with a \ne 0. The graph of the left side is a parabola. Solving the equation means finding where that parabola crosses the horizontal axis.

Take x² - 3x + 2 = 0. Here a = 1, b = -3 and c = 2. The solutions are x = 1 and x = 2, because 1 - 3 + 2 = 0 and 4 - 6 + 2 = 0. The parabola dips below the axis between those two points and touches zero at each of them. That is the whole problem: two numbers where the curve meets zero.

Some quadratics have one repeated root, and some have no real roots at all (their parabola never touches the axis). One number, the discriminant, tells you which case you are in before you do any more work.

When to use this and when not to

Use the quadratic method when the highest power of the variable is exactly 2 after you collect everything on one side. That includes disguised cases. The equation x² = 5x - 6 is quadratic once you move terms over: x² - 5x + 6 = 0.

Do not use it when the leading coefficient is zero. If a = 0, the equation is linear, for example 3x + 2 = 0 with the single solution x = -2/3. For linear systems or higher-degree polynomials, reach for the Equation solver instead.

Always rearrange to ax² + bx + c = 0 first. A common error is applying the formula to x² = 3x - 2 as if b = 3 and c = -2. The correct form is x² - 3x + 2 = 0, so b = -3 and c = 2. Sign mistakes here change every later number.

The formula and why it works

The roots come from the quadratic formula:

x = \frac{-b \pm \sqrt{b^2 - 4ac}}{2a}

Here a, b and c are the three coefficients, and the \pm means you compute two values: one with a plus, one with a minus. The quantity under the root has its own name, the discriminant:

D = b^2 - 4ac

The formula is completing the square written out once and for all. Start from ax^2 + bx + c = 0, divide by a, and force the left side into a perfect square. The -b/2a is the center of that square, and \sqrt{D}/2a is how far each root sits from the center. The two roots are always symmetric about -b/2a.

The sign of D decides the outcome:

D \gt 0
Two distinct real roots. The parabola crosses the axis twice.
D = 0
One repeated real root at -b/2a. The parabola touches the axis once.
D \lt 0
Two complex conjugate roots. The parabola never touches the axis.

A worked example with the demo data

Solving x² - 3x + 2 = 0

Use a = 1, b = -3, c = 2, the values behind the demo button.

  1. Discriminant: D = (-3)^2 - 4(1)(2) = 9 - 8 = 1. Since D = 1 > 0, expect two distinct real roots.
  2. Square root of the discriminant: \sqrt{1} = 1.
  3. Plug into the formula: x = \frac{-(-3) \pm 1}{2(1)} = \frac{3 \pm 1}{2}.
  4. Plus branch: x = \frac{4}{2} = 2. Minus branch: x = \frac{2}{2} = 1.
  5. Vertex: the axis of symmetry is x = -b/2a = 3/2 = 1.5. The vertex height is (1.5)^2 - 3(1.5) + 2 = 2.25 - 4.5 + 2 = -0.25, so the vertex is (1.5, -0.25).
  6. Factored form: (x - 1)(x - 2) = 0. Expand to check: x^2 - 3x + 2.

The roots are exactly 1 and 2, no decimals needed. The vertex sits below the axis at -0.25, which agrees with two real crossings.

The parabola crosses the axis at x = 1 and x = 2, with the vertex at the marked line x = 1.5, height -0.25.

Watching the discriminant change the picture

Hold a = 1 and b = -3 fixed, then slide c. As c rises, the parabola lifts, the two roots move toward each other, and at c = 2.25 the discriminant hits zero: 9 - 4(2.25) = 0. Above that, the roots go complex.

With a = 1 and b = -3 fixed: at c = 0 the roots are 0 and 3 (D = 9); at c = 2 they are 1 and 2 (D = 1); at c = 2.25 they merge to 1.5 (D = 0); at c = 4 they are complex, 1.5 ± 1.32i (D = -7).

Reading and interpreting the results

The solver reports several quantities. Each answers a different question.

What each output tells you, using x² - 3x + 2 = 0
OutputValue hereMeaning
Discriminant1Positive, so two distinct real roots.
Roots1, 2Where y equals zero.
Vertex(1.5, -0.25)Lowest point when a > 0.
Axis of symmetryx = 1.5Vertical line the parabola mirrors across.
Factored form(x-1)(x-2)The equation written as a product of linear factors.

Exact roots keep radicals intact. For x² - 4x + 1 = 0, D = 16 - 4 = 12, so x = \frac{4 \pm \sqrt{12}}{2} = 2 \pm \sqrt{3}, roughly 3.732 and 0.268. If you want to simplify a root like \sqrt{12} = 2\sqrt{3} by hand, the Radical simplifier does that step. When the discriminant is negative, roots appear as complex conjugates; the Complex number calculator handles arithmetic on them.

Common mistakes

Most wrong answers trace back to a few slips.

  • Dropping a sign on -b. With b = -3, the numerator starts -(-3) = +3, not -3.
  • Forgetting the 4ac factor. The discriminant is b^2 - 4ac, not b^2 - ac. For a = 1, b = -3, c = 2 the correct value is 1, not 7.
  • Dividing only part of the numerator by 2a. Both terms sit over 2a. Write it as one fraction.
  • Calling a negative discriminant an error. It is not. It means the roots are complex, for example 1.5 \pm 1.32i when D = -7.

Check your factored form by expanding it. If (x-1)(x-2) multiplies back to x^2 - 3x + 2, your roots are right. This catches almost every sign error in seconds.

Related tools

Once you can solve quadratics, nearby calculators extend the idea. Use the Polynomial toolkit to factor or divide cubics and higher. When a quadratic appears in the denominator of a fraction, the Partial fraction decomposition tool splits it apart. To solve x² - 3x + 2 > 0 rather than the equation, the Inequality solver returns interval notation. If your problem grew into a system of equations, the Matrix calculator handles the linear algebra.

Frequently asked questions

What does a negative discriminant mean?

It means no real roots. The parabola stays entirely above or below the axis. The two roots are complex conjugates of the form p \pm qi. For x² - 3x + 4 = 0, D = 9 - 16 = -7, giving 1.5 \pm \tfrac{\sqrt{7}}{2}i \approx 1.5 \pm 1.32i.

How do I find the vertex without the formula?

The axis of symmetry is always x = -b/2a. Plug that x back into ax^2 + bx + c to get the vertex height. For a = 1, b = -3, c = 2: x = 1.5, height -0.25.

Can every quadratic be factored?

Over the real numbers, only when the discriminant is a perfect square or the roots are otherwise nice. x² - 3x + 2 factors as (x-1)(x-2). x² - 4x + 1 has roots 2 \pm \sqrt{3}, so its factors carry a radical: (x - 2 - \sqrt{3})(x - 2 + \sqrt{3}).

What if a is 0?

Then it is not quadratic. The equation bx + c = 0 is linear with the single solution x = -c/b, provided b \ne 0.

Why are the two roots symmetric?

Because the formula writes each root as the center -b/2a plus or minus the same distance \sqrt{D}/2a. Their average is exactly -b/2a, the axis of symmetry. For roots 1 and 2, the average is 1.5.