Quadratic Formula Calculator
Solve any quadratic equation in standard form ax² + bx + c = 0. Enter a, b and c and the calculator returns both roots, the discriminant, the vertex of the parabola, the axis of symmetry and every step of the quadratic formula — including complex roots when the discriminant is negative.
Quadratic Formula Calculator tool
About the Quadratic Formula Calculator
Use it to check algebra homework, find where a projectile lands, locate the break-even point of a profit curve, or confirm a factoring answer. The roots are computed with a numerically stable version of the formula, so equations with one very large and one very small root still come out accurate.
If your equation is not in standard form yet, move every term to one side first. 2x² = 3x − 1 becomes 2x² − 3x + 1 = 0, so a = 2, b = −3 and c = 1. If a is 0 the equation is linear, not quadratic, and the calculator tells you so instead of dividing by zero.
How the Quadratic Formula Calculator works
The quadratic formula comes from completing the square on ax² + bx + c = 0. The expression under the square root, b² − 4ac, is the discriminant. Its sign tells you what kind of roots to expect before you finish the arithmetic.
The vertex of the parabola y = ax² + bx + c sits halfway between the roots, at x = −b / 2a. Substituting that x back in gives the minimum value (a > 0) or maximum value (a < 0) of the quadratic.
x = (−b ± √(b² − 4ac)) / 2a
D = b² − 4ac
h = −b / 2a, k = c − b² / 4a
Example
x² − 5x + 6 = 0: D = 25 − 24 = 1, so x = (5 ± 1) / 2, giving x = 2 and x = 3. The vertex is (2.5, −0.25).
How to Use the Quadratic Formula Calculator
- Rewrite the equation so one side is 0: ax² + bx + c = 0.
- Enter a, b and c, keeping negative signs (x² − 5x + 6 means b = −5).
- Read the roots at the top of the result panel.
- Check the discriminant to see whether the roots are real, repeated or complex.
- Use the vertex and axis of symmetry to sketch the parabola.
Quadratic Formula Calculator Examples
Two real roots
2x² − 3x + 1 = 0: D = 9 − 8 = 1, x = (3 ± 1) / 4, so x = 0.5 and x = 1.
One repeated root
x² − 6x + 9 = 0: D = 36 − 36 = 0, so x = 3 is a double root and the parabola just touches the x-axis.
Complex roots
x² + 2x + 5 = 0: D = 4 − 20 = −16, √−16 = 4i, so x = (−2 ± 4i) / 2 = −1 ± 2i.
Projectile height
h = −4.9t² + 20t + 1.5 hits the ground when h = 0. With a = −4.9, b = 20, c = 1.5 the positive root is t ≈ 4.15 seconds.
How to Solve a Quadratic Equation With the Formula
Start in standard form. Identify a, b and c, then compute the discriminant first — it is the part most people get wrong, usually by dropping the sign of b or forgetting that −b² is not the same as (−b)². With b = −5, b² is 25, not −25.
Next take the square root of the discriminant, add and subtract it from −b, and divide each result by 2a. Divide the whole numerator, not just the square root. A common slip is writing −b ± √D / 2a, which only divides the root.
Finally, check one root by substituting it back into ax² + bx + c. The result should be 0, or very close to 0 when the root was rounded.
Discriminant and the Shape of the Parabola
The graph of y = ax² + bx + c is a parabola. The roots are the x-intercepts. The sign of a decides whether it opens upward or downward, and the discriminant decides how many times it meets the x-axis.
| Discriminant b² − 4ac | Roots | Graph |
|---|---|---|
| Positive (> 0) | Two different real roots | Crosses the x-axis twice |
| Zero (= 0) | One repeated real root | Vertex touches the x-axis |
| Negative (< 0) | Two complex roots, p ± qi | Never touches the x-axis |
| Perfect square (e.g. 1, 4, 9) | Rational roots | Equation can be factored over the integers |
Vertex Form and Completing the Square
Every quadratic can be written as y = a(x − h)² + k, where (h, k) is the vertex. The calculator reports h = −b/2a and k = c − b²/4a, so x² − 5x + 6 becomes (x − 2.5)² − 0.25.
Vertex form is the fastest way to read the minimum or maximum of a quadratic — useful for maximizing area with a fixed perimeter or finding the highest point of a thrown ball. The slope calculator handles straight lines; this page covers the curved case.
Frequently Asked Questions
What does the discriminant tell me?
If b² − 4ac is positive there are two different real roots. If it is zero there is one repeated real root. If it is negative there are two complex conjugate roots and the parabola never crosses the x-axis.
What if a = 0?
Then the equation is bx + c = 0, which is linear. Its single solution is x = −c / b. The quadratic formula would divide by zero, so the calculator asks for a nonzero a.
Can the coefficients be decimals or fractions?
Decimals work directly. For fractions such as ½x² + ⅓x − 1 = 0, either type the decimals or multiply every term by the common denominator (6) to get 3x² + 2x − 6 = 0, which has the same roots.
Why are some roots shown as long decimals?
Roots are often irrational. x² − 2 = 0 has roots ±√2 ≈ ±1.4142135624. The calculator shows up to 10 decimal places rather than a radical.
Is factoring or the quadratic formula better?
Factoring is faster when the roots are small integers or simple fractions. The quadratic formula always works, including for irrational and complex roots, which is why this calculator uses it.
What is the sum and product of the roots?
For two roots, x₁ + x₂ = −b/a and x₁ × x₂ = c/a (Vieta's formulas). They are a quick way to check an answer.
Related Calculators
Slope Calculator
Slope, intercept, angle and distance from two points.
Fraction Calculator
Add, subtract, multiply and divide fractions and mixed numbers.
Scientific Calculator
Trig, logarithms, exponents, roots and factorials in your browser.
Factor Calculator
List every factor and the prime factorization of a whole number.
Triangle Calculator
Solve SSS, SAS, ASA, AAS and SSA triangles for sides, angles and area.