What do you get when you differentiate a $e^{f(x)}$-like function I need help with exponential functions. I know that the derivative of $e^x$ is $e^x$, but wolfram alpha shows a different answer to my function below. If you, for example, take the derivative of $e^{-2x}$ do you get $-2e^{-2x}$ or $e^{-2x}$?

You have to use the chain rule here. Writing $f(x) = e^x$ and $g(x) = -2x$ we have $h(x) := f(g(x)) = e^{-2x}$, hence by the chain rule
$$ h'(x) = f'(g(x))g'(x) $$
Now $f'(x) = e^x$, hence $f'(g(x)) = e^{-2x}$, and $g'(x) = -2$, this gives
$$ h'(x) = f'(g(x))g'(x) = e^{-2x} \cdot (-2) = -2e^{-2x} $$ 
