Boneyard Tools

Quadratic Equation Solver

Solve a quadratic equation of the form ax^2 + bx + c = 0. Enter the three coefficients and the solver returns the roots, the discriminant and the vertex of the parabola instantly.

How to solve a quadratic equation

  1. Enter the coefficients a, b and c from your equation ax^2 + bx + c = 0.
  2. Read the roots, which may be two real values, one repeated value or a complex pair.
  3. Check the discriminant to see the nature of the roots and the vertex for the turning point.

Examples

Two real roots

a = 1, b = -5, c = 6
Roots: 2 and 3, discriminant 1

Complex roots

a = 1, b = 0, c = 1
Roots: 0 + 1i and 0 - 1i, discriminant -4

Frequently asked questions

What is the quadratic formula?

For ax^2 + bx + c = 0 with a not equal to 0, the roots are x = (-b plus or minus the square root of (b^2 - 4ac)) / (2a). This solver applies that formula directly and also handles the linear case where a is 0.

What does the discriminant tell me?

The discriminant is b^2 - 4ac. If it is positive there are two distinct real roots, if it is exactly zero there is one repeated real root, and if it is negative the two roots are complex conjugates.

How are complex roots shown?

When the discriminant is negative the roots have an imaginary part. They are written as a conjugate pair such as 1 + 2i and 1 - 2i, where i is the square root of -1.

What is the vertex of the parabola?

The graph of y = ax^2 + bx + c is a parabola whose turning point, the vertex, is at x = -b / (2a) and y = c - b^2 / (4a). It is the minimum point when a is positive and the maximum when a is negative.

What happens if a is zero?

If a is 0 the equation is linear, bx + c = 0, with the single root -c/b. The solver returns that root. If both a and b are 0 there is nothing to solve and it reports an error.

Are the answers exact?

Roots are computed with standard floating point math and rounded to four decimal places for display, so irrational roots such as the square root of 2 appear as approximations like 1.4142.

Related tools