Elementary complex functions

Starting from this lecture, we study functions between sets of complex numbers.

Definition 1 (Functions). Let XX and YY be two sets. A function ff from XX to YY, often written as f:X→Yf: X\to Y, is a binary relation between XX and YY that associate each xx in a subset of XX to a unique y∈Yy\in Y. The set of x∈Xx\in X on which ff is defined is called the domain of the function, denoted by Dom(f)Dom(f). The set of all yy values, {y∈Y∣y=f(x),x∈X}\{y \in Y \mid y=f(x),\ x\in X\}, is called the range of the function ff, which we denote by Rang(f)Rang(f).

In calculus, we have seen many elementary functions that are real-valued, meaning that the range of those functions are subsets of ℝ\mathbb R. Examples of these elementary functions include, but are not limited to, the polynomial functions, the exponential function, the trignometric functions, and the logarithmic function. We now briefly introduce the complex equivalence of those functions.

Polynomial functions

Definition 2 (The complex power function). The usual power function f(z)=znf(z)=z^n (n∈ℤ,n≥0n\in\mathbb Z, n\ge 0) is defined on the complex plane ℂ\mathbb C as follows: ∀z∈ℂ,zn:={1,n=0z⋅z⋯z⏟n,n≥1\forall z\in \mathbb C,\ \ z^n:= \left\{ \begin{array}{cc} 1, & n=0\\ \underbrace{z\cdot z \cdots z}_{n}, & n\ge 1 \end{array} \right.

For instance, let f(z)=z3f(z)=z^3, then when z=2+iz=2+i, we have f(2+i)=(2+i)3=(2+i)(2+i)(2+i)=2+11if(2+i)=(2+i)^3=(2+i)(2+i)(2+i)=2+11i. For any n≥0n\ge 0, this function is well defined at any point z∈ℂz\in\mathbb C, therefore we can take Dom(f)=ℂDom(f)=\mathbb C.

Example 3 (Equivalent representation of a complex function). Note that for any given complex function f(z)f(z) (z=x+iyz=x+iy), we can separate its real and imaginary components as follows: f(z)=f(x+iy)=u(x,y)+iv(x,y)f(z)=f(x+iy)=u(x,y)+iv(x,y) where xx, yy, u(x,y)u(x,y) and v(x,y)v(x,y) are all real-valued.

Take the example f(z)=z3f(z)=z^3, z∈ℂz\in\mathbb C, we can write f(z)=f(x+iy)=(x+iy)3=(x3−3xy2)+i(3x2y−y3)f(z)=f(x+iy)=(x+iy)^3=(x^3-3xy^2)+i(3x^2y-y^3). Here u(x,y)=x3−3xy2u(x, y)=x^3-3xy^2 and v(x,y)=3x2y−y3v(x, y)=3x^2y-y^3.

Definition 4 (Polynomial Function). The polynomial function of nn-th order, often denoted by Pn(z)P_n(z), is defined as Pn(z):=a0+a1z+⋯+anzn=∑k=0nakzk,P_n(z) := a_0+a_1 z + \cdots + a_n z^n = \sum_{k=0}^n a_k z^k, where ak∈ℂa_k\in \mathbb C, k=0,1,...,nk=0,1,...,n, are complex numbers.

A rational function f(z)f(z) is a function of the form f(z)=Pn(z)Qm(z)f(z)=\dfrac{P_n(z)}{Q_m(z)} where PnP_n and QmQ_m are polynomials of order nn and mm respectively, and Qm(z)≠0Q_m(z)\neq 0.

Here is a simple polynomial function: f(z)=2z3+4z+1,z∈ℂ.f(z) = 2z^3+4z+1, \ \ z\in\mathbb C.

Here is a simple rational function: f(z)=11+z,z≠−1f(z) = \dfrac{1}{1+z}, \ \ z\neq -1 We can write this rational function into the u(x,y)+iv(x,y)u(x,y)+iv(x,y) form as f(z)=11+z=1+z‾|1+z|2=1+x−iy(x+1)2+y2=1+x(x+1)2+y2−iy(x+1)2+y2.f(z)=\dfrac{1}{1+z}= \dfrac{1+\bar z}{|1+z|^2} = \dfrac{1+x-iy}{(x+1)^2+y^2}=\dfrac{1+x}{(x+1)^2+y^2}-i\dfrac{y}{(x+1)^2+y^2}.

The exponential function

Definition 5 (Exponential Function). For any z=x+iyz=x+iy, x,y∈ℝx, y\in\mathbb R, we define the complex exponential function eze^z as ez≡ex+iy:=exeiy=ex(cosy+isiny).e^z\equiv e^{x+iy} := e^x e^{iy}=e^x(\cos y + i\sin y).

Note that this definition uses Euler’s formula.

It is straightforward to prove the following result.

Theorem 6. (i) ∀z1,z2∈ℂ\forall z_1, z_2\in\mathbb C, we have that ez1ez2=ez1+z2.e^{z_1}e^{z_2}=e^{z_1+z_2}. (ii) ∀z∈ℂ\forall z\in\mathbb C and k∈ℕk\in \mathbb N, we have that (ez)k=ekz.(e^z)^k=e^{kz}.

Proof. (i) Let z1=x1+iy1z_1=x_1+iy_1 and z2=x2+iy2z_2=x_2+iy_2, then ez1ez2=ex1eiyex2eiy2=ex1+x2(cosy1+isiny1)(cosy2+isiny2)=ex1+x2(cos(y1+y2)+isin(y1+y2))=ex1+x2ei(y1+y2)=ez1+z2.\begin{gathered} e^{z_1}e^{z_2}=e^{x_1}e^{iy}e^{x_2}e^{iy_2}=e^{x_1+x_2}(\cos y_1+i\sin y_1)(\cos y_2+i\sin y_2) \\ =e^{x_1+x_2}(\cos (y_1+y_2)+i\sin (y_1+y_2))=e^{x_1+x_2}e^{i(y_1+y_2)}=e^{z_1+z_2}. \end{gathered} (ii) We apply (i) k−1k-1 times with z1=z2=zz_1=z_2=z. ◻

The exponential function is very useful in the theory and applications of complex variables. Here are some examples.

Example 7. To compute (1+i)9(1+i)^9, we first observe that z=1+i=2eiπ/4z=1+i=\sqrt{2}e^{i\pi/4}. Therefore, z9=(2eiπ/4)9=162ei9π/4=162(cos(9π/4)+isin(9π/4))=16(1+i)z^9=(\sqrt{2}e^{i\pi/4})^9=16\sqrt{2}e^{i9\pi/4}= 16\sqrt{2}(\cos(9\pi/4)+i\sin(9\pi/4))=16(1+i).

Example 8. Let’s try to find complex solutions to the equation: z2+2z+5=0.z^2+2z+5=0. We first observe that we can rewrite the equation as (z+1)2=−4.(z+1)^2=-4. Let w=z+1=|w|eiθw=z+1=|w|e^{i\theta}. Use the fact that −4=−4+0i=4(−1+0i)=4e(1+2k)πi-4=-4+0i=4(-1+0i)=4e^{(1+2k)\pi i} k∈ℤk\in\mathbb Z, we can further simplify the equation to |w|2ei2θ=4e(1+2k)πi.|w|^2e^{i2\theta}=4e^{(1+2k)\pi i}. Therefore |w|=2|w|=2 and 2θ=(1+2k)π⟹θ=(1/2+k)π2\theta=(1+2k)\pi\implies \theta=(1/2+k)\pi. Therefore, w=2e(1/2+k)πi,k∈ℤ.w=2e^{(1/2+k)\pi i}, \quad k\in\mathbb Z. There are two distinct values of ww: w1=2e1/2πi=2iw_1=2e^{1/2 \pi i}=2i and w2=2e3/2πi=−2iw_2=2e^{3/2 \pi i}=-2i. Thus zz has two distinct values z1=w−1=−1+2iz_1=w-1=-1+2i and z2=w2−1=−1−2iz_2=w_2-1=-1-2i.

Example 9. Let’s try to find all the complex solutions to the equation: ez=−1.e^z=-1. We first observe that −1=cos(π+2kπ)+isin(π+2kπ)=ei(1+2k)π,k∈ℤ.-1 = \cos(\pi+2k\pi)+i\sin(\pi+2k\pi) = e^{i(1+2k)\pi}, \ \ k\in\mathbb Z. Therefore the equation can be rewritten as ez=ei(1+2k)π,e^z= e^{i(1+2k)\pi}, which implies z=i(1+2k)π,k∈ℤ.z=i(1+2k)\pi, \ \ k\in \mathbb Z.

Trigonometric functions

We first observe that from Euler’s formula, we immediately have ∀y∈ℝ,cosy=eiy+e−iy2,and,siny=eiy−e−iy2i.\forall y\in\mathbb R, \qquad \cos y=\dfrac{e^{iy}+e^{-iy}}{2}, \quad \mbox{and},\quad \sin y=\dfrac{e^{iy}-e^{-iy}}{2i}.

This motivates the following definition of complex trigonometric functions.

Definition 10. For any complex variable zz, we define the complex trigonometric sine (sinz)(\sin z), cosine (cosz)(\cos z), tangent (tanz)(\tan z) and cotangent (cotz)(\cot z) functions as follows: sinz:=eiz−e−iz2i,\sin z := \frac{e^{iz}-e^{-iz}}{2i}, cosz:=eiz+e−iz2,\cos z := \frac{e^{iz}+e^{-iz}}{2}, tanz:sinzcosz,whencosz≠0\tan z : \frac{\sin z}{\cos z}, \ \ \mbox{when}\ \ \cos z\neq 0 cotz:=coszsinz,whensinz≠0\cot z := \frac{\cos z}{\sin z}, \ \ \mbox{when}\ \ \sin z\neq 0

The trignometric functions we defined above shares many nice properties with their real-valued counterparts. For instance, one can prove the trignometric identies: sin2z+cos2z=1\sin^2 z + \cos^2 z=1, ∀z∈ℂ\forall z\in\mathbb C, and sin(z+z′)=sinzcosz′+coszsinz′\sin(z+z')=\sin z\cos z' + \cos z\sin z' (these are left as exercises). However, there are also some properties that makes the complex version of those functions special. For instance, it is well-known that −1≤sinx≤1-1\le \sin x\le 1 ∀x∈ℝ\forall x\in\mathbb R. This is NOT true for sinz\sin z when z∈ℂz\in\mathbb C. To see that, let z=x+iyz=x+iy, x,y∈ℝx, y\in\mathbb R. Then sinz=eiz−e−iz2i=e−yeix−eye−ix2i=(e−y−ey)cosx+i(e−y+ey)sinx2i.\sin z=\dfrac{e^{iz}-e^{-iz}}{2i}=\dfrac{e^{-y}e^{ix}-e^ye^{-ix}}{2i}=\dfrac{(e^{-y}-e^y)\cos x+i(e^{-y}+e^y)\sin x}{2i}. It is easy to see that, for a general xx, both the real and the imaginary parts of sinz\sin z blow up when y→−∞y\to -\infty or y→+∞y\to +\infty.

The logarithmic function

The complex logarithmic function is defined as the inverse of the exponential function, just as in the real variable case.

Definition 11. For the complex variable zz, the complex logarithmic function of zz, denoted by lnz\ln z, is defined through the relation elnz=z.e^{\ln z}=z.

Note that from the definition, we have elnz=z=|z|ei(θ+2kπ)=eln|z|+i(θ0+2kπ),θ0∈(−π,π],k∈ℤ.e^{\ln z}=z=|z|e^{i(\theta+2k\pi)} = e^{\ln|z|+i(\theta_0+2k\pi)}, \quad \theta_0\in(-\pi, \pi],\quad k\in\mathbb Z. This implies that lnz=ln|z|+i(θ0+2kπ),θ0∈(−π,π],k∈ℤ.\ln z =\ln|z|+i(\theta_0+2k\pi), \quad \theta_0\in(-\pi, \pi],\quad k\in\mathbb Z. This relation can be directly used as the definition of the complex logarithmic function. It shows that lnz\ln z is a “multi-valued” function. We have to specify which kk we take every time we use this function. The function with different kk are called different branches of the function.

Guided review and additional examples

Learning goals

  • Relate the complex exponential to real exponential and trigonometric functions.
  • Solve exponential and trigonometric equations while accounting for periodicity.
  • Distinguish the multivalued logarithm from a selected branch of the logarithm.
  • Recognize how branch choices affect powers such as zaz^a.

Concept connection: periodicity creates branches

Euler’s formula gives ex+iy=ex(cosy+isiny)e^{x+iy}=e^x(\cos y+i\sin y). The exponential is therefore periodic with period 2πi2\pi i. Reversing the exponential cannot produce a single value on all of ℂ\{0}\mathbb C\setminus\{0\}; a logarithm branch is a consistent local choice of argument.

Worked example 1: solve ez=−1e^z=-1

Write z=x+iyz=x+iy. Taking moduli gives ex=1e^x=1, so x=0x=0. The point −1-1 has arguments (2k+1)π(2k+1)\pi. Hence

z=(2k+1)πi,k∈ℤ. z=(2k+1)\pi i,\qquad k\in\mathbb Z.

Substitution confirms that e(2k+1)πi=−1e^{(2k+1)\pi i}=-1.

Worked example 2: understand iii^i

Complex powers are defined using a logarithm. Since

logi=i(π2+2πk), \log i=i\left(\frac{\pi}{2}+2\pi k\right),

the multivalued expression is

ii=exp(ilogi)=exp(−π2−2πk),k∈ℤ. i^i=\exp(i\log i)=\exp\left(-\frac{\pi}{2}-2\pi k\right), \qquad k\in\mathbb Z.

All these values are positive real numbers. Using the principal logarithm selects the principal value e−π/2e^{-\pi/2}.

Check your understanding

Why can the principal logarithm fail to satisfy Log(z1z2)=Logz1+Logz2\operatorname{Log}(z_1z_2)=\operatorname{Log}z_1+\operatorname{Log}z_2?

Show the answer

Principal arguments are restricted to a fixed interval. For z1=z2=−1z_1=z_2=-1, the right side is 2πi2\pi i, while the left side is Log(1)=0\operatorname{Log}(1)=0. The two values differ by 2πi2\pi i, reflecting the exponential’s periodicity.