11. Complex numbers
Back Home Next

Complex Numbers

Dr. R.J.C. Brown

12.1 Definitions

A complex number is defined as a pair of ordinary (real) numbers x and y, and can be designated as (x, y); on occasion this pair of numbers is designated by a single symbol such as z = (x, y). Complex numbers can be combined to form other complex numbers, according to the following rules:

Addition: (x1, y2) + (x, y2) = (x1 + x2, y1 + y2)
Subtraction: (x1, y1) - (x2, y2) = (x1 - x2 , y1 - y2)
Multiplication: (x1, y1) (x2,y2) = (x1 x2 - y1y2, x1y2 + y1x2)

c (x, y) = (cx, cy) where c is a real number.

The definition of multiplication may seem to be artificial, but it turns out to make sense in due course. Division will be discussed a little later. Numbers of the form (x,0) behave under these rules like ordinary numbers: (x1,0) (x2,0) = (x1x2,0). The complex number (1,0) plays the role of unity in complex number multiplication, since (x, y) (1,0) = (x,y),and hence (1,0) is often written simply as 1. Numbers of the form (0,y) behave differently: (0,Y1) (0,Y2) = (-Y1Y2,0). The number (0,1) plays a role somewhat like that of (1,0), since (0,1)(0,1) = (-1,0) = -1 (1,0). The number (0,1) is often designated by the symbol i so that a complex number (x, y) can be written as (x, y) = x(1,0) + y(0,1) = x + i y. Notice that i ´ i = i2 = -1 and hence i can be interpreted as the square root of -1. Such a number does not exist within the arithmetic of ordinary numbers, but arises in a natural way with complex numbers. This extension of ordinary arithmetic has many applications in science.

In the complex number z = (x, y) = x + i y, x is called the real part of z and y is called the imaginary part. If the imaginary part of a number is zero, the number is real, and if the real part of a number is zero, the number is pure imaginary, or simply imaginary.

12.2 The Argand Diagram, or Complex Plane

Just as real numbers can be represented by points along a number line, complex numbers can be represented pictorially by treating the real and imaginary parts as coordinates in a plane, and indeed it is very helpful to do so.


The complex number (x, y) is represented by the point having x and y as coordinates in the plane and the "unit" complex numbers 1 = (1,0) and i = (0,1) form the unit measures along the real and imaginary axes. The complex plane is an extension of the real number line into two dimensions.

A point in the complex plane can also be specified by its distance from the origin and an angle referred to a fixed direction such as the real axis, as shown in the diagram below. These coordinates are called polar coordinates. The distance from the origin to the point representing the complex number z is the modulus or absolute value of z, and is written |z|. The angle q is called the argument of z, and is sometimes written arg(z). From ordinary geometry, and tan q = y / x.

It is clear that x = |z| cos q and y = |z| sin q, so that z = |z| (cos q, sin q) where the complex number (cos q, sin q) lies on the circle of unit radius centered at the origin.

The multiplication of numbers on the unit circle shows the usefulness of this method of representing complex numbers. By the rules of multiplication,

(cosq1, sin q1)´(cos q2, sin q2) =

(cos q1 cos q2 - sin q1 sin q2, cos q1, sin q2 + sin q1 cos q2)
= (cos(q1 + q2), sin(q1 + q2))

In other words, multiplication leads to addition of the angles. This is similar to the rule for combining exponents: ap ´ aq = ap+q and it follows from this and a little more analysis that any complex number on the unit circle can be represented by an imaginary power of the number e (=2.7183...):

(cos q, sin q) = eiq

One way to see this is to make the series expansion of the exponential.

The above equation for multiplication of two numbers of unit modulus then becomes:

.

The following special cases should be noted:

e0 = 1 eip/2 = i eip = -1 ei3p/2 = -i ei2p = -1

Any complex number z can now be represented as z = |z|eiq and it is often convenient and useful to do this. It should be remembered that for a particular complex number z, the corresponding angle q is not unique and can be changed by the addition or subtraction of any multiple of 2p without changing the number z. This is not special to complex numbers, but is also true for the trigonometric functions such as sine and cosine.

The complex conjugate of a complex number z = x + iy = |z|eiq is z* = x - iy = |z|e-iq.

We note that zz* = |z|2 = x2 + y2. we can now calculate the inverse of a complex number and

carry out divisions as the product of one number with the inverse of the other.

A quotient z1/z2 can now be calculated as

Square roots and nth roots are readily calculated:

Notice that the nth roots of +1 are n points spaced evenly around the unit circle.

12.3 Applications of Complex Numbers

The solution of ordinary algebraic equations is not complete unless complex numbers are used. In the familiar case of quadratic equations, the two roots of the equation may involve the square root of a negative number, which has no meaning if we are limited to real numbers. Allowing complex numbers means that an algebraic equation of order n always has n roots, which may be found in various places in the complex plane. Some of those roots may lie on the real axis, but others may lie off the real axis and so can only be described by means of complex numbers.

Complex numbers are often encountered in chemistry and physics to describe phenomena which are periodic or oscillatory. We will deal with several specific applications in chemistry where the use of complex numbers assists us in understanding the concepts involved.

12.4 Applications: Atomic Orbitals

For instance, the motion of electrons in atoms, like the motion of the planets around the sun, are essentially periodic. In the quantum picture of atoms, the motion of an electron is described by the solutions to the Schrödinger equation, which are called orbitals. As an example, consider the p orbitals, of which there are three for any given principal quantum number. There are two ways of classifying these functions. One way is by means of their orientation in space, which we indicate by writing px, py and pz. The angular factors of the wavefunctions for these three orbitals are as follows:

px: sin q cos f py: sin q sin f pz: cos q

In these functions, q and f are polar coordinates defined in the usual way. These functions are real, i.e., not complex.

Another way of looking at the p orbitals is in terms of the orbital and magnetic quantum numbers l and m. For p orbitals, l = 1 and correspondingly m takes any of the three values -1, 0, +1. The corresponding orbitals can be designated p-1 p0 and p+1, and are important in applications such as spectroscopy where the angular momentum of the electrons is of importance. The angular factors for these three states of the atom are complex numbers:

p+1: sin q eif p0: cos q p-1: sin q e-if

Hence we can see that the two sets of orbitals are related to each other as follows:

p+1 = px + ipy p0 = pz p-1 = px - ipy

For higher orbitals such as d and f orbitals where the quantum number I has higher integer values, more complicated shapes must be considered as well as different orientations. The number of orbitals is 2l+1, regardless of whether they are treated as the real or the complex forms.

12.5 Applications: Oscillations and Vibrations

Vibrations and oscillations are met in many different approaches to the properties of molecules and their interactions with light and other electromagnetic fields. In simple harmonic motion, the time dependence of the oscillating motion is described by a cosine or sine function:

f(t) = A cos(w t + f)

where f represents the oscillating quantity, w is the angular frequency of the motion, A is the amplitude of the motion, and f represents a phase shift. The angular frequency w, measured in radians per second, is equal to 2p times the frequency n measured in hertz, which gives the number of oscillations per second. This function has a well-known "sine-wave" shape, which repeats itself after a time interval equal to 2p/w, which is the period of the oscillation. This can also be represented in complex form:

f(t) = 1/2 A(ei(w t + f) + e-i(w t + f)).

It is useful to think about this as follows. The real form represents a point oscillating back and forth along the real axis. The complex form represents the sum of two points rotating around the circumference of a circle, one clockwise and the other anti-clockwise, so that the sum of the two complex numbers is equal at all times to a real number; the two numbers are complex conjugates of each other and ran be represented as z and z*.

In some circumstances, it is permissible to omit one of these numbers, since it is merely the complex conjugate of the other, and therefore one of the two complex numbers is sufficient to describe everything that is happening. Then we can write:

· f(t) = 1/2 Aei(w t + f) = 1/2 A eif eiw t

Here the time dependence is expressed in the factor eiw and the information about amplitude and phase is expressed in the first two factors. Differentiating this function twice with respect to time (by the ordinary rules of calculus) leads to the following:

which is the equation for simple harmonic motion. An example of simple harmonic motion can be seen below:

Where the coloured dots represent the functions:

12.6 Applications: Spectroscopy

According to basic quantum theory, atoms or molecules can emit or absorb energy at a particular frequency n if there are two energy levels E1 and E2 which differ in energy by an amount hn, where h is Planck's constant:

E1 -E2 = hn

The spectrum of a sample is a representation of the absorption of energy as a function of frequency. For some types of spectroscopy this is an adequate description, for a spectrum is in fact recorded by measuring the absorption of energy as a function of the frequency, but for nuclear magnetic resonance (NMR) and some types of laser spectroscopy more sophisticated techniques are used. The transient response of the sample as a function of time following a pulse of energy is recorded, and the spectrum is calculated mathematically by a technique known as the Fourier transform, which will be discussed separately. At this stage, we simply note that the transient response has two parts which represent "in-phase" and "out-of-phase" components and are generated electronically within the spectrometer. In terms of the complex plane, these two components can be thought of as rotating together around the origin but separated by 90 degrees in the plane.

The resulting spectrum also has two parts. One part is the absorption, referred to above, and in many cases can be described by a function similar to the following:

where w is the angular frequency at which the absorption is calculated, and w0 is the "resonant" frequency at which the absorption is a maximum. The quantity d measures the width (on the frequency scale) of the absorption peak. The angular frequency, w, has units of radians per second, while the frequency, n, which gives the number of cycles per second, has units of hertz; the two are related by w = 2pn .

The other part of the spectrum is the dispersion part. The dispersion curve corresponding to the above absorption curve is:

The dispersion associated with an absorption peak is most familiar in optics, where it leads to a refractive index which varies path the frequency (or wavelength) of light. This allows a prism to separate white light into a "spectrum" showing its component colours.

The two parts of the spectrum can be regarded as the real and imaginary parts of a single complex number function g(w):

g(w) = g'(w) + ig"(w)

The initial spectrum produced by an NMR spectrometer has two parts, G"(w) and G'(w), which together form a single complex quantity G(w), which is generally not the same as g(w) but is related to it by a shift of phase:

G(w) = g(w)eif

where f is some phase angle which depends very much upon the adjustment of the spectrometer. This leads to funny-looking distorted peaks in the spectrum. In order to obtain the pure" absorption and dispersion parts of the spectra, it is necessary to look for a value of f which, when substituted in the equation

g(w) = G(w)e-if

leads to satisfactory absorption peaks. This process is called "phasing" the spectrum. The calculations can be done using the following two equations, which are the real and imaginary parts of the last equation:

g'(w) = G'(w) cos f +G"(w) sin f

g"(w) = -G'(w) sin f +G"(w)cos f

This process is really one of twisting the complex spectrum G(w) in the complex plane until the absorption and dispersion parts lie along the real and imaginary axes, which is what appears on the screen.

12.7 Manipulating Complex Numbers with your Calculator

To enter your calculator into Complex Number mode, press <MODE> then <4>. The Complex keys are denoted by purple printing on the keypad. To enter a complex number into your calculator, you must do it in two parts. For example, to enter the number 3+4i, you would press <3>, <+>, <4>, <i>, then <=>. When you press the <=> key a small R-1 appears in the upper right-hand corner of the LCD display and only the 3 is displayed on the screen. When you press the <Re<->Im> key, the 4 is then displayed along with a small i. Therefore, all calculations must be completed by first entering the real part, then the imaginary part of the first complex number, then the operator, and then the real and imaginary parts of the second complex number. When you complete a calculation in Complex mode, you must use the <Re<->lm> key to view both parts of the answer.

The calculator also has two complex number function keys; the <arg> key and the <|z|> key. You must use the <SHIFT> key to access them. The <arg> key gives the argument of any complex number. For example, if your calculator is in Complex and Radian mode and you enter <3>, <+>, <4>, <i>, <=>, then <SHIFT>, <arg>, and <=>, the result of 0.927295218 r will appear of the screen. The <|z|> key returns the modulus of a complex number. For example, if you enter <5>, <+>. <12>, <i>. <=>, then <SHIFT>, <|z|>, and <=>, the calculator will show the result of 13.

12.8 Handling Complex Numbers in Excel

Excel can be used to deal with complex numbers. A complex number can be represented either as a pair of ordinary numbers (which can be either the real and imaginary parts, or the modulus and argument) stored separately in two cells of the worksheet, or as a single complex number in a single cell. Excel functions are available to inter-convert these forms, to perform the common operations (addition, division, complex conjugate etc.), and to evaluate various common functions of a complex number. See Tables 12.1, 12.2 and 12.3 for summaries of these functions. Note that if the real and imaginary parts are placed in separate cells, the complex number which they represent can be plotted on the complex plane by making an XY "scatter" plot on a chart.

Table 12.1 - Complex number inter-conversion commands in Excel

Command Syntax Explanation
COMPLEX (number1 , number2, suffix) Converts real and imaginary coefficients into a complex number of the form x+yi or x+yi.

Examples:

COMPLEX(5,6) returns 5+6i
COMPLEX(2,4,j) returns 2+4j

IMAGINARY(cnumber) Returns the imaginary coefficient of a complex number in the x+yi format.

Examples:
IMAGINARY("3+4
i") returns 4
IMAGINARY("0-j") returns -1
IMAGINARY(4) returns 0

IMREAL(cnumber) Returns the real coefficient of a complex number in the x+yi format.

Example:
IMREAL("5+8
i") returns 5

IMABS(cnumber) Returns the absolute value (modulus) of a complex number in the x+yi format.

Example:
IMABS("5+12
i") returns 13

IMARGUMENT(cnumber) Returns the argument of a complex number, an angle expressed in radians.

Example:
IMARGUMENT("3+4
i") returns 0.927295

IMCONJUGATE~(cnumber) Returns the conjugate of a complex number in the x+yi format.

Example:
IMCONJUGATE("3+4
i") returns 3-4i

NOTE:

bulletnumber1, number2, ... represent real numbers
bulletcnumber represents a complex number
bulletSuffix is the suffix for the imaginary component of the complex number (I or j). If omitted, assumed to be "i".

Table 12.2 - Complex number arithmetic commands in Excel

Command Syntax Explanation
IMSUM(cnumber1, cnumber2,...) returns the sum of two or more complex numbers in the x+yi format.

Example:
IMSUM("3+4
i","5-3i") returns 8+i

IMSUB(cnumber1, cnumber2) returns the difference of two complex numbers in the x+yi format.

Example:
IMSUB("13+4
i", "5+3i") returns 8+i

IMPRODUCT(cnumber1, cnumber2, ...) returns the product of 2 or more (up to 29) complex numbers in the x+yi format.

Example:
IMPRODUCT("3+4
i","5-3i") returns 27+11i

IMDIV(cnumber1, cnumber2) returns the quotient of two complex numbers in the x+yi format.

Example:
IMDIV("-238+240
i", "10+24i") returns 5+2i

bulletcnumber represents a complex number

Table 12.3 - Complex number function commands in Excel

Command Syntax Explanation
IMEXP(cnumber) returns the exponential of a complex number in the x+yi format.

Example:
IMEXP("1+
i") returns 1.468694+ 2.287355i

IMSIN(cnumber) returns the sine of a complex number in the x+yi format.

Example:
IMSIN("3+4
i") returns 3.853738-27.016813i

IMCOS(cnumber) returns the cosine of a complex number in the x+yi format.

Example:
IMCOS("1+
i") returns 0.83373-0.988898i

IMPOWER(cnumber,number) returns a complex number in x+yi format raised to a specified power.

Example:
IMPOWER("2+3i", 3) returns -46+9i

IMSQRT(cnumber) returns the square root of a complex number in x+yi format.

Example:
IMSQRT("1+
i") returns 1.098684+0.45509i

IMLN(cnumber) returns the natural logarithm of a complex number in the x+yi format.

Example:
IMLN("3+4
i") returns 1.609438+0.927295i

IMLOG10(cnumber) returns the base 10 logarithm of a complex number in the x+format.

Example:
IMLOG("3+4
i" ) returns 0.69897+0.402719i

bulletnumber represents a real number
bulletcnumber represents a complex number

12.9 Short Theory Questions

  1. What is the rule for addition of complex numbers?
  2. What is the definition of i2
  3. Which part in the complex number x+yi is the imaginary part?
  4. Which axis (x or y) in the Complex plane is the real axis?
  5. What is the mathematical definition of the modulus?
  6. What is the requirement for a number to be pure imaginary?
  7. What is the equivalent of eip'?
  8. What is the complex conjugate of 5-8i?
  9. What is the angular factor of the wavefunction for the py orbital?
  10. The spectrum of a sample can be divided into the absorption part and the _________ part.

12.10 Exercises

  1. On paper, convert the following to polar form, expressing the angle in radians:
1+2i, -1 - i, 4+8i
  1. On paper, calculate the sum, difference, product and quotient of the following pairs of complex numbers, expressing the result as x+iy:
(a) (1, 3) (2, 4)
(b) 2 - 3i -2 - 0.5i
(c). 2eip/4 2e-i3p/4
  1. On paper, plot the following numbers in the complex plane:
1+i i z2 z3 z* 1/z

where z = (1 +i)/2

  1. Repeat the above exercises using the complex number functions in Excel.
  1. Lay out a spreadsheet to solve a quadratic equation with the coefficients a, b and c placed in cells Al, A2 and A3. Allow for the possibility of the roots being negative by using complex functions. Plot the two roots on complex plane, using a square and a triangle to mark the points. Extend this to a series of quadratic equations so that the roots of a number of quadratic equations can be seen at once. and their positions in the complex plane followed.
  1. Find the three cube roots of +1 and plot on the complex plane.
  1. Plot absorption and dispersion functions of spectroscopy on a single graph using Excel, for a central frequency w0 of 10 kilohertz, and a width parameter d of 15 hertz. Allow for specification of the parameters w0 and d in two fixed cells such as A1 and A2 so that you can experiment to see the effect of changing these parameters.

Last edited: 26 Sep 2008

Back Home Next