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.

ax² + bx + c = 0

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.

Tested & Reviewed by:

Arefin Bappy

Owner, Admin & Developer of AjaxCalculators
Individually tested against the calculation method described on this page.
Last reviewed: September 8, 2026
About the Admin · Editorial Policy

Sponsored Offers

Explore more from

Volume Calculator

Calculate the volume of common three-dimensional solids using measurements in compatible units.

Long Division Calculator

Perform long division with a quotient, remainder and step-by-step divide-multiply-subtract work.

Proportion Calculator

Solve a missing value in equivalent ratios and verify the result using equal cross products.

Mean Median Mode Calculator

Use our Mean Median Mode Calculator to find the average, median, and mode from any data set. Supports raw numbers, value:count input, and sorted preview.

Fraction Calculator

Calculate fraction operations, simplify the result and understand common denominators and reciprocals.

Average Percentage Calculator

Average percentage calculator to find simple or weighted averages of multiple percentages with quick, accurate results.

Slope Calculator

Use our Slope Calculator to find slope, angle, percent grade, line equation, y-intercept, rise/run, and distance using two points or other methods.

Area Calculator

Calculate the area of common two-dimensional shapes using dimensions in compatible units.

Pythagorean Theorem Calculator

Pythagorean Theorem Calculator solves missing sides of a right triangle fast. Use it to find the hypotenuse or any unknown side easily.