<s>[INST] Solution verification about complex multiplication in polar form I am trying to prove the process behind complex multiplication in polar form, which is similar to this:

The product of two complex numbers in polar form $r_{1}\,\angle\,\theta_{1}$ and $r_{2}\,\angle\,\theta_{2}$ is $r_{1}r_{2}\,\angle\,(\theta_{1} + \theta_{2})$.

The proof where the polar form is written into rectangular form which will then use sum-to-product formula is already established like this, so I want to try something new.
Can someone verify if my attempt is correct?

Define two complex numbers $z_{1} = a + bi$ and $z_{2} = c + di$. Writing it in polar form, we get $z _{1} = \sqrt{a^{2} + b^{2}}\,\angle\,\tan^{-1}\left(\frac{b}{a}\right)$ and $z_{2} = \sqrt{c^{2} + d^{2}}\,\angle\,\tan^{-1}\left(\frac{d}{c}\right)$, respectively. Also, the product of the two complex numbers $z_{1}z_{2}$ is equal to $(ac - bd) + (ad + bc)i$. Writing this in polar form, we have $z_{1}z_{2} = \sqrt{(ac - bd)^{2} + (ad + bc)^{2}}\,\angle\,\tan^{-1}\left(\frac{ad + bc}{ac - bd}\right)$. Let this product be $z_{3}$.
We then check if the radius of the product is equal to the product of the radii of the factors.
\begin{align*}r_{1}r_{2} &\overset{?}{=} r_{3} \\ \left(\sqrt{a^{2} + b^{2}}\right)\left(\sqrt{c^{2} + d^{2}}\right) &\overset{?}{=}\sqrt{(ac - bd)^{2} + (ad + bc)^{2}} \\ \sqrt{(a^{2} + b^{2})(c^{2} + d^{2})} &\overset{?}{=} \sqrt{(ac)^{2} - 2abcd + (bd)^{2} + (ad)^{2} + 2abcd + (bc)^{2}} \\ \sqrt{(ac)^{2} + (ad)^{2} + (bc)^{2} + (bd)^{2}} &\overset{?}{=} \sqrt{(ac)^{2} + (bd)^{2} + (ad)^{2} + (bc)^{2}} \\ \sqrt{(ac)^{2} + (ad)^{2} + (bc)^{2} + (bd)^{2}} &= \sqrt{(ac)^{2} + (ad)^{2} + (bc)^{2} + (bd)^{2}}\end{align*}
Next, we check if the angle of the product is the sum of the angles of the factors.
\begin{align*}\theta_{1} + \theta_{2} &\overset{?}{=} \theta_{3} \\\tan^{-1}\left(\frac{b}{a}\right) + \tan^{-1}\left(\frac{d}{c}\right) &\overset{?}{=} \tan^{-1}\left(\frac{ad + bc}{ac - bd}\right).\end{align*}
Before proceeding, we must restrict $\theta_{i}$ on the range of the arctangent function which is $(-\frac{\pi}{2},\frac{\pi}{2})$ as the arctangent function. If, for instance, $\mathrm{Re}(z_{i}) = 0$, then the sign of $\mathrm{Im}(z_{i})$ will determine the sign of $\frac{\pi}{2}$. Also, if $\mathrm{Re}(z_{i}) < 0$ and $\mathrm{Im}(z_{i}) > 0$, we can just take the angle of a complex number $z$ where $\mathrm{Re}(z) = \mathrm{Im}(z_{i})$ and $\mathrm{Im}(z) = \mathrm{Re}(z_{i})$.
Rewrite the relation by letting $b$, $d$, $a$, and $c$ take the value of $\frac{b}{a}$, $\frac{d}{c}$, $1$, and $1$. Then, by simplifying,
\begin{align*}\tan^{-1}\left(\frac{(\frac{b}{a})}{1}\right) + \tan^{-1}\left(\frac{(\frac{d}{c})}{1}\right) &\overset{?}{=} \tan^{-1}\left(\frac{(1)(\frac{d}{c}) + (\frac{b}{a})(1)}{(1)(1) - (\frac{b}{a})(\frac{d}{c})}\right) \\ \tan^{-1}\left(\frac{b}{a}\right) + \tan^{-1}\left(\frac{d}{c}\right) &\overset{?}{=} \tan^{-1}\left(\frac{\frac{b}{a} + \frac{c}{d}}{1 - (\frac{b}{a})(\frac{d}{c})}\right)\end{align*}
Then, let $\tan u = \frac{b}{a}$ and $\tan v = \frac{d}{c}$. By substitution,
\begin{align*}\tan^{-1}\left(\tan u\right) + \tan^{-1}\left(\tan v\right) &\overset{?}{=} \tan^{-1}\left(\frac{\tan u + \tan v}{1 - (\tan u)(\tan v)}\right) \\ u + v &\overset{?}{=} \tan^{-1}\left(\frac{\tan u + \tan v}{1 - (\tan u)(\tan v)}\right) \\ \tan(u + v) &\overset{?}{=} \frac{\tan u + \tan v}{1 - (\tan u)(\tan v)}\end{align*}
The last relation is known to be true. Thus, $$\tan(u + v) = \frac{\tan u + \tan v}{1 - (\tan u)(\tan v)}$$
Since the product of the radii of the factors is equal to the radius of the product and the angle of the product is equal to the sum of the angles of the factors, therefore, $(r_{1}\,\angle\,\theta_{1})(r_{2}\,\angle\,\theta_{2}) = r_{1}r_{2}\,\angle\,(\theta_{1} + \theta_{2})$.

Edit: Tried to fix the angle problem. "Before proceeding...", in particular.
 [/INST] Your computations are correct, but you do not cover all possible cases. Problems are

*

*Your formulae based on $\tan^{-1} = \arctan$ only work if both $a \ne 0$ and $c \ne 0$. This reflects the fact $\tan x$ is not defined if $x = k \pi/2$ with odd $k \in \mathbb Z$. Thus you must separately treat a number of special cases: $a = 0, c = 0$ / $a \ne 0, c = 0$ / $a = 0, c \ne 0$.


*There are infinitely many branches of the arc tangent, let us denote them by $\arctan_k : \mathbb R \to ((2k - 1)\pi/2, (2k + 1)\pi/2)$ with $k \in \mathbb Z$. If $k$ is odd, then your formulae describe points $z$ with real part $\Re(z) > 0$, and if $k$ is even, then your formulae describe points $z$ with  $\Re(z) < 0$. Usually one works with the principal value $\arctan = \arctan_0 : \mathbb R \to (-\pi/2, \pi/2)$. Anyway, it gives again many cases which have to be considered. As you do it, it only works if all three points $z_1, z_2, z_1z_2$ have real part $> 0$. And it seems that if for example $\Re(z_1) > 0 $ and $\Re(z_2) < 0$ you get really into troubles because you cannot use the same branch of $\arctan$ for both points.


*The polar form is not unique, angles are determined only up to a summand $2k\pi$. The formula $(r_{1}\,\angle\,\theta_{1})(r_{2}\,\angle\,\theta_{2}) = r_{1}r_{2}\,\angle\,(\theta_{1} + \theta_{2})$ is true for all choices of $\theta_i$. You can of course restrict to angles in $[0,2\pi)$, but the sum of two such values may by outside of this interval. This can easily be treated, but again it needs additional arguments.
</s>