Complex Numbers

Download as pdf or txt
Download as pdf or txt
You are on page 1of 21

Complex Numbers

with
TI-Nspire™ CAS
Forest W. Arnold
September 2020
Typeset in LATEX.

Copyright © 2020 Forest W. Arnold

This work is licensed under the Creative Commons Attribution-Noncommercial-


Share Alike 4.0 International License. To view a copy of this license, visit http:
//creativecommons.org/licenses/by-nc-sa/4.0/legalcode/ or send a let-
ter to Creative Commons, 171 Second Street, Suite 300, San Francisco, California,
94105, USA.

You can use, print, duplicate, share this work as much as you want. You can
base your own work on it and reuse parts if you keep the license the same.

Trademarks

TI-Nspire is a registered trademark of Texas Instruments, Inc.


Attribution

Most of the examples in this article are from A First Course in Linear Algebra
an Open Text by Lyrix Learning, base textbook version 2017 - revision A, by K.
Kuttler.

The text is licensed under the Creative Commons License (CC BY) and is avail-
able for download at the link

https://lyryx.com/first-course-linear-algebra/.
1 Introduction
This article describes and demonstrates how to use TI-Nspire’s builtin functions
to
• add and subtract complex numbers,

• multiply and divide complex numbers,

• graph complex numbers in a complex plane,

• use the Polar Form of complex numbers,

• convert complex numbers from rectangular to polar form and vice versa,

• use De Moivre’s Theorem to find powers and roots of complex numbers.


Some of the TI-Nspire examples in this article require the CAS version of TI-
Nspire.

2 Complex Numbers
2.1 Definitions
Complex numbers extend the real numbers, adding functionality to solve prob-
lems such as x2 + 4 = 0. Problems like this can not be solved with real num-
bers√
since the solution involves taking the square root of a negative number; e.g.,
x = −4.

The set of real numbers is a subset of the set of complex numbers. The set of
complex numbers includes an imaginary number, i such that i2 = −1. Complex
numbers are represented in standard form as z = a + bi, where a is the real part
and b is the imaginary part of the complex number z. With this form, a real num-
ber is simply a + 0i and a pure imaginary number is 0 + bi. Standard form of a
complex number is also called rectangular form.

2.2 Complex Numbers with TI-Nspire


Enabling Complex Numbers

1
To enable complex numbers in TI-Nspire, open the Document Settings dialog
by selecting the File - Settings - Document Settings... menu item, then choose
either Rectangular or Polar from the Real or Complex Format drop-down list:

Note: The polar form for complex numbers is discussed in a subsequent sec-
tion of this article.

Entering Complex Numbers

The imaginary number i is inserted in a TI-Nspire application by either typing


@i or selecting its symbol from the Symbols pane in the Documents Toolbox. A
complex number in standard form is inserted by typing the number as a+b@i. An
example of entering a complex number in a calculator page is

After the enter key is pressed, @i is replaced with the symbol for the imaginary
number:

2
Extracting the Real and Imaginary Parts of a Complex Number

The TI-Nspire functions real() and imag() return the real and imaginary parts
of a complex number. Examples of using these two functions are

2.3 Mathematical Operations with Complex Numbers


Addition and Subtraction

Addition of complex numbers cplx1 and cplx2 is performed by adding the real
parts of the numbers and adding the imaginary parts of the numbers:

Subtracting complex numbers is similar: the real and imaginary parts of the sub-
trahend are subtracted from the real and imaginary parts of the minuend:

Examples of adding and subtracting complex numbers are:

Multiplication

3
Multiplication of complex numbers is defined as follows [Kuttler]:

(a + bi)(c + di) = ac + adi + bci + bdi2


= ac + (ad + bc)i + bd(−1)
= ac + (ad + bc)i − bd
= (ac − bd) + (ad + bc)i

Examples of multiplying both symbolic and concrete complex numbers are:

Division

Dividing complex numbers is analogous to rationalizing denominators and is de-


fined as follows [Kuttler]:

Given rational numbers z = a + bi and w = c + di with both c and d not equal


to zero, the quotient wz is
z a + bi a + bi c − di
= = ×
w c + di c + di c − di
(ac + bd) + (bc − ad)i
=
c2 +
d
2

ac + bd bc − ad
= 2 + i
c + d2 c2 + d 2
where c − di is the complex conjugate of c + di.

Examples of dividing complex numbers are:

The conjugate of a complex number z changes the sign of the imaginary part

4
of the complex number. The notation for the complex conjugate places a line over
the complex number:
z = a + bi = a − bi
As shown above, the result of multiplying a complex number by its conjugate (and
vice versa) is a real number:

a + bi (a + bi) = (a − bi)(a + bi) = a2 + b2 − (ab − ab)i = a2 + b2




The TI-Nspire function for obtaining the conjugate of a complex number is conj(z).
Examples of using the function are

Inverse of a Complex Number

The multiplicative inverse of a nonzero number x is the number x−1 such that
xx−1 = 1. A complex number z = a + bi is nonzero exactly when a2 + b2 6= 0. If
z = a + bi 6= 0, then z−1 exists and is defined as follows:
1 1 1 a − bi a − bi a b
z−1 = = = × = 2 2
= 2 2
− 2 i
z a + bi a + bi a − bi a + b a +b a + b2
Examples of multiplicative inverses of complex numbers are

5
Absolute Value

The absolute value, or modulus, of a complex number is defined as


p
|a + bi| = a2 + b2

Examples of the absolute value of a complex number are

2.3.1 Algebraic Functions for Complex Numbers


The TI-Nspire functions for solving, factoring, and finding zeros of equations that
involve complex numbers are cSolve(),cFactor(),cZeros(), and cPolyRoots().
These functions are added to a calculator page from the Document Tools - Alge-
bra - Complex or the Document Tools - Algebra - Polynomial Tools submenus.
Although specific to equations involving complex numbers, they can also be used
for equations whose solutions consist of only real numbers.

Examples of using these functions in a calculator page are

Notice that two of the roots (zeros) of the polynomial are complex numbers and
that the complex roots are conjugates (2i, −2i). Complex roots of polynomials
with real coefficients always occur as pairs of complex conjugates.

6
2.4 Graphs of Complex Numbers in Standard Form
Complex numbers in standard form a + bi are graphed in a rectangular coordinate
system called a complex plane. In the complex plane, the x axis in a standard
rectangular coordinate system is designated as a real axis and the y axis is des-
ignated as an imaginary axis. A complex number a + bi in the complex plane is
plotted as the (real,imaginary) coordinate pair, (a, b), with the a coordinate lo-
cated along the real axis and the b coordinate located along the imaginary axis.
Figure 1 depicts a complex plane with plots of the complex conjugates 3 + 2i and
3 − 2i.

Figure 1: Graph of Points in a Complex Plane

3 Complex Numbers in Polar Form


The representation of a point (a, b) in the complex plane in polar form is (r, θ ),
where r is the distance from the origin of the coordinate system to the point and θ
is the angle between the real axis and the line segment from the origin to the point.

Given z = a + bi, a is the horizontal distance from the origin to the point and

7
b is the vertical distance to the point. From the Pythagorean
√ Theorem, the length
of the line segment from the origin to the point is r = a + b2 , which equals |z|.
2
From trigonometry, the angle between  the horizontal axis and the line from the
origin to the point is θ = tan −1 b
a . Also from trigonometry, a = r cos(θ ) and
b = r sin(θ ). r is called the modulus of z and θ is called the argument of z.

Figure 2 displays the graph of the complex number z = 3 + 2i in polar form in


the complex plane.

Figure 2: Graph of Polar Form of a Complex Number

Substituting the formulas a = r cos(θ ) and b = r sin(θ ) for a and b in z = a + bi


yields a trigonometric formula for a complex number in polar form:

z = a + bi = r cos(θ ) + r sin(θ )i = r(cos(θ ) + i sin(θ ))

Further, Euler’s Formula states that cos(θ ) + i sin(θ ) = eiθ , so a simpler formula
for a complex number in polar form is

z = reiθ

8
The identity cos(θ ) + i sin(θ ) = eiθ enables converting a complex number in stan-
dard (rectangular) form to polar form and vice versa as illustrated by the following
examples:

Example: Write z = 3 + 2i in polar form z = reiθ .

Analysis: The required values for polar form are


√ r, the modulus, and θ , the
argument. The formula for the modulus is |z| = a2 + b2 and the argument is
calculated with the formula θ = tan−1 ab .

Solution:

Calculate r and θ using values a = 3 and b = 2:


√ √
r = 32 + 22= 13
θ = tan−1 32 = 0.588003

Write the polar form using the values of r and θ :


√ 0.588003i
z= 13e
π
Example: Write z = 4ei 4 in standard form z = a + bi.

Analysis: The required values are the values of a and b. These values are found
with the formulas a = r cos(θ ) and b = r sin(θ ).

Solution:

From the polar form, r = 4 and θ = π4 . Calculate the values of a and b using
the values of r and θ :
√ √
2
π

a = r cos(θ ) = 4 cos 4 = 4√2
= 2 2
π 2

b = r sin(θ ) = 4 sin 4 =4 2 =2 2

Write the complex number in standard form using the values of a and b:
√ √
z = 2 2 + 2 2i

9
4 TI-Nspire Information/Conversion Commands
There are TI-Nspire commands or functions that display complex numbers in dif-
ferent formats, return the modulus and argument for complex numbers, and con-
vert complex numbers to a different format. These commands are

1. Display-only conversion commands. These two commands do not return a


value nor do they assign a value to the variable ans. They simply display a for-
matted value. The displayed value can be copied and pasted if necessary.

To display a complex number in polar format, type the command num@>Polar.


An example is

To display a complex number in standard (rectangular) format, type the command


num@>Rect. An example is

2. Information functions.

Use the abs() function to determine the modulus of a complex number:

Use the angle() function to determine the argument of a complex number:

10
3. Formatting command. Given the complex coordinates of a point, (r, θ ), the
formatting command returns the complex number corresponding to the point in
standard or polar format. The complex coordinates in TI-Nspire are specified as
(r ∠ θ ) which is typed as r @< theta. The returned format is determined by
the current Real or Complex Format specified in the Document Settings dialog.
Examples are

5 Products, Quotients, Powers, and Roots of Com-


plex Numbers in Polar Form
5.1 Products and Quotients of Complex Numbers in Polar Form
Multiplying and dividing complex numbers in polar form z = reiθ is easy, since
the process conforms to the rules for multiplying and dividing exponential expres-
sions.

The formula for the product of two complex numbers z1 = r1 eiθ1 and z2 = r2 eiθ2
is   
z1 z2 = r1 eiθ1 r2 eiθ2 = r1 r2 eiθ1 +iθ2 = r1 r2 ei(θ1 +θ2 )
The trigonometric form of the product is thus
z1 z2 = r1 r2 (cos(θ1 + θ2 ) + i sin(θ1 + θ2 ))
The formula for the quotient of two complex numbers is
z1 r1 eiθ1 r1 iθ1 −iθ2 r1 i(θ1 −θ2 )
= = e = e
z2 r2 eiθ2 r2 r2

11
The trigonometric form of the quotient is thus
z1 r1
= (cos(θ1 − θ2 ) + i sin(θ1 − θ2 ))
z2 r2
The easiest and least confusing way to multiply and divide complex numbers with
TI-Nspire is by defining functions to perform the calculations. The functions are
defined in a calculator page as follows:

Given complex numbers z1 and z2 defined in a calculator page with the docu-
ment format set to polar format:

The product is calculated with the user-defined function cplx prod() as

and the product is displayed in standard format as

The quotient is calculated with the user-defined function cplx quot() as

12
and the quotient is displayed in standard format as

5.2 Powers and Roots of Complex Numbers in Polar Form


De Moivre’s Theorem posits an identity for raising a complex number to a power
n. The theorem is [Kuttler]:

For any positive integer n,


(eiθ )n = einθ
Thus for any real number r > 0 and any positive integer n,

(r(cos(θ ) + i sin(θ )))n = rn (cos(nθ ) + i sin(nθ ))

Raising a complex number to a power is easily performed using the identity in the
theorem.

A corollary to De Moivre’s theorem specifies the number of roots of a non-zero


complex number [Kuttler]:

Let z be a non-zero complex number. Then there are always exactly k many kth
roots of z.

A formula for calculating the kth roots of a complex number z based on the theo-
rem and corollary is
    
1 θ + 2lπ θ + 2lπ
|z| cos
k + i sin , l = 0, 1, 2, · · · , k − 1
k k

Proofs of the theorem and derivation of the formula for finding the roots of a
complex number are in paragraph 6.3 of [Kuttler].

5.3 Raising a Complex Number to an Integer Power


TI-Nspire’s exponentiation function is used to raise a complex number in either
standard form or polar form to an integer power. Examples:

13
Raising a complex number in standard form to a power with the document set-
ting as rectangular:

Raising a complex number in standard form to a power with the document set-
ting as polar:

Raising a complex number in polar form to a power with the document setting
as polar:

Raising a complex number in polar form to a power with the document setting
as rectangular:

14
5.4 Finding Roots of a Complex Number
TI-Nspire’s root() function returns the nth root of both real and complex num-
bers in either standard or polar form. However, the function only returns one root:
it does not return all the k roots of a complex number. Examples of finding roots
with this function are

The formula for finding the kth roots of a complex number presented in para-
graph 5.2 is used to find all k roots. Using this formula is made easier by defining
a convenience function:

This function can be used for complex numbers in both standard and polar for-
mat and with document settings in either rectangular or polar format. Examples
of using the function are:

Find all three roots of i in polar format:

15
Find all three roots of 2 + 2i in standard format:

Some polynomials can also be factored by finding kth roots. For example,

Problem: Factor x4 − 16 by finding all four roots using the kth root formula from
paragraph 5.2.

Solution:

First, find the four roots of 16 + 0i:

Next, form the four factors:

16
Finally, verify the factorization by multiplying the four factors and expanding
the result:

6 Summary
This article described complex numbers and TI-Nspire’s builtin functions for com-
plex numbers. Examples of graphing complex numbers and performing arithmetic
and algebraic operations with them were presented. As demonstrated by the ex-
amples, mathematical operations with complex numbers in TI-Nspire is almost as
simple as operations with real numbers.

17
References
[Kuttler] Kuttler, K., A First Course in Linear Algebra - An Open Text, Lyrix
Learning, 2017

[1] Sullivan, Michael, and Sullivan,III, Michael Precalculus Enhanced with


Graphing Utilities, 6th Ed., Pearson Education, Inc., 2013

18

You might also like