<s>[INST] If $t=\tan{\frac{x}{2}}$, then $\cos{x}$ can be expressed as... If $t=\tan{\frac{x}{2}}$, then $\cos{x}$ can be expressed as
a) $\frac{1+t^2}{1-t^2}$ 
b) $\frac{2t}{1+t^2}$
c) $\frac{1-t^2}{1+t^2}$
d) $\frac{2t}{1-t^2}$
Attempt: I tried using the half angle formula but it just leaves me with an expression in terms of $\tan{x}$'s and I don't know how to go to $t$, let alone express $\cos{x}$ in $t$.
 [/INST] Note that $$\sin^{2}\left(\frac{x}{2}\right) = \frac{1-\cos x}{2},\quad \cos^{2}\left(\frac{x}{2}\right) = \frac{1+\cos x}{2},$$
so $$\tan^{2}\left(\frac{x}{2}\right) =\frac{1-\cos x}{1+\cos x}.$$
Setting $$t = \tan \left(\frac{x}{2}\right)$$
we get
\begin{align*}
t^{2} &= \frac{1-\cos x}{1+\cos x}\\ \implies t^{2} + t^{2}\cos x &= 1 - \cos x\\ \implies (1+t^{2})\cos x &= 1-t^{2}\\
\implies \cos x &= \frac{1-t^{2}}{1+t^{2}}
\end{align*}
*Edited based on Arnaldo's suggestion.
</s>