作者kaiweiliou (意志消沉的我)
看板NTUNL
標題Re: [心得] 一些matlab小程式
時間Sat Nov 26 00:43:34 2005
這是julia set:(我的班門弄斧...)
limit = 120;
dif = 0.01;
d=complex(-0.63,-0.4)
for a = -2 : dif : 2;
for b = -2 : dif : 2;
c = complex(a,b);
z = c;
count = 1;
while count < limit
z = z^2 +d;
if abs(z) > 2
break;
end
count = count + 1;
end
if count == limit
plot(a, b, '.');
hold on;
end
end
end
hold off;
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 140.112.223.94
1F:推 ANUBISANKH:感謝 11/26 09:36