# Complex number - how to find the angle between the imaginary axis and real axis?

Assume I have complex number $z = a + ib$.

$z$ can be represented by a polar representation as $r(\cos \theta+i\sin \theta)$,

when $r$ is the absolute value of $z$, $\sqrt{a^2 + b^2}$.

But how can I find $\theta$?

• Consider the right triangle formed by the complex number in the Argand-Gauss plane and it's projections on the axis. – José Siqueira Nov 12 '13 at 17:21
• In particular what is the definition of sine of theta in terms of the known sides of the above mentioned right triangle? – Adam Nov 12 '13 at 17:27

Consider the following Argand-diagram

The y-axis is the imaginary axis and the x-axis is the real one. The complex number in question is

$$x + yi$$

To figure out $\theta$, consider the right-triangle formed by the two-coordinates on the plane (illustrated in red). Let $\theta$ be the angle formed with the real axis.

$$\tan\theta = \frac{y}{x}$$

$$\implies \boxed{\tan^{-1}\left(\frac{y}{x}\right)}$$

The hypotenuse of the triangle will be

$$\sqrt{x^2 + y^2}$$

Therefore,

$$\sin\theta = \frac{y}{\sqrt{x^2 + y^2}}$$

So long as $a,b$ not both $0,$ the system of equations $$\begin{cases}\cos\theta=\frac{a}{\sqrt{a^2+b^2}}\\\sin\theta=\frac{b}{\sqrt{a^2+b^2}}\end{cases}$$ has a unique solution in the interval $[0,2\pi).$ In particular: if $a=0,$ then we have either $\theta=0$ or $\theta=\pi$ (determined by the second equation); if $b=0$, then we have either $\theta=\frac\pi2$ or $\theta=\frac{3\pi}2$ (determined by the first equation); if $a,b\ne 0,$ then either $\theta=\arctan\frac ba$ or $\theta=\pi+\arctan\frac ba$ (determined by the quadrant in which $a+ib$ lies).

I think, you can find it using inverse trigonometric functions: $$\varphi = arccos(\frac{a}{r})$$ $$\varphi = arcsin(\frac{b}{r})$$ where $$r = \sqrt{a^2+b^2}$$