If $u=\sqrt {a\cos^{2}x+b\sin^{2}x} + \sqrt {b\cos^{2}x+a\sin^{2}x}$ , find the maximum and minimum value of $u^2$.
Put $$1-\cos2x =2\sin^2x$$ $$1+\cos2x =2\cos^2x$$
$u=\sqrt {a\cos^{2}x+b\sin^{2}x} + \sqrt {b\cos^{2}x+a\sin^{2}x}$
Let
$p = a \cos^2 x + b \sin^2 x$
$q = b \cos^2 x + a \sin^2 x$
and
$u = \sqrt{p} + \sqrt{q}$
Then $u^2 = p + q + 2 \sqrt{pq}$
Now
$p + q = a + b$
and
$\displaystyle pq = \frac{(a+b)^2}{4} - \frac{(a-b)^2}{8} - \frac{(a-b)^2}{8} \cos 4x$
If $\cos 4x = -1$ then $u^2$ is maximum and is equal to
$2(a+b)$
If $\cos 4x = 1$ then $u^2$ is minimum and is equal to
$a+b + 2 \sqrt{ab}$
Please check the calculations.