OUNZOZ

Quadratic Equation Solver

Solve ax² + bx + c = 0 for x — enter your coefficients to get real or complex roots instantly.

Solve ax² + bx + c = 0

Enter a, b, and c to solve for x

About the Quadratic Equation Solver

A quadratic equation has the form ax² + bx + c = 0, where a can't be zero — it's one of the core equation types covered in algebra, showing up anywhere a relationship involves a squared term: projectile motion, area problems, and plenty of standardized-test questions. Solving one by hand means correctly applying the quadratic formula and simplifying a square root, which is easy to get wrong under time pressure. This tool does the arithmetic instantly so you can check your work or move straight to interpreting the answer.

The key to understanding the result is the discriminant — the b² − 4ac term under the square root. When it's positive, the equation has two distinct real solutions. When it's exactly zero, both solutions land on the same value, so there's only one repeated root. When it's negative, there's no real number that satisfies the equation — the two solutions are a complex conjugate pair instead, which this tool reports explicitly rather than showing a real number that isn't actually a valid answer.

Enter your three coefficients exactly as they appear in your equation, including their signs — for 2x² − 5x + 3 = 0, that's a = 2, b = −5, c = 3. The one input that has to follow a rule is a: it can't be zero, since a missing x² term means the equation isn't quadratic in the first place.

A worked example

Take x² − 7x + 12 = 0, so a = 1, b = −7, c = 12. The discriminant is b² − 4ac = (−7)² − 4(1)(12) = 49 − 48 = 1, which is positive, so there are two distinct real roots. Plugging into the formula: x = (−7 ± √1) / 2 = (7 ± 1) / 2, giving x = 4 and x = 3 — which checks out, since (x − 4)(x − 3) expands back to x² − 7x + 12.

A common misconception

It's easy to assume every quadratic equation has two real-number solutions, since that's the case most textbook practice problems are built around. In reality, a good number of quadratics — any with a negative discriminant — have no real solutions at all. It's also a common slip to drop the sign on b when reading coefficients out of an equation: in ax² + bx + c = 0, a term written as −5x means b = −5, not b = 5, and getting that sign wrong flips the roots to incorrect values even though the rest of the arithmetic is done correctly.

When there's no real solution

Take x² + 2x + 5 = 0: the discriminant is 2² − 4(1)(5) = 4 − 20 = −16, which is negative. Graphically, this means the parabola y = x² + 2x + 5 never touches the x-axis — it sits entirely above it, since its minimum value is positive. The two solutions are still mathematically valid, but they're complex numbers: −1 + 2i and −1 − 2i (real part −1, imaginary part ±2, from −b/2a and √16/2a). This calculator reports that pairing directly rather than showing a real number that wouldn't actually satisfy the original equation.

How to check your result

Vieta's formulas give a fast sanity check without re-solving anything: for ax² + bx + c = 0, the sum of the roots always equals −b/a, and their product always equals c/a. In the worked example above, 4 + 3 = 7, and −b/a = −(−7)/1 = 7 — it matches. Their product, 4 × 3 = 12, also matches c/a = 12/1 = 12. If your two roots don't satisfy both checks, it's worth re-entering your coefficients rather than trusting the result.

The quadratic formula vs. factoring

Factoring — rewriting ax² + bx + c as a product like (x − 4)(x − 3) — is often faster by hand when the roots are small whole numbers, but it only works cleanly when such factors exist and can take real trial and error to spot. The quadratic formula always works, for any a, b, and c, including messy decimals or a negative discriminant that no amount of factoring would reveal cleanly. This calculator always uses the formula rather than attempting to factor, precisely because it has to handle every possible input, not just the tidy cases a textbook chooses to illustrate.

Solves using the standard quadratic formula: x = (−b ± √(b² − 4ac)) / 2a.

Frequently asked questions

The discriminant is the part of the quadratic formula under the square root: b² − 4ac. Its sign tells you what kind of solutions to expect before you even finish solving — positive means two distinct real roots, zero means one repeated real root, and negative means the equation has no real solutions at all.