Polynomial Calculator - Roots, Factoring, Long Division

    Finds all roots of a polynomial with their multiplicity, factors it exactly, and divides, multiplies, adds or subtracts two polynomials, with synthetic division and P(a) shown row by row.

    Parameters

    Enter data for calculations

    Variable x, powers with ^

    Empty = roots and factoring

    Value of P(x) at this number

    Form progress0 / 1 fields

    💡 Fill in all required fields to unlock the calculate button

    Roots, factors and long division of any polynomial

    Type x^3 - 6x^2 + 11x - 6 and the answer comes back as (x - 1)(x - 2)(x - 3), with the roots 1, 2 and 3 listed in a table. This polynomial calculator finds every root with its multiplicity, factors the polynomial as far as exact arithmetic allows, and also divides, multiplies, adds and subtracts two polynomials. Division prints the quotient, the remainder and, when the divisor is linear, the full synthetic division table. Everything rational stays a fraction: a remainder of 15/2 is shown as 15/2, not 7.4999999.

    It accepts the notation you would write on paper. Multiplication signs can be left out (2x, 3(x - 1)), powers go after ^ or as ² and ³, fractions can sit in front of x (1/2x^2), and a product such as (x - 1)^3(x + 2)^2 is expanded before anything else happens. The degree can go up to 30.

    Four boxes, filled in order

    1. 1
      Polynomial P(x) - the polynomial you want to solve or the dividend. Use a period for decimals (0.5) and no thousands separators: a comma is rejected, because 1,000 would mean one thousand to some readers and one point zero to others.
    2. 2
      Operation - left empty, the calculator finds roots and factors. The other four choices (divide, multiply, add, subtract) need a second polynomial.
    3. 3
      Second polynomial D(x) - the divisor when you divide, the other operand otherwise. A divisor of degree 1, such as x - 2 or 2x + 1, also gets a synthetic division table and a line from the remainder theorem.
    4. 4
      Evaluate at x = - optional. A number such as 3, -1/2 or 1.5; the value P(x) is worked out by synthetic substitution, row by row. A result of 0 means the number is a root.

    Every result ends with a "Copy and paste" line in plain text (x^2 - 4x + 3), which you can drop straight back into the first box to keep going, for example to factor a quotient further.

    Long division or synthetic division: which one you are looking at

    Both give the same quotient and remainder. The table below shows where each one applies and what the calculator prints for it.

    PointLong divisionSynthetic division
    Divisor it handlesAny degree: x^2 + x, x^3 - 1Degree 1 only: x - a, or ax + b after rescaling
    What you write downWhole terms with xCoefficients only, one row
    Missing powersEasy to skip by mistakeMust be written as 0 (4x^3 - 2x + 7 is 4, 0, -2, 7)
    RemainderA polynomial of lower degree than the divisorOne number, the last entry, equal to P(a)
    Shown by the calculatorQuotient, remainder, P = D·Q + R and a checkAll of that plus the table and the remainder theorem line
    Use it whenThe divisor is quadratic or higherYou are testing a possible root or evaluating P(a)

    How the roots are found, shown on three polynomials

    The calculator first removes repeated factors (squarefree factorization), then tries every candidate from the rational root theorem: a rational root p/q in lowest terms must have p dividing the constant term and q dividing the leading coefficient. Each candidate is tested exactly, on fractions, and each hit is divided out. A quadratic left over is solved with the discriminant Δ = b² - 4ac. Anything of degree 3 or more with no rational root goes to a numeric method (Aberth-Ehrlich), and a Sturm sequence settles exactly how many of those roots are real.

    Example 1: 2x^4 - 3x^3 - 3x^2 + 7x - 3. Candidates are ±1, ±3, ±1/2 and ±3/2. Two of them work: -3/2 once and 1 three times, so P(x) = (2x + 3)(x - 1)³. The table lists 1 with multiplicity 3, and 1 + 3 = 4 matches the degree.
    Example 2: x^3 + 2x^2 - 4x - 3, also evaluated at x = 1.5. The only rational root is -3. Dividing it out leaves x^2 - x - 1 with Δ = 5, so the other two roots are 1/2 ± (1/2)√5, about -0.6180339887 and 1.618033989. Synthetic substitution at 3/2 runs 1, 7/2, 5/4 and ends at P(3/2) = -9/8 = -1.125.
    Example 3: 4x^3 - 2x + 7 divided by 2x + 1. The quotient is 2x² - x - 1/2 and the remainder 15/2. Synthetic division uses a = -1/2 and gives the row 4, -2, -1, 15/2; because the divisor has 2 in front of x, those first three numbers are divided by 2 to get the quotient. The remainder theorem agrees: P(-1/2) = 15/2.

    Some other results checked with the same engine:

    InputOperationResult
    x^2 - 2x - 1Roots1 ± √2, Δ = 8, about -0.4142135624 and 2.414213562
    x^2 + 4x + 13Roots-2 ± 3i, Δ = -36, no real factors
    (x-1)^3(x+2)^2RootsExpanded to x^5 + x^4 - 5x^3 - x^2 + 8x - 4; roots -2 (multiplicity 2) and 1 (multiplicity 3)
    x^5 - x - 1RootsOne real root, about 1.167303978, and two complex pairs
    2x^3 - 5x^2 + x + 2 and x - 2DivideQuotient 2x^2 - x - 1, remainder 0, so 2 is a root
    x^3 - 7x - 6 and x^2 + xDivideQuotient x - 1, remainder -6x - 6
    3x^2 - x + 4 and x^2 + 2Multiply3x^4 - x^3 + 10x^2 - 2x + 8

    Slips that give a wrong quotient or a missing root

    Dropping a zero coefficient in synthetic division. 4x^3 - 2x + 7 has no x² term, so the row must read 4, 0, -2, 7. Leave the 0 out and every later number shifts one place. The calculator always writes the zeros into the table.
    Forgetting the rescaling for 2x + 1. Synthetic division with a = -1/2 divides by x + 1/2, not by 2x + 1. The bottom row has to be halved to give the true quotient; the remainder stays the same.
    Counting a repeated root once. 2x^4 - 3x^3 - 3x^2 + 7x - 3 has only two distinct roots, but a degree-4 polynomial has four roots with multiplicity. The Multiplicity column is what makes the count come out right.
    Reading "no rational roots" as "does not factor". x^4 - 5x^2 + 6 has no rational root, yet it equals (x² - 2)(x² - 3). The calculator says so honestly in a note: for a factor of degree 4 or more it does not test for splits into rational quadratics, and shows the approximate real factorization instead.

    Polynomial questions students send in

    How many roots does a polynomial have?
    Exactly as many as its degree, counting complex roots and multiplicity. A cubic always has 3; at least one of them is real, because complex roots of a polynomial with real coefficients come in conjugate pairs. The first tile of the result shows that count.
    Why are some roots marked "approximation only"?
    Roots of a factor of degree 3 or higher with no rational root generally have no simple closed form (for degree 5 and up there is no general formula in radicals at all). The calculator prints them to about 10 significant digits. Rational roots and roots of quadratics are always exact.
    Can I type coefficients as decimals?
    Yes. 0.5x^2 - 0.125 is read as the fractions 1/2 and 1/8, so the result is exact: roots -1/2 and 1/2. Use a period as the decimal mark; a comma is rejected with a message.
    What does the remainder theorem line mean?
    The remainder after dividing P(x) by x - a equals P(a). For 2x^3 - 5x^2 + x + 2 and x - 2 that value is 0, which is the factor theorem: x - 2 divides P(x) exactly, and 2 is a root.
    Why is the derivative shown?
    A repeated root of P is also a root of P′, which is how repeated factors are separated before the root search. For x^3 - 6x^2 + 11x - 6 the derivative is 3x^2 - 12x + 11; its zeros are where the graph turns.

    Related tools

    Beaufort Scale Calculator

    Wind speed in mph, knots, km/h or m/s to its Beaufort force, wave height and hurricane category - See the calculator

    Dog Body Condition Score Calculator

    A 1-9 body score from ribs, waist and belly, with body fat and an ideal weight in lb - See the calculator

    Quadratic Equation Calculator

    Solves ax² + bx + c = 0 with the discriminant shown step by step - See the calculator

    Quadratic Function Calculator

    Vertex, zeros and the shape of a parabola - See the calculator

    Derivative Calculator

    Derivatives of any function with every rule named and the tangent line - See the calculator

    Binomial Expansion Calculator

    Expands (a + b)^n term by term with the binomial coefficients - See the calculator

    System of Equations Calculator

    Two or three linear equations solved by elimination, substitution or Cramer's rule - See the calculator

    Fraction Calculator

    Adds, subtracts, multiplies and divides fractions in lowest terms - See the calculator

    Similar calculators from this section