Limit from UPB exam book 2014 $$\lim_{x \to 0^{+}} (\sin x)^{\cos x}\left(\frac{\cos^{2}x}{\sin x} - \sin x\log(\sin x)\right)$$
The answer is one, but i dont know how to proceed in solving the problem.
 A: First note that instead of $x \to 0$ you must have $x \to 0^{+}$ otherwise both $\log\sin x$ and $(\sin x)^{\cos x}$ are undefined. The given expression can be expressed as $$(\sin x)^{\cos x - 1}\cos^{2}x - (\sin x)^{\cos x}\sin x\log\sin x$$ and limit of each term will be evaluated separately.
Now note that as $x \to 0^{+}$, $\cos x \to 1$ and $\log\sin x \to -\infty$ hence $\cos x \log \sin x \to -\infty$ and therefore $$(\sin x)^{\cos x} = \exp(\cos x \log \sin x) \to 0\tag{1}$$ Further note the standard result $$\lim_{t \to 0^{+}}t\log t = 0$$ and hence on putting $t = \sin x$ we get $$\lim_{x \to 0^{+}}\sin x \log \sin x = 0\tag{2}$$ It follows from $(1), (2)$ that $$\lim_{x \to 0^{+}}(\sin x)^{\cos x}\sin x\log \sin x = 0\tag{3}$$ We are now left with the term $$\lim_{x \to 0^{+}}(\sin x)^{\cos x - 1}\cos^{2}x$$ and since $\cos^{2}x \to 1$ we just need to calculate the limit of $(\sin x)^{\cos x - 1}$. This limit will be the final answer. Let it be $L$. Then
\begin{align}
\log L &= \log\lim_{x \to 0^{+}}(\sin x)^{\cos x - 1}\notag\\
&= \lim_{x \to 0^{+}}\log(\sin x)^{\cos x - 1}\text{ (by continuity of log)}\notag\\
&= \lim_{x \to 0^{+}}(\cos x - 1)\log\sin x\notag\\
&= \lim_{x \to 0^{+}}(\cos x - 1)\log\left(\frac{\sin x}{x}\cdot x\right)\notag\\
&= \lim_{x \to 0^{+}}(\cos x - 1)\log\left(\frac{\sin x}{x}\right) + (\cos x - 1)\log x\notag\\
&= 0\cdot \log 1 + \lim_{x \to 0^{+}}\frac{\cos^{2}x - 1}{\cos x + 1}\cdot\log x\notag\\
&= -\frac{1}{2}\lim_{x \to 0^{+}}\sin^{2}x\log x\notag\\
&= -\frac{1}{2}\lim_{x \to 0^{+}}\frac{\sin^{2}x}{x^{2}}\cdot x\cdot x\log x\notag\\
&= -\frac{1}{2}\cdot 1\cdot 0\cdot 0 = 0\notag
\end{align}
It follows that $L = e^{0} = 1$.
A: Denote the original expression by $I$, and make the substitution $t = \sin x$. Then
\begin{align*}
& \log I = \sqrt{1 - t^2}\log t + \log\left(\frac{1}{t} - t - t\log t\right) \\
= & \left(1 - \frac{1}{2}t^2 + o(t^2)\right)\log t + \log(1 - t^2 - t^2\log t) - \log t\\
= & \log t - \frac{1}{2}t^2 \log t + \log(1 - t^2 - t^2 \log t) - \log t + o(t^2\log t) \\
= & -\frac{1}{2}t^2\log t - \log(1 - t^2 - t^2\log t) + o(t^2\log t) \\
\to & 0
\end{align*}
as $t \to 0$. Hence $I \to 1$ as $t \to 0$.
During the calculation, we used the Taylor expansion of $\sqrt{1 + x}$, and the fact that $\lim\limits_{t \to 0} t^2 \log t = 0$.
A: $$\lim_{x\to 0 }x^{cos x-1}=1\\\lim_{x\to 0 }\frac{x^{cos x}}{x}=1\\ \xrightarrow[x \to 0]{sin x \approx  x} \lim_{x\to 0 }\frac{sin x^{cos x}}{x}=1 $$ name
 $u(x)=sinx ^{cos x}\\u'(x)=sinx ^{cos x} (\frac {cos^2x}{sinx}-sin x \ln sinx )$ 
now 
$$ \lim_{x\to 0 }\frac{sin x^{cos x}}{x}=1\\\lim_{x\to 0 }\frac{u(x)}{x}=\frac{0}{0}=1 $$ l'hosptial because ($\lim_{x\to 0 }sin x^{cos x}=0$ )
$$\lim_{x\to 0 }\frac{u(x)}{x}=\frac{U'(x)}{1}=1 \ \to \\ \lim_{x\to 0 }u'(x)=1 \\\lim_{x\to 0 }u'(x) =\lim_{x\to 0 }sinx ^{cos x}\\u'(x)=sinx ^{cos x} (\frac {cos^2x}{sinx}-sin x \ln sinx )=1 $$
