\(cotx-tanx-2tan2x=\frac{cosx}{sinx}-\frac{sinx}{cosx}-\frac{2sin2x}{cos2x}\)
\(=\frac{cos^2x-sin^2x}{\frac{1}{2}.2.sinxcosx}=\frac{cos2x}{\frac{1}{2}sin2x}=2\left(\frac{cos2x}{sin2x}-\frac{sin2x}{cos2x}\right)\)
\(=2\left(\frac{cos^22x-sin^22x}{\frac{1}{2}2sin2xcos2x}\right)=4\frac{cos4x}{sin4x}=4cot4x\)