<s>[INST] Find the maximum and minimum value of $\cos^2x-6\sin(x)\cos(x)+3\sin^2x+2$ Find the maximum and minimum value of $$\cos^2x-6\sin(x)\cos(x)+3\sin^2x+2$$.
i simplified and reach to expression as follows :
$5 + 2\sin(x)[\sin(x)-3\cos(x)]$. How do i go from here?
Thanks
 [/INST] $$\cos^2x-6\sin(x)\cos(x)+3\sin^2x+2$$
$$-3\sin(2x)+2\dfrac{1-\cos2x}{2}+3$$
$$-3\sin(2x)-\cos(2x)+4$$
now use
$$|a\sin\alpha+b\cos\alpha|\leq\sqrt{a^2+b^2}$$
</s>