Quadratic Formula Calculator
Solve quadratic equations in the form ax² + bx + c = 0 using the quadratic formula, with real or complex roots and full calculation steps.
Results
The Quadratic Formula Calculator solves equations in the form ax²+bx+c=0 when a is nonzero. It calculates the discriminant b²−4ac and uses it to determine whether the equation has two real roots, one repeated real root, or a complex-conjugate pair.
What the discriminant says about the graph
The roots are x=(−b±√(b²−4ac))/(2a). Parentheses around the entire numerator and denominator are essential. The discriminant controls the root type before the square root is evaluated.
For ax²+bx+c=0 with a≠0, x = (−b ± √(b²−4ac))/(2a).
Enter the values in their mathematical roles
Rewrite the equation in standard form with zero on one side, then enter a, b, and c with their signs. Use 0 for a missing linear or constant term. Check that a is not zero; otherwise the equation is linear.
The governing relationship
For ax²+bx+c=0 with a≠0, x = (−b ± √(b²−4ac))/(2a).
A compact example
For x²−5x+6=0, the discriminant is 1 and the roots are 2 and 3.
Valid inputs and boundary cases
Coefficients may be integers or decimals, but rounded inputs produce rounded roots. A negative discriminant introduces i=√−1. Very close repeated roots can be sensitive to coefficient precision.
Read the answer in context
A negative discriminant produces complex roots; a zero discriminant produces one repeated real root.
An independent check
Substitute each reported root into ax²+bx+c. The result should be zero within rounding. Vieta’s relations offer another check: the root sum is −b/a and the product is c/a.
Errors that change the answer
- Dropping a negative coefficient sign
- Entering an equation not equal to zero
- Forgetting the ± branch
- Dividing only the square-root term by 2a
- Treating a negative discriminant as no solution
Continue with a related calculator
Continue with the Long Division Calculator or Area Calculator. For everyday arithmetic and order-of-operations checks, use the Basic Calculator.
What this numerical result cannot decide
The formula returns roots but does not explain multiplicity, graph shape, domain restrictions in an original word problem, or whether rounded coefficients accurately represent the model.
A second way to understand the method
A positive discriminant means the parabola crosses the x-axis twice. A zero discriminant means it touches the axis at the vertex. A negative discriminant means it has no real x-intercepts, although two complex roots still exist.
Stable evaluation matters for extreme coefficients
When b² is much larger than 4ac, subtracting nearly equal floating-point quantities in one formula branch can lose precision. For ordinary coursework the displayed roots are usually sufficient, but numerical computing may use a reformulated branch and Vieta’s product to improve stability. Keep exact radicals when possible.
Connect roots, factors, and intercepts
If the roots are r₁ and r₂, the quadratic can be written as a(x−r₁)(x−r₂). For x²−5x+6, the roots 2 and 3 give (x−2)(x−3). Expanding returns the original coefficients, while the graph crosses the x-axis at those root values.
Completing the square leads to the formula
Dividing ax²+bx+c=0 by a, moving the constant term, and completing the square produces (x+b/2a)²=(b²−4ac)/(4a²). Taking both square-root branches and isolating x gives the familiar quadratic formula. This derivation explains why the discriminant appears and why the ± sign cannot be omitted.
Repeated roots count twice algebraically
When the discriminant is zero, both formula branches produce −b/(2a). The graph has one x-intercept, but the polynomial has a root of multiplicity two and factors as a(x−r)².
Quadratic Formula Calculator FAQ
What happens when a=0?
The equation is not quadratic; solve the resulting linear equation instead.
Can the calculator show complex roots?
Yes, when the discriminant is negative and complex output is supported.
Why are there two answers?
The ± symbol represents two branches of the square root.
For additional worked mathematics, see the free OpenStax Prealgebra 2e reference.