StatGardenREF. DESK
Calculators/Maths/Partial fraction decomposition (2 factors)
Maths

Partial fraction decomposition (2 factors) calculator

Splits (ax+b)/((x−p)(x−q)) into simple fractions, including the repeated-root case.

Published 6 August 2026 · Updated 23 September 2026

What this calculator does

Partial fraction decomposition reverses adding fractions. A single expression over a product of factors becomes a sum of simpler fractions, each with one factor in its denominator, which is what makes it integrable.

The cover-up method makes it quick. For (x + 1) over (x − 1)(x − 2) the decomposition is −2.000 over (x − 1) plus 3.000 over (x − 2), found by substituting each root in turn.

The formula

Formulap≠q: A/(x−p)+B/(x−q), A=N(p)/(p−q), B=N(q)/(q−p); p=q: A/(x−p)+B/(x−p)², A=a, B=ap+b

For distinct roots, each numerator is the original numerator evaluated at that root, divided by the difference of the roots. A repeated root needs a different form with both a linear and a squared denominator.

TermMeaning
Partial fractionsA sum of simple fractions equivalent to one complicated one.
Cover-up methodFinding each numerator by substituting the corresponding root.
Repeated rootWhen both factors are the same, requiring a squared term in the decomposition.

The inputs explained

FieldWhat to enter
Numerator: coefficient of x (a)Coefficient of x in the numerator.
Numerator: constant (b)Constant term in the numerator.
Denominator root p (x−p)First denominator root, giving the factor (x − p).
Denominator root q (x−q)Second denominator root. Setting it equal to p gives the repeated-root case.

When to use it

Preparing an integral

Rational functions become integrable once split into partial fractions.

Inverse Laplace transforms

The standard method requires decomposing into recognisable pieces first.

Checking algebra

Recombining the fractions should return the original expression.

Worked examples

Every figure in the tables below is produced by this page’s own calculator at build time, so the numbers and the tool always agree. Select any row to load that scenario.

How do the numerators change with the roots?

The same numerator with three second roots.

Numerator x + 1, first root p = 1
Second root qAB
q = 11.0002.000
q = 2-2.0003.000
q = 4-0.66671.667
With q = 2 the decomposition is A = −2.000 and B = 3.000. Setting q = 1 makes the roots repeat, which switches to the squared form and gives A = 1.000 and B = 2.000 instead.

Questions

Why does a repeated root need a different form?

Because two copies of the same fraction would just add together into one, which cannot reproduce the original. The squared denominator supplies the extra independent piece the decomposition needs.

What is the cover-up method?

Substituting each root into the numerator while ignoring its own factor in the denominator. It works because that factor vanishes at its own root, leaving only one term, and it is considerably faster than equating coefficients.

What if the numerator degree is too high?

Divide first. Partial fractions require the numerator degree to be below the denominator degree, so a polynomial division step comes first and leaves a proper fraction to decompose.

What about irreducible quadratic factors?

They need a linear numerator rather than a constant, in the form (Ax + B) over the quadratic. This calculator handles the two-linear-factor case, which covers most introductory work.

For dividing polynomials, see the synthetic division calculator. For solving quadratics, see the quadratic calculator.