How to use this solver
Type the equation the way it appears in your book or notes. Terms can be on both sides, brackets can stay unexpanded, and any letter can be the variable. For example, x(x + 1)(x + 2) = 120 or 2t³ = 5t − 1. The solver moves everything to one side, expands and collects like terms, and shows the standard form it actually solved. If you already have the coefficients, a list such as 1, 0, −4, 2 (highest power first) also works.
The answer lists every root with its multiplicity, a factored form, a table showing how each real root appears on the graph, and the full working. Roots are exact whenever they are whole numbers, fractions or square-root expressions. Anything that has to be estimated is marked ≈.
What a polynomial equation is
A polynomial equation sets a sum of terms like a·xⁿ, with whole-number powers, equal to zero. The highest power is the degree. Degree 1 is linear, 2 is quadratic, 3 is cubic, 4 is quartic and 5 is quintic. Expressions with x under a root, in a denominator or inside sin or ln are not polynomials, and they need different methods.
The fundamental theorem of algebra guarantees that a degree-n equation has exactly n roots, as long as you count complex roots and count a repeated root as many times as it repeats. That is why the solver always reports n roots in total, even when only some of them are real.
How the roots are found
The solver follows the order a careful student would use, and the working shows each stage.
- Standard form. Expand, collect terms and make one side zero. If every term contains x, factor out the highest common power, which gives the root 0.
- Rational root theorem. With whole-number coefficients, any fraction root p/q must have p dividing the constant term and q dividing the leading coefficient. That gives a short list of candidates to test. For 3x³ − 4x² − 17x + 6 = 0, the candidates are ±1, ±2, ±3, ±6, ±1/3 and ±2/3.
- Synthetic division. Each root found is divided out using a compact table of coefficients. That lowers the degree by one. In the example, dividing by the factor (3x − 1) leaves x² − x − 6, and dividing by (x + 2) leaves x − 3, so the roots are 1/3, −2 and 3.
- Quadratic formula. When a quadratic factor is left, its roots come from x = (−b ± √(b² − 4ac)) ÷ 2a. They stay in exact form, such as √2 or −1 ± i√3.
- Substitution. When a quartic has only even powers, such as x⁴ − 20x² + 64 = 0, it behaves like a quadratic. Put u = x², solve u² − 20u + 64 = 0 to get u = 4 or 16, then take square roots: x = ±2 or ±4.
- Numerical solving. Anything left with degree 3 or more and no rational roots is solved numerically. Exact formulas exist for cubics and quartics, but they produce long nested radicals that are rarely useful. For degree 5 and higher, no general formula in radicals exists at all. That was proved by Abel and Galois in the 1820s and 1830s.
Predicting the roots: Descartes’ rule of signs
Before any solving, the signs of the coefficients give a useful forecast. Count how often the sign changes as you read the coefficients of P(x) from the highest power down. The number of positive real roots equals that count, or is smaller by an even number. Do the same for P(−x) to count negative roots. For x⁵ − x − 1 there is one sign change, so there is exactly one positive real root. The solver finds it at about 1.1673.
Repeated roots and the graph
A root that appears more than once has multiplicity greater than one, and the graph shows it. At a root of odd multiplicity the curve crosses the x-axis. A triple root crosses but flattens out as it does. At a root of even multiplicity, such as the double root in (x − 3)², the curve touches the axis and turns back without crossing.
Complex roots never appear on the real graph. When the coefficients are real, they always come in conjugate pairs such as −1 + i√3 and −1 − i√3. So a cubic always has at least one real root, and the curve must cross the axis somewhere.
Checking the answer
Two checks are shown with every result. First, Vieta’s formulas: the roots of aₙxⁿ + aₙ₋₁xⁿ⁻¹ + … = 0 always add up to −aₙ₋₁ ÷ aₙ. Second, each root is substituted back into the polynomial. For exact roots the error is zero. For numerical roots it should be tiny, around 10⁻¹⁵.
Worked examples from real problems
A box with consecutive dimensions
A box measures x, x + 1 and x + 2 centimetres and holds 120 cm³. Type x(x + 1)(x + 2) = 120. The solver expands it to x³ + 3x² + 2x − 120 = 0, finds the rational root x = 4 and leaves x² + 7x + 30, whose roots are complex. The box is 4 cm × 5 cm × 6 cm. The complex roots are mathematically valid but have no physical meaning.
Cutting corners from a sheet
Squares of side x are cut from each corner of a 12 cm × 12 cm sheet and the sides are folded up. The volume is x(12 − 2x)², and for 128 cm³ the roots are x = 2 (a double root) and x = 8. Only x = 2 works, because the cut must be less than half of 12 cm. The double root means 128 cm³ is the largest volume possible: the graph just touches 128 at x = 2.
When does a model reach a target?
A model predicts f(t) = t³ − 9t² + 23t + 5. To find when it equals 20, type t³ − 9t² + 23t + 5 = 20. The solver moves the 20 across and finds t = 1, 3 and 5. Keep only the times that fall inside the range where your model was built.
Scaling a 3D object
If a model is enlarged so that its volume is 27 times larger, every length is multiplied by a factor x with x³ = 27. The real root is 3. The other two roots are complex, which tells you there is only one real scale factor.
Common mistakes
- Dividing both sides by x. That throws away the root x = 0. Factor x out instead.
- Forgetting a zero for a missing power when entering coefficients. For x³ − 4x + 2, the list is 1, 0, −4, 2, not 1, −4, 2.
- Stopping at the real roots. A cubic with one real root still has two complex roots.
- Counting a repeated root once when the question asks for all roots with multiplicity.
- Rounding an approximate root early and then using it in a further calculation.