<s>[INST] Find range of $f(x)=\frac{5}{\sin^2x-6\sin x\cos x+3\cos^2x}$ Find range of $f(x)=\frac{5}{\sin^2x-6\sin x\cos x+3\cos^2x}$
My attempt :
\begin{align*}
f(x)&=\dfrac{5}{9\cos^2x-6\sin x\cos x+\sin^2x-6\cos^2x}\\
&= \dfrac{5}{(3\cos x+\sin x)^2-6\cos^2x}
\end{align*}
The problem is if I'm going to use
$$-1\leqslant\sin x\leqslant1\;\text{and}-1\leqslant\cos x\leqslant1$$
I think I need to have only one term.
Edit : I have made some more progress
$$-3\leqslant 3\cos x\leqslant 3$$
$$\therefore -4\leqslant 3\cos x+\sin x\leqslant 4$$
$$ 0\leqslant (3\cos x+\sin x)^2\leqslant 16$$
 [/INST] The denominator can be written
$$\sin^2x-6\sin x\cos x+3\cos^2x
=\frac{1-\cos 2x}2-3\sin 2x+3\frac{\cos 2x+1}2
\\=2+\cos2x-3\sin2x,$$
which varies continuously in $[2-\sqrt{10},2+\sqrt{10}]$.
Hence as the interval straddles $0$, the range of the function is
$$\left(-\infty,\frac5{2-\sqrt{10}}\right]\cup\left[\frac5{2+\sqrt{10}},\infty\right)$$
</s>