# Need help with converting $\frac{1}{(x-1)(x+2)^2}$ to partial fractions

So far I have my working ... I think I got wrong ... since after checking with http://calc101.com/webMathematica/partial-fractions.jsp#topdoit

$A = \frac{1}{9}$

$B = - \frac{1}{9}$

$C = - \frac{1}{3}$

Is there a better way to do this than simultaneous equations? Or any tips on how solving such problems ... in a recent exam, I find myself getting a ton of simultaneous equations like below (maybe I need to see "patterns" that make my lefe easier) and likely made careless mistakes within them

• See this answer for a closed formula for partial fraction decomposition. – Pierre-Yves Gaillard Oct 13 '11 at 13:11
• $(2)-(1)$ should be $0=3A+C$ instead of $0=3A-C$. – Américo Tavares Oct 13 '11 at 13:24

Once you get to the line with

$$1 = A(x+2)^2+ B(x-1)(x+2) + C(x-1)$$

You can try plugging in x values that simplify things a bunch to solve for the variables. For example, plugging in $x = 1$ or $x = -2$ leaves only one variable to solve for. This is not always possible, but it's a lot simpler than looking at the $x^2$ term and so on, when it is possible.

Plug in $x = -2$ and you get $1 = C(-3)$, so $C = -\frac{1}{3}$. Plug in $x = 1$ and you get $1 = 9A$, so $A = \frac{1}{9}$. Now, you know $A$ and $C$, so you can plug in any other value to get $B$, say, $x = 0$. That gives

$$1 = \frac{1}{9} \cdot 4 - 2B + \frac{1}{3}$$

which gives $B = -\frac{1}{9}$.

As mentioned, there is a sign error is in the calculation of $\:(2)-(1)\:.\:$ As for "better ways" here are a couple remarks. First, eliminate easy things first. Above you have $A + B = 0,\:$ so $B = -A$. Eliminating $B$ yields $\:3\:A + C = 0,\$ $6\:A-C = 1,\:$ which summed, yields $\:9\:A = 1\:.\:$ Now back-substituting yields $B,C\:.$ Notice how much easier the elimination is using this ordering strategy.

Second, there are well-known tricks that exploit the special structure enjoyed by systems of linear equations that arise from partial fraction decompositions, e.g. see Heaviside's cover-up method. Additionally see my post here which discusses nonlinear generalizations of this method.