Why is the "i" disappearing? The task is: 

Find the argument in its simplest form. 
  $$(\sin(x) +i(1-\cos(x)))^2$$
  where $x$ is an acute angle.

I multiplied out the equation and let alpha be the required argument, then said that
$$\tan(\alpha) = \frac{2i\sin(x)(1-\cos(x))}{\sin(x)^2-(1-\cos(x))^2}.$$
However, the solutions says the same thing except there is no $i$ in $2i\sin(x)(1-\cos(x))$. So I was wondering where the $i$ went?
 A: Since
$$\eqalign{c:&=\bigl(\sin x+i(1-\cos x)\bigr)^2\cr &=\left(2\cos{x\over2}\sin{x\over2}+i\>2\sin^2{x\over2}\right)^2\cr &=
4\sin^2{x\over2}\left(\cos{x\over2}+i\sin{x\over2}\right)^2\cr&=4\sin^2{x\over2}\>e^{ix}\ ,\cr}$$
and the first factor on the right hand side is $>0$, it follows that $\arg c=x$.
A: $$(\sin(x) +i(1-\cos(x)))^2=$$
$$\left(\sin(x)+i\left(2\sin^2\left(\frac{x}{2}\right)\right)\right)^2=$$
$$\sin^2\left(\frac{x}{2}\right)(4\cos(x)+4i\sin(x))=$$
$$\sin^2\left(\frac{x}{2}\right)4\cos(x)+\sin^2\left(\frac{x}{2}\right)4i\sin(x)=$$
$$(2\cos(x)-\cos(2x)-1)+\left(4\sin^2\left(\frac{x}{2}\right)\sin(x)\right)i=$$
$$\left|(2\cos(x)-\cos(2x)-1)+\left(4\sin^2\left(\frac{x}{2}\right)\sin(x)\right)i\right|e^{\arg\left((2\cos(x)-\cos(2x)-1)+\left(4\sin^2\left(\frac{x}{2}\right)\sin(x)\right)i\right)i}=$$
$$\sqrt{\left(2\cos(x)-\cos(2x)-1\right)^2+\left(4\sin^2\left(\frac{x}{2}\right)\sin(x)\right)^2}e^{\arg\left((2\cos(x)-\cos(2x)-1)+\left(4\sin^2\left(\frac{x}{2}\right)\sin(x)\right)i\right)i}=$$
$$4\sqrt{\sin^4\left(\frac{x}{2}\right)}e^{\arg\left(e^{ix}\sin^2\left(\frac{x}{2}\right)\right)i}$$
$-------$
1) Argument if $\Re$ and $\Im$ are both positive:
$$\tan^{-1}\left(\frac{|\Im|}{|\Re|}\right)$$
2) Argument if $\Re$ and $\Im$ are both negative:
$$\pi+\tan^{-1}\left(\frac{|\Im|}{|\Re|}\right)$$
3) Argument if $\Re$ is negative and $\Im$ is positive:
$$\frac{1}{2}\pi +\tan^{-1}\left(\frac{|\Re|}{|\Im|}\right)$$
3) Argument if $\Re$ is positive and $\Im$ is negative:
$$-\tan^{-1}\left(\frac{|\Im|}{|\Re|}\right)$$
