Proving an inequality of trigonometric functions I am trying to prove that $$(\cos x)^{\cos x} > (\sin x)^{\sin x}$$ for $x \in \left(0, \frac{\pi}{4}\right)$.
I have plotted the graph of $y=(\cos x)^{\cos x} - (\sin x)^{\sin x}$ and see that my conjecture is supported.
Therefore, I tried to prove an equivalent statement $$ \cos x  \ln  \cos x> \sin x \ln \sin x$$.
I tried to use Calculus to prove the statement.
Let $$f(x)= \cos x  \ln  \cos x-\sin x \ln \sin x$$
then $$f'(x)=-\sin x\ln \cos x -\cos x \ln \sin x -\sin x - \cos x.$$
From here I don't know how to proceed.
Any help to prove the inequality will be much appreciated!
 A: We need to prove that $f(x)>0$, where
$$f(x)=x\ln{x}-\frac{1}{2}\sqrt{1-x^2}\ln(1-x^2)$$
for $\frac{1}{\sqrt2}<x<1$.
Indeed, $$f'(x)=\ln{x}+1+\frac{x}{2\sqrt{1-x^2}}\left(2+\ln(1-x^2)\right);$$
$$f''(x)=\frac{x\ln(1-x^2)+2(1-x^2)(x+\sqrt{1-x^2})}{2x\sqrt{(1-x^2)^3}}.$$
Let $$g(x)=\ln(1-x^2)+\frac{2(1-x^2)\left(x+\sqrt{1-x^2}\right)}{x}.$$
Thus, $$g'(x)=-\frac{2x}{1-x^2}-2\sqrt{1-x^2}\left(2+\frac{1}{x^2}\right)-4x<0.$$
$\lim\limits_{x\rightarrow1^-}f''(x)=-\infty$ and $f''\left(\frac{1}{\sqrt2}\right)>0$, 
which says that there is unique $x_1\in\left(\frac{1}{\sqrt2},1\right)$, for which $f''=0$.
Indeed, $x_1=0.8197...$ and in this point we have a maximum of $f'$.
We have $f'\left(\frac{1}{\sqrt2}\right)>0$, which says that on $\left[\frac{1}{\sqrt2},x_1\right]$ $f'$ increasing. Also $f\left(\frac{1}{\sqrt2}\right)=0$.
Thus, our inequality is proven for $\frac{1}{\sqrt2}<x\leq x_1$.
But on $\left[x_1,1\right)$ $f$ is a concave function, $f(x_1)=0.156...>0$ and $\lim\limits_{x\rightarrow1^-}f(x)=0$,
which ends the proof.
A: Thanks for the suggestion of Marty Cohen.
Here is my work.
Let $u=\cos x$. 
Then $\sin x = \sqrt{1-u^2}$ and $u \in (\sqrt{2}/2,1)$ for $x \in (0, \pi/4)$
We need to prove $u^u > \sqrt{1-u^2}^{\sqrt{1-u^2}}$, or equivalently $u \ln u > \frac{ \sqrt{1-u^2}} 2 \ln (1-u^2)$
$$\sqrt{2}/2 < u <1 \implies \frac 12 < u^2 < 1 \implies 0 < 1-u^2 < \frac 12 $$
Therefore, $ 0 < \frac {\sqrt{1-u^2}}2 < \frac 1{2\sqrt{2}}=\sqrt{2}/4$, and we have $\sqrt{2}/2<u<1$
Thus, $$0< \frac {\sqrt{1-u^2}}2 <u---(1)$$
Besides, $0<1-u^2 <\frac 12 < \sqrt {2}/2 < u <1$
so we have $$\ln (1-u^2) < \ln u<0---(2)$$
(1) and (2) implies $$u \ln u > \frac {\sqrt{1-u^2}}2\ln (1-u^2)$$
A: [This proof is messy. There are some computations done with calculators, I will try to double-check for any errors, but I believe the overall idea should work]
Note that $\cos x \gt \sin x$ for $x \in (0, \pi / 4)$.
Also note that $x^x$ is a strictly increasing function on the interval $[1/e, \infty)$ and strictly decreasing on the interval $(0, 1/e]$, where $e$ is Euler's constant.
The following cases need to be considered:


*

*$1/e \leq \sin x \lt \cos x$

*$\sin x \leq 1/e \lt \cos x$

*$\sin x \lt 1/e \leq \cos x$

*$\sin x \lt \cos x \leq 1/e$


Case (1) shows that $(\cos x)^{\cos x} \gt (\sin x)^{\sin x}$ since $\cos x \gt \sin x$ and they end up in the interval where $x^x$ is strictly increasing.
Case (4) is impossible because it would imply $\cos^2 x + \sin^2 x \lt 2/e^2 \lt 1$.
Cases (2) and (3) require more detailed estimates.
First observe that if $\sin x \leq 1/e$ then $\cos x \geq \sqrt{1 - 1/e^2} \gt 0.9$ and thus in order for $(\sin x)^{\sin x} \geq (\cos x)^{\cos x} \gt 0.9$ we need $\sin x \lt 0.04$.
From now on we will replace $\sin x$ by $x$ and $\cos x$ by $\sqrt{1 - x^2}$, and assume $x \lt 0.04$.
Let $F_1(y)$ be the solution of $x^x = y$ with $0 \lt x \leq 1/e$ and $F_2(y)$ be the solution with $x \geq 1/e$. Note that this is well-defined because $x^x$ is strictly monotonic on those intervals.
We also note that $x^x$ is a convex function (because $\log(x^x) = x\log x$ is convex because its derivative is $1 + \log x$ and its second derivative is $1/x \gt 0$). This means that it lies below any secant line through two distinct points, and above any tangent line at a point.
Therefore on the interval $(0, 0.04)$ we have $x^x \lt \left((0.04)^{0.04}-1\right)25x + 1 \lt -3x + 1$ and for any $0 \lt x \lt 1$ we have $x^x \gt x$.
What I've done here is find the secant line passing through $(0, 1)$ and $(0.04, (0.04)^{0.04})$ and the tangent line at $(1, 1)$.
Therefore on $x \in (0, 0.04)$ we have $y \lt -3x + 1$ and thus $x \lt (1 - y)/3$, so $F_1(y) \lt (1 - y)/3$.
On $(1/e, 1)$ we have $y \gt x$ and therefore $F_2(y) \lt y$.
Combining the inequalities, we find that $F_1(y) \lt (1 - F_2(y))/3$ for any $y$ such that $F_1(y) \lt 0.04$.
In order to have $x^x \geq \sqrt{1 - x^2}^{\sqrt{1 - x^2}}$ with $0 \lt x \leq 0.04$, we need $x \leq F_1\left(\sqrt{1 - x^2}^{\sqrt{1 - x^2}}\right) \lt \frac{1}{3}\left(1 - F_2\left(\sqrt{1 - x^2}^{\sqrt{1 - x^2}}\right)\right) = \frac{1}{3}\left(1 - \sqrt{1 - x^2}\right)$.
Note that the second inequality should be valid because when $x \lt 0.04$, $\sqrt{1 - x^2}^{\sqrt{1 - x^2}} \gt 0.999$ and $F_1\left(\sqrt{1 - x^2}^{\sqrt{1 - x^2}}\right) \lt F_1(0.999) \lt 0.04$.
This means $1 - 3x \gt \sqrt{1 - x^2}$ and thus $1 - 6x + 9x^2 \gt 1 - x^2$ and so $10x^2 - 6x \gt 0$ and finally $x \gt 0.6$. This contradicts the constraint $x \lt 0.04$ and we are done.
A: (sin x + cos x)^cos x   =  sin x^cos x + cos x^cos x + P1( sin x, cos x)
(sin x + sin x) ^sin x  = sin x^sin x + cos x^sin x +  P2( sin x, cos x)
Where P1 and P2 are polynomials with factors sin x and cos x.
But cos x > sin x in range 0 < x <   π /4 , therefore:
(sin x + cos x)^cos x  >  (sin x + sin x) ^sin x;
⇒ sin x^cos x + cos x^cos x + P1( sin x, cos x) >  sin x^sin x + cos x^sin x 


*

*P2( sin x, cos x)


⇒  cos x^cos x  > sin x^sin x + cos x^sin x - sin x^cos x + P2(sin x, cos x) - P1( sin x, cos x) 
Lim (cos x^sin x - sin x^cos x ) =1 when x    →  0
Lim(cos x^sin x - sin x^cos x ) = 0 when  x   →   π /4
⇒  0 < (cos x^sin x - sin x^cos x ) < 1 in range 0 < x <   π /4 
Lim [ P2( sin x, cos x) - P1( sin x, cos x) ] = 0 when x  →  0
Lim [ P2( sin x, cos x) - P1( sin x, cos x) ] = 0 when x  →   π /4
⇒  [ P2( sin x, cos x) - P1( sin x, cos x) ]   ≈   0 in range  0 < x <  π /4 
Therefore :in range  0 < x <  π /4,  cos x^cos x  >   sin x^sin x 
