SET MODE "color" SET WINDOW 0,1920,0,1024 SET BACKGROUND COLOR "white" LET x=.5 LET y=.75 LET a=0 LET b =0 LET s1=900 LET s2 =s1*1024/1920 RANDOMIZE PRINT " KISSING CIRCLES FRACTION I.F.S.7 PART " PRINT " APPOLONIAN 5 RUG" PRINT " BY R.L.BAGULA 16 feb 20002 ©" LET R=1+SQR(1.55) dim aa(10),bb(10) for i=1 to 5 let aa(i)=cos(2*Pi*i/5) let bb(i)=sin(2*Pi*i/5) next i LET R1=1+SQR(2.9) FOR n= 1 TO 4000000 LET a =RND LET b=RND IF a <= 1/7 THEN LET x1= 2*X*Y/(X^2+Y^2) LET y1=(Y^2-X^2)/(Y^2+X^2) END IF IF a<=2/7 AND a>1/7 THEN LET x1=X/R1+SQR(2)*aa(1)/R LET y1=Y/R1+SQR(2)*bb(1)/R END IF IF a<=3/7 AND a>2/7 THEN LET x1=X/R1+SQR(2)*aa(2)/R LET y1=Y/R1+SQR(2)*bb(2)/R END IF IF a<=4/7 AND a>3/7 THEN LET x1=X/R1+SQR(2)*aa(3)/R LET y1=Y/R1+SQR(2)*bb(3)/R END IF IF a<=5/7 AND a>4/7 THEN LET x1=X/R1+SQR(2)*aa(4)/R LET y1=Y/R1+SQR(2)*bb(4)/R END IF IF a<=6/7 AND a>5/7 THEN LET x1=X/R1+SQR(2)*aa(5)/R LET y1=Y/R1+SQR(2)*bb(5)/R END IF IF a<= 1 AND a>6/7 THEN LET x1=(X^2-Y^2)/(X^2+Y^2) LET y1=2*X*Y/(Y^2+X^2) END IF SET COLOR 255 LET x=x1 LET y=y1 IF n>10 THEN PLOT 1920/2+s1*x,1024/2+s2*y NEXT n END