Quadratic Formula Calculator: Exact Roots With Steps
For ax² + bx + c = 0, x = (−b ± √(b² − 4ac)) ÷ 2a. For x² − 2x − 2 = 0 that gives x = (2 ± √12) ÷ 2 = 1 ± √3.
- Exact & decimal roots
- Complex roots too
- Vertex & factored form
- Discriminant 1 + 2425
- x = (−1 ± 5) ÷ 41, −3/2
- Factored(2x + 3)(x − 1)
- Vertex(−1/4, −25/8)
To solve a quadratic equation with the quadratic formula, write it as ax² + bx + c = 0, then put a, b and c into x = (−b ± √(b² − 4ac)) ÷ 2a. For 2x² + x − 3 = 0, a = 2, b = 1 and c = −3: the discriminant is 1² − 4 × 2 × (−3) = 25, so x = (−1 ± 5) ÷ 4, giving x = 1 or x = −3/2. This quadratic formula calculator keeps answers exact where it can (1 ± √3, or −1 ± 2i when there are no real roots), gives decimals, and shows the steps, the factored form and the vertex of the parabola.
How to Use the Quadratic Formula
- Write it in standard form, ax² + bx + c = 0, with a ≠ 0. For 3x² = 5x + 2, subtract to get 3x² − 5x − 2 = 0.
- Read off a, b and c, signs included: a = 3, b = −5, c = −2.
- Find the discriminant, b² − 4ac = 25 + 24 = 49.
- Use the formula: x = (−b ± √(b² − 4ac)) ÷ 2a = (5 ± 7) ÷ 6, so x = 2 or x = −1/3 (OpenStax College Algebra 2e, 2.5).
The most common slip is the sign of b: −b means "the opposite of b", so when b = −5, −b is +5. Put negative values in brackets when you square them: (−5)² = 25.
What the Discriminant Tells You
The discriminant, b² − 4ac, is the part under the square root. Its sign tells you what kind of solutions to expect before you finish (OpenStax, 2.5):
| Discriminant | Solutions | Example |
|---|---|---|
| Positive, perfect square | Two rational solutions | x² − 5x + 6 = 0: b² − 4ac = 1, x = 2, 3 |
| Positive, not a perfect square | Two irrational solutions | x² − 2x − 2 = 0: b² − 4ac = 12, x = 1 ± √3 |
| Zero | One rational (double) solution | x² − 6x + 9 = 0: b² − 4ac = 0, x = 3 |
| Negative | Two complex solutions, no real ones | x² + 2x + 5 = 0: b² − 4ac = −16, x = −1 ± 2i |
The table is for whole-number a, b and c. With fractions, a "perfect square" discriminant means the square of a fraction, such as 1/4, and the roots are still rational.
Simplifying the Answer
When the discriminant isn't a perfect square, simplify the root and then the fraction. For x² − 2x − 2 = 0, x = (2 ± √12) ÷ 2. Since √12 = √(4 × 3) = 2√3 (OpenStax Elementary Algebra 2e, 9.2), x = (2 ± 2√3) ÷ 2 = 1 ± √3, about −0.7321 and 2.7321. With a negative discriminant, the square root of a negative number brings in i, defined as the square root of −1 (OpenStax College Algebra 2e, 2.4): x² + 2x + 5 = 0 has discriminant −16, so x = (−2 ± 4i) ÷ 2 = −1 ± 2i.
The Parabola: Vertex and Axis
The graph of y = ax² + bx + c is a parabola. It opens upward when a > 0 and downward when a < 0, its vertex is at h = −b ÷ 2a with k = f(h), the axis of symmetry is the line x = h, and it crosses the y-axis at c (OpenStax College Algebra 2e, 5.1). The real solutions are where it crosses or touches the x-axis (a double root only touches it), so no real solutions means the parabola never reaches it. For x² − 5x + 6, the vertex is at (5/2, −1/4), halfway between the roots 2 and 3.
Frequently Asked Questions
What is the quadratic formula?
x = (−b ± √(b² − 4ac)) ÷ 2a. It solves any equation of the form ax² + bx + c = 0 with a ≠ 0.
When should I use the quadratic formula instead of factoring?
Any time: it always works. Factoring is quicker when the roots are rational; with whole-number a, b and c, that's when the discriminant is a perfect square (including 0). The calculator shows the factored form whenever the roots are rational.
What if a is 0?
Then there's no x² term, so the equation is linear, bx + c = 0, and the quadratic formula doesn't apply. When b isn't 0, the solution is x = −c ÷ b.
What does "no real solutions" mean?
The discriminant is negative, so the square root isn't a real number and the parabola doesn't cross the x-axis. The solutions are complex numbers, written p ± qi.
More tools: the square root calculator simplifies roots, the factor calculator lists factor pairs, and the math calculators page has the rest.
Sources
- OpenStax, College Algebra 2e, 2.5 Quadratic Equations (quadratic formula, discriminant)
- OpenStax, College Algebra 2e, 5.1 Quadratic Functions (vertex, axis of symmetry, direction, y-intercept)
- OpenStax, Elementary Algebra 2e, 9.2 Simplify Square Roots
- OpenStax, College Algebra 2e, 2.4 Complex Numbers
- Formulas and test cases: how we calculate