Quadratic Equation Solver
Table of Contents
- Quadratic equation definition
- Parts of a quadratic equation
- How to solve a quadratic equation
- The graph of a quadratic equation
- Frequently asked questions
Quadratic equation definition
A quadratic equation is an equation in which the unknown, x, appears squared, and no higher. Every quadratic equation can be rearranged into the standard form:
a * x² + b * x + c = 0
where a, b and c are known numbers and a is not zero (otherwise it would be a linear equation). The name comes from the Latin quadratus, square.
A quadratic equation has at most two real solutions, also called roots. They describe anything that follows a parabola: the path of a thrown ball, the area of a rectangle with a fixed perimeter, or the stopping distance of a car.
Parts of a quadratic equation
You enter the coefficients a, b and c, and the tool shows the two solutions, x1 and x2. On the way, it calculates the discriminant in the background, which decides how many solutions there are.
Coefficients (a, b, c)
The three coefficients define the equation:
- a multiplies
x², and can't be 0. When it is positive the parabola opens upwards, and when it is negative, downwards. - b multiplies x. It can be 0, as in
x² - 9 = 0. - c is the constant term, the number on its own. It can be 0 too, as in
x² - 4x = 0.
Discriminant
The discriminant (D) is the part of the quadratic formula under the square root:
D = b² - 4 * a * c
This tool works it out first, without showing it, because its sign decides which solutions there are:
D > 0: two different real solutions.D = 0: one real solution (a double root), where the parabola just touches the x-axis.D < 0: no real solutions, since the square root of a negative number isn't real, so both solution fields stay empty.
Solutions (x1, x2)
The solutions (or roots) are the values of x that make the equation true. They come from the quadratic formula:
x1 = (-b + √D) / (2 * a)x2 = (-b - √D) / (2 * a)
When D = 0, both give the same value, x = -b / (2 * a), which this tool shows as x1.
The two solutions always add up to -b / a, and multiply to c / a (Vieta's formulas).
How to solve a quadratic equation
Example: solve x² - 5x + 6 = 0, where a = 1, b = -5 and c = 6.
-
The discriminant. It is positive, so there are two solutions:
D = (-5)² - 4 × 1 × 6 = 25 - 24 = 1 -
The quadratic formula.
x1 = (5 + √1) / 2 = 3andx2 = (5 - √1) / 2 = 2 -
Check. Both make the equation true:
3² - 5 × 3 + 6 = 0and2² - 5 × 2 + 6 = 0
Some equations can be solved faster by hand:
- Factoring:
x² - 5x + 6 = (x - 2) * (x - 3), sox = 2orx = 3. It is quick when the roots are whole numbers. - Square roots: when
b = 0, as inx² - 9 = 0, rearrange tox² = 9, sox = 3orx = -3.
The quadratic formula always works, which is why this tool uses it.
The graph of a quadratic equation
The graph of y = a * x² + b * x + c is a parabola, a U-shaped curve, and the solutions are where it crosses the x-axis:
- It crosses twice when
D > 0, touches once whenD = 0, and never meets the x-axis whenD < 0. - Its turning point, the vertex, is at
x = -b / (2 * a), exactly halfway between the two roots.
You can draw any parabola, and see its roots, with the Grapher.
Frequently asked questions
How do you solve a quadratic equation?
Use the quadratic formula, x = (-b ± √(b² - 4 * a * c)) / (2 * a). Work out the discriminant first: if it is negative, there are no real solutions.
What is the discriminant?
The discriminant, b² - 4 * a * c, is the expression under the square root in the quadratic formula. When it is positive there are two real solutions, when it is zero one, and when it is negative none.
Can a quadratic equation have no solution?
It has no real solution when the discriminant is negative, as in x² + 1 = 0. It then has two complex solutions, x = i and x = -i, where i is the square root of -1.
What is the difference between a quadratic and a linear equation?
A linear equation has x only to the first power and exactly one solution. A quadratic equation has x², which gives it up to two solutions and makes its graph a parabola instead of a straight line.