REM EllipseArt, RG Weston, 27.12.2002 MODE8:OFF PRINTTAB(32,8)"Ellipses" delay=INKEY(100):CLS REPEAT GCOL0,RND(8) p=100:q=100 TIME=0 Time=200+RND(800) T=RND(360) :REM angle of ellipse axis to the x axis a=5+RND(100):REM semimajor axis e=RND(100)/100 :REM eccentricity REPEAT ORIGIN p,q PROCellipse(a,e,T) p=(p+RND(30))MOD1200:q=(q+RND(30)) MOD1000 UNTIL TIME>Time UNTIL FALSE END : DEF PROCellipse(a,e,T) PLOT69,0,0 b=a*SQR(1-(e^2)) FOR t=1 TO 360 STEP 2 REM ellipse centred on origin x= a*COSRADt y=b*SINRADt REM shift centre to the focus xx=x-(a*e) yy=y REM Rotate point by angle T xxx=(xx*COSRADT) + (yy*SINRADT) yyy=-(xx*SINRADT) + (yy*COSRADT) IF t=1 MOVE xxx,yyy DRAW xxx,yyy NEXT REM G=GET ENDPROC