This page’s menu:
** This Applet May Not Work in IE **
Here are the applet requirements: "You are required to draw the Mandelbrot set and calculate it recursively. The user interface should ask for 4 things to be input: X min, X max, Y min, Y max. There will also be a button to redraw the set. There is a simple equation for calculating the Mandelbrot set. For each pixel (X, Y): The Mandelbrot equation is: Z(n+1) = (Zn)2 + C where Z0 = 0 and C is the (X,Y) coordinate. You will be using a recursive method using this equation to determine the color of each pixel. Each recursive call will figure a NewX and a NewY coordinate to determine whether or not to recurse again, or just to return the number of iterations. NewX= (CurX*CurX)-(CurY*CurY)+OrigX; NewY= (2*CurX*CurY)+OrigY; You will pass the pixel's X,Y coordinates into the method as the OrigX and OrigY. For the first iteration, the CurX and CurY coordinates are Zero, and the Count is Zero. If sqrt[(NewX*NewX)+(NewY*NewY)] is greater than 2, then return the number of recursive calls were made to reach this point. Otherwise, if the number of calls is greater than 400 then return 400; Otherwise, call the method recursively, passing in as the CurX and CurY the NewX and NewY you just figured." -- BYU Computer Science 142, Lab 13