How to use the quadratic formula calculator
- Enter the coefficient a for the x² term. It cannot be zero.
- Enter the coefficient b for the x term.
- Enter the constant c.
- Read the results below: the discriminant, both roots (or one repeated root, or complex roots) and the vertex of the parabola.
How the quadratic formula works
The quadratic formula solves any equation in the standard form ax² + bx + c = 0 where a is not zero. The formula is:
x = (-b ± √(b² - 4ac)) / (2a)
The expression under the square root, b² - 4ac, is called the discriminant. It determines the nature of the roots. For example, to solve x² - 5x + 6 = 0, set a = 1, b = -5, c = 6. The discriminant is (-5)² - 4(1)(6) = 25 - 24 = 1. Because it is positive, there are two distinct real roots: x = (5 + 1) / 2 = 3 and x = (5 - 1) / 2 = 2.
Understanding the discriminant
This tool also acts as a discriminant calculator. The value of D = b² - 4ac tells you exactly what kind of solutions to expect before you finish computing them.
| Discriminant (D) | Number of roots | Type of roots |
|---|---|---|
| D > 0 | 2 | Distinct real numbers |
| D = 0 | 1 | Repeated real number |
| D < 0 | 2 | Complex conjugates (a ± bi) |
When D is negative, the square root produces an imaginary component. The quadratic formula calculator above formats these complex roots as a + bi and a - bi so they are easy to read.
Finding the vertex of the parabola
Beyond solving for x, the quadratic equation defines a parabola y = ax² + bx + c. The vertex is the highest or lowest point on that curve, depending on whether a is negative or positive. Its x-coordinate is always -b / (2a). Substituting that back into the equation gives the y-coordinate, which simplifies to -D / (4a).
For x² - 5x + 6, the vertex x is 5/2 = 2.5 and the vertex y is -1/4 = -0.25. The vertex form of the same equation is y = (x - 2.5)² - 0.25. Knowing the vertex helps when graphing or finding maximum and minimum values in physics and economics problems.
Common mistakes when solving ax² + bx + c
A frequent error is forgetting to include the sign of each coefficient. If the equation is 2x² - 7x + 3 = 0, then b is -7, not 7. Plugging in the wrong sign changes the discriminant and produces incorrect roots.
Another mistake is dividing only part of the numerator by 2a. The entire expression -b ± √D must be divided by 2a. Writing -b ± √D / 2a without parentheses around the denominator is ambiguous and often leads to arithmetic errors.
Finally, setting a = 0 reduces the equation to a linear one (bx + c = 0). A quadratic equation solver requires a non-zero leading coefficient. If a is zero, use basic algebra instead.
Practical uses of quadratic equations
Quadratic equations appear whenever a quantity depends on the square of another. In projectile motion, the height of a thrown ball over time follows a parabolic path described by a quadratic. Setting height to zero and using the quadratic formula reveals when the ball hits the ground.
In business, profit functions are often quadratic. Finding the break-even points means solving for the roots. In geometry, area problems frequently lead to equations like x(x + 3) = 40, which expands to x² + 3x - 40 = 0. You can use tools like the square footage calculator for direct area measurements, but when the relationship involves an unknown dimension squared, you need to solve ax² + bx + c = 0.
Worked examples
Each result below was produced by the same code the tool runs, so you can check your own numbers against them.
| Example | Input | Result |
|---|---|---|
| Two distinct real roots | Coefficient a (x²): 1; Coefficient b (x): -5; Coefficient c (constant): 6 | Discriminant: 1; Root x₁: 3; Root x₂: 2; Vertex x: 2.5; Vertex y: -0.25 |
| One repeated root | Coefficient a (x²): 1; Coefficient b (x): -4; Coefficient c (constant): 4 | Discriminant: 0; Root x₁ = x₂: 2; Vertex x: 2; Vertex y: 0 |
| Complex roots | Coefficient a (x²): 1; Coefficient b (x): 2; Coefficient c (constant): 5 | Discriminant: -16; Root x₁: -1 + 2i; Root x₂: -1 - 2i; Vertex x: -1; Vertex y: 4 |
| Fractional coefficients | Coefficient a (x²): 0.5; Coefficient b (x): -3.5; Coefficient c (constant): 3 | Discriminant: 6.25; Root x₁: 6; Root x₂: 1; Vertex x: 3.5; Vertex y: -3.125 |
FAQ
What is the quadratic formula?
The quadratic formula is x = (-b ± √(b² - 4ac)) / (2a). It provides the solutions to any quadratic equation written in the standard form ax² + bx + c = 0.
Can this quadratic equation solver handle complex roots?
Yes. When the discriminant is negative, the calculator returns the two complex conjugate roots in the form a + bi and a - bi.
What happens if a is zero?
If a is zero the equation is linear, not quadratic. This tool will show an error because the quadratic formula requires division by 2a.
How do I find the vertex from the coefficients?
The x-coordinate of the vertex is -b / (2a). The y-coordinate is -D / (4a), where D is the discriminant b² - 4ac.
Is my data sent to a server?
No. This quadratic formula calculator runs entirely in your browser. Nothing you type is uploaded anywhere.
Why does the discriminant matter?
The discriminant tells you how many real solutions exist. A positive value means two real roots, zero means one repeated root, and a negative value means two complex roots.