Problem 178
Easy Differentiation Techniques

Find y' for y = (sin x)^(cos x), where sin x > 0

Find $y'$ for $y = (\sin x)^{\cos x}$, where $\sin x \gt 0$.

Explanation of Method

Both base and exponent are trigonometric.

Step 1: Take the natural logarithm

\[ \ln y = \cos x\cdot\ln\sin x. \]

Step 2: Differentiate both sides

Product rule on the right, with $\bigl(\ln\sin x\bigr)' = \cot x$ from Problem 119: \[\frac{y'}{y} = -\sin x\cdot\ln\sin x + \cos x\cdot\frac{\cos x}{\sin x} = -\sin x\ln\sin x + \frac{\cos^{2}x}{\sin x}.\]

Step 3: Solve for $y'$

\[ y' = (\sin x)^{\cos x}\left(\frac{\cos^{2}x}{\sin x} - \sin x\ln\sin x\right). \]

Step 4: Verification

\[x = \frac{\pi}{2}:\quad \sin x = 1,\ \cos x = 0 \;\Longrightarrow\; y = 1^{0} = 1,\quad y' = 1\cdot(0 - 0) = 0 \;\;\checkmark\]

\[\frac{y(\pi/2+10^{-5})-y(\pi/2-10^{-5})}{2\times 10^{-5}} \approx 0 \;\;\checkmark\]

\[\text{General rule (Problem 176) with } u=\sin x,\ v=\cos x: \quad v u^{v-1}u' + u^{v}\ln u\cdot v' \;\;\checkmark\]


Result

Final answer:

\[\boxed{\,y' = (\sin x)^{\cos x}\left(\dfrac{\cos^{2}x}{\sin x} - \sin x\,\ln\sin x\right), \qquad \sin x > 0\,}\]

Remark

Remark. The condition $\sin x \gt 0$ is genuinely needed: for $\sin x \lt 0$ the expression $(\sin x)^{\cos x}$ is not real for most $x$, since a negative base raised to a non-integer power leaves the reals. The domain is therefore the union of intervals $(2k\pi,(2k+1)\pi)$, and $x = \tfrac{\pi}{2}+2k\pi$ is a maximum, where $y = 1$.