Developer(s): Murray Barasch, Carolyn Barasch
Date: 1992
Type: Program
Platform(s): TS 2068
Tags: Mathematics
A four-line program that plots an ellipse of any size and rotation from its parametric equations.
RUN it and enter five values, pressing ENTER after each: the centre X and Y, the half width A, the half height B, and the rotation R in radians (128, 88, 80, 40, 0.5 is a good first try). The whole ellipse has to fit on the 256 by 176 screen. Drawing takes under two minutes.
Published in LISTing November 1992 (Looping the 2068).
Source Code
10 INPUT "INPUT X,Y,A,B,R"'X'Y'A'B'R
20 FOR T=0 TO 2*PI STEP .05
30 PLOT X+A*COS T*COS R-B*SIN T*SIN R,Y+A*COS T*SIN R+B*SIN T*COS R
40 NEXT TNote: Type-in program listings on this website use ZMAKEBAS notation for graphics characters.


