Use the chain rule#(f(g(x)))'=f'(g(x)*g'(x)# to take the derivative of f(x) by starting from the outer most function while copying everything else inside the same then multiply by the derivative of the inside. Keep doing this until you get to the inner most function. Remember you cannot take derivatives of two functions at once it is one layer at a time.