Complex Visualizer 1.0

A simple program used for visualizing complex functions. The left coordinate area can be drawn upon and the right coordinate area shows how the drawn points are mapped via the function defined in the lower area text fields (distinct fields for x and y mappings also, used if the f(z) is left empty). You can also use the graphical animation buttons on the left and control the speed of the animation with the slider below the left coordinate area. You can also define the limits of the areas or use the zoom buttons.
The program uses Java classes made by Leigh Brookshaw (Leigh's Java 2D Graph Package homepage) and DJEP for parsing the functions. This program, and these libraries are published under GNU GPL Licence.
Feel free to send suggestions and feedback to me at You can find the source code here
NOTICE! The main concept of the program is to offer visual take on the functions, not to offer exact or accurate values nor graphs. The general concept of the code is quite broad and approximate and hence especially the right area can show artifacts and "weird things" when zoomed. So some discretion and reservation is required from the viewer.
Example function presented is f(z) = z^2, hence -> x : x^2-y^2 and -> y : 2*x*y
You can:
  • Define the function either by offering distinct real and imaginary part mapping or by giving complex function in form f(z) = z^2 (for example). If the f(z) field is empty, distinct parts are used, if f(z) field contains text, it will be used. You can use any of the three variables: z, x, y. z is identical to structure x+y*i.
  • Draw to the left coordinate area with left mouse button
  • Dynamically move the coordinate areas with right mouse button + dragging (HINT! Use this while animation is running, or grid is active)
  • Drive various graphical animations with the buttons on the left
  • Scale and change the viewable limits of the coordinate areas
  • Change the function by using the textfields at the bottom of the screen (remember to use parentheses, for example sin(x))
  • Change the speed of the animation with the slider
NOTICE!
  • If the scale difference between the two coordinate areas is too big, the rightmost image will definitely be unaccurate, as only some of the critical points from the left are picked for mapping
  • The mapped points are connected with straight lines to make the image more intuitive, but with some functions this will also cause problems, because if the points are "divided" to different places on the plane, the combining line will still be drawn between them, making the view easily cluttered with extra lines. Use the Lines -button for switching between modes where the connecting lines are drawn or omitted.



Interesting functions (recommend to set the left area so that it's not centered at origo. For example [0,10] for x and y works nicely):

f(z)
(z^2-i)/(2*z^2+2*i)
sin((z^3)-1)/z
log(z)
z+1/z
e^z
z*e^(i*angle) - rotation (angle in radians pi/3 for example)
z*cos(x/20)*cos(y/20)
z*(-1)^x
z*e^(i*y+i*x)
z^(5*i)+z^(4*i)+z^(3*i)+z^(2*i)+z
-> x-> y
x^2-y^22*x*y
x^2+y^22*x*y
sin(x)cos(x)
sin(x)*(exp(y)+exp(-y))/2cos(x)*(exp(y)+exp(-y))/2
cos(x)*(exp(y)+exp(-y))/2sin(x)*(exp(y)+exp(-y))/2
exp(x)*cos(y)exp(x)*sin(y)