Well, it seems (to me) that I have discovered a new Turtle-type fractal.
Here's a snapshot of the XLISP version:
The Brain fractal for n=12 iterations. |
You can have the original XLISP
sources [lost!]
for MSDOS (unfortunatedly I was not able to compile it for LINUX) and the
xlisp.exe binary (i.e. the LISP environment).
I have carefully checked it for viruses -- it seems to be clean.
Running it it's simple: unpack the archive to some directory and
(from MSDOS or DOSEmu under Linux) type the following command:
xlisp brain.lsp
If you want to compile the binary by yourself, you can get the whole XLISP package.
I wanted to have a Java version of it.
Hence I have hardly worked on modifying the CLSFractal class from Sun's JDK.
After two days of hard programming I discovered that I did not have to
modify the class itself but it was enough to modify the parameters for this
class such that for a to have the same shape.
This is a paradoxical conclusion because the algorithm's primitives for
moving the turtle are not the same. (You can convince yourself of
that by running my LISP version with n running in {1,...,4} and the Java version
for the same n)
You may compare the LISP version with the Java version