# Partial fraction when $N^r$ and $D^r$ are quadratic and cubic polynomials

I need to find the nth derivative of the following function $$y=\frac {x^2+4x+1}{x^3+2x^2-x-2}$$ The trouble is I don't know how to break a fraction like the above one. How do I break it into partial fractions? Or is there any other way to calculate it's nth derivative(leibnitz theorem?) without breaking it into partial fractions? Thanks in advance.

• As some intuition on how to break it up (as lab did), note that the coefficients of the denominator sum to $0$; thus there must be a factor of $(x - 1)$. – user61527 Nov 30 '13 at 6:39

As $x^3+2x^2-x-2=x^2(x+2)-1(x+2)=(x+2)(x^2-1)=(x+2)(x-1)(x+1)$

and the order of the numerator is less than that of denominator

$$\frac {x^2+4x+1}{x^3+2x^2-x-2}=\frac A{x+2}+\frac B{x-1} +\frac C{x+1}$$ where $A,B,C$ are arbitrary constants

Multiply either sides by $x^3+2x^2-x-2$ and compare the constants and the coefficients of the different powers of $x$ to determine $A,B,C$

Without breaking into partial fractions, the computation of any high order derivative will start to be a nightmare. I shall give you here a case I worked a few years ago : in the area of thermodynamics, I needed to compute the successive (up to several thousands) derivatives of a function containing terms such as 1 / (x^2 + a x + b). You can suppose that I did not do it without partial fractions. Using partial fractions, I took me almost one minute to define the derivative of my function for any order up to infinity. Always remember the partial fraction decomposition. Trust the old man !