quadratic equation solver — the complete guide
This is everything about the Quadratic Equation Solver in one place: what it does, the two formulas it runs on, all three kinds of answer, and the mistakes that trip people up. If you only read one guide on this tool, read this one.
What it does
You enter a, b and c, and the solver returns the roots of ax² + bx + c = 0 — the values of x that make the equation true. It also shows the discriminant, b² − 4ac, which tells you what kind of answer to expect before the roots are worked out.
The formulas
Discriminant: D = b² − 4ac Quadratic formula: x = (−b ± √D) ÷ 2a
The three cases
- D is positive — two real roots. x² − 5x + 6 = 0 has D = 1 and roots 3 and 2. The curve crosses the x-axis twice.
- D is zero — one repeated root. x² − 6x + 9 = 0 has D = 0 and the single root x = 3, counted twice. The curve just touches the x-axis.
- D is negative — no real roots. x² + 2x + 5 = 0 has D = −16 and the complex roots −1 ± 2i. The curve never reaches the x-axis.
Worked examples
x² − 5x + 6 = 0 → D = 1, x = 3 and 2 x² − 6x + 9 = 0 → D = 0, x = 3 (repeated) x² + 2x + 5 = 0 → D = −16, x = −1 ± 2i
The mistake to avoid
Skipping the discriminant and going straight to the formula. Then a negative D looks like an error instead of an answer, and a zero D looks like a missing root. Work out D first; it tells you what kind of answer to expect, and the formula then fills in the numbers.
Solver or scientific calculator — what do you lose with the calculator?
A scientific calculator will solve a quadratic and print the two roots. What it will not do is tell you which kind of answer you are looking at, or why. The solver shows the discriminant first, so you know before the roots appear whether to expect two real roots, one repeated root, or a complex pair — and if a root looks odd, the discriminant tells you where to check. Take x² − 4x + 3 = 0: D = 16 − 12 = 4, √4 = 2, and the roots are (4 ± 2) ÷ 2, which are x = 3 and x = 1. A calculator gives you 3 and 1 and stops; the solver shows the 4 that connects them, and the 4 is what proves there are two distinct real roots rather than a repeated one.
Use the calculator when you only need the number — a quick check on site, say. Use the solver when the answer has to be explained, defended, or written out for an exam: the discriminant is the part of the working a marker actually reads.
Do not round √D before you finish
Not every discriminant is a neat square, and rounding it early quietly moves both roots. Take x² + 4x + 1 = 0. The discriminant is D = 16 − 4 = 12, and √12 is about 3.46, so the roots are (−4 ± 3.46) ÷ 2, which are x = −0.27 and x = −3.73. Round √12 down to 3 first and the roots become −0.5 and −3.5 — and the check gives it away: put −0.5 back in and you get 0.25 − 2 + 1 = −0.75, not 0. Keep √D to at least two decimal places until the roots are written down, and only round at the very end. A root that is off by a quarter looks close, but it is not a root at all.
Frequently asked questions
What does the Quadratic Equation Solver do?
It takes a, b and c and returns the roots of ax² + bx + c = 0, with the discriminant shown.
What is the discriminant?
b² − 4ac. Positive: two real roots. Zero: one repeated root. Negative: two complex roots.
What if a is 0?
The equation is linear, bx + c = 0, with the single root x = −c ÷ b.
How do I check a root?
Put it back into ax² + bx + c. A correct root gives 0.
More guides on the Quadratic Equation Solver
- How to use the Quadratic Equation Solver — step by step
- Quadratic Equation Solver explained with worked examples
- Quadratic Equation Solver formula — how it actually works
- Quadratic Equation Solver for beginners — start here
- Common mistakes people make with the Quadratic Equation Solver
- Quadratic Equation Solver vs doing it by hand — which is faster?
- How to get an accurate result from the Quadratic Equation Solver
- Quadratic Equation Solver for students — with examples
- Quadratic Equation Solver for homeowners and DIYers
Solve a quadratic equation, see the discriminant and both roots — free, in your browser.