An excursion to the visual world of complex functions and dynamics

Zoltán Kovács, Bolyai Institute, University of Szeged, Hungary

1.General overview

However complex analysis seems to be an extremal discipline of teaching of mathematics, many areas of introductory education at university level are much easier to understand if the student has some overview of behavior of complex functions. Many problems to be solved in real variable are specializations of the complex case, including dynamic systems, numerical analysis and differential equations. The workshop will summarize the benefit of using complex numbers for these usual areas of mathematics education.

Three different pieces of software will be shown applicable for the teacher's use: WebMathematics Interactive 2 (WMI2, http://matek.hu), Real-Time Zooming Math Engine (RTZME, http://rtzme.sf.net) and XaoS (http://xaos.sf.net). Surprisingly enough, we will also use a regular spreadsheet editor for basic visualizations.

2.Technical overview of the workshop

This workshop is planned to an audience having personal computers (laptops) for each individual. The workshop consists of 3 separated parts:

  1. During the first part we will use WMI2. The participant only have to use a simple web browser (Google Chrome, Mozilla Firefox or Internet Explorer should work “out of the box”). This first part will be closed showing the “complex variable function graphs” in WMI2 which can be extended to a real-time demonstration. This will be covered in the second part.
  2. In the second part we need to have a Linux workstation to run RTZME.

    1. If you have Linux on your laptop running, and it is available to use Debian repositories (in other words, you have a Debian based distribution, e.g. Ubuntu), then you could add the “deb http://matek.hu/linux linuxversioncodename main” line to /etc/apt/sources.list (for example, for Ubuntu Karmic Koala this line is “deb http://matek.hu/linux karmic main”). Then run “apt-get update; apt-get install rtzme” from command line. The “rtzme” executable is the appropriate software you need now (it is also available from command line).
    2. If you don't have Linux on your laptop, or it is incompatible with Debian repositories, please take an Xubuntu or Ubuntu Live CD from the lecturer with a 1 page description on what to do. Don't worry no software will be installed on your laptop, only the memory will be used for the time of the workshop presentation. The Xubuntu CD is faster, but gives less user experience features than Ubuntu. If you have an older laptop, please ask an Xubuntu from the lecturer. If you have a fast, new model, you can use Ubuntu as well.
  3. In the third part we need an arbitrary type of workstation to run XaoS, and, in addition, we also need a spreadsheet program. To run XaoS, do the following:

    1. If you have Linux on your laptop running, and you were able it during the second part without any problems, you should install the “xaos” package as you usually do.
    2. If you restarted your laptop and tried the Xubuntu (or Ubuntu) Live CD during the second part, you should install the “xaos” package by pressing ALT-F2 and typing “sudo apt-get install xaos”.
    3. If you rebooted your laptop since the second part and you are now using Windows (or Mac), the please visit http://matek.hu/xd to download the installer executable for XaoS which fits to your current operating system.

    You can use your favourite spreadsheet program, but the lecturer will show everything in OpenOffice Calc (or Gnumeric, depending on the participants). So, if you are in a doubt, just use OpenOffice, too.

3.The workshop

3.1.Complex numbers everywhere

Expressions and their factorization is a normal problem in secondary school. Many tricks are to be learned to have usual skills to transform a2 + 2 a b + b2 to (a + b)2. But what to do with a2 + b2? An easy question! The answer is: (a + b i)(a - b i), and, unfortunately, there is no easier answer.

Invoking WMI2, we do not get this “complex” answer: “factors of a^2+b^2” give nothing special. (You may also have a look at the web URL.) The usual computer algebra systems give the possibility to define the domain of the symbolic calculation, but here it is not allowed. (Exercise: do the factorization in your favourite CAS. Solution for Maxima, WMI2's backend is factor(a^2+b^2,i^2+1).) Is this a good result from the teacher's point of view? Probably yes, in secondary school. Probably no, at university level. (→WMI 2.2)

Of course, such a problem can be written to an essentially same question: to find the roots of x2 + 1 = 0. WMI2's solution does not give any result, but here you can fine tune the calculation with a different button. These buttons are installed in different layouts in WMI2 to prevent young students from catching bogus output.

Solving third order polynomials are also a kind of bitter. Adding x3 to the above equation, we gain a terrible result for most human being (try both buttons on your own!). A good example of modern handling of this general problem is Wolfram's approach in Wolfram|Alpha. This also shows the graph of the function in real variable, the roots symbolically and numerically, and also visualizes the roots in the complex plane. Luckily, WMI2 has a built-in function to make even more visualization of complex roots. To see that, try this. To understand the graph, we need to learn about domain coloring (see this page for another explanation). (→Merge the articles + add link to WMI2.)

Now let's do some experiments. Try the complex color wheel graph of the following functions:

It's worthy to zoom in and out and try to switch the grid on and off.

Before continuing experiments in the second part, some more “easy” examples which lead to complex arithmetics:

  1. (Continuing the introductory example.) Factorization of higher order polynomials in real variable. It is very helpful to know the factorization over the field of complex number fields. As the final step, pairing the complex conjugate roots lead to the factorization over the field of real numbers.
  2. General solution of arbitrary polynomial (or non-polynomial) equation. Elementary calculus exercises can rely on stable methods for equation solving. Zeroes, extremas, convexity questions all lead to equations which “sometimes” cannot be solved symbolically.
  3. Eigenvalues. Basic application of linear algebra methods can already lead to 2×2, 3×3 (and larger) matrix eigenvalue problems which can make undergraduate feel miserable on having complex roots on calculation. Hint: if symbolic calculation gives bogus output, search for graphical solutions first.

3.2.Understanding by exploring

In this second part we will use RTZME. Our aim is to

3.3.Granny and the Mandelbrot Set

You don't need extraordinary tools to visualize basic chaotic behavior on the real line. All you need is a spreadsheet software and 2 minutes:

  1. Enter “1” into cell A1.
  2. Enter “=A1^2+A$1” into A2.
  3. “Pull down” A2.
  4. Create a graph.

Now you can illustrate all of the following:

To see more, you need a fractal explorer software. Now we will try XaoS, written by Jan Hubicka (and other contributors).

Try the following:

  1. The Mandelbrot fractals (keys 1–5).
  2. Go to Fractal→User formula and enter “z^2+c”, “z^1.5+c”, “z^2+i+c”.
  3. Newton's formula (keys 6–7).