Partial Fraction Calculator
Partial Fraction Calculator with Steps
Split a proper rational function into partial fractions, with the real algebra shown step by step — free, in your browser, nothing uploaded. Supported scope, stated plainly: the denominator must be a product of distinct linear factors such as (x – 1)(x – 2). You enter the numerator and the root of each factor, and the tool finds each constant by the cover-up method.
The numerator’s degree must be lower than the number of factors (a proper fraction), and the roots must all be different. Two to four factors are supported.
Partial fractions is one of those topics that looks like a magic trick the first time a teacher does it. A single complicated fraction, such as (5x − 4) / ((x − 1)(x − 2)), is suddenly rewritten as −1/(x − 1) + 6/(x − 2), two far simpler fractions, and the rewrite turns out to be an exact identity, not an approximation. The trick matters because the simple fractions are dramatically easier to work with: each one integrates to a single logarithm, each one has a simple inverse Laplace transform, and each one can be expanded or manipulated in ways the combined fraction resists. A partial fraction calculator with steps does the decomposition for you, but — unlike a bare answer box — this one shows the real algebra: the substitution for each constant, the arithmetic of the other factors, and a numerical check at the end. Enter a numerator and the roots of your denominator's linear factors, and the calculator at the top of this page finds every constant by the cover-up method and lays out how.
Honesty about scope belongs at the front, not buried at the bottom. Partial fraction decomposition covers several cases, and this tool covers one of them completely and correctly: a proper fraction whose denominator factorises into distinct linear factors, such as (x − 1)(x − 2) or (x + 3)(x − 1)(x − 4). Repeated factors like (x − 1)², irreducible quadratic factors like (x² + 1), and improper fractions whose numerator degree is not below the denominator degree are different cases needing extra machinery, and this tool says so and stops rather than producing a confident wrong answer. If your problem is in the covered case — and a large share of textbook and integration problems are — you get exact constants with steps you can copy into your own working and adapt to the neighbouring cases by hand.
What It Is
A rational function is a fraction whose numerator and denominator are both polynomials. Partial fraction decomposition rewrites such a fraction, when the denominator factorises, as a sum of simpler fractions, one for each factor, each with a constant numerator in the distinct-linear case. The constants are what you solve for. Once found, the identity holds for every value of x except the roots of the denominator, where the original fraction is undefined. For (5x − 4) / ((x − 1)(x − 2)), the constants are −1 and 6, and you can verify the identity at any test value: at x = 5, the original is (25 − 4) / (4 × 3) = 21/12 = 1.75, and the parts give −1/4 + 6/3 = −0.25 + 2 = 1.75. The calculator performs exactly this kind of check on every problem, at a point chosen away from every root, and prints both sides so you can see them agree.
The cover-up method, also called the Heaviside cover-up method, is the fastest honest way to find the constants in the distinct-linear case, and it is what the tool uses. Here is the idea. Write the fraction as A/(x − 1) + B/(x − 2), multiply both sides by the full denominator, and you get 5x − 4 = A(x − 2) + B(x − 1), an identity in x. Now substitute x = 1: the B term vanishes because (x − 1) becomes zero, leaving 5 − 4 = A(1 − 2), so A = 1 / (−1) = −1. Substitute x = 2: the A term vanishes, leaving 10 − 4 = B(2 − 1), so B = 6 / 1 = 6. Each constant is the numerator evaluated at that factor's root, divided by the remaining factors evaluated at the same root. There is no system of equations to solve and no elimination to track; each substitution isolates one constant because the other factors were designed by algebra to disappear. The tool's steps print exactly these evaluations, with the numbers in place, for as many as four factors.
How to Use the Calculator
Using the tool takes less than a minute. Follow these steps:
- Enter the numerator's coefficients, highest power of x first, separated by commas. For 5x − 4, enter 5, -4. For a constant numerator like 7, enter 7. For x² + 3x + 1, enter 1, 3, 1. The live test uses 5, -4.
- Enter the root of each denominator factor, separated by commas. The factor (x − 1) has root 1; the factor (x + 3) has root −3; the factor x itself has root 0. The live test uses 1, 2 for the factors (x − 1)(x − 2).
- Check the two conditions the tool enforces: the roots must all be different (distinct linear factors), and the numerator's degree must be lower than the number of factors (a proper fraction). If either fails, the tool explains which condition failed instead of answering.
- Press "Find Partial Fractions" and read the decomposition, then the steps: for each constant, the numerator evaluated at that root, the other factors evaluated at the same root, and the division. Finally, read the numerical check comparing the original fraction with the sum of its parts at a test value of x.
If your numerator's degree is too high, divide the numerator by the denominator first — polynomial long division — and decompose the proper remainder; the article's limits section explains why the tool leaves that step to you.
What do you do with an improper fraction before decomposing it?
Divide first, then decompose only the proper remainder. Worked: x^2 / ((x-1)(x-2)). The denominator expands to x^2 - 3x + 2, so dividing x^2 by it gives quotient 1 and remainder 3x - 2. Decompose the remainder by cover-up: at root 1, (3(1)-2)=1 divided by (1-2)=-1 gives -1; at root 2, (3(2)-2)=4 divided by (2-1)=1 gives 4. Full result: 1 - 1/(x-1) + 4/(x-2). Check at x=0: the original is 0, and the parts give 1 + 1 - 2 = 0.
| Denominator form | Partial fraction template | What this tool does |
| distinct linear (x-a)(x-b) | A/(x-a) + B/(x-b) | covered, 2-4 factors |
| repeated linear (x-a)^2 | A/(x-a) + B/(x-a)^2 | not covered — cover-up alone gives only the squared-term constant |
| irreducible quadratic x^2+bx+c | (Bx+C)/(x^2+bx+c) | not covered — needs simultaneous equations |
| improper fraction | polynomial part + decomposition of the remainder | divide first, as above, then use this tool on the remainder |

Worked Examples
Example 1: (5x − 4) / ((x − 1)(x − 2)), the live test
Numerator coefficients 5, -4; roots 1, 2. For the first constant, substitute the root 1 into the numerator: P(1) = 5(1) − 4 = 1. Evaluate the other factor at 1: (1 − 2) = −1. So A = 1 / (−1) = −1. For the second constant, substitute 2: P(2) = 5(2) − 4 = 6. The other factor at 2: (2 − 1) = 1. So B = 6 / 1 = 6. Result: −1/(x − 1) + 6/(x − 2). The tool's check at x = 8.3 (chosen away from both roots) gives the original fraction as about 0.8154 and the sum of the parts as about 0.8154 — they agree. And this is the form you actually want downstream: integrated term by term, it becomes −ln|x − 1| + 6 ln|x − 2| + C, a result that would be painful to reach from the combined fraction directly.
Example 2: Three factors — 1 / ((x)(x − 1)(x − 2)) style problems
Take the fraction with constant numerator 1 and denominator factors x, (x − 1), (x − 2) — roots 0, 1, 2, entered as numerator 1 and roots 0, 1, 2. Cover-up for the root 0: P(0) = 1; other factors at 0: (0 − 1)(0 − 2) = (−1)(−2) = 2; constant = 1/2. Root 1: P(1) = 1; others at 1: (1)(1 − 2) = (1)(−1) = −1; constant = −1. Root 2: P(2) = 1; others at 2: (2)(2 − 1) = 2; constant = 1/2. Result: (1/2)/x − 1/(x − 1) + (1/2)/(x − 2). Three substitutions, three constants, no simultaneous equations — this is why the cover-up method is worth learning as a hand technique, and why the tool's steps mirror it exactly.
Example 3: A quadratic numerator — (x² + 1) / ((x − 1)(x − 2)(x − 3))
The numerator may have degree up to one less than the number of factors, so a quadratic numerator over three linear factors is fine. Roots 1, 2, 3; P(x) = x² + 1. At 1: P(1) = 2; other factors (1 − 2)(1 − 3) = (−1)(−2) = 2; constant = 1. At 2: P(2) = 5; others (2 − 1)(2 − 3) = (1)(−1) = −1; constant = −5. At 3: P(3) = 10; others (3 − 1)(3 − 2) = 2; constant = 5. Result: 1/(x − 1) − 5/(x − 2) + 5/(x − 3). Verify at x = 0: the original is 1 / ((−1)(−2)(−3)) = −1/6 ≈ −0.1667; the parts give 1/(−1) − 5/(−2) + 5/(−3) = −1 + 2.5 − 1.6667 = −0.1667. Agreement again — and notice the tool performs this same style of check automatically on your own numbers.
Example 4: Why the decomposition earns its keep — integration
Suppose you must integrate (5x − 4) / ((x − 1)(x − 2)). From the combined form, there is no direct rule. From the decomposed form of Example 1, each term is a constant over a linear factor, and the integral of k/(x − a) is k ln|x − a|. So the answer is −ln|x − 1| + 6 ln|x − 2| + C, in two lines. The same pattern powers inverse Laplace transforms in engineering, where each simple fraction corresponds to a standard time-domain term, and series expansions, where each part can be expanded separately. Partial fraction decomposition is a translation step: it changes nothing about the function's value, and everything about how easily you can proceed.
One more habit separates reliable work from hopeful work here: write the template before touching numbers. State the shape — A over the first factor, B over the second, and so on — with the actual factors from your denominator, and only then start substituting roots. Most student errors in partial fractions are not arithmetic at all; they come from solving for constants against a template that was never written down, losing track of which constant belongs to which factor, or dropping a factor when three or four are involved. The calculator's first step line prints the template for your problem for exactly this reason: copy that shape into your own notes, then follow its substitutions in order, and the bookkeeping problems largely disappear.
The Cases This Tool Does Not Cover, and What They Need
Three neighbouring cases appear in full courses, and naming them keeps you from misapplying the covered method. First, repeated linear factors: for (x − 1)² in the denominator, the decomposition needs both a term A/(x − 1) and a term B/(x − 1)², and the cover-up alone gives only the second constant directly; the rest needs a derivative trick or coefficient comparison. Second, irreducible quadratic factors: a factor like (x² + 1) that does not split into real linear factors takes a linear numerator, (Bx + C)/(x² + 1), and finding B and C needs equation-solving beyond substitutions. Third, improper fractions: if the numerator's degree equals or exceeds the denominator's, divide first; only the proper remainder decomposes. This tool rejects all three situations with a message identifying which one you are in, because the honest answer for an unsupported case is an explanation, not a number. Everything within its stated case, it solves exactly.
Common Mistakes
The first common mistake is a sign error on roots: the factor (x + 3) has root −3, not 3, and entering 3 decomposes a different fraction. The tool builds each factor from the root you enter, so double-check the sign against your denominator. The second mistake is trying to decompose an improper fraction directly; the constants from cover-up will not reproduce the original, which is why the tool checks degrees and refuses. The third mistake is applying cover-up to a repeated factor and expecting all constants at once — with (x − 1)², substitution at 1 yields only the constant over the squared term. The fourth mistake is forgetting the check: any decomposition can be verified by recombining over a common denominator or by testing a number, as the tool does, and skipping that step lets arithmetic slips survive into integrals and exams. The fifth mistake is treating the identity as valid at the roots themselves; at x = 1 or 2 in the live test, both sides are undefined, and the identity holds everywhere else.
Limits: What This Tool Does and Does Not Do
This tool decomposes proper rational functions whose denominators are products of two to four distinct linear factors with real roots, using the cover-up method, and shows the genuine substitution steps plus a numerical verification. It does not handle repeated factors, irreducible quadratic factors, improper fractions, denominators with more than four factors, or symbolic simplification of the result. Constants are shown to four decimal places when they are not whole, and the underlying computation is exact arithmetic on the numbers you enter, subject to ordinary rounding in display. Within its stated case, its steps are the real algebra, not a narration pasted over a hidden answer: each constant printed is the quotient of the two evaluations printed beside it.
Privacy: Your Numbers Stay in Your Browser
Every coefficient and root you enter into this partial fraction calculator stays in your browser. Nothing is uploaded to a server, nothing is stored, and there is no account to create. The calculation runs entirely on your own device, and closing the page removes your inputs. This browser-only design is the same principle behind the other free tools on Your Smart Kit: a simple tool that does one job well, keeps your data private, and gives an answer you can check.
Frequently Asked Questions
What is the cover-up method?
A way to find each partial fraction constant by substitution: to find the constant over the factor (x − r), evaluate the numerator at x = r and divide by the other denominator factors evaluated at x = r. Substituting r makes every other term vanish after multiplying through, which isolates that constant.
What does "proper fraction" mean here?
The numerator's degree is lower than the denominator's degree. (5x − 4) / ((x − 1)(x − 2)) is proper — degree 1 over degree 2. If the degrees are equal or the numerator's is higher, do polynomial division first and decompose the remainder.
How do I enter the factor (x + 3)?
By its root. (x + 3) is zero when x = −3, so enter −3 in the roots box. The tool displays the factor it understood, so you can confirm it reads (x + 3) before trusting the answer.
Can this calculator handle (x − 1) squared or (x squared plus 1) factors?
No, and it will tell you so. Repeated factors need an extra term and an extra step beyond cover-up; irreducible quadratics need a linear numerator and simultaneous equations. Both are stated plainly in the tool rather than answered incorrectly.
How can I check a partial fraction answer?
Two ways: recombine the parts over the common denominator and compare numerators, or test a number — pick any x that is not a root, evaluate the original and the parts, and compare. The tool does the numeric test automatically and prints both values.
Why do the steps show P(r) and the other factors separately?
Because that division is the entire method. Showing the numerator's value at the root and the product of the other factors at the root lets you verify each constant with two quick evaluations of your own, instead of taking the final constants on faith.
Related Tools on Your Smart Kit
If you found the partial fraction calculator with steps useful, you may also like the other free calculators on Your Smart Kit, including the polynomial root calculator for finding where a polynomial crosses zero, the linear equations in two variables calculator for solving pairs of equations with determinant steps, and the midpoint rule calculator for numeric integration with its full table of values. Each runs in your browser, free, with no sign-up, and each is built on the same principle: a simple tool that does one job well, keeps your data private, and gives an answer you can check. Try the partial fraction calculator at the top of this page with your own rational function, and follow the substitutions until the cover-up method feels like something you own.
