I decided to start a series of posts about the beauty and the mystery of numbers. This is the first post in this series.
What are complex numbers good for? Well, they are for, for instance, for the production of fractals. How much is investment is needed for starting such a production? Not much. Let me start from complex numbers next time I will move to the Mandelbrot fractal. Later on I will explain what quantum fractals are about.
First complex numbers. To deal with them one only needs to know how to add and how to multiply. Well, some knowledge of fractions will also prove to be useful.
A complex number is nothing else but an expression of the form
x+yj
Here x and y are „ordinary numbers”, real numbers, while j is a symbol. The only thing we need to know is the rule that „j times j is minus one”
j2 = jj = -1
Note: Mathematicians and physicist usual write „i” instead of „j”. In the science electricity „j” is used instead, mainly because "i" is reserved for the electric current. I will keep to the notation „j”.
The usual rule of addition and multiplication hold. Given two complex numbers, for instance
0.5+0.75j
0.3-2j
we can add them:
(0.5+0.75j)+(0.3-2j) = 0.5+0.75j+0.3-2j
collect the coefficients, those without j and those with j:
(0.5+0.3)+(0.75-2)j
and we obtain a new complex number, the sum of the two:
0.8-1.25j
There is no difference between this rule of addition of complex numbers and the usual rule of adding vectors using the parallelogram rule (the same way we add forces), as depicted below:
Therefore complex numbers are vectors on the plane. The number x+yj is represented as a vector in Cartesian coordinates, with coordinates x,y.
The same way as a vector, a complex number z can be described by giving its length and the angle between the vector z and the x axis. The length of the vector that represents z is called the modulus (or absolute value) of z. It is usually denoted as |z|. The angle between the vector and the x-axis is called the argument of z, and is usually denoted by arg(z). Sometimes we also use the term „phase of z” instead of „argument of z”. Here is the picture:
Two complex numbers can be also multiplied one by another to give another complex number – their product. The only rule needed in order to multiply two complex numbers is this one: j times j is -1.
Therefore
(0.5+0.75j)(0.3-2j) =
(0.5)(0.3)+(0.5)(-2)j+(0.75j)(0.3)+(0.75j)(-2j) =
0.15-j+0.225j+1.5 = 1.65-0.775j
One can ask: why such a strange rule? Yet this rule has a simple geometrical interpretation. Multiplying two complex numbers, the lengths multiply while the phases add. Below is the illustration of this fact using the simple example of multiplying j = 0 + 1j by itself
The vector representing j has unit length, therefore jj will also have length 1 (1 times 1 is 1). The vector representing j is at 90 degrees to the x axis, therefore jj will be at 90+90=180 degrees. And this exactly -1 on the x axis. This way we obtain back our starting rule: „j times j is -1.”
Given a complex number z=x+yj, the number x (x-component of the vector) is called the real part of z and denoted by the symbol Re(z) („Re” for „real”), while the number y (y- component of the vector) is called the imaginary part of z and denoted by the symbol Im(z) („Im” for „imaginary”). Yet there is nothing imaginary about it. It is as real as x. Just a tradition.
When we add two complex numbers, their real and imaginary parts add separately:
Re(z1+ z2) = Re(z1) + Re(z2)
Im(z1+ z2) = Im(z1) + Im(z2)
There is no „interaction between them”. With the multiplication it is differently. There is an interaction, and it is this interaction that is responsible for the beauty of complex numbers. Let us make a simple calculation. We will multiply two complex numbers z1 and z2.
z1=x1+y1j, z2 = x2+y2j
z1z2=(x1+y1j)(x2+y2j)=x1x2+x1y2j+x2y1j-x2y2= (x1x2-y1y2)+(x1y2+x2y1)j
We can write it as:
Re(z1z2) = Re(z1)Re(z2) – Im(z1)Im(z2)
Im(z1z2) = Re(z1)Im(z2) + Im(z1)Re(z2)
In particular we can take a complex number z=x+yj and multiply it by itself. What will be the result?
A) Re(z2) = Re(zz) = Re(z)Re(z) – Im(z)Im(z) = Re(z)2 – Im(z)2
B) Im(z2) = Im(zz) = Re(z)Im(z) + Im(z)Re(z) = 2Re(z)Im(z)
These two formulas A), B) will be useful in just a while. We will use them to build a fractal – the Mandelbrot set. But I will dive into it next time. First let us play with the numbers starting with a simple formula. Let us fix a complex number c, say:
c = 0.75 + 0.1j
We shall consider transformations of a complex number z described by the formula:
New z is the old z squared plus c
T(z) = z2+c
Let us start with z = 0. According to our transformation rule:
T(0) = 02+c = c = 0.75 + 0.1j
We can apply our transformation the second time, now to the result of the first transformation:
T(T(0)) = c2+c
and so continuing we will get
T(T(T(0))) = (c2+c)2+c
(T(T(T(0)))) = ((c2+c)2+c)2+c
Calculating even with a piece of paper and a calculator would soon cease to make sense. A computer can do it for us. Let us denote by Tn(0) the result after the n-th application of the transformation T. Let me show on the picture below the point obtained as the result of the first 33 transformations (note: when we apply the same transformation many times, as in for instance above, we use the term „iterations”). Why do I stop at 33 iterations? Because 33 is, for some reason, a mysterious number? Not exactly. You will see it in a while. So, we are iterating T thirty three times. Here is the result:
On the picture there is also a circle of radius 2 – I have put it there for a reason. We can see that for 32 iterations our complex number was politely wandering inside the circle. But, evidently, enough was enough, and the next time it escaped from the circle. Using some algebra it can be shown that once our point escapes from the circle of radius 2, it will never return there, independently of the value of our constant c. We will not discuss here these rather technical matters.
So, we got the number 33. Let's see what will happen if we choose this time
c = 0.75 + 0.01j.
How many iterations are needed for Tn(z) to escape the enchanted circle? A simple computer experiment shows that this time 315 iterations are needed. Here is the result. The 315 iteration is outside the circle:
It looks like there may be some regularity, some rule.... So let's continue with our experiments. What will happen with c = 0.75 + 0.001j? Well, I checked what will happen and here is the result:
This time 3143 iterations were necessary for the point to escape from the circle.
Well, look:
0.1 times 33 = 3.3
0.01 times 315 = 3.15
0.001 times 3143 = 3.143
If you know some programming language ( I am going to discuss it in the next note and my chosen language will be Basis, in fact I will suggest FreeBasic, a freeware available from here, in fact I am going to explain how to use it), you can continue the experiment. I did it and here is what comes out with c = -0.75+0.0000001j – the point escapes with 31415927-th iteration. Notice that:
0.0000001 times 31415927 = 3.1415927
It looks much like an approximation of a well known number. Is it Pi? Did we discover, while playing with numbers, something new? Well, not this time. This phenomenon was discovered by Dave Boll in 1992. It took a while before someone got interested, and then another while before the phenomenon has been understood. (see the pdf link). The author of the linked paper, Aaron Klebanoff is a mathematician and his research was supported by NSF and encouraged by the Navy.
So we see that playing with numbers one can discover new unsuspected regularities.
To be continued.
What are complex numbers good for? Well, they are for, for instance, for the production of fractals. How much is investment is needed for starting such a production? Not much. Let me start from complex numbers next time I will move to the Mandelbrot fractal. Later on I will explain what quantum fractals are about.
First complex numbers. To deal with them one only needs to know how to add and how to multiply. Well, some knowledge of fractions will also prove to be useful.
A complex number is nothing else but an expression of the form
x+yj
Here x and y are „ordinary numbers”, real numbers, while j is a symbol. The only thing we need to know is the rule that „j times j is minus one”
j2 = jj = -1
Note: Mathematicians and physicist usual write „i” instead of „j”. In the science electricity „j” is used instead, mainly because "i" is reserved for the electric current. I will keep to the notation „j”.
The usual rule of addition and multiplication hold. Given two complex numbers, for instance
0.5+0.75j
0.3-2j
we can add them:
(0.5+0.75j)+(0.3-2j) = 0.5+0.75j+0.3-2j
collect the coefficients, those without j and those with j:
(0.5+0.3)+(0.75-2)j
and we obtain a new complex number, the sum of the two:
0.8-1.25j
There is no difference between this rule of addition of complex numbers and the usual rule of adding vectors using the parallelogram rule (the same way we add forces), as depicted below:
Therefore complex numbers are vectors on the plane. The number x+yj is represented as a vector in Cartesian coordinates, with coordinates x,y.
The same way as a vector, a complex number z can be described by giving its length and the angle between the vector z and the x axis. The length of the vector that represents z is called the modulus (or absolute value) of z. It is usually denoted as |z|. The angle between the vector and the x-axis is called the argument of z, and is usually denoted by arg(z). Sometimes we also use the term „phase of z” instead of „argument of z”. Here is the picture:
Two complex numbers can be also multiplied one by another to give another complex number – their product. The only rule needed in order to multiply two complex numbers is this one: j times j is -1.
Therefore
(0.5+0.75j)(0.3-2j) =
(0.5)(0.3)+(0.5)(-2)j+(0.75j)(0.3)+(0.75j)(-2j) =
0.15-j+0.225j+1.5 = 1.65-0.775j
One can ask: why such a strange rule? Yet this rule has a simple geometrical interpretation. Multiplying two complex numbers, the lengths multiply while the phases add. Below is the illustration of this fact using the simple example of multiplying j = 0 + 1j by itself
The vector representing j has unit length, therefore jj will also have length 1 (1 times 1 is 1). The vector representing j is at 90 degrees to the x axis, therefore jj will be at 90+90=180 degrees. And this exactly -1 on the x axis. This way we obtain back our starting rule: „j times j is -1.”
Given a complex number z=x+yj, the number x (x-component of the vector) is called the real part of z and denoted by the symbol Re(z) („Re” for „real”), while the number y (y- component of the vector) is called the imaginary part of z and denoted by the symbol Im(z) („Im” for „imaginary”). Yet there is nothing imaginary about it. It is as real as x. Just a tradition.
When we add two complex numbers, their real and imaginary parts add separately:
Re(z1+ z2) = Re(z1) + Re(z2)
Im(z1+ z2) = Im(z1) + Im(z2)
There is no „interaction between them”. With the multiplication it is differently. There is an interaction, and it is this interaction that is responsible for the beauty of complex numbers. Let us make a simple calculation. We will multiply two complex numbers z1 and z2.
z1=x1+y1j, z2 = x2+y2j
z1z2=(x1+y1j)(x2+y2j)=x1x2+x1y2j+x2y1j-x2y2= (x1x2-y1y2)+(x1y2+x2y1)j
We can write it as:
Re(z1z2) = Re(z1)Re(z2) – Im(z1)Im(z2)
Im(z1z2) = Re(z1)Im(z2) + Im(z1)Re(z2)
In particular we can take a complex number z=x+yj and multiply it by itself. What will be the result?
A) Re(z2) = Re(zz) = Re(z)Re(z) – Im(z)Im(z) = Re(z)2 – Im(z)2
B) Im(z2) = Im(zz) = Re(z)Im(z) + Im(z)Re(z) = 2Re(z)Im(z)
These two formulas A), B) will be useful in just a while. We will use them to build a fractal – the Mandelbrot set. But I will dive into it next time. First let us play with the numbers starting with a simple formula. Let us fix a complex number c, say:
c = 0.75 + 0.1j
We shall consider transformations of a complex number z described by the formula:
New z is the old z squared plus c
T(z) = z2+c
Let us start with z = 0. According to our transformation rule:
T(0) = 02+c = c = 0.75 + 0.1j
We can apply our transformation the second time, now to the result of the first transformation:
T(T(0)) = c2+c
and so continuing we will get
T(T(T(0))) = (c2+c)2+c
(T(T(T(0)))) = ((c2+c)2+c)2+c
Calculating even with a piece of paper and a calculator would soon cease to make sense. A computer can do it for us. Let us denote by Tn(0) the result after the n-th application of the transformation T. Let me show on the picture below the point obtained as the result of the first 33 transformations (note: when we apply the same transformation many times, as in for instance above, we use the term „iterations”). Why do I stop at 33 iterations? Because 33 is, for some reason, a mysterious number? Not exactly. You will see it in a while. So, we are iterating T thirty three times. Here is the result:
On the picture there is also a circle of radius 2 – I have put it there for a reason. We can see that for 32 iterations our complex number was politely wandering inside the circle. But, evidently, enough was enough, and the next time it escaped from the circle. Using some algebra it can be shown that once our point escapes from the circle of radius 2, it will never return there, independently of the value of our constant c. We will not discuss here these rather technical matters.
So, we got the number 33. Let's see what will happen if we choose this time
c = 0.75 + 0.01j.
How many iterations are needed for Tn(z) to escape the enchanted circle? A simple computer experiment shows that this time 315 iterations are needed. Here is the result. The 315 iteration is outside the circle:
It looks like there may be some regularity, some rule.... So let's continue with our experiments. What will happen with c = 0.75 + 0.001j? Well, I checked what will happen and here is the result:
This time 3143 iterations were necessary for the point to escape from the circle.
Well, look:
0.1 times 33 = 3.3
0.01 times 315 = 3.15
0.001 times 3143 = 3.143
If you know some programming language ( I am going to discuss it in the next note and my chosen language will be Basis, in fact I will suggest FreeBasic, a freeware available from here, in fact I am going to explain how to use it), you can continue the experiment. I did it and here is what comes out with c = -0.75+0.0000001j – the point escapes with 31415927-th iteration. Notice that:
0.0000001 times 31415927 = 3.1415927
It looks much like an approximation of a well known number. Is it Pi? Did we discover, while playing with numbers, something new? Well, not this time. This phenomenon was discovered by Dave Boll in 1992. It took a while before someone got interested, and then another while before the phenomenon has been understood. (see the pdf link). The author of the linked paper, Aaron Klebanoff is a mathematician and his research was supported by NSF and encouraged by the Navy.
So we see that playing with numbers one can discover new unsuspected regularities.
To be continued.