I've looked everywhere!
There has to be a special rule for finding the derivative of (x^x), because (x^x) is not an exponential expression, is it constant? No... can't be....
gaah! Anyone good with math/calc help me!
I've looked everywhere!
There has to be a special rule for finding the derivative of (x^x), because (x^x) is not an exponential expression, is it constant? No... can't be....
gaah! Anyone good with math/calc help me!
This isn't homework BTW; I'm working on some calculus algorithms
the derivative of (x^x) is (ln(x) + 1) * x^x
why? my calculator told me so.
That doesn't help... I got the same thing on my calculator; I need to be able to get there, I cannot find any forumals, proof, identities... ANYTHING that helps me grrrr... this bites
let's start off at the basics
hmm...
the derivative of a*n^r == a*r*n^(r-1)
however, 1 * x^x == 1 * x * x^(x-1) == 1 * x^x
hmm...
maybe this will help
http://members.lycos.co.uk/kgsfs/xpwrx.html
//edit: here's the definite solution:
http://mathforum.org/library/drmath/view/53419.html
Ahh good 'ol calculus...
had to whip out my stuff from last year, but here you go: (It's called logarithmic differentiation, btw)
y = x^x
take natural log of both sides
ln(y) = x*ln(x) < - this last part is a property of logarithms
now take the derivative of both sides...
(dy/dx)*ln(y) = (dy/dx)(x*ln(x))
because taking the derivative of y gives dy/dx....
(1/y)*(dy/dx) = 1*ln(x) + x*(1/x) < - product rule
(1/y)*(dy/dx) = ln(x) + 1 <- just simplified the right side...
multiply both sides by y...
(dy/dx) = y(ln(x) + 1)
and since we know y = x^x...
(dy/dx) = x^x * (ln(x) + 1)
and voila.
I don't know how that would be programmed easily, but thats how you get there..
That gives an approximated numerical derivative... (like a calculator gives) perhaps not what he needs?
[edit]
and that drmath explanation.. kinda stinks. He is making it overly complicated by doing e^(log(x^x))...
thanks guys... I figured it out before I checked back here.
I just need to build a math function for the special case of (x^x) because it is neither a power expression nor an exponential expression...
(d/dx)[x^x] = [(ln(x)+1)(x^x)] works great!