If u=√a2cos2θ+b2sin2θ+√a2sin2θ+b2cos2θ, then the difference between the maximum and minimum values of u2 is given by
u2=a2+b2+2√(a2cos2θ+b2sin2θ)(a2sin2θ+b2cos2θ)=a2+b2+2√a4cos2θsin2θ+b4sin2θcos2θ+a2b2(sin4θ+cos4θ)=a2+b2+2√(a4+b4)sin2θcos2θ+a2b2(1−2sin2θ+cos2θ)=a2+b2+2√sin2θcos2θ(a2−b2)+a2b2=a2+b2+2√a2b2+(a2−b2)sin22θ4=(u2)max=a2+b2+2√a2b2(a2−b2)24=2(a2+b2)=(u2)min=a2+b2+2√a2b2=(a+b)2=(u2)max−(u2)min=2(a2+b2)−(a+b)2=(a−b)2