Codes for Archimedes' spiral

to main cs ht setpensize [2 2] archimed.spiral.draw 1 .05 0 6 end to archimed.spiral.draw :w :v :t :nmax ; w - angle velocity ; v - linear velocity ; t - time ; nmax - number of turns aroun the center if :w*:t>:nmax*360 [stop] pu fd :v*:t pd fd 0 pu bk :v*:t rt :w archimed.spiral.draw :w :v :t+1 :nmax end