Using the differentiation rules and the derivative table, find the derivative of the function y=(\sin x)^{\cos x}



y' = (\sin x)^{\cos x} \left( -\sin x \cdot \ln (\sin x) + \frac{\cos^2 x}{\sin x} \right)


We can use the identity y=e^{\ln y} valid for every y>0 to rewrite the function as

y = e^{\displaystyle\ln \big( (\sin x)^{\cos x} \big)}


Using the property of logarithms \ln(a^b) = b \ln(a), we get:

y = e^{\displaystyle\cos x \cdot \ln (\sin x)}


To calculate the derivative we can use the theorem of derivation of a composition.

  • Identify the outer function and the inner function

    We write

    y=e^{g(x)}\qquad \text{con}\qquad g(x)=\cos x \cdot \ln (\sin x). 


    From the Chain Rule we then get that

    y' = e^{g(x)}\cdot g'(x)


  • Calculate the derivative of g

    We use the Product Rule:

    \frac{d}{dx} [\cos x \cdot \ln (\sin x)]= \frac{d}{dx} [\cos x] \cdot \ln (\sin x) + \cos x \cdot \frac{d}{dx} [\ln (\sin x)]


    The derivative of \cos x is -\sin x, so:

    \frac{d}{dx} [\cos x] \cdot \ln (\sin x) = -\sin x \cdot \ln (\sin x)


    The derivative of \ln (\sin x) is calculated with the Chain Rule: derivative of the outer function (i.e. \ln(\cdot)) calculated at the inner function \sin x, for the derivative of \sin x:

    \frac{d}{dx} [\ln (\sin x)] = \frac{1}{\sin x} \cdot \cos x = \frac{\cos x}{\sin x}


    Therefore:

    \cos x \cdot \frac{d}{dx} [\ln (\sin x)] = \frac{\cos^2x}{\sin x} 


    Putting the terms together:

    \frac{d}{dx} g(x)= -\sin x \cdot \ln (\sin x) + \frac{\cos^2x}{\sin x}


  • Replace g and g' in the Chain Rule


  • y' = e^{\cos x\cdot \ln(\sin x)} \left( -\sin x \cdot \ln (\sin x) + \frac{\cos^2 x}{\sin x}\right)


    Remembering that e^{\cos x\cdot \ln(\sin x)}= (\sin x)^{\cos x}, we get the final result:


    y' = (\sin x)^{\cos x} \left( -\sin x \cdot \ln (\sin x) + \frac{\cos^2 x}{\sin x} \right)