# Finding Derivative of x^x

## Homework Statement

I've been challenging myself with finding tricky derivatives lately, and I'm stuck with this one. Does anyone have a good way to differentiate x^x? I tried the difference quotient and you used the concept of pascal's triangle to try to simplify terms such as (x+h)^(x+h) or (x+h)^x(x+h)^h and of course this got incredibly messy.

Another strange thing I'm finding is that when I use a derivative calculator online it shows: x^xlog(x)+x^x. However, when I use my ti-83 to test dy/dx at a given x value it's yielding a different value. I tried x=3, and according to the derivative calculator dy/dx should equal about 39.8. But my ti-83 shows 56.6 at x=3 when using dy/dx on the graph.

This isn't a homework problem. Sorry if I don't know how to approach the problem correctly.

## Answers and Replies

Try this:
notice that $$y=x^x \iff logy=logx^x=xlogx$$
and if you differentiate both sides you get $$\frac{y'}{y}=....$$
and from there it's simple algebra.

Fredrik
Staff Emeritus
Gold Member
Just a different way of saying what talolard said:

$$f(x)=x^x=e^{\log x^x}=e^{x\log x}$$

This little rewrite allows you to use the rules you're familiar with to find f'(x): How to find the derivative of an exponential, the chain rule, the product rule, how to find the derivative of a logarithm, and how to find the derivative of the identity function (i.e. "x").

Mentallic
Homework Helper
Using the definition of a derivative, we have $$lim_{h\rightarrow 0}\frac{(x+h)^{x+h}-x^x}{h}$$

And after using the binomial theorem and such, it turns into the indeterminate form 0/0. How do you go about solving this from first principles?

Last edited:
HallsofIvy
Homework Helper
You don't! That's why we have the "sum rule", "product rule", and other "rules of derivatives"- so we don't have to go back to "first principles" for every problem.

Mentallic
Homework Helper
So if I were to solve this from first principles just due to pure curiosity, I would have to prove the derivative rules first in order to do so?

So if I were to solve this from first principles just due to pure curiosity, I would have to prove the derivative rules first in order to do so?

You would have to start with the Peano axioms, and then get the rationals, the reals, etc...
It's quite a lengthy process!
:surprised

So if I were to solve this from first principles just due to pure curiosity, I would have to prove the derivative rules first in order to do so?

The formal method is to use the definition of taking the power of a number to a real number exponent, which is xr = exp(r*log x).
The exp function is defined as the inverse function to the log function, which is defined as
$$\log x = \int_1^x \frac{1}{t} dt$$
Thus, to find the derivative of the exp function, we just use the theorem about derivatives of inverse functions, which we derive from the definition of the inverse function together with the chain rule theorem. The chain rule theorem is derived directly from the definition of the derivative.
So in total, you would first start at the proof of the chain rule and if you really wanted to, plug in each step towards the exp function.

Fredrik
Staff Emeritus
Gold Member
You would have to start with the Peano axioms, and then get the rationals, the reals, etc...
It's quite a lengthy process!
Hey, that's cheating! The integers should be constructed from the ZFC axioms. :grumpy:

Hey, that's cheating! The integers should be constructed from the ZFC axioms. :grumpy:

I choose to reject AC, if that's possible...

So if I were to solve this from first principles just due to pure curiosity, I would have to prove the derivative rules first in order to do so?

Actually if you set it up as

ln(y) = x ln(x)

You would only have to prove the derivative of ln(x), product rule, and implicit differentiation.

You can prove d/dx ln(x) by setting up e^(lnx)=x and using implicit differentiation, and the derivative of e^x which is easily done with the difference quotient.

I'm now curious as to how the product rule is proven...

And if I'm not mistaken implicit differentiation is simply the chain rule? correct? Of course I haven't seen the chain rule proven either.

Mentallic
Homework Helper
You would have to start with the Peano axioms, and then get the rationals, the reals, etc...
It's quite a lengthy process!
:surprised
Hey, that's cheating! The integers should be constructed from the ZFC axioms. :grumpy:
I choose to reject AC, if that's possible...
Ok, ok, I get it

The formal method is to use the definition of taking the power of a number to a real number exponent, which is xr = exp(r*log x).
The exp function is defined as the inverse function to the log function, which is defined as
$$\log x = \int_1^x \frac{1}{t} dt$$
Thus, to find the derivative of the exp function, we just use the theorem about derivatives of inverse functions, which we derive from the definition of the inverse function together with the chain rule theorem. The chain rule theorem is derived directly from the definition of the derivative.
So in total, you would first start at the proof of the chain rule and if you really wanted to, plug in each step towards the exp function.
Thanks slider.

Hello, folks,

This is how you prove the product rule:

If $$f$$ and $$g$$ are differentiable at $$a$$, then exist the limits

$$f'(a)=\lim_{x\rightarrow a} \frac{f(x)-f(a)}{x-a}$$

and

$$g'(a)=\lim_{x\rightarrow a} \frac{g(x)-g(a)}{x-a}$$

We want to evaluate $$(fg)'(a)$$, that is,

$$\lim_{x\rightarrow a} \frac{(fg)(x)-(fg)(a)}{x-a}=\lim_{x\rightarrow a} \frac{f(x)g(x)-f(a)g(a)}{x-a}.$$

But we have

$$f(x)g(x)-f(a)g(a)=f(x)g(x)-f(a)g(x)+f(a)g(x)-f(a)g(a)=[f(x)-f(a)]g(x)+f(a)[g(x)-g(a)].$$

Therefore,

$$(fg)'(a)=\lim_{x\rightarrow a} \frac{f(x)-f(a)}{x-a}\cdot\lim_{x\rightarrow a}f(x)+f(a)\cdot\lim_{x\rightarrow a} \frac{g(x)-g(a)}{x-a}=f'(a)g(a)+f(a)g'(a),$$

where $$\lim_{x\rightarrow a}f(x)=f(a)$$ follows from the fact that $$f$$ is continuous at $$a$$ because it is differentiable at $$a$$.

Using the definition of a derivative, we have $$lim_{h\rightarrow 0}\frac{(x+h)^{x+h}-x^x}{h}$$

And after using the binomial theorem and such, it turns into the indeterminate form 0/0. How do you go about solving this from first principles?

Please tell us what is the expansion of $(x + h)^{x + h}$ up to $O(h)$!