R



On Fri, Feb 26, 2010 at 10:01 PM, Adam Majewski <adammaj1 at o2.pl> wrote:
> Hi,
>
> I would like to made similar animation :
> http://commons.wikimedia.org/wiki/File:Mandelbrot_Creation_Animation_%
> 28800x600%29.gif
>
> I have made :
>
> f(x,y):=
> ?block([i:0, c:x+y*%i,ER:4,iMax:20,z:0],
>
> ?while abs(z)<ER and i<iMax
> ? ? do (z:z*z + c,i:i+1),
> ?abs(z))$
>
> plot3d('f(x,y), [x,-2,2], [y,-2,2], [plot_format,gnuplot],
> ?[gnuplot_pm3d,true],
> ?[gnuplot_preamble, "set pm3d at b; set view map"])$
>
> wxMaxima works ( it is only one image ) but after some time still no
> effect.

You can start with this (you will need wxmaxima 0.8.4).

f(x,y,n) :=
 block([i:0, c:x+y*%i,ER:4,iMax:n,z:0],
 while abs(z)<ER and i<iMax
    do (z:z*z + c,i:i+1),
 min(ER,abs(z)))$

wxanimate_draw3d(
    n, 5,
    enhanced3d=true,
    user_preamble="set pm3d at b; set view map",
    xu_grid=70,
    yv_grid=70,
    explicit('f(x,y,n), x, -2, 0.7, y, -1.2, 1.2))$

To get a nicer animation you will need to increase n, xu_grid and
yv_grid options. It takes a lot of time so I didn't try.

Andrej