Use the given equalities to derive trigonometric functions. 

(A) $\sin(-x)=-\sin x$
    (B) $\cos(-x)=\cos x$
    (C) $\cos(x+y)=\cos x\cos y-\sin x\sin y$
    (D) $\sin(x+y)=\sin x\cos y+\cos x\sin y$
Use these equalities to derive the following important trigonometric functions:
    f) $\left|\cos\dfrac{x}{2}\right|=\sqrt{\dfrac{1+\cos x}{2}}$
    g) $\left|\sin\dfrac{x}{2}\right|=\sqrt{\dfrac{1-\cos x}{2}}$  


This is for (f): Since this is a half-angle identity I replace $x$ with $\frac{\pi}{2}$. And I'll use (C). $\cos(\frac{\pi}{2}+\frac{\pi}{2})=\cos\frac{\pi}{2}\cos\frac{\pi}{2}-\sin\frac{\pi}{2}\sin\frac{\pi}{2}\Rightarrow \cos2\frac{\pi}{2}=\cos^2\frac{\pi}{2}-\sin^2\frac{\pi}{2}$
Using power reduction identity of: $\cos^2\theta=\dfrac{1+\cos2\theta}{2}$ yields $\cos2\frac{\pi}{2}=\dfrac{1+\cos2\frac{\pi}{2}}{2}$.
I do not believe this is correct because $\cos^2\theta\ne \cos2\theta$. Please help, but no answers.
 A: Note that the identity $$\cos^2\theta=\frac{1+\cos 2\theta}2$$ is equivalent to (f), so you shouldn’t be using it: your argument will necessarily be circular. Using (C) is fine, however: just set apply it to $\cos\left(\frac{x}2+\frac{x}2\right)$. You’ll also need the Pythagorean identity $\sin^2x+\cos^2x=1$.
A: I know from an earlier question of yours that you are familiar with the identities
$$\cos 2w =2\cos^2 w-1=1-2\sin^2 w,\tag{$1$}$$
which can be derived fairly quickly from (C).
(Yes, I have changed the name of the variable. That is deliberate.)
Now let $w=\frac{x}{2}$. Then the identities $(1)$ can be rewritten as
$$\cos x=2\cos^2 \frac{x}{2}-1=1-2\sin^2 \frac{x}{2}.$$
(We are replacing $w$ by $\frac{x}{2}$. So $2w=x$.)
Look first at the identity $\cos x=2\cos^2 \frac{x}{2}-1$.  This can be rewritten as 
$1+\cos x=2\cos^2 \frac{x}{2}$, and then as $\cos^2\frac{x}{2}=\frac{1+\cos x}{2}$.
Take the square root of both sides. We get
$$\sqrt{\frac{1+\cos x}{2}}=\left|\cos \frac{x}{2}\right|.$$
Here we used the general fact that $\sqrt{a^2}=|a|$.
The other identity is proved the same way. From $\cos x=1-2\sin^2\frac{x}{2}$ we get $2\sin^2\frac{x}{2}=1-\cos x$. Divide both sides by $2$ and take the square root.
