Advertisement

Quadratic Formula Solver (Step by Step)

Enter a, b and c of ax² + bx + c = 0 and see the quadratic formula worked step by step, with simplified exact roots and decimals.

Enter the three coefficients of ax² + bx + c = 0 and this solver substitutes them into the quadratic formula one step at a time, the way a teacher would write it on the board. It simplifies the square root (√12 becomes 2√3), reduces the fraction, and gives both the exact roots and their decimal values, so you can check your working as well as the final answer.

How to use this tool

  1. Rewrite your equation as ax² + bx + c = 0, moving every term to one side first.
  2. Enter a, b and c, including any minus signs, for example b = −4.
  3. Read the exact solutions and the decimal roots.
  4. Follow the step table to see the substitution, the discriminant and the simplification.

Formula

x = (−b ± √(b² − 4ac)) / (2a)

The ± gives two answers, one with + and one with −. The expression under the root, D = b² − 4ac, is the discriminant. A perfect-square D gives rational roots, any other positive D gives irrational roots written with √, D = 0 gives a single repeated root, and a negative D gives two complex roots written with i.

Example

Solve x² − 4x + 1 = 0, so a = 1, b = −4 and c = 1. The discriminant is (−4)² − 4 × 1 × 1 = 16 − 4 = 12. Simplify √12 = √(4 × 3) = 2√3, so x = (4 ± 2√3) / 2. Dividing every term by 2 gives x = 2 ± √3, about 0.267949 and 3.732051. Check: the roots add up to 4 (= −b/a) and multiply to 1 (= c/a).

Frequently asked questions

Where does the quadratic formula come from?

It is what you get by completing the square on ax² + bx + c = 0 in general: divide by a, move c/a across, add (b/2a)² to both sides and take the square root. The formula is that process done once, for every quadratic.

What if a is 0?

Then there is no x² term and the equation is linear, bx + c = 0, with the single solution x = −c/b. The solver tells you this instead of dividing by zero.

Should I use the formula or factor?

Factoring is quicker when the roots are small whole numbers or simple fractions, which happens exactly when the discriminant is a perfect square. The formula always works, including for irrational and complex roots.

Why do my calculator’s decimals differ slightly?

The decimal roots here are rounded to six places. The exact form is the precise answer; keep it in later working to avoid rounding errors.

Last updated: 2026-10-30

Advertisement