Skip to content
MasterMath

Polynomial Factoring Calculator

Factors a polynomial with integer coefficients by finding its rational roots and dividing by each one.

Factored polynomial

—

Factored polynomial—
Original polynomial—
Roots—
Degree—
What is left—

How it was solved

    The formula

    if p/q is a root, p divides the constant term and q the leading coefficient

    Why it works

    Factoring a polynomial means finding its roots, because every root r gives a factor (x − r). The trouble is that there are infinitely many candidates, and that is where the rational root theorem comes in: if the polynomial has integer coefficients and a root p/q in lowest terms, then p divides the constant term and q the leading coefficient. That turns infinitely many possibilities into a short list you can test one by one. Each root found lowers the degree by synthetic division, and the process repeats until a quadratic is left, which the formula finishes off.

    How to solve it by hand

    1. Take out the common factor of the coefficients and any powers of x you can
    2. List the divisors of the constant term and of the leading coefficient
    3. Test each quotient of the first by the second, with both signs
    4. Every root that makes the polynomial vanish is divided out, lowering the degree

    What is worth knowing

    The theorem only finds rational roots, so a polynomial like x² − 2 will not factor this way even though it has real roots: they are irrational, and the candidate list does not contain them. When that happens this page says so rather than handing you an approximate decimal dressed up as an exact factorisation. And mind the order of the coefficients: they run from the highest degree down, and you have to write the zeros of any missing terms, because «1, 0, -4» is x² − 4 while «1, -4» is x − 4, which have nothing to do with each other.

    Frequently asked questions

    How do you factor a polynomial?

    By finding its rational roots with the rational root theorem and dividing by each one you find.

    What if it has no rational roots?

    Then it does not factor over the integers. It may have irrational or complex roots, but this method will not find them.

    How do I write the coefficients?

    Highest degree first, including zeros: x² − 4 is «1, 0, -4».

    What about repeated roots?

    They come up twice when dividing, and the factor appears squared. The calculator counts the multiplicity.