Trigonometric identity proof I’ve got to proof that:
$$\tan\left(\frac{A}{2}\right) = \sqrt{\frac{1 -\cos(A)}{1 + \cos(A)}}$$
My attempt was (tried with right side):
$$= \pm \sqrt{\frac{1 -\cos(A)}{1 + \cos(A)} \cdot \frac{1 -\cos(A)}{1 - \cos(A)}}$$
$$= \pm \sqrt{\frac{\left(1 -\cos(A)\right)^2}{1 - \cos^2(A)}}$$
$$= \pm \frac{1 -\cos(A)}{\sin(A)}$$
They are not even similar.
I tried Wolfram Alpha online calculator and it showed one of the alternate answers as:
$$\sqrt{\tan^2\left(\frac{A}{2}\right)}$$
That’s the answer I suppose I should get to, but I’ve tried it many times and I can’t find (imagine) a possible route.
Please, if you could point me in the right direction, I’d greatly appreciate it.
Thank you very much in advance.
 A: Hint:  From the start, $$\sqrt{\frac{1-\cos (A)}{1+\cos(A)}},$$ try using the double angle identities for cosine.  Specifically, use $$\cos(A)=2\cos^2\left(\frac{A}{2}\right)-1$$ for the denominator, and 
$$\cos(A)=1-2\sin^2\left(\frac{A}{2}\right)$$ for the numerator.  You will see that things simplify very nicely.
Remark:  Why should we expect to use double angle identities?  The reason why is that I have $\tan \frac{A}{2}$ on the left hand side, and $\cos(A)$, $\sin(A)$ on the right hand side.  This means that the only way to change the right hand side into the left hand side is to use the double angle identities to cut $A$ in half.
A: Knowing that all [direct] trigonometric functions of the simple angle (half-angle) can be expressed rationally as a function of the $\tan$ of the half-angle (double angle), we can think of transforming the given identity (edited: with the LHS replaced by its absolute value, as pointed by others)  
$$\left|\tan \frac{A}{2}\right|=\sqrt{\frac{1-\cos A}{1+\cos A}}\tag{1}$$
into this equivalent one, by simple algebraic manipulation, i.e. solving for $\cos A$
$$\cos A=\frac{1-\tan ^{2}\frac{A}{2}}{1+\tan ^{2}\frac{A}{2}}.\tag{2}$$
And now prove it$^1$, e.g. as follows
$$\cos A=\cos \left(\frac{A}{2}+\frac{A}{2}\right)=\cos ^{2}\frac{A}{2}-\sin ^{2}\frac{A}{2}=\frac{\cos ^{2}\frac{A}{2}
-\sin ^{2}\frac{A}{2}}{\cos ^{2}\frac{A}{2}+\sin ^{2}\frac{A}{2}}=\frac{
1-\tan ^{2}\frac{A}{2}}{1+\tan ^{2}\frac{A}{2}}.$$
$$\tag{3}$$
--
$^1$ Assuming one knows the addition formula for $\cos$. From
$$\cos (\alpha +\beta )=\cos \alpha \cdot \cos \beta -\sin \alpha \cdot \sin
\beta$$
for $\alpha =\beta =\frac{A}{2}$, we have
$$\cos A=\cos ^{2}\frac{A}{2}-\sin ^{2}\frac{A}{2}.$$
(Also in this answer of mine.)
A: You can solve most trignometric identities using Euler's formula:
$$
e^{i \theta }=\cos (\theta )+i \sin (\theta )
$$
Solving for sin and cos, we see:
$$
\cos (\theta )=\frac{1}{2} \left(e^{-i \theta }+e^{i \theta }\right)
$$
$$
\sin (\theta )=\frac{1}{2} i \left(e^{-i \theta }-e^{i \theta }\right)
$$
Plugging in the formula above on the right side yields:
$$
\sqrt{\frac{1+\frac{1}{2} \left(-e^{-i \theta }-e^{i \theta
}\right)}{1+\frac{1}{2} \left(e^{-i \theta }+e^{i \theta }\right)}}
$$
Algebraic simplication yields:
$$
\sqrt{-\frac{\left(-1+e^{i \theta }\right)^2}{\left(1+e^{i \theta
}\right)^2}}
$$
Now, replacing the left side with sin/cos and substituting as above yields:
$$
\frac{i \left(e^{-\frac{i \theta }{2}}-e^{\frac{i \theta
}{2}}\right)}{e^{-\frac{i \theta }{2}}+e^{\frac{i \theta }{2}}}
$$
Simplifying yields:
$$
-\frac{i \left(-1+e^{i \theta }\right)}{1+e^{i \theta }} 
$$
which is identical to the right side after you take the square root.
A: $\tan(a/2)$ is not uniquely determined by $\cos(a)$. For the formula to hold, one needs to restrict the angles to an interval, or take absolute values of both sides. 
A correct statement without any qualification is that the squares of the two sides of the equation are equal:
$\tan^2(A/2)=\frac{1-\cos(A)}{1+\cos(A)}$
which follows from the half- or double-angle formulas for $\sin$ and $\cos$.
A: HINT You can go from 
$$
\frac{1-\cos A}{\sin A}
$$
to $\tan (A/2)$ using the double-angle formulas:
$$
\sin (2x) = 2 \sin x \cos x
$$
and
$$
\cos (2x) = \cos^2 x - \sin^2 x = 2 \cos^2 x - 1 = 1 - 2 \sin^2 x,
$$
where, of course, $x = A/2$. (In the formula for $\cos (2x)$, all three formulas are really the same, but one of them will work "directly". I will leave it to you to figure which of the three formulas to use.)

Thanks to AD for pointing this out. 
The expression 
$$
\sqrt{\frac{1-\cos A}{1+\cos A}}
$$
is not equal to 
$$
\pm \sqrt{\frac{1-\cos A}{1+\cos A}}
$$
that you have written down in the next line. There is no need for the $\pm$ sign here. Similarly, in the next line, you are manipulating the expression inside the radical, so again, the $\pm$ is unnecessary when you say
$$
\pm \sqrt{\frac{1-\cos A}{1+\cos A} \cdot \frac{1-\cos A}{1-\cos A}}.
$$
But in the next line, you are actually taking square roots, and you do not know the sign of 
$$
\frac{1-\cos A}{\sin A}.
$$
In this case, it is best to say
$$
\sqrt{\frac{1-\cos A}{1+\cos A} \cdot \frac{1-\cos A}{1-\cos A}} = \left| \frac{1-\cos A}{\sin A} \right|.
$$
Although this is the correct way to write, it is, unfortunately, kind-of customary to be sloppy when people are doing trigonometry :). In particular, it is quite common to drop the absolute value signs here and just say
$$
\sqrt{\frac{1-\cos A}{1+\cos A} \cdot \frac{1-\cos A}{1-\cos A}} =  \frac{1-\cos A}{\sin A}.
$$
As I showed in the hint, you can express the right hand side as $\tan(A/2)$. 
If one is careful with her/his absolute value signs, one will end up with
$$
\left| \tan \frac{A}{2} \right|.
$$ 
