Thursday, December 4, 2014

A one variable application of the multivariable chain rule

In the last post the theme was using the one variable chain rule in place of the multivariable version. I wanted to relay a pretty cool trick that goes in the other direction. Suppose you want to differentiate $x^x$. You remember that $\frac{d}{dx} x^k=kx^{k-1}$ and $\frac{d}{dx}b^x=\ln b b^x$. Now think of $x^x=u^v$ where $u=v=x$. The chain rule now says
\begin{align*}
\frac{d}{dx} u^v&=(\ln u) u^v u_x+v u^{v-1}v_x\\
&=(\ln x) x^x+ x\, x^{x-1}\\
&=(\ln x+1)x^x
\end{align*}
And we get the right answer as if by magic. In general, you can take a derivative by isolating every occurrence of the variable $x$, then differentiating while thinking of all other occurrences as constant, and then adding up the results.

2 comments:

  1. Is the final result correct? I guess it should read $(\log x + 1)x^x$

    ReplyDelete