27 lines
536 B
Plaintext
27 lines
536 B
Plaintext
escala = 1/120
|
|
zeroX = 320
|
|
zeroY = 240
|
|
maxiter = 32
|
|
|
|
CR = -.798
|
|
CI = .1618
|
|
|
|
clear screen
|
|
open window 640, 480
|
|
for x = 0 to 2*zeroX - 1
|
|
for y = 0 to 2*zeroY - 1
|
|
zreal = (x - zeroX) * escala
|
|
zimag = (zeroY - y) * escala
|
|
for iter = 1 to maxiter
|
|
BR = CR + zreal*zreal - zimag*zimag
|
|
zimag = CI + 2*zreal*zimag
|
|
zreal = BR
|
|
if zreal*zreal + zimag*zimag > 4 then
|
|
dot x, y
|
|
break
|
|
end if
|
|
next iter
|
|
next y
|
|
next x
|
|
end
|