# Partial fraction decomposition solver

Splits a ratio of polynomials into partial fractions, checking their sum.

- Page: https://www.acalculator.org/math/partial-fraction-calculator
- JSON spec: https://www.acalculator.org/math/partial-fraction-calculator.json
- Version: 22742e792e29

## Default answer

Example with the default inputs (Rational function (3x + 2)/(x^3 - x^2 - 2x)): The partial fraction decomposition of (3x + 2)/(x^3 - x^2 - 2x) is 4/(3 (x - 2)) - 1/(3 (x + 1)) - 1/x.

## Inputs

| Key | Label | Description |
| --- | --- | --- |
| f | Rational function | A ratio of two polynomials in one letter. |

## Outputs

| Key | Label | Description |
| --- | --- | --- |
| decomposition | Partial fractions | The same function as a sum of simpler fractions. |

## Method

A computer algebra system finds the partial fractions; they show only when their sum equals the fraction at 20 points.

## Assumptions

- The denominator is factored over the rationals.
- An answer that fails its check is not shown.

## Worked examples

1. f = (3x + 2)/(x^3 - x^2 - 2x) gives decomposition = 4/(3 (x - 2)) - 1/(3 (x + 1)) - 1/x. Source: OpenStax Calculus Vol. 2, 3.4, Ex. 3.29. https://openstax.org/books/calculus-volume-2/pages/3-4-partial-fractions.
2. f = (x^2 + 3x + 1)/(x^2 - 4) gives decomposition = 1 + 1/(4 (x + 2)) + 11/(4 (x - 2)).
3. f = (2x - 3)/(x (x^2 + 1)) gives decomposition = (3x + 2)/(x^2 + 1) - 3/x.

## FAQ

### What is partial fraction decomposition?

Writing a ratio of polynomials P(x)/Q(x) as a sum of simpler fractions, one for each factor of the denominator Q. For example (3x + 2)/(x³ − x² − 2x) = −1/x + (4/3)/(x − 2) − (1/3)/(x + 1). It reverses adding fractions over a common denominator.

### Why is it used?

Mostly to integrate rational functions: each simple fraction has a standard integral. ∫ 1/(x − 2) dx = ln|x − 2| + C, while the original fraction has no obvious antiderivative. It is also used for inverse Laplace transforms and to sum some series.

### What if the top has a higher degree than the bottom?

Then the fraction is improper, and a polynomial part comes first, found by long division. (x² + 3x + 1)/(x² − 4) = 1 + (3x + 5)/(x² − 4), and the remainder then splits into 1/(4(x + 2)) + 11/(4(x − 2)).

### What happens with a repeated or quadratic factor?

A repeated linear factor (x − a)ᵏ gets one fraction for each power from 1 to k: A/(x − a) + B/(x − a)² + …. A quadratic factor with no real root, such as x² + 1, gets a fraction with a linear top: (Bx + C)/(x² + 1).

### Why is x² − 2 in my denominator not split?

The denominator is factored over the rational numbers. x² − 2 = (x − √2)(x + √2) needs √2, so it stays whole and is treated like x² + 1, with a linear numerator.

### What does "No verified answer" mean?

The fractions are added back up, in effect: the page compares their sum with your function at 20 points. If they differ, if no decomposition is found, or if the work takes over 3 seconds, the page says "No verified answer" instead.

## Sources

- OpenStax, Calculus Volume 2, section 3.4 Partial Fractions: https://openstax.org/books/calculus-volume-2/pages/3-4-partial-fractions
- OpenStax, College Algebra 2e, section 7.6 Partial Fractions: https://openstax.org/books/college-algebra-2e/pages/7-6-partial-fractions
