Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
19
Task/Julia-set/XPL0/julia-set.xpl0
Normal file
19
Task/Julia-set/XPL0/julia-set.xpl0
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
def Cx = -0.72, Cy = 0.27;
|
||||
def ScrW=800, ScrH=600;
|
||||
int X, Y, Iter;
|
||||
real Zx, Zy, T;
|
||||
[SetVid($115);
|
||||
for Y:= 0 to ScrH-1 do
|
||||
for X:= 0 to ScrW-1 do
|
||||
[Iter:= 0;
|
||||
Zx:= 3.2 * float(X-ScrW/2) / float(ScrW);
|
||||
Zy:= 2.4 * float(ScrH/2-Y) / float(ScrH);
|
||||
while Zx*Zx + Zy*Zy < 4.0 and Iter < 300 do
|
||||
[T:= Zx*Zx - Zy*Zy + Cx;
|
||||
Zy:= 2.0*Zx*Zy + Cy;
|
||||
Zx:= T;
|
||||
Iter:= Iter+1;
|
||||
];
|
||||
Point(X, Y, Iter<<21+Iter<<8+Iter<<3);
|
||||
];
|
||||
]
|
||||
Loading…
Add table
Add a link
Reference in a new issue