Line Command Example

Details

Action

Draws a line segment between two specified points. The segment is not stored in window memory, so is not redrawn when the window is refreshed.

line [2, 3], [5, 4]
draws a line segment from the point (2,3) to the point (5,4)

If you define a circle as a parametric function as follows:
make cir(t) [ 5*cos(t) , 5*sin(t) ]
then
line cir(0) cir(1.57)
connects two points on the circle.

Also, the following command draws a pencil of lines:

Command pencil (ex n) {

let cir(t) be [ 5*cos(t) , 5*sin(t) ];

let step be .062831;

do

i := 0

until i>=100 {

line cir(i*step) cir(n*i*step);

let i be i+1;

}

}