Quadratic Equations calculator

Quadratic Equation Calculator for Finding Roots

A quadratic equation calculator finds values that satisfy a supported equation with a squared term. Follow a selected method, such as factoring or the quadratic formula.

  • Independent answer checks
  • Every step shown
  • Free, no sign-up

What math problem do you want to solve?

Ctrl+V pastes a screenshot · Shift+Enter: new line (one equation per line)

Try

Typed problems our engine solves stay in your browser. Photos, screenshots, PDFs and AI-helped problems are processed by our AI service — privacy.

For real coefficients, the discriminant determines whether real roots are distinct, repeated, or absent. Substitute each candidate into the original equation to check it.

Quadratic Equations · worked example✓ Verified
3x2+5x−2=03x^{2} + 5x - 2 = 0
Identify a, b and c
a=3,b=5,c=−2\displaystyle a = 3,\allowbreak b = 5,\allowbreak c = -2
Factor the quadratic
(3x−1)(x+2)=0(3x - 1)(x + 2) = 0
Set each factor to zero
x=13,x=−2\displaystyle x = \frac{1}{3},\allowbreak x = -2
x=13,x=−2\displaystyle x = \frac{1}{3},\allowbreak x = -2Re-checked by a second engine
Quadratic Equations · worked example✓ Verified
4x2−12x+9=04x^{2} - 12x + 9 = 0
Identify a, b and c
a=4,b=−12,c=9\displaystyle a = 4,\allowbreak b = -12,\allowbreak c = 9
The discriminant is zero
D=−122−4(4)(9)=0D = -12^{2} - 4(4)(9) = 0
Compute the repeated root
x=128=32x = \frac{12}{8} = \frac{3}{2}
x=32x = \frac{3}{2}Re-checked by a second engine
Quadratic Equations · worked example✓ Verified
x2+2x+5=0x^{2} + 2x + 5 = 0
Identify a, b and c
a=1,b=2,c=5\displaystyle a = 1,\allowbreak b = 2,\allowbreak c = 5
The discriminant is negative
D=−16<0D = -16 < 0
Apply the quadratic formula with i
x=−2±−162=−2±4i2x = \frac{-2 \pm \sqrt{-16}}{2} = \frac{-2 \pm 4i}{2}
x=−1+2ix = -1 + 2i
x=−1−2ix = -1 - 2i
Re-checked by a second engine

1 / 3

Quick examples

Study guide

How to solve quadratic equations

A quadratic equation has an x² term: ax² + bx + c = 0. Unlike linear equations, it can have two solutions — the two points where the parabola crosses the x-axis.

Always try factoring first. For x² − 5x + 6 = 0, ask: which two numbers multiply to 6 and add to −5? That is −2 and −3, so (x − 2)(x − 3) = 0, giving x = 2 or x = 3.

If it does not factor neatly, complete the square: move the constant over, halve the x-coefficient, square it, and add to both sides. This turns the left side into a perfect square you can square-root.

The quadratic formula always works: x = (−b ± √(b² − 4ac)) / 2a. The part under the root, b² − 4ac, is the discriminant — if it is negative, there are no real solutions.

US teachers often require a specific method, so the solver lets you choose: factoring, completing the square, or the formula. Use the Method selector above the solver.

Parabola y = x² − 7x + 10 crossing the x-axis at x = 2 and x = 5, with its lowest point, the vertex, at (3.5, −2.25) on the dashed axis of symmetry x = 3.5.
The roots of x² − 7x + 10 = 0 are where the parabola meets the x-axis: x = 2 and x = 5. The vertex sits halfway between them, at x = 3.5.

Checking the result

How this result is checked

The math engine checks displayed roots against the original quadratic, including supported complex roots, rather than trusting the factoring or formula steps alone.

Before you start

Standard form for the quadratic equation calculator

Every method assumes the equation reads ax2+bx+c=0ax^2 + bx + c = 0 — everything on one side, zero on the other. If yours does not, move the terms across first: x2=7x−10x^2 = 7x - 10 becomes x2−7x+10=0x^2 - 7x + 10 = 0.

Then read off a, b and c with their signs. In 3x2+5x−2=03x^2 + 5x - 2 = 0, a=3a = 3, b=5b = 5 and c=−2c = -2. Most errors with the quadratic formula start with a lost minus sign at this point, which is why the calculator always shows this as its first step.

If every term shares a factor, divide it out: 2x2+8x+6=02x^2 + 8x + 6 = 0 is the same equation as x2+4x+3=0x^2 + 4x + 3 = 0, and the smaller numbers are easier to factor — the factoring calculator shows each pattern.

Many quadratics arrive inside a word problem about an area or a product of two numbers. Start those in the AI math solver, which writes the story as an equation for you to confirm before it solves.

Reading the discriminant

How many roots, before you solve

The discriminant b2−4acb^2 - 4ac is the part of the quadratic formula under the square root. Working it out first tells you what kind of answer to expect:

  • Positive and a perfect square (1, 4, 9, 49…): two rational roots — the quadratic factors over the integers.
  • Positive, not a perfect square: two irrational roots, written with a square root such as 1±31 \pm \sqrt{3}.
  • Zero: one repeated root. The parabola touches the x-axis at its vertex.
  • Negative: no real roots. Over the complex numbers there are two, written with ii.

Save time on tests

A quick discriminant check tells you whether factoring is worth trying. If b2−4acb^2 - 4ac is not a perfect square, go straight to the formula.

Reference

Quadratic formulas to know

Quadratic formula

x=−b±b2−4ac2ax = \frac{-b \pm \sqrt{b^2 - 4ac}}{2a}

Always works. The whole numerator is divided by 2a.

Discriminant

Δ=b2−4ac\Delta = b^2 - 4ac

Its sign decides how many real roots there are.

Vertex

xv=−b2ax_v = -\frac{b}{2a}

Halfway between the two roots, when they exist.

Sum and product of roots

x1+x2=−ba,x1x2=cax_1 + x_2 = -\frac{b}{a},\quad x_1 x_2 = \frac{c}{a}

A fast way to check a pair of roots.

Completed square

x2+bx=(x+b2)2−b24x^2 + bx = \left(x + \frac{b}{2}\right)^2 - \frac{b^2}{4}

The idea behind completing the square.

Difference of squares

x2−k2=(x−k)(x+k)x^2 - k^2 = (x - k)(x + k)

For quadratics with no x-term.

Worked examples

Quadratic Equations, worked step by step

Each solution below is the solver’s own working, checked before it was published. Press “Solve it live” to open it in the calculator above.

Example 1 · Two whole-number roots

x2−7x+10=0x^{2} - 7x + 10 = 0

Two numbers that multiply to 10 and add to −7: −2 and −5.

x=5,x=2\displaystyle x = 5,\allowbreak x = 2
✓ Verified

Independent check

x=5:52−7⋅5+10=0x = 5:\quad 5^{2}-7\cdot 5+10 = 0
x=2:22−7⋅2+10=0x = 2:\quad 2^{2}-7\cdot 2+10 = 0

Check with the sum and product: 5 + 2 = 7 = −b/a, and 5 × 2 = 10 = c/a.

  1. Identify a, b and c
    a=1,b=−7,c=10\displaystyle a = 1,\allowbreak b = -7,\allowbreak c = 10
    The coefficients decide which method works best.
  2. Factor the quadratic
    (x−5)(x−2)=0(x - 5)(x - 2) = 0
    The discriminant is a perfect square, so the quadratic splits into two linear factors.
  3. Set each factor to zero
    x=5,x=2\displaystyle x = 5,\allowbreak x = 2
    A product is zero exactly when one of its factors is zero.

Example 2 · Leading coefficient other than 1

3x2+5x−2=03x^{2} + 5x - 2 = 0

With a = 3 the roots are fractions; the solver still finds a factorization.

x=13,x=−2\displaystyle x = \frac{1}{3},\allowbreak x = -2
✓ Verified

Independent check

x=13:3⋅132+5⋅13−2=0x = \frac{1}{3}:\quad 3\cdot \frac{1}{3}^{2}+5\cdot \frac{1}{3}-2 = 0
x=−2:3⋅(−2)2+5⋅(−2)−2=0x = -2:\quad 3\cdot \left(-2\right)^{2}+5\cdot \left(-2\right)-2 = 0
  1. Identify a, b and c
    a=3,b=5,c=−2\displaystyle a = 3,\allowbreak b = 5,\allowbreak c = -2
    The coefficients decide which method works best.
  2. Factor the quadratic
    (3x−1)(x+2)=0(3x - 1)(x + 2) = 0
    The discriminant is a perfect square, so the quadratic splits into two linear factors.
  3. Set each factor to zero
    x=13,x=−2\displaystyle x = \frac{1}{3},\allowbreak x = -2
    A product is zero exactly when one of its factors is zero.

Example 3 · A repeated root

4x2−12x+9=04x^{2} - 12x + 9 = 0

The discriminant is 144−144=0144 - 144 = 0, so expect exactly one root.

x=32x = \frac{3}{2}
✓ Verified

Independent check

x=32:4⋅322−12⋅32+9=0x = \frac{3}{2}:\quad 4\cdot \frac{3}{2}^{2}-12\cdot \frac{3}{2}+9 = 0
  1. Identify a, b and c
    a=4,b=−12,c=9\displaystyle a = 4,\allowbreak b = -12,\allowbreak c = 9
    The coefficients decide which method works best.
  2. The discriminant is zero
    D=−122−4(4)(9)=0D = -12^{2} - 4(4)(9) = 0
    A zero discriminant means one repeated root: x = -b / 2a.
  3. Compute the repeated root
    x=128=32x = \frac{12}{8} = \frac{3}{2}
    Both solutions coincide at this single value.

Example 4 · No real roots

x2+2x+5=0x^{2} + 2x + 5 = 0

The discriminant is 4−20=−164 - 20 = -16. There are no real solutions; the complex ones involve ii.

x=−1+2ix = -1 + 2i
x=−1−2ix = -1 - 2i
✓ Verified

Independent check

x=−1+2i:(−1+2i)2+2(−1+2i)+5=(−3−4i)+(−2+4i)+5=0x = -1 + 2i:\quad \left(-1 + 2i\right)^2 + 2\left(-1 + 2i\right) + 5 = \left(-3 - 4i\right) + \left(-2 + 4i\right) + 5 = 0
x=−1−2i:(−1−2i)2+2(−1−2i)+5=(−3+4i)+(−2−4i)+5=0x = -1 - 2i:\quad \left(-1 - 2i\right)^2 + 2\left(-1 - 2i\right) + 5 = \left(-3 + 4i\right) + \left(-2 - 4i\right) + 5 = 0

If your course only uses real numbers, the expected answer here is "no real solution".

  1. Identify a, b and c
    a=1,b=2,c=5\displaystyle a = 1,\allowbreak b = 2,\allowbreak c = 5
    The coefficients decide which method works best.
  2. The discriminant is negative
    D=−16<0D = -16 < 0
    A negative discriminant means there are no real solutions — the roots are complex.
  3. Apply the quadratic formula with i
    x=−2±−162=−2±4i2x = \frac{-2 \pm \sqrt{-16}}{2} = \frac{-2 \pm 4i}{2}
    √(negative) becomes an imaginary number: √(-k) = i√k.
  4. Simplify
    x=−1+2i,x=−1−2i\displaystyle x = -1 + 2i,\allowbreak x = -1 - 2i
    Evaluate the ± cases to get the conjugate pair.

Example 5 · Finding a parameter k

find k so that x2+kx+9=0 has equal roots\text{find } k \text{ }\allowbreak \text{so }\allowbreak \text{that } x^{2} + kx + 9 = 0 \text{ }\allowbreak \text{has }\allowbreak \text{equal }\allowbreak \text{roots}

Equal roots happen exactly when the discriminant is zero, so set k2−4(1)(9)=0k^2 - 4(1)(9) = 0 and solve for k.

k=6,k=−6\displaystyle k = 6,\allowbreak k = -6
✓ Verified

Independent check

k=6:b2−4ac=0, repeated root x=−3k = 6:\quad b^2 - 4ac = 0,\ \text{repeated root } x = -3
k=−6:b2−4ac=0, repeated root x=3k = -6:\quad b^2 - 4ac = 0,\ \text{repeated root } x = 3

Both values work: k = 6 gives (x+3)2(x + 3)^2 and k = −6 gives (x−3)2(x - 3)^2.

  1. Read a, b and c
    a=1, b=k, c=9\displaystyle a = 1,\allowbreak \ b = k,\allowbreak \ c = 9
    Write the equation as ax² + bx + c = 0; the coefficients depend on k.
  2. Write the discriminant
    b2−4ac=(k)2−4(1)(9)=−36+k2b^{2} - 4ac = (k)^{2} - 4(1)(9) = -36+k^{2}
    The discriminant decides how many real roots there are.
  3. Equal roots: set the discriminant to 0
    −36+k2=0-36+k^{2} = 0
    Equal roots happen exactly when b² − 4ac = 0.
  4. Write in standard form
    k2−36=0k^{2} - 36 = 0
    Quadratics are easiest to solve as ak^2 + bk + c = 0.
  5. Identify a, b and c
    a=1,b=0,c=−36\displaystyle a = 1,\allowbreak b = 0,\allowbreak c = -36
    The coefficients decide which method works best.
  6. Factor the quadratic
    (k−6)(k+6)=0(k - 6)(k + 6) = 0
    The discriminant is a perfect square, so the quadratic splits into two linear factors.
  7. Set each factor to zero
    k=6,k=−6\displaystyle k = 6,\allowbreak k = -6
    A product is zero exactly when one of its factors is zero.

Avoid these

Common quadratic equations mistakes

  • Not setting it equal to zero

    Factoring x2−7x=−10x^2 - 7x = -10 as it stands gives nonsense. Move everything to one side first.

  • Dividing only part of the formula by 2a

    In −b±Δ2a\frac{-b \pm \sqrt{\Delta}}{2a}, the fraction bar covers −b as well. Writing −b±Δ2a-b \pm \frac{\sqrt{\Delta}}{2a} is a different number.

  • Losing the sign of b

    If b = −7, then −b = +7 and b2=49b^2 = 49. Put brackets around negatives when you substitute.

  • Taking only the positive root

    x2=9x^2 = 9 means x=3x = 3 or x=−3x = -3. The ± is not optional.

  • Dividing by x

    From x2=5xx^2 = 5x, dividing by x loses the root x = 0. Factor instead: x(x−5)=0x(x - 5) = 0.

  • Stopping at the discriminant

    A negative discriminant does not mean "error" — it means no real roots. Say so explicitly in your answer.

FAQ

Quadratic Equations calculator FAQ

How do you solve a quadratic equation by factoring?

Write it as ax²+bx+c=0, then find two numbers that multiply to a·c and add to b. For x²−5x+6=0 those are −2 and −3, so (x−2)(x−3)=0 and x=2 or x=3.

When should I use the quadratic formula?

When the quadratic does not factor with integers. The formula x=(−b±√(b²−4ac))/2a always works for ax²+bx+c=0 — just plug in a, b and c carefully.

What does the discriminant tell you?

The discriminant b²−4ac predicts the solutions: positive means two real solutions, zero means exactly one (a repeated root), negative means no real solutions.

Can a quadratic have only one solution?

Yes — when the discriminant is zero, like x²−6x+9=0 which factors as (x−3)²=0. The parabola just touches the x-axis at x=3.

Can I choose completing the square instead of the formula?

Yes. After solving, use the Method menu next to the input to switch between factoring, completing the square and the quadratic formula. The roots stay the same; the working changes. For when each method is quickest, see how to solve quadratic equations.

Does it give complex roots?

Yes. When the discriminant is negative, the roots are given in the form a±bia \pm bi. If your class only works with real numbers, the answer to write is "no real solution".

Why are my roots written with a square root?

Because they are irrational, and the exact form is what most teachers expect. 1+31 + \sqrt{3} is exact; 2.732 is a rounded approximation.

Your own quadratic equations problem

Paste your quadratic into the quadratic equation calculator, pick the method your teacher uses from the Method menu, and compare every line with your own.