z2+1=0 is an example of an equation that has no solution in R. To find a solution, we therefore extend the field to R2 and call it the field (covered in more detail in chapter 5, Algebra, of Discrete Mathematics) of complex numbersC.
Definitionimaginary unit
i2i=−1=^ the imaginary unit
DefinitionCartesian form
z=x+iy
Definitionreal and imaginary part
Re(z)Im(z):=x∈R=^ real part:=y∈R=^ imaginary part
Definitionconjugation
The conjugate of z=x+iy∈C is
z=x−iy∈C.
Conjugation has the following properties:
(i) For all z=x+iy=(x,y),z∈C=R2 we have
z⋅z=(x+iy)⋅(x−iy)=x2−i2y2=x2+y2=∥z∥2.
(ii) For all z1,z2∈C we have
z1+z2=z1+z2;
z1z2=z1z2.
Remark
Further properties of the complex numbers. Let z,w∈C; then the following hold:
The angle φ′ in the interval [0,2π) can in principle be computed by first computing the angle in (−π,π] as described above and, only if it is negative, increasing it by 2π:
φ′={φ+2π,φ,φ<0otherwise.
Remark
As an alternative to arctan, φ can also be computed via sine and cosine:
z2+1=0 is an example of an equation with no solution in R that does have solutions in C (namely z=±i). More generally, the fundamental theorem of algebra holds: every polynomial
p(z)=zn+an−1zn−1+⋯+a0
of degree n≥1 has a root in C. That is, unlike R, C is algebraically closed.
Example 1
Compute: 3−8i6+7i
Show solutionHide solution3−8i6+7i=3−8i6+7i⋅3+8i3+8i=9−64i218+21i+48i+56i2=9+6418+21i+48i−56=73−38+69i
Example 2
Compute the polar form of z=1+i.
Show solutionHide solutionrφ=12+12=2=arctan(11)=4π⇒z=2ei4π
Example 3
Compute the Cartesian form of 7ei3π.
Show solutionHide solution7ei3π=7(cos(3π)+isin(3π))=7⋅21+7⋅23i=27+273i
Example 4
Sketch the following set in the complex plane:
D:={(22(1+i))n:n∈N}Show solutionHide solution
In polar coordinates (1+i)=2ei4π, hence
(22(1+i))n=ei4nπ.
Since eiθ=ei(θ+2kπ)∀k∈Z, D consists of 8 points, obtained for n=0,1,2,..7:
Below you see the "nice" cosine and sine values on the unit circle, where the x-direction corresponds to cos(φ) and the y-direction to sin(φ):
Remark
Quadratic formula (learn by heart)
ax2+bx+c⇒x1,2=0=2a−b±b2−4ac
Example 6
Find all solutions of the following equation:
z2−2(3i+eiπ)=0(1)Show solutionHide solutionz2−2(3i+eiπ)⟺eiπ=−1z2−2(3i−1)⟺z2⟺z2⟺z2⟺polar form and Euler’s formula(reiϑ)2⟺r2e2iϑ=0=0=2(3i−1)=−2+23i=4(−21+23i)=4ei32π=4ei32π⟹r⟹2ϑ⟺ϑ=4=2=32π+2kπ,∀k∈Z=3π+kπ,∀k∈Z⟹z⟺z⟺z=2ei(3π+kπ)for k=0,1={2ei3π,2ei34π}={1+3i,−1−3i}
MATLAB
If you have a function but are not sure what it needs as input or what it returns, you can find out as follows:
In the Matlab Command Window with: help <name> or doc <name>
Otherwise you can also use Google.
Example 7Lucas numbers
Definition
Ln:=⎩⎨⎧2,1,Ln−1+Ln−2,n=0n=1n>1
This gives us the sequence: 2,1,3,4,7,11,18,29,47,76,123,…
Task
Write a Matlab function lucas(n) that, for a given positive integer n, computes the Lucas numbers L0,…,Ln.