By Tim King · Updated
Polynomial Root Calculator
Real and Complex Roots of Cubic and Quartic Polynomials, With Factored Form
OneTask is free, with no sign-up, and built by one person.
If this tool saved you time, a coffee helps keep new ones coming.
How the Polynomial Root Calculator works
This polynomial root calculator finds every root of a cubic, quartic or higher-degree polynomial, including repeated and complex roots. Type the expression, such as x^3 − 6x^2 + 11x − 6, or just its coefficients, such as 1, −6, 11, −6. You get the factored form and the working.
A root, or zero, is a value of x that makes the polynomial equal zero. A polynomial of degree n has exactly n roots once you count repeats and complex ones. The real roots are where its graph crosses or touches the x-axis.
How the polynomial root calculator works
With whole-number coefficients the calculator first applies the rational root theorem: any fraction root p/q must have p dividing the constant term and q dividing the leading coefficient. It tests each candidate with synthetic division, and every hit splits off a factor and lowers the degree. A quadratic left over is solved with the formula x = (−b ± √(b² − 4ac)) ÷ 2a. Anything higher with no rational roots is solved numerically, to about ten significant figures.
First example. x^3 − 6x^2 + 11x − 6: the candidates are ±1, ±2, ±3 and ±6. x = 1 works, leaving x^2 − 5x + 6, which factors as (x − 2)(x − 3). The roots are 1, 2 and 3.
Second example. 6x^3 + 11x^2 − 4x − 4 has the fraction roots −1/2 and 2/3, plus −2, giving (2x + 1)(3x − 2)(x + 2).
How many real roots can a cubic have? One or three, counting repeats. Complex roots come in conjugate pairs, so a cubic always crosses the x-axis at least once.
Example polynomials with their real roots and factored form
| Polynomial | Real roots | Factored form |
|---|---|---|
| x^3 - 6x^2 + 11x - 6 | 1, 2, 3 | (x - 1)(x - 2)(x - 3) |
| x^3 - 7x + 6 | -3, 1, 2 | (x - 1)(x - 2)(x + 3) |
| x^3 + x^2 - 4x - 4 | -2, -1, 2 | (x + 1)(x - 2)(x + 2) |
| 2x^3 - 3x^2 - 11x + 6 | -2, 1/2, 3 | (2x - 1)(x + 2)(x - 3) |
| x^3 - 1 | 1 | (x - 1)(x^2 + x + 1) |
| x^3 + 8 | -2 | (x + 2)(x^2 - 2x + 4) |
| x^3 - 3x^2 + 3x - 1 | 1 (×3) | (x - 1)^3 |
| x^3 - 2x^2 - 5x + 6 | -2, 1, 3 | (x - 1)(x + 2)(x - 3) |
| 3x^3 - 2x^2 - 7x - 2 | -1, -1/3, 2 | (3x + 1)(x + 1)(x - 2) |
| x^3 - 4x | -2, 0, 2 | x(x - 2)(x + 2) |
| x^3 + x^2 + x + 1 | -1 | (x + 1)(x^2 + 1) |
| x^3 - 9x^2 + 26x - 24 | 2, 3, 4 | (x - 2)(x - 3)(x - 4) |
| x^4 - 5x^2 + 4 | -2, -1, 1, 2 | (x - 1)(x + 1)(x - 2)(x + 2) |
| x^4 - 1 | -1, 1 | (x - 1)(x + 1)(x^2 + 1) |
| x^3 - 2 | 1.259921 | (x^3 - 2) |
| 2x^3 + x^2 - 13x + 6 | -3, 1/2, 2 | (2x - 1)(x - 2)(x + 3) |
| x^4 - 10x^2 + 9 | -3, -1, 1, 3 | (x - 1)(x + 1)(x - 3)(x + 3) |
| x^3 - 3x - 2 | -1 (×2), 2 | (x + 1)^2(x - 2) |
| 4x^3 - 13x + 6 | -2, 1/2, 3/2 | (2x - 1)(2x - 3)(x + 2) |
| x^3 + 3x^2 - x - 3 | -3, -1, 1 | (x - 1)(x + 1)(x + 3) |
| x^4 + 4x^3 + 6x^2 + 4x + 1 | -1 (×4) | (x + 1)^4 |
| x^3 - 6x^2 + 12x - 8 | 2 (×3) | (x - 2)^3 |
Tips
- Use ^ for powers. x^3, x³ and x**3 are all accepted.
- Coefficient lists need every power. For x^3 − 2 type 1, 0, 0, −2, with zeros for missing terms.
- Fractions are fine. 1/2x^2 + 3x − 2 is read as a half times x squared.
FAQ
What is the rational root theorem?
If a polynomial has whole-number coefficients, any rational root written in lowest terms as p/q has p dividing the constant term and q dividing the leading coefficient. That gives a short, finite list of candidates to test, which is why it is the first step for factoring cubics by hand.
What is synthetic division?
It is a shortcut for dividing a polynomial by (x − r). Bring down the first coefficient, multiply by r, add to the next coefficient, and repeat. If the last number is zero, r is a root and the other numbers are the coefficients of the quotient, one degree lower.
Why does the calculator show complex roots?
Some polynomials never reach zero on the real number line. x^2 + 1 is always at least 1, so its roots are i and −i. Including complex roots means you always see all n roots of a degree-n polynomial, as the fundamental theorem of algebra promises.
Is there a cubic formula like the quadratic formula?
Yes, Cardano's formula, but it is long and often produces cube roots of complex numbers even when all three roots are real. In practice people use the rational root theorem, then the quadratic formula, or a numerical method, which is exactly what this calculator does.
See also: all Algebra and Geometry tools, Arithmetic, Number Theory, Statistics, Trigonometry and Calculus.
Related tools
Quadratic Equation Calculator
Solve ax² + bx + c = 0, with exact roots and the vertex.
Completing The Square Calculator
Vertex form, vertex and roots of any quadratic, step by step.
Linear Equation Calculator
Solve one-variable linear equations with full working.
Factor Calculator
All the factors, factor pairs and prime factorisation of a number.
Determinant And Inverse Matrix Calculator
Determinant and inverse of a square matrix, as exact fractions.