Partial Fraction Decomposition Calculator

Partial fractions break a rational function into a sum of simpler pieces, which is the key step before integrating or inverting a Laplace transform. This calculator handles a proper fraction (Nx + M) over (x - r1)(x - r2) with two distinct real roots, returning the constants A and B in A over (x - r1) plus B over (x - r2).

0.00
0.00
0.00
0.00

Decomposition formula

(Nx + M) / ((x - r1)(x - r2)) = A / (x - r1) + B / (x - r2)
A = (N * r1 + M) / (r1 - r2)
B = (N * r2 + M) / (r2 - r1)
Check: A + B = N

The cover-up method evaluates the numerator at each root divided by the other factor. The sum A plus B must equal the numerator's leading coefficient N, a useful consistency check.

Worked example

Decompose (3x + 5) over (x - 1)(x + 2), so r1 = 1 and r2 = minus 2. A = (3 times 1 plus 5) divided by (1 minus (minus 2)) = 8 divided by 3 = 2.6667. B = (3 times (minus 2) plus 5) divided by ((minus 2) minus 1) = (minus 1) divided by (minus 3) = 0.3333. Check: A plus B = 3 = N.

Partial fractions: frequently asked questions

What is partial fraction decomposition?

It rewrites a single rational function as a sum of simpler fractions, each with a linear or quadratic denominator. This makes integration, inverse Laplace transforms, and series expansion much easier. This calculator handles a proper fraction with two distinct real linear factors.

What form does this calculator solve?

It decomposes (Nx + M) divided by (x - r1)(x - r2) into A over (x - r1) plus B over (x - r2), where r1 and r2 are distinct real roots and the numerator is linear or constant, so the fraction is proper.

What is the cover-up method?

To find A, substitute x = r1 into the numerator divided by the remaining factor (x - r2). To find B, substitute x = r2 into the numerator divided by (x - r1). Formally A = (N*r1 + M) / (r1 - r2) and B = (N*r2 + M) / (r2 - r1).

What if the two roots are equal?

Equal roots give a repeated factor (x - r) squared, which needs a different form with terms A over (x - r) and B over (x - r) squared. This calculator requires distinct roots and returns not applicable when they coincide.

Sources

Reviewed by the CalculatorHub team, edited by James Graham, 19 June 2026. See our methodology.