|
Julia Set: Cosine Variant : Executable or Text Version
The basic Julia Set is formed from the iteration: Znew = Z x Z - C , but you get some great pictures from variations on this theme.
The picture below is from the formula: Znew = COS(Z/C)
Putting Z = x + i.y , to do calculations with COS(Z) is far from obvious. You have to use the following formula:
COS(x + i.y) = COS(x).COSH(y) - i.SIN(x).SINH(y)
Although I haven't included a picture of it, the relevant "Mandelbrot" set asociated with COS(Z/C) looks nothing like the usual Mandelbrot set; it is shaped more like a strange "X"
For the new Assembly Language version above, I found I needed to write my own Floating Point algorithm for EXP(x). Basically, you cannot work out EXP(x) directly in FP Assembler. You have to use EXP(x) = 2^k .EXP(f) where k is an integer. Not only that, but you have to use the formula EXP(f) = 2^(f.lg(e)), where lg(e) is the logarithm of the number e (=2.718281828...) to base 2, and where f.lg(e) must lie between -1 and +1.
|
|