Partial fraction decomposition calculator

Enter a numerator and a denominator polynomial. The calculator divides first if the fraction is improper, factors the denominator, and solves for the partial fraction coefficients exactly — the step that comes before integrating a rational function or taking an inverse Laplace transform.

A polynomial in x, such as 3x + 5 or x^3 - 2x.
A polynomial in x. Typing it as a product, like (x + 1)(x^2 + 4), helps when it has no rational roots.
Partial fractions2/(x + 1) + 1/(x + 2)
Polynomial part (quotient)
0
Factored denominator
(x + 1)(x + 2)
Number of fractions
2

Runs in your browser: nothing you enter is sent anywhere.

How to use it

  1. Type the numerator and the denominator, for example 3x + 5 and (x + 1)(x + 2).
  2. Read the decomposition; a polynomial part appears first if the fraction was improper.

How it works

  1. If deg N ≥ deg D, divide: N / D = Q + R / D.
  2. Factor D over the rational numbers into linear factors and irreducible quadratics, with their multiplicities.
  3. Write one unknown term per factor and power: A / (ax + b)ᵏ for linear factors, (Bx + C) / (quadratic)ᵏ for quadratics.
  4. Multiply through by D and match the coefficients of each power of x. This gives a square linear system, solved exactly.

Worked example

(3x + 5) / ((x + 1)(x + 2)) = A / (x + 1) + B / (x + 2), so 3x + 5 = A(x + 2) + B(x + 1).

  • At x = −1: 2 = A, so A = 2.
  • At x = −2: −1 = −B, so B = 1.

Result: 2 / (x + 1) + 1 / (x + 2).

Tips

  • Check a result by adding the fractions back over a common denominator.
  • After decomposing, ∫ A / (x − r) dx = A ln|x − r|, and (Bx + C) / (x² + 1) splits into a logarithm and an arctangent.

Frequently asked questions

What is partial fraction decomposition?

Rewriting a fraction of polynomials as a sum of simpler fractions whose denominators are the factors of the original one. For example (3x + 5) / ((x + 1)(x + 2)) = 2 / (x + 1) + 1 / (x + 2). Each simple piece is easy to integrate.

What forms do the fractions take?

A linear factor (x − r) gives A / (x − r). A repeated factor (x − r)² gives A / (x − r) + B / (x − r)². An irreducible quadratic such as x² + 1 gives (Bx + C) / (x² + 1), and repeated quadratics get one term per power in the same way.

What if the numerator's degree is not lower than the denominator's?

Then the fraction is improper, and polynomial long division comes first. The quotient is shown as the polynomial part and the remainder is decomposed. For example (x³ + 1) / (x² − 1) = x + 1 / (x − 1).

How does the calculator factor the denominator?

It takes out powers of x, then tries every rational root p/q allowed by the rational root theorem, then splits off repeated factors with a greatest common divisor. What remains must be of degree 2 or less; otherwise type the denominator already factored.

Are the coefficients exact?

Yes. The unknowns are found by solving a linear system in exact fractions, so 1/(x² − 1) comes out as 1/(2(x − 1)) − 1/(2(x + 1)), not 0.5/(x − 1).

More in Math

All tools in this category: Math ·Updated November 4, 2026

Privacy choices

Google Analytics shows us which tools are used and whether they work. It may set cookies. Your choice is kept in this browser.