Math Applets

Complex Multiplication

Complex Multiplication:

Using the polar form of complex numbers we can find a geometric interpretation of the multiplication of two complex numbers. For z1,z2Cz_1, z_2 \in \mathbb{C} with
z1=r1eiφ1z_1 = r_1 \cdot e^{i\varphi_1} and z2=r2eiφ2z_2 = r_2 \cdot e^{i\varphi_2} with
r1,r2(0,)r_1, r_2 \in (0,\infty) and φ1,φ2(π,π]\varphi_1, \varphi_2 \in (-\pi,\pi], it holds that

z:=z1z2=r1r2ei(φ1+φ2)=reiφ,z := z_1 z_2 = r_1 r_2 e^{i(\varphi_1 + \varphi_2)} = r e^{i\varphi},

i.e., we obtain the absolute value of zz by multiplying the absolute values of z1z_1 and z2z_2, and the angle φ\varphi by adding the angles φ1\varphi_1 and φ2\varphi_2. This is illustrated in Figure 5.4.

Note that we may have φ(π,π]\varphi \notin (-\pi,\pi], so φ\varphi may not be the principal value of arg(z)\arg(z).


How to use the applet

  • Drag the points z1z_1 (green) and z2z_2 (red) in the complex plane.
  • The arrows from the origin represent z1z_1, z2z_2, and the product z=z1z2z=z_1z_2 (black).
  • The colored angle sectors show the arguments (angles with the positive real axis):
φ1=arg(z1),φ2=arg(z2),φ=arg(z). \varphi_1=\arg(z_1),\qquad \varphi_2=\arg(z_2),\qquad \varphi=\arg(z).

If

z1=r1eiφ1,z2=r2eiφ2, z_1=r_1 e^{i\varphi_1},\qquad z_2=r_2 e^{i\varphi_2},

then

z=z1z2=(r1r2)ei(φ1+φ2). z=z_1z_2=(r_1r_2)e^{i(\varphi_1+\varphi_2)}.

So, when you drag z1z_1 and z2z_2:

  • the length of the product vector changes like z=z1z2|z|=|z_1|\,|z_2|;
  • the angle of the product changes like φφ1+φ2\varphi \approx \varphi_1+\varphi_2 (modulo 2π2\pi, so it may “wrap around”).

Loading graph…
  • Hold Shift + scroll to zoom
  • Hold Shift + drag to move
  • Points shaped like <> act as sliders

Description

Link to code.

Reference: Lecture Notes Calculus 1 ( May22,2022 ) Figure 5.4 page 88

This applet visualizes complex multiplication using the polar interpretation. The axes represent the complex plane: the horizontal axis is Re(z)\mathrm{Re}(z) and the vertical axis is Im(z)\mathrm{Im}(z). Two draggable points represent the complex numbers z1z_1 and z2z_2, and the product z=z1z2z=z_1z_2 is shown as a third vector.

The points z1z_1 and z2z_2 are draggable. The product zz is defined from their Cartesian coordinates using the standard algebraic rule (a1+ib1)(a2+ib2)=(a1a2b1b2)+i(a1b2+b1a2)(a_1+ib_1)(a_2+ib_2)=(a_1a_2-b_1b_2)+i(a_1b_2+b_1a_2). In code this is kept explicitly as Re(z) = z1.X()*z2.X() - z1.Y()*z2.Y() and Im(z) = z1.X()*z2.Y() + z1.Y()*z2.X().

        const z = createPoint(board,
          [
            () => z1.X() * z2.X() - z1.Y() * z2.Y(),
            () => z1.X() * z2.Y() + z1.Y() * z2.X(),
          ],
          {
            name: "",
            fixed: true,
            withLabel: false,
          },
          Z_COLOR
        );

The three arrows from the origin (created with board.create("arrow", [O, ...])) represent the vectors z1z_1 (green), z2z_2 (red), and z=z1z2z=z_1z_2 (black). The colored angle sectors labeled φ1\varphi_1, φ2\varphi_2, and φ\varphi (created with board.create("angle", [U, O, ...])) visualize their arguments.

To avoid an unstable argument near the origin, the applet constrains the draggable points so that z1|z_1| and z2|z_2| stay above a small minimum radius (MIN_RADIUS), enforced in enforceMinRadius during dragging.