   Question Answers

# Find $\dfrac{{dy}}{{dx}}$, when $y = {x^x} - {2^{\sin x}}$.

Hint: Let $u = {x^x}$ and $v = {2^{\sin x}}$. Take logarithm of u and v. Compute $\dfrac{{du}}{{dx}}$ and $\dfrac{{dv}}{{dx}}$.
Then use $\dfrac{{dy}}{{dx}} = \dfrac{{du}}{{dx}} - \dfrac{{dv}}{{dx}}$ to get the answer.

Complete step by step solution:
Given that $y = {x^x} - {2^{\sin x}}$
We have to find the derivative of y with respect to x.
Let$u = {x^x}$ and $v = {2^{\sin x}}$
Then $y = u - v$
We will first differentiate u and v with respect to x.
Now consider $u = {x^x}$.
Taking log on both the sides,
$\log u = \log {x^x} \\ \Rightarrow \log u = x\log x.......(1) \\$
Here we used the property of logarithm, $\log {a^b} = b\log a$
Differentiate (1) with respect to x on both the sides
$\dfrac{{d(\log u)}}{{dx}} = \dfrac{{d(x\log x)}}{{dx}} \\ \Rightarrow \dfrac{1}{u}\dfrac{{du}}{{dx}} = (x \times \dfrac{1}{x} + \log x \times 1) = 1 + \log x \\ \Rightarrow \dfrac{{du}}{{dx}} = u(1 + \log x) \\$
Now, substitute the value of u.
$\dfrac{{du}}{{dx}} = {x^x}(1 + \log x).....(A)$
Consider $v = {2^{\sin x}}$
Taking log on both the sides,
$\log v = \log ({2^{\sin x}}) \\ \Rightarrow \log v = \sin x(\log 2)......(2) \\$
Here $\log 2$is a constant.
Differentiate (2) with respect to x on both the sides
$\dfrac{{d(\log v)}}{{dx}} = \dfrac{{d(\sin x(\log 2))}}{{dx}} \\ \Rightarrow \dfrac{1}{v}\dfrac{{dv}}{{dx}} = \log 2\dfrac{{d(\sin x)}}{{dx}} = \log 2(\cos x) \\ \Rightarrow \dfrac{{dv}}{{dx}} = v(\log 2)(\cos x) \\$
Now, substitute the value of v.
$\dfrac{{dv}}{{dx}} = {2^{\sin x}}(\log 2)(\cos x)....(B)$
Now, $y = u - v$
Differentiate with respect to x on both the sides
$\dfrac{{dy}}{{dx}} = \dfrac{{du}}{{dx}} - \dfrac{{dv}}{{dx}}$
Using (A) and (B), we get
$\dfrac{{dy}}{{dx}} = {x^x}(1 + \log x) - {2^{\sin x}}(\log 2)(\cos x)$ which is the required answer.

Note: Whenever we have two functions given like in this question,make sure to find the derivative of each of the function and separately and then add/subtract both the derivatives.Do not solve it directly