Forum Moderators: coopster & phranque

Message Too Old, No Replies

perl Mandelbrot

         

littleman

2:07 am on Jan 9, 2001 (gmt 0)



I found this on the web, I can't give the author credit.

#!/usr/local/bin/perl
$Cols=79; $Lines=30;
$MaxIter=16;
$MinRe=-2.0; $MaxRe=1.0;
$MinIm=-1.0; $MaxIm=1.0;
@chars=(' ','.',',','-',':','/','=','H','O','A','M','%','&','$','#','@','_');

for($Im=$MinIm;$Im<=$MaxIm;$Im+=($MaxIm-$MinIm)/$Lines)
{ for($Re=$MinRe;$Re<=$MaxRe;$Re+=($MaxRe-$MinRe)/$Cols)
{ $zr=$Re; $zi=$Im;
for($n=0;$n<$MaxIter;$n++)
{ $a=$zr*$zr; $b=$zi*$zi;
if($a+$b>4.0) { last; }
$zi=2*$zr*$zi+$Im; $zr=$a-$b+$Re;
}
print $chars[$n];
}
print "\n";
}

littleman

2:23 am on Jan 9, 2001 (gmt 0)



And, though is has nothing to do with SEO or anything else, check out [arosmagic.com ]. It is pretty cool
Her is the link to the download [arosmagic.com].