# Quadratic Equation Solver - Roots, Discriminant, Vertex and Factored Form with Steps

Page: https://hirantha.me/tools/quadratic-equation-solver
Part of: Hirantha Sandaruwan Lakshan free tools (https://hirantha.me/tools)
Updated: 2026-10-13

Solve ax² + bx + c = 0: real or complex roots, discriminant, vertex, axis of symmetry and factored form, with the working shown.

This is a free tool that runs in the browser: open the page to use it. File tools process files on the visitor's own device; files are never uploaded or stored. No account, sign-up, payment or watermark.

Enter the three numbers a, b and c of ax² + bx + c = 0 to find the roots, whether real or complex, along with the discriminant, the vertex, the axis of symmetry, the y-intercept and, when the roots are rational, the factored form. The working is written out step by step. The coefficients can be whole numbers, decimals or fractions, and they are handled exactly, so nothing is lost to rounding.

A quadratic equation has the form ax² + bx + c = 0 with a not equal to 0. The quadratic formula gives its solutions: x = (-b ± √(b² - 4ac)) / (2a). The part under the square root, D = b² - 4ac, is the discriminant.

The discriminant tells you what kind of roots to expect. If D is positive there are two different real roots and the parabola crosses the x-axis twice. If D is zero there is one repeated real root and the parabola just touches the axis. If D is negative there are no real roots: the two roots are complex conjugates, a + bi and a - bi, where i is the square root of -1.

The graph of y = ax² + bx + c is a parabola with its vertex at x = -b / (2a) and y = c - b² / (4a). The vertical line through the vertex is the axis of symmetry. The parabola opens upward with a minimum at the vertex when a is positive, and downward with a maximum when a is negative. The y-intercept is c.

When D is the square of a rational number the roots are rational and the equation factors. The page reads coefficients as exact fractions, so it spots this without rounding error and gives the factors with whole-number coefficients, like (2x - 1)(x - 2). Otherwise it shows the exact roots with a square root, such as (1 ± √5) / 2, and computes the decimals with the numerically stable form of the formula, which avoids the loss of digits (catastrophic cancellation) that the plain formula can cause when b² is much larger than 4ac.

If a is 0 the x² term vanishes and the equation is linear, so the tool solves bx + c = 0 instead. If a and b are both 0 there is either no solution (when c is not 0) or every number is a solution (when c is 0).

What the discriminant D = b² - 4ac tells you:
| Discriminant | Roots | Parabola | Example |
| --- | --- | --- | --- |
| D is positive | Two different real roots | Crosses the x-axis twice | x² - 3x + 2 = 0 has D = 1 and roots 1 and 2 |
| D is zero | One repeated real root | Touches the x-axis at its vertex | x² - 2x + 1 = 0 has D = 0 and the root 1 |
| D is negative | Two complex roots, a + bi and a - bi | Never reaches the x-axis | x² + 2x + 5 = 0 has D = -16 and roots -1 + 2i and -1 - 2i |
| D is a perfect square | Rational roots, so it factors | Crosses at rational points | 2x² - 5x + 2 = 0 has D = 9 and factors as (2x - 1)(x - 2) |

Q: What is the quadratic formula?
A: For ax² + bx + c = 0 with a not equal to 0, x = (-b ± √(b² - 4ac)) / (2a). The plus sign gives one root and the minus sign gives the other. Put in a, b and c, work out the discriminant under the square root first, then finish the arithmetic.

Q: What does the discriminant tell me?
A: Its sign tells you the kind of roots. Positive means two different real roots, zero means one repeated real root, and negative means two complex roots with no real solutions. Its value also shows whether the roots are rational: if it is a perfect square the equation factors neatly.

Q: What are complex roots and what does a + bi mean?
A: When the discriminant is negative the square root is of a negative number, which is written with i, where i² = -1. The roots are then a + bi and a - bi, called complex conjugates. The real part is -b / (2a), and the size of the imaginary part is the square root of -D divided by twice the size of a.

Q: How do I know if a quadratic can be factored?
A: It factors with rational numbers exactly when the discriminant is the square of a rational number. For x² - 3x + 2, D = 1, so it factors as (x - 1)(x - 2). For x² - x - 1, D = 5 is not a perfect square, so it does not factor over the rationals.

Q: What happens if a is 0?
A: Then there is no x² term and the equation is linear: bx + c = 0 gives x = -c / b. If b is also 0, the equation is either never true (c is not 0) or always true (c is 0). The tool handles all three cases and says which one applies.

Q: How do I find the vertex of the parabola?
A: The x-coordinate of the vertex is -b / (2a) and the y-coordinate is c - b² / (4a). The vertex is the lowest point if a is positive and the highest point if a is negative. The vertical line x = -b / (2a) is the axis of symmetry.

Q: Can I type fractions and decimals?
A: Yes. Type 0.25 or 1/4 and the value is stored exactly, so a root such as 1/3 is not blurred into 0.333 and a discriminant of 0.01 is not shown as 0.0099999. Up to 12 digits after the point are accepted, and values up to 1,000,000,000,000,000 in size.

Q: What is a repeated root?
A: When D = 0 the two roots are the same number. The parabola touches the x-axis at its vertex, and the quadratic is a perfect square: x² - 2x + 1 = (x - 1)².

Sources: Quadratic formula - Wikipedia: the formula, the discriminant and the stable form (https://en.wikipedia.org/wiki/Quadratic_formula); Discriminant - Wikipedia: sign and the nature of the roots (https://en.wikipedia.org/wiki/Discriminant); Quadratic function - Wikipedia: vertex, axis of symmetry and vertex form (https://en.wikipedia.org/wiki/Quadratic_function); Complex number - Wikipedia: the imaginary unit and conjugates (https://en.wikipedia.org/wiki/Complex_number)

Related tools:

- [Fraction calculator](https://hirantha.me/tools/fraction-calculator.md): Add, subtract, multiply and divide fractions and mixed numbers, with the working shown, the answer in lowest terms and as a decimal.
- [GCD and LCM calculator](https://hirantha.me/tools/gcd-lcm-calculator.md): Find the greatest common divisor and least common multiple of two or more whole numbers, with the Euclidean steps and prime factors shown.
- [Mean, median, mode and standard deviation calculator](https://hirantha.me/tools/statistics-calculator.md): Paste a list of numbers to get the mean, median, mode, range, quartiles, and sample and population variance and standard deviation.
- [Prime number checker](https://hirantha.me/tools/prime-number-checker.md): Check whether a number is prime, up to 2^64, see its prime factors and the previous and next prime, and list every prime up to 100,000.
- [Percentage calculator](https://hirantha.me/tools/percentage-calculator.md): Find X% of a number, what percent one number is of another, the whole from a part, or add and subtract a percentage, with the working shown.
