y=x^(cosx)
i thought the derivative was....
y'=ln(x)(x^cosx)(-sinx)
where did i go wrong?
thanks
$\displaystyle y=x^{\cos x}$
taking ln both side
$\displaystyle ln y= \cos x \ ln x$
$\displaystyle \frac{d(ln y)}{dx}= \frac{d(\cos x\ ln x)}{dx}$
$\displaystyle \frac{1}{y} \frac{dy}{dx}= \frac{1}{x} \cos x -ln x\ \sin x$
$\displaystyle \frac{dy}{dx}= y\left ( \frac{1}{x} \cos x - ln x \ \sin x \right )$
$\displaystyle \frac{dy}{dx}= x^{\cos x}\left ( \frac{1}{x} \cos x - ln x\ \sin x \right)$
$\displaystyle y=x^{cos(x)}$
Take the ln of both sides.
$\displaystyle ln(y)=cos(x)ln(x)$
Use implicit differentiation:
$\displaystyle \frac{1}{y}\frac{dy}{dx}=-sin(x)ln(x)+cos(x)\frac{1}{x}$
$\displaystyle \frac{dy}{dx}=-ysin(x)ln(x)+cos(x)\frac{1}{x}$
$\displaystyle =-x^{cos(x)}sin(x)ln(x)+x^{cos(x)}cos(x)\frac{1}{x}$