document.documentElement.classList.add("cf-on");'; return; } ?>

How to Use the Quadratic Formula

Solve any quadratic equation in four steps, read the discriminant to know what kind of answer to expect, and check your roots, with garden, ball and textbook examples.

How to Use the Quadratic Formula

Kofi is laying a new vegetable plot. He wants it to cover exactly 40 square metres, with the length 3 metres longer than the width, and he cannot find two numbers that work by guessing. The quadratic formula settles it in four steps: write the problem as x² + 3x – 40 = 0, drop the three numbers into one formula, and the width comes out as 5 metres.

This guide shows how to use the formula step by step, what the discriminant tells you before you finish, how to handle negative and decimal coefficients, and how to check an answer in seconds.

Quick answer: The quadratic formula solves ax² + bx + c = 0 with x = (-b ± √(b² – 4ac)) / 2a. Rearrange to equal zero, read off a, b and c, find b² – 4ac, then work out the plus and minus versions. For x² + 3x – 40 = 0 the answers are 5 and -8.

Quadratic Formula CalculatorEnter a, b and c to get both roots, the discriminant and the vertex, with every step shown.
Open the calculator

How do you use the quadratic formula step by step?

To use the quadratic formula, rearrange the equation into the form ax² + bx + c = 0, identify a, b and c with their signs, calculate the discriminant b² – 4ac, and then substitute into x = (-b ± √(b² – 4ac)) / 2a once with plus and once with minus. Here is Kofi’s garden, worked through.

  1. Set up the equation. If the width is x, the length is x + 3, and the area is x(x + 3) = 40. Expanding and moving 40 across gives x² + 3x – 40 = 0.
  2. Read off the coefficients. a = 1, b = 3 and c = -40. The minus sign on c belongs to it.
  3. Work out the discriminant. b² – 4ac = 3² – 4 x 1 x (-40) = 9 + 160 = 169, and the square root of 169 is 13.
  4. Finish both roots. x = (-3 + 13) / 2 = 5, and x = (-3 – 13) / 2 = -8.

A plot cannot have a width of minus 8 metres, so Kofi takes x = 5. His garden is 5 m wide and 8 m long, and 5 x 8 = 40 confirms it. Discarding a root that makes no sense in the real situation is a normal final step in word problems.

Four steps showing how to use the quadratic formula to find the width of a garden plot
The positive root gives a 5 m by 8 m plot; the negative root is rejected because a width cannot be negative.

What does the discriminant tell you?

The discriminant, b² – 4ac, tells you how many real solutions a quadratic has before you finish the calculation: a positive value gives two real roots, zero gives one repeated root, and a negative value gives no real roots. If it is also a perfect square, the roots are whole numbers or fractions and the equation could have been factorised.

Discriminant b² – 4acNumber of real rootsExampleRoots
Positive perfect squareTwo rational rootsx² + 3x – 40 = 0, discriminant 1695 and -8
Positive, not a perfect squareTwo irrational roots-4.9t² + 14t + 1.5 = 0, discriminant 225.4About -0.10 and 2.96
ZeroOne repeated rootx² – 6x + 9 = 0, discriminant 03
NegativeNo real roots (two complex roots)x² + 2x + 5 = 0, discriminant -16-1 + 2i and -1 – 2i

The negative case is where many people think they have gone wrong. They have not: the parabola for x² + 2x + 5 simply never touches the x axis. In courses that use complex numbers, √(-16) is written as 4i, giving x = (-2 ± 4i) / 2 = -1 ± 2i. The Wikipedia article on the discriminant extends the same idea to cubic and higher equations.

Table showing how the discriminant in the quadratic formula decides the number and type of roots
Work out b² minus 4ac first and you know what kind of answer to expect.

How do you solve a real problem with the quadratic formula?

The quadratic formula solves any real problem that reduces to a squared term, a plain term and a constant, such as areas, profits and the flight of a thrown object. Physics problems are the classic case, because the height of an object under gravity follows a quadratic in time.

Kofi’s daughter throws a ball upwards at 14 metres per second from a hand height of 1.5 metres. Using 9.8 m/s² for gravity, its height after t seconds is h = -4.9t² + 14t + 1.5. To find when it lands, set h to zero, so a = -4.9, b = 14 and c = 1.5.

The discriminant is 14² – 4 x (-4.9) x 1.5 = 196 + 29.4 = 225.4, and its square root is about 15.013. Dividing by 2a = -9.8 gives t = (-14 + 15.013) / -9.8 = -0.10 and t = (-14 – 15.013) / -9.8 = 2.96. Time cannot be negative, so the ball lands after about 2.96 seconds.

The same numbers give the highest point. The vertex of any parabola sits at x = -b / 2a, here 14 / 9.8 = 1.43 seconds, and putting that time back into the equation gives a peak of 11.5 metres. For square roots of awkward decimals like 225.4, the square root calculator or the online scientific calculator saves a lot of hand working.

Worked projectile example using the quadratic formula to find when a ball lands
The ball lands after about 2.96 seconds and peaks at 11.5 metres.

Which mistakes trip people up with the quadratic formula?

The most common mistake is mishandling the sign of b, especially when b is negative, because the formula starts with -b and the discriminant squares b. Take 2x² – 7x + 3 = 0, where a = 2, b = -7 and c = 3.

Here -b is +7, and b² is (-7)² = 49, not -49. The discriminant is 49 – 24 = 25, its root is 5, and the solutions are (7 + 5) / 4 = 3 and (7 – 5) / 4 = 0.5. Other frequent slips:

  • Forgetting to rearrange to zero first. x² + 3x = 40 must become x² + 3x – 40 = 0 before c can be read off.
  • Dividing only the square root by 2a. The whole of -b ± √(b² – 4ac) sits over 2a.
  • Typing -7² into a calculator, which gives -49. Use brackets: (-7)².
  • Rounding the square root too early. Keep at least four decimal places until the final answer.
  • Using the formula when a = 0. Then the equation is linear, and the linear equation calculator is the right tool.

A fast check catches most errors: the two roots always add up to -b / a and multiply to c / a. For Kofi’s equation, 5 + (-8) = -3 and 5 x (-8) = -40, which match -b / a and c / a exactly.

When should you use the formula instead of factorising?

Use the quadratic formula whenever factorising is not obvious within a few seconds, because it always works, while factorising only works neatly when the roots are whole numbers or simple fractions. Completing the square is the third method, and it is actually how the formula is derived.

MethodWorks forSpeedBest when
FactorisingRational roots onlyFastestCoefficients are small and the discriminant is a perfect square
Completing the squareEvery quadraticMediumYou also need the vertex form of the parabola
Quadratic formulaEvery quadraticSteadyCoefficients are decimals, large or negative, or roots are irrational

The derivation is short. Divide ax² + bx + c = 0 by a, move c / a across, add (b / 2a)² to both sides to complete the square, take the square root of both sides and rearrange for x. The result is the formula itself, which is why it can never fail on a genuine quadratic. The Wikipedia page on the quadratic formula sets out each line of that derivation and its long history. To skip the arithmetic entirely, the quadratic formula calculator shows each of these steps for your own a, b and c, and the maths calculators hub lists more equation solvers.

Key points

  • The quadratic formula is x = (-b ± √(b² – 4ac)) / 2a for any equation ax² + bx + c = 0.
  • Rearrange to equal zero and keep the signs of a, b and c.
  • The discriminant b² – 4ac decides whether there are two, one or no real roots.
  • Kofi’s x² + 3x – 40 = 0 gives 5 and -8, and only 5 makes sense as a width.
  • Check answers: the roots add to -b / a and multiply to c / a.
Square Root CalculatorFind exact and decimal square roots, handy for the discriminant step.
Open the calculator

Key Quadratic Formula Terms Explained

These are the parts of the quadratic formula and the ideas around it that you need to read, solve and check any quadratic equation.

Quadratic equation
A quadratic equation is any equation that can be written as ax² + bx + c = 0 with a not equal to zero. Kofi’s garden problem, x² + 3x – 40 = 0, is a quadratic with a = 1, b = 3 and c = -40.
Coefficients a, b and c
The coefficients are the numbers in front of x², in front of x, and on their own once everything is moved to one side. Their signs matter, so in 2x² – 7x + 3 = 0 the value of b is minus 7.
Discriminant
The discriminant is b² – 4ac, the part under the square root. If it is positive there are two real roots, if it is zero there is one repeated root, and if it is negative there are no real roots.
Root
A root is a value of x that makes the quadratic equal zero, also called a solution or zero. On a graph, the real roots are the points where the parabola crosses the x axis.
Parabola
A parabola is the U shaped curve drawn by a quadratic. When a is negative it opens downwards, like the path of the thrown ball, and its highest or lowest point sits at x = -b / 2a.

Frequently Asked Questions

My equation is 3x² = 12x. Where is c?

Rearrange it to 3x² – 12x = 0, so a = 3, b = -12 and c = 0. The discriminant is 144, its root is 12, and the formula gives x = (12 + 12) / 6 = 4 and x = 0. Factorising as 3x(x – 4) = 0 confirms both.

The discriminant came out negative. Have I made a mistake?

Not necessarily. A negative discriminant, such as -16 for x² + 2x + 5 = 0, means the parabola never crosses the x axis, so there are no real roots. Double check the signs of b and c, then report no real solutions or give the complex roots.

Why do I get one answer instead of two?

When the discriminant is exactly zero, the plus and minus versions give the same value, so the root is repeated. For x² – 6x + 9 = 0 the discriminant is 36 – 36 = 0 and the single answer is x = 3.

Does the quadratic formula work with decimals and fractions?

Yes, it works for any real values of a, b and c, as long as a is not zero. The ball example uses a = -4.9 and c = 1.5 and gives 2.96 seconds. With fractions, multiplying through by a common denominator first makes the arithmetic tidier.

How can I check my roots without redoing the whole calculation?

Add and multiply them. The roots always sum to -b / a and multiply to c / a. For 2x² – 7x + 3 = 0, the roots 3 and 0.5 add to 3.5, which is 7 / 2, and multiply to 1.5, which is 3 / 2.

What do I do if a is negative?

Use it exactly as it is, keeping the minus sign in 2a. In the ball problem a = -4.9, so 2a = -9.8, and dividing by a negative number flips the signs of the results. Alternatively, multiply the whole equation by -1 first; the roots stay the same.

Kofi’s plot is now marked out at 5 by 8 metres, and the method behind it works on every quadratic you will meet. Learn the quadratic formula once, read the discriminant first and check with the sum and product of the roots. Method checked October 2026.

Written and checked by the Tools Veria Editorial Team

We research every figure in this guide from official sources such as GOV.UK, HMRC, Ofgem and the ONS, and test the related tools against worked examples. This guide is general information, not personal financial or tax advice.

About usEditorial policyDisclaimerReport an error