Let's complete the identity:
[tex]\begin{gathered} \sin 2x-\cot x=2\sin x\cos x-\frac{\cos x}{\sin x} \\ =\frac{2\sin^2x\cos x-\cos x}{\sin x} \\ =\frac{\cos x(2\sin^2x-1)}{\sin x} \\ =\frac{\cos x}{\sin x}(2\sin ^2x-1) \\ =\frac{\cos x}{\sin x}(2(1-\cos ^2x)-1) \\ =\frac{\cos x}{\sin x}(2-2\cos ^2x-1) \\ =\frac{\cos x}{\sin x}(1-2\cos ^2x) \\ =\frac{\cos x}{\sin x}(-\cos 2x) \\ =-\cot x\cos 2x \end{gathered}[/tex]