<s>[INST] The maximum and minimum values of the expression Here is the question:find the difference between maximum and minimum values of $u^2$ where $$u=\sqrt{a^2\cos^2x+b^2\sin^2x} + \sqrt{a^2\sin^2x+b^2\cos^2x}$$

My try:I have just normally squared the expression  and got
$u^2=a^2\cos^2x+b^2\sin^2x + a^2\sin^2x+b^2\cos^2x +2\sqrt{a^2\cos^2x+b^2\sin^2x} \sqrt{a^2\sin^2x+b^2\cos^2x}$ 
$u^2=a^2+b^2 +2\sqrt{a^2\cos^2x+b^2\sin^2x} .\sqrt{a^2\sin^2x+b^2\cos^2x}$ 
I am not getting how to solve the irrational part,so how should we do it.Is there some general way to solve such questions?
 [/INST] For $\min$
Using $\triangle$ Inequality::
Let $z_{1} = a\cos x+i b\sin x$ and $z_{2} = b\cos x+i a\sin x$
So $$|z_{1}|+|z_{2}|\geq |z_{1}+z_{2}|$$
So $$\sqrt{a^2\cos^2 x+b^2 \sin^2 x}+\sqrt{a^2 \sin^2 x+b^2 \cos^2 x}\geq \sqrt{(a+b)\cos^2 x+(a+b)^2\sin^2 x}=|a+b|$$
For $\max$ Same as Deepsea
$$\left[\left(\sqrt{a^2\cos^2 x+b^2 \sin^2 x}\right)^2+\left(\sqrt{a^2\sin^2 x+b^2 \cos^2 x}\right)^2\right]\cdot \left[1^2+1^2\right]\geq \bigg(\sqrt{a^2\cos^2 x+b^2 \sin^2 x}+\sqrt{a^2 \sin^2 x+b^2 \cos^2 x}\bigg)^2$$
So $$\sqrt{a^2\cos^2 x+b^2 \sin^2 x}+\sqrt{a^2 \sin^2 x+b^2 \cos^2 x}\leq \sqrt{2(a^2+b^2)}$$
So $$|a+b|\leq \sqrt{a^2\cos^2 x+b^2 \sin^2 x}+\sqrt{a^2 \sin^2 x+b^2 \cos^2 x}\leq \sqrt{2(a^2+b^2)}$$
</s>