SinCos

Help Contents Examples SinCos
SineCosine (simple) SketchPad (advanched)

SinCos

shows how to draw curves by first creating an object with the formula in it and then only changing the parameter without mentioning the depending objects in the loop at all!

run "geomland

ob "O point 0 0
ob "Ox line :O 0
ob "Oy line :O 90

make "scale :scale*70

ob "csc point 2 0

ob "a 0
make "st (2*pi/360)

ob "sinu point :a*:st sin :a [traced]
ob "cosi point :a*:st cos :a [traced]

historical "sinu
historical "cosi

repeat 72 [ob "a :a+5]

clrdr

ob "cs polygon :history.sinu
ob "cc polygon :history.cosi

SineCosine (simple) SketchPad (advanched)