Solution
Let
(x−1)2(x+2)x=x−1A+(x−1)2B+x+2C
Multiplying by (x−1)2(x+2),
x=A(x−1)(x+2)+B(x+2)+C(x−1)2
Putting x=1,
1=3B
Therefore,
B=31
Putting x=−2,
−2=9C
Therefore,
C=−92
Using A+C=0,
A=92
Hence,
(x−1)2(x+2)x=9(x−1)2+3(x−1)21−9(x+2)2
Integrating,
∫(x−1)2(x+2)xdx=92log∣x−1∣−3(x−1)1−92log∣x+2∣+C
Therefore,
∫(x−1)2(x+2)xdx=92logx+2x−1−3(x−1)1+C