Sum of real solutions on equation $\sqrt{\sin^2{x} + {1 \over 2}} + \sqrt{\cos^2{x} + {1 \over 2}} = 2$ in interval $[0,2\pi]$ is? I know that solution is $4\pi$ but I do not know how do they get to this solution. I always get that $x \in R$ and that  $-1 < \cos 2x < 1$ when converting it to double angle.
EDIT : So ok, I tried to do this and at the end I get that $\sin^2{2x} = 1$ which when I solve I get that solutions are $2x = {\pi\over2}$ and $2x = {3\pi\over2}$ but when I sum up these two I get that result is $\pi$, which is not the solution by my booklet $(4\pi)$. 
 A: Let $t=\cos^2x$. Then, we have$$\begin{align}\sqrt{1-t+\frac 12}=2-\sqrt{t+\frac 12}&\Rightarrow 1-t+\frac 12=4-4\sqrt{t+\frac 12}+t+\frac 12\\&\Rightarrow 4\sqrt{t+\frac 12}=2t+3\\&\Rightarrow 16\left(t+\frac 12\right)=4t^2+12t+9\\&\Rightarrow (2t-1)^2=0\\&\Rightarrow t=\frac 12\end{align}$$
If $\cos^2x=\frac 12$, then we have $\sin^2x=\frac 12$. So, it is sufficient.
A: Square everything to get
$$
\begin{align}
4&=\left(\sqrt{\sin^2(x)+\tfrac12}+\sqrt{\cos^2(x)+\tfrac12}\right)^2\\
&=2+2\sqrt{\tfrac34+\sin^2(x)\cos^2(x)}
\end{align}
$$
Since the sum of square roots is positive, we have not added any solutions. Therefore, we get
$$
\begin{align}
\tfrac14&=\sin^2(x)\cos^2(x)\\
1&=\sin^2(2x)
\end{align}
$$
The rest is pretty straightforward.
A: Using the Cauchy-Schwarz inequality. which states that for any 2 vectors $( a, b )$ and $( c, d )$ with $a,b,c,d \ge 0$:
$$(ac + bd)^2 \le (a^2 + b^2)(c^2 + d^2) $$
Let $a = \sqrt{\sin^2 x + \frac{1}{2}}$, $b = \sqrt{\cos^2 x + \frac{1}{2}}$ and $c = d = 1$ we have
$$ \left(\sqrt{\sin^2 x + \frac{1}{2}} + \sqrt{\cos^2 x + \frac{1}{2}}\right)^2 \le \left( \sin^2 x + \frac{1}{2} + \cos^2 x + \frac{1}{2}\right)(1^2+1^2) = 4 $$
or 
$$ \sqrt{\sin^2 x + \frac{1}{2}} + \sqrt{\cos^2 x + \frac{1}{2}} \le 2 $$
The equality happens only when $\frac{a}{c} = \frac{b}{d}$, or $\sin^2 x = \cos^2 x = \frac{1}{2}$. That's 4 solutions on the interval $[0, 2\pi]$
A: The function
$$ f(x) = \sqrt{\frac{1}{2}+\sin^2 x}+\sqrt{\frac{1}{2}+\cos^2 x}$$
is symmetric with respect to the point $x=\pi$, i.e. $f(x+\pi)=(x-\pi)$, hence the sum of the roots of $f(x)-2$ is just $\pi$ times the number of the roots in $[0,2\pi]$. Are you able to find such number?
A: We can parametrize $\sin^2 x$ and $\cos^2 x$ as $1/2 - c(t)$ and $1/2 + c(t)$ with $c(t) \in [-\frac{1}{2}, \frac{1}{2}]$ and $t \in [0, 2\pi]$. 
So we have $$\sqrt{1 - c(t)} + \sqrt{1 + c(t)} = 2$$  
One can verify through calculus or other methods that the left hand side has a maximum of $2$ at $c(t) = 0$ and thus the only viable solutions are when $c(t) = 0$. Thus, we wish to find the sum of the values of $x \in [0, 2\pi]$ for which $\sin^2 x = \cos^2 x = \frac{1}{2}$, which is $\pi/4 + 3\pi/4 + 5\pi/4 + 7\pi/4 = \boxed{4\pi}$.
