The Derivative of x to the x to the x

A use case for logarithmic differentiation.

February 3, 2023

To find the derivative of xxxx^{x^x}, use logarithmic differentiation. In order to apply this technique, let the expression being differentiated equal yy:

y=xxxy = x^{x^x}.

Now take the natural logarithm of both sides:

lny=lnxxx\ln{y} = \ln x^{x^x}.

Use the properties of the logarithm to get

lny=xxlnx\ln{y} = x^x \ln x.

xxx^x is still problematic, so take the natural logarithm of both sides again:

ln(lny)=ln(xxlnx)\ln (\ln{y}) = \ln (x^x \ln x).

Using the properties of the logarithm once more, arrive at

ln(lny)=xlnx+ln(lnx)\ln (\ln{y}) = x \ln x + \ln (\ln x).

Take the derivative of both sides with respect to xx. Use the chain rule and the product rule. Simplify the equation, then solve it for dydx\frac{\textrm{d}y}{\textrm{d}x}. You’ll get

ddxln(lny)=ddx(xlnx+ln(lnx))1lny1ydydx=lnx+x1x+1lnx1x1lny1ydydx=lnx+1+1xlnxdydx=ylny(lnx+1+1xlnx). \begin{aligned} \frac{\textrm{d}}{\textrm{d}x} \ln (\ln{y}) &= \frac{\textrm{d}}{\textrm{d}x} (x \ln x + \ln (\ln x)) \\ \frac{1}{\ln y} \cdot \frac{1}{y} \cdot \frac{\textrm{d}y}{\textrm{d}x} &= \ln x + x \cdot \frac{1}{x} + \frac{1}{\ln x} \cdot \frac{1}{x} \\ \frac{1}{\ln y} \cdot \frac{1}{y} \cdot \frac{\textrm{d}y}{\textrm{d}x} &= \ln x + 1 + \frac{1}{x \ln x} \\ \frac{\textrm{d}y}{\textrm{d}x} &= y \ln y (\ln x + 1 + \frac{1}{x \ln x}). \\ \end{aligned}

We can make our result a bit more useful by substituting xxxx^{x^x} for yy. This produces

dydx=xxxlnxxx(lnx+1+1xlnx)=xxxxxlnx(lnx+1+1xlnx)=xxx+x(ln2x+lnx+1x). \begin{aligned} \frac{\textrm{d}y}{\textrm{d}x} &= x^{x^x} \ln x^{x^x} (\ln x + 1 + \frac{1}{x \ln x}) \\ &= x^{x^x} x^x \ln x (\ln x + 1 + \frac{1}{x \ln x}) \\ &= x^{x^x + x} (\ln^2 x + \ln x + \frac{1}{x}). \end{aligned}

© 2018–2023 Patrick Michalik

GitHubEmail