In a bid to check my understanding I have this case: Decompose: $ \dfrac{x^4-8}{x^2+2x}$ Here I see it is an improper factions- degree of $x$ is higher on the numerator than on denominator. Using long division to divide, I get $$x^2-2x+4+ \dfrac{(-8x-8)}{x^2+2x}$$
this is also same as $$x^2-2x+4+ \dfrac{(-8x-8)}{x(x+2)}$$ How do I proceed to derived the decomposition template fraction?
Let the last fraction term be $\dfrac{A}{x}+\dfrac{B}{x+2}$, then
$$\begin{align} \frac{x^4-8}{x^2+2x} =& x^2 - 2x + 4 + \frac{-8x-8}{x^2+2x}\\ =& x^2 - 2x + 4 + \frac{A}{x}+\frac{B}{x+2}\\ =& x^2 - 2x + 4 + \frac{A(x+2)+Bx}{x(x+2)}\\ \end{align}$$
By comparing coefficients on the numerator of the fraction term, $$A=-4,\ B=-4$$
So $$\frac{x^4-8}{x^2+2x} = x^2 - 2x + 4 - \frac{4}{x} - \frac{4}{x+2}$$