<s>[INST] Find the derivative using the chain rule and the quotient rule 
$$f(x) = \left(\frac{x}{x+1}\right)^4$$ Find $f'(x)$.

Here is my work:
$$f'(x) = \frac{4x^3\left(x+1\right)^4-4\left(x+1\right)^3x^4}{\left(x+1\right)^8}$$
$$f'(x) = \frac{4x^3\left(x+1\right)^4-4x^4\left(x+1\right)^3}{\left(x+1\right)^8}$$
I know the final simplified answer to be:
$${4x^3\over (x+1)^5}$$
How do I get to the final answer from my last step? Or have I done something wrong in my own work?
 [/INST] I usually try to avoid the quotient rule if possible.
$$ f(x) = \left(\frac{x}{x+1}\right)^4 = \left(\frac{x+1-1}{x+1}\right)^4 = \left(\frac{x+1}{x+1} + \frac{-1}{x+1}\right)^4 = \left(1 - \frac{1}{x+1}\right)^4 $$
Applying the chain rule yields
$$ f'(x) = 4 \cdot \left(1-\frac{1}{x+1}\right)^3 \cdot \frac{1}{(x+1)^2} = 4 \cdot \left(\frac{x}{x+1}\right)^3 \cdot \frac{1}{(x+1)^2} = 4 \cdot \frac{x^3}{(x+1)^3} \cdot \frac{1}{(x+1)^2} = \frac{4x^3}{(x+1)^5} $$
</s>