How to calculate derivative of $f(x) = \frac{1}{1-2\cos^2x}$? $$f(x) = \frac{1}{1-2\cos^2x}$$
The result of $f'(x)$ should be equals
$$f'(x) = \frac{-4\cos x\sin x}{(1-2\cos^2x)^2}$$
I'm trying to do it in this way but my result is wrong.
$$f'(x) =  \frac {1'(1-2\cos x)-1(1-2\cos^2x)'}{(1-2\cos^2x)^2} = 
\frac {1-2\cos^2x-(1-(2\cos^2x)')}{(1-2\cos^2x)^2} = $$
$$=\frac {-2\cos^2x + 2(2\cos x(\cos x)')}{(1-2\cos^2x)^2} = 
\frac {-2\cos^2x+2(-2\sin x\cos x)}{(1-2\cos^2x)^2} = $$
$$\frac {-2\cos^2x-4\sin x\cos x}{(1-2\cos^2x)^2}$$

Avoid the quotient formula for functions of the form $1/g(x)$. Rather consider
$$
f(x)=\frac{1}{1-2\cos^2x}=\frac{1}{g(x)}
$$
where $g(x)=1-2\cos^2x$. Since $\Bigl(\dfrac{1}{x}\Bigr)'=-\dfrac{1}{x^2}$, you have, by the chain rule,
$$
f'(x)=-\frac{1}{g(x)^2}g'(x)
$$
and
$$
g'(x)=4\sin x\cos x,
$$
so
$$
f'(x)=-\frac{4\sin x\cos x}{(1-2\cos^2x)^2}.
$$
