Polynomial Division Calculator

Compute the quotient and remainder of \(P(x) / S(x)\) instantly

Overview

This interactive calculator performs polynomial long division. Enter a dividend \( P(x) \) and a nonzero divisor \( S(x) \), and the tool computes the quotient \( Q(x) \) and remainder \( R(x) \) in the identity

\[ \dfrac{P(x)}{S(x)} = Q(x) + \dfrac{R(x)}{S(x)} \]

where \( \deg(R) < \deg(S) \). This is exactly the form used to factor polynomials, apply the Factor and Remainder Theorems, and simplify rational expressions.

Interactive Division Calculator

Enter the dividend \( P(x) \) and divisor \( S(x) \) using +, -, *, ^, and parentheses. Example: 2*x^4 + x^3 + 2*x^2 - x - 7.





Worked Example

Divide \( P(x) = 2x^4 + x^3 + 2x^2 - x - 7 \) by \( S(x) = x^2 - 2x - 1 \).

Step-by-step solution

Step 1 — Divide the leading terms. The leading term of \(P\) is \(2x^4\); the leading term of \(S\) is \(x^2\). So the first quotient term is \(2x^4 / x^2 = 2x^2\).

Step 2 — Multiply and subtract.

\[ (x^2 - 2x - 1) \cdot 2x^2 = 2x^4 - 4x^3 - 2x^2 \] \[ P(x) - (2x^4 - 4x^3 - 2x^2) = 5x^3 + 4x^2 - x - 7 \]

Step 3 — Repeat. Divide \(5x^3 / x^2 = 5x\):

\[ (x^2 - 2x - 1) \cdot 5x = 5x^3 - 10x^2 - 5x \] \[ (5x^3 + 4x^2 - x - 7) - (5x^3 - 10x^2 - 5x) = 14x^2 + 4x - 7 \]

Step 4 — Repeat. Divide \(14x^2 / x^2 = 14\):

\[ (x^2 - 2x - 1) \cdot 14 = 14x^2 - 28x - 14 \] \[ (14x^2 + 4x - 7) - (14x^2 - 28x - 14) = 32x + 7 \]

Step 5 — Stop. The remainder \(32x + 7\) has degree 1, which is less than \(\deg(S) = 2\). Long division is finished.

Final answer:

\[ Q(x) = 2x^2 + 5x + 14, \qquad R(x) = 32x + 7 \] \[ \dfrac{2x^4 + x^3 + 2x^2 - x - 7}{x^2 - 2x - 1} = 2x^2 + 5x + 14 + \dfrac{32x + 7}{x^2 - 2x - 1} \]

Check: \((x^2 - 2x - 1)(2x^2 + 5x + 14) + (32x + 7)\) expands to \(2x^4 + x^3 + 2x^2 - x - 7\) ✓

Practice Exercises

Try these with the calculator above, then check the answers.

Exercise 1 — Divide \(x^3 - 1\) by \(x - 1\)

Answer
\[ Q(x) = x^2 + x + 1, \qquad R(x) = 0 \]

(This is the standard factorization \(x^3 - 1 = (x-1)(x^2+x+1)\).)

Exercise 2 — Divide \(3x^4 - 2x^3 + x - 5\) by \(x^2 + 1\)

Answer
\[ Q(x) = 3x^2 - 2x - 3, \qquad R(x) = 3x - 2 \]

(Check: \((x^2+1)(3x^2 - 2x - 3) + (3x-2)\) expands to \(3x^4 - 2x^3 + x - 5\) ✓)

Exercise 3 — Divide \(x^4 - 16\) by \(x - 2\)

Answer
\[ Q(x) = x^3 + 2x^2 + 4x + 8, \qquad R(x) = 0 \]

(This is the factorization \(x^4 - 16 = (x-2)(x^3 + 2x^2 + 4x + 8)\), part of the more complete \(x^4 - 16 = (x-2)(x+2)(x^2+4)\).)

Frequently Asked Questions

How do you divide polynomials?

Polynomial long division works like integer long division: repeatedly divide the leading term of the current remainder by the leading term of the divisor, subtract the resulting product, and repeat until the degree of the remainder is less than the degree of the divisor. The result is \(P(x)/S(x) = Q(x) + R(x)/S(x)\).

What is the degree of the remainder?

The remainder \(R(x)\) always has degree strictly less than the degree of the divisor \(S(x)\). If \(\deg(S) = 2\), then \(\deg(R) \le 1\) (or \(R = 0\)). This is what makes long division terminate.

What is the Remainder Theorem?

The Remainder Theorem says that when a polynomial \(P(x)\) is divided by \((x - c)\), the remainder equals \(P(c)\). This gives a fast way to evaluate \(P\) at a point and underlies the Factor Theorem.

What if the divisor is zero?

Division by the zero polynomial is undefined — the calculator will report an error if you enter \(0\) as the divisor.

More Tutorials and Practice

Last updated: October 17, 2026