A principal branch is a function which selects one branch, or "slice", of a multi-valued function.
$\text {arg}(z=a+ib)= \{\varphi_i \ | \ \cos \varphi_i=a/|z| \ , \ \sin \varphi_i =b/|z| \ \}$, since $z=|z| \cdot (\cos \varphi + i \cdot \sin \varphi)$ this is why even though $\text {arctg}(x)$ is $\pi-$periodic.
$\text {arg}(z) = \{\varphi + 2k\pi, \ k\in \mathbb Z, \ \varphi = \text {arctg}(b/a)\in ]-\pi, \ \pi]\ \}$
But $\text {arctg}(x)$ on the other hand is simply
$\text {arctg}(x)=\{\varphi + k\pi, \ k\in \mathbb Z, \ \varphi \in ]-\pi, \ \pi]\ \}$
Both $\text {arg}(z)$ and $\text {arctg}(x)$ have many possible values but according to your question, by using the function (notation) $\text {Arg}(z)$ and $\text {Arctg}(x)$ (note the capitalized $\text A$), we are only interested in values in the given range i.e.
$\text {Arg}(z)=\text {arg}(z) \ \bigcap \ ]−π,\ π]$ $\quad \quad \ \ \ \ \ \text {Arctg}(x)=\text {arctg}(x)\ \bigcap \ ]− π/2,\ π/2[$
The complex logarithm is a perfect example of a multi-valued function. Given $z=a+ib$ the $\mathrm{log}(z)= w\ |\ e^w=z$ and since $z=\sqrt{a^2+b^2}\cdot e^{\ i\cdot(\mathrm {arctg}(b/a) + 2\pi k)}$ where $k$ is any integer, then $\mathrm{log}(z)= \ln(\sqrt{a^2+b^2}) + i\cdot(\mathrm {arctg} (b/a) + 2\pi k)$. This gives a sequence of different values for just one value of $z\ne 0$.
The notation $\mathrm{Log}(z)$ (note the start with a capital $\text L$) is mostly used to denote the principal value of $\mathrm{log}(z)$. For a complex number $z\ne 0$, the principal value $\text {Log} (z)$ is the logarithm whose imaginary part lies in the interval $]−π,π]$.
Back to your question. Given $z=x+iy\ne 0$, then $\text {arg}(z)$ and $\text {arctg}(y/x)$ both take the sequence of values I gave above but by using $\text {Arg}(z)$ and $\text {Arctg}(y/x)$ they are defined in the given intervals.
If $\text {Arctg}(y/x) = \theta \in ]−π/2,\ π/2[$, then $\text { arctg}(y/x) =\{\theta + k\pi , \ \forall k\in \mathbb Z\}$
Since $]−π/2,\ π/2] \subset ]−π,\ π]$ let's consider the following cases for $\text{Arctg(y/x)}$ where
- $ ]-\pi/2, \ 0[\quad \Rightarrow \quad -1 < \sin \theta<0, \ \ 0<\cos \theta<1, \text { possibly $x>0$, $y<0$ and $y/x \le0$} $
- $ [0, \ \pi/2[\quad \Rightarrow\quad 0 \le \sin \theta<1, \ \ 0<\cos \theta\le 1, \text { possibly $x>0$, $y\ge0$ and $y/x \ge0$} $
If we divide the interval $ ]−π,\ π]$ into four for cases of $\text{Arg(z)}$
- $]−π,\ -π/2]$ $\quad \Rightarrow\quad $ $-1\le\sin \theta < 0$, $-1<\cos \theta \le 0$ and $y/x \ge 0$
- $]−π/2,\ 0]$ $\quad \Rightarrow\quad $ $-1<\sin \theta \le 0$, $0< \cos \theta \le 1$ and $y/x \le 0$
- $]0,\ π/2]$ $\quad \Rightarrow\quad $ $0<\sin \theta \le 1$, $0\le \cos \theta < 1$ and $y/x \ge 0$
- $]π/2,\ π]$ $\quad \Rightarrow\quad $ $0\le\sin \theta < 1$, $-1\le \cos \theta < 0$ and $y/x \le 0$
- If $x\le 0$ and $y< 0$ then $\text{Arg(z)} = \theta \in ]-\pi, \ -\pi/2]$ then $\text{Arctg}(y/x) = \theta+\pi \in ]0, \ \pi/2[$ and we have $\text{Arg}(z)-\text{Arctg}(y/x) = -\pi$
- If $x >0$ and $y\le 0$ then $\text{Arg(z)} = \theta \in ]-\pi/2, \ 0]$ then $\text{Arctg}(y/x) = \theta \in ]-\pi/2, \ 0[$ and we have $\text{Arg}(z)-\text{Arctg}(y/x) = 0$
- If $x\ge 0$ and $y> 0$ then $\text{Arg(z)} = \theta \in ]0,\ π/2]$ then $\text{Arctg}(y/x) = \theta \in ]0,\ π/2]$ and we have $\text{Arg}(z)-\text{Arctg}(y/x) = 0$
- If $x< 0$ and $y\ge 0$ then $\text{Arg(z)} = \theta \in ]\pi/2, \ π]$ then $\text{Arctg}(y/x) = \theta-\pi \in ]-\pi/2, \ 0[$ and we have $\text{Arg}(z)-\text{Arctg}(y/x) = \pi$
P.S. The most important thing to know is that $\text {arctg}(y/x)$ only cares about the sign of $y/x$ but $\text {arg}(z)$ cares about the sign of both $x$, $y$ and $x/y$.