Quadratic Formula Calculator

  • Free
  • No sign-up
  • Works on phones
  • Shows the working
Algebra & Trig#28

Quadratic Formula Solver

Solves \(ax^2 + bx + c = 0\): discriminant, roots (real or complex), vertex and factored form.

This quadratic formula calculator solves any equation of the form \( ax^2 + bx + c = 0 \). Enter the three coefficients and it returns the discriminant, both roots in exact form and as decimals, the factored form, the vertex, the axis of symmetry and the y-intercept. When the discriminant is negative it gives the complex roots \( p \pm qi \) instead of an error.

It is built for algebra, pre-calculus and calculus students checking homework, and for anyone who needs the zeros of a parabola quickly. It’s free and needs no sign-up.

Quadratic Formula Calculator: The parabola y = x² − 2x − 3 crosses the x-axis at the two solutions x = −1 and x = 3 given…
The parabola y = x² − 2x − 3 crosses the x-axis at the two solutions x = −1 and x = 3 given by the quadratic formula; its vertex is (1, −4).

How to use the quadratic formula calculator

  1. Rearrange your equation so one side is zero: \( ax^2 + bx + c = 0 \).
  2. Enter a, b and c. Include the signs: for \( 2x^2 - 7x + 3 = 0 \), enter \( a = 2 \), \( b = -7 \), \( c = 3 \). Fractions such as 1/2 and decimals are accepted.
  3. Press Solve. The first row is the discriminant \( \Delta = b^2 - 4ac \), which tells you how many real roots there are.
  4. Read the roots, the factored form (when the roots are rational) and the vertex. The vertex is the minimum point when \( a > 0 \) and the maximum point when \( a < 0 \).

Formula

The calculator uses the quadratic formula, which comes from completing the square on \( ax^2 + bx + c = 0 \):

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

The expression under the root is the discriminant:

DiscriminantRootsGraph
\( \Delta > 0 \)Two different real rootsCrosses the x-axis twice
\( \Delta = 0 \)One repeated real rootTouches the x-axis at the vertex
\( \Delta < 0 \)Two complex rootsNever touches the x-axis

The vertex sits halfway between the roots, at

$$x_v = -\frac{b}{2a}, \qquad y_v = c - \frac{b^2}{4a}$$

Worked example: two rational roots

Solve \( 2x^2 - 7x + 3 = 0 \). These are the values loaded in the calculator above.

Teacher in front of a blackboard with math formulas, including quadratic formula.

Discriminant. \( \Delta = (-7)^2 - 4(2)(3) = 49 - 24 = 25 \). It’s a perfect square, so the roots are rational.

Roots. \( x = \frac{7 \pm 5}{4} \), so \( x_1 = \frac12 \) and \( x_2 = 3 \).

Factored form. \( 2\left(x - \tfrac12\right)(x - 3) = (2x - 1)(x - 3) \).

Vertex. \( x_v = \frac{7}{4} \) and \( y_v = 3 - \frac{49}{8} = -\frac{25}{8} \). The parabola opens upward, so \( -\frac{25}{8} \) is its minimum value.

Worked example: complex roots

Solve \( x^2 + 2x + 5 = 0 \). Next, the discriminant is \( 4 - 20 = -16 \), so there are no real roots. The formula still works with \( \sqrt{-16} = 4i \):

A compass and a pencil on a piece of paper with lines.

$$x = \frac{-2 \pm 4i}{2} = -1 \pm 2i$$

The vertex is \( (-1, 4) \). It lies above the x-axis and the parabola opens upward, which is why the graph never crosses it.

Worked example: irrational roots

For \( 2x^2 + 4x - 1 = 0 \), \( \Delta = 16 + 8 = 24 \). The calculator shows the exact form \( x = \frac{-4 \pm 2\sqrt6}{4} \), which simplifies to \( \frac{-2 \pm \sqrt6}{2} \), and the decimals \( x \approx 0.2247 \) and \( x \approx -2.2247 \).

Tips and common mistakes

  • Dropping a sign. In \( 3x^2 - 5x - 2 = 0 \), \( b = -5 \), so \( -b = 5 \) and \( b^2 = 25 \), not \( -25 \).
  • Dividing only part of the top by 2a. The whole numerator \( -b \pm \sqrt{\Delta} \) is divided by \( 2a \).
  • Forgetting to set the equation to zero. \( x^2 + 3x = 10 \) must become \( x^2 + 3x - 10 = 0 \) before you read off \( c = -10 \).
  • Using the formula when a = 0. Then the equation is linear, \( bx + c = 0 \), with the single root \( x = -c/b \).
  • Check by substitution. Plugging \( x = 3 \) into \( 2x^2 - 7x + 3 \) gives \( 18 - 21 + 3 = 0 \).

Where quadratics show up in calculus

Setting a derivative to zero often yields a quadratic. For \( f(x) = 2x^3 - 3x^2 - 12x \), \( f'(x) = 6x^2 - 6x - 12 = 0 \) gives \( x = -1 \) and \( x = 2 \). These are the critical points (see how to find critical points). Projectile heights \( h(t) = -4.9t^2 + v_0t + h_0 \) are also quadratics. A projectile motion calculator solves them. You can also use a quadratic formula calculator for such equations.

A rocket launching at night, surrounded by bright smoke and light.

What the discriminant tells you

\( b^2 - 4ac \)RootsGraph
positive, perfect squaretwo rational rootscrosses the x-axis twice
positive, not a squaretwo irrational rootscrosses twice
zeroone repeated roottouches the axis at its vertex
negativetwo complex rootsnever meets the x-axis

Worked example: a ball in the air

A ball is thrown upward so that its height is \( h(t) = -4.9t^2 + 20t + 1.5 \) metres. It lands when \( h = 0 \):

$$t = \frac{-20 - \sqrt{400 + 4(4.9)(1.5)}}{2(-4.9)} \approx 4.16 \text{ s}$$

(the other root is negative and makes no physical sense). The highest point is at \( t = -\frac{b}{2a} \approx 2.04 \) s, about 21.9 m up.

Vertex form

Completing the square writes \( ax^2 + bx + c \) as \( a(x - h)^2 + k \), with vertex \( (h, k) \) and \( h = -\frac{b}{2a} \). See the completing the square calculator.

Practice problems

  1. Solve \( x^2 - 6x + 9 = 0 \).
  2. How many real roots does \( 2x^2 + 3x + 5 = 0 \) have?

Answers: 1. \( x = 3 \) (repeated). 2. None: \( 9 - 40 < 0 \).

Applying the Formula Step-by-Step

Solving a quadratic equation manually takes careful steps. First, ensure your equation is in standard form: ax^2 + bx + c = 0. Identify coefficients a, b, and c; pay close attention to signs. Then, calculate the discriminant, b^2 – 4ac. This value determines root nature. A quadratic formula calculator can simplify this process.

Next, substitute a, b, c, and the discriminant into the quadratic formula. The formula is x = (-b +- sqrt(b^2 – 4ac)) / (2a). Simplify the expression under the square root. If it is negative, you will have complex roots. Finally, perform the addition and subtraction parts separately for the 'plus-minus' sign. This yields your two solutions.

When Other Methods Work Best

The quadratic formula is a universal tool. However, sometimes other methods are quicker. For example, factoring is often faster if the quadratic equation is easily factorable. Consider x^2 + 5x + 6 = 0. This factors into (x + 2)(x + 3) = 0, giving roots x = -2 and x = -3 almost instantly.

Completing the square is useful for converting to vertex form or for specific types of equations. For example, x^2 + 4x – 5 = 0 can be written as (x + 2)^2 – 9 = 0. This shows the vertex and makes solving for x straightforward. Using the quadratic formula calculator is always an option, but recognizing simpler cases saves time.

Verifying Your Solutions

After finding the roots, always check your work. Substitute each solution back into the original equation. If the equation holds true, your solution is correct. For example, if x = 2 is a root of x^2 – 3x + 2 = 0, then 2^2 – 3(2) + 2 must equal 0. Here, 4 – 6 + 2 = 0, so it checks out. A quadratic formula calculator can help verify these steps.

You can also use the relationships between roots and coefficients. For a quadratic ax^2 + bx + c = 0, the sum of the roots is -b/a, and the product of the roots is c/a. These checks provide a quick way to confirm your results without full substitution. This is especially useful for checking results from a quadratic formula calculator.

Related guides

Further reading

FAQ

What is the quadratic formula?

\( x = \frac{-b \pm \sqrt{b^2 - 4ac}}{2a} \). It gives both solutions of \( ax^2 + bx + c = 0 \) for any \( a \neq 0 \).

How do I know how many solutions a quadratic has?

Look at the discriminant \( b^2 - 4ac \). Positive means two real solutions, zero means one repeated solution, and negative means two complex solutions.

Can the calculator give complex roots?

Yes. When \( b^2 - 4ac < 0 \), it shows the roots as \( p \pm qi \), for example \( -1 \pm 2i \) for \( x^2 + 2x + 5 = 0 \).

How do I find the vertex of a parabola?

Use \( x = -\frac{b}{2a} \), then substitute that x into the equation to get y. The calculator does both and also states whether the vertex is a minimum or a maximum.

Embed this calculator on your website

Teachers, tutors and bloggers are welcome to use this calculator for free. Copy the code below and paste it into any page (in WordPress, use a "Custom HTML" block). The small script makes the calculator grow to fit its answer; if your site removes scripts, it still works at a fixed height. Please keep the credit link.

More calculators

See all calculators