# Phase of the Fourier Transform of a function

The Fourier Transform of this function

$$f(n)=u(n)-u(n-m)$$

(where $u$ is the unity step)

is:

$$F(\omega)=\frac{\sin(\omega m/2)}{\sin(\omega/2)}e^{-i(m-1)/2}$$

The phase of $F$ is: $$\phi=\angle{\frac{\sin(\omega m/2)}{\sin(\omega/2)}}+\angle{e^{-i(m-1)/2}}$$

My question is how to find the phase of: $$\angle{\frac{\sin(\omega m/2)}{\sin(\omega/2)}}$$

As it is a real number, $0$ or $\pi$ (modulo $2k\pi$, $k\in\mathbb{Z}$), depending on its sign. Since $e^{(0+2k\pi)\imath}=1$, and $e^{(\pi+2k\pi)\imath}=-1$, every positive real number can be written as $r = |r|e^{(0+2k\pi)\imath}$, and every negative real number as $r = |r|e^{(\pi+2k\pi)\imath}$. And there is an indeterminacy for $0$, since any phase would suit.
Finally, it is conventional to choose, for each number, a "simple" phase, for instance that looks constant, or "relatively continuous". Yet to be clean, on each non-zero number the phase is defined (modulo $2k\pi$).