Charles T. Smith wrote:
> Hello Yehuda,
>
> At 8:27 PM +0300 6/28/1998, Yehuda wrote:
> >Here's a different approach to draw Cardioid and Nephroid. The following short
> >codes are for MSWLogo and UCBLogo. The Cardioid and the Nephroid are the
> >envelope of the relevant images:
>
> I was not able to make the following work in UCBLogo. My version (v4.6)
> choked on setsc and circle. (I tried an earlier version of MSWLogo, but had
> the same results.) I assume that setsc is like setbg, but I wasn't sure how
> circle was supposed to work. My guess is that :rad is radius. Can you
> enlighten me on how circle works. Is it a procedure in your library?
>
> I am not sure what you mean by "envelope of the relevant images." That
> might become clear, though, when I get it to work.
>
> Thanks for the help. This "string art" is a blast!
>
> Chuc
>
> >
> >to main ; Cardioid
> >cs ht pu rt 90
> >setsc 0 setpc 6 draw 35
> >end
> >
> >to draw :rad
> >repeat 32[fd :rad pd
> > circle distance se 0 :rad
> > pu bk :rad rt 360/32]
> >end
> >
> >============================
> >
> >to main ; Nephroid
> >cs ht pu
> >setsc 0 setpc 4 draw 46
> >end
> >
> >to draw :size
> >repeat 32[fd :size pd
> > circle xcor
> > pu bk :size rt 360/32]
> >end
Hi Chuck,
You are right, I'm sorry. For UCBLogo please replace SETSC 0 by SETBG 0, and CIRCLE
:RAD by ARC 360 :RAD.
I attach the resulting images (you can find them also in
http://www.geocities.com/CollegePark/lab/2276/ ).
Regards...
[[Yehuda]]
_/ _/ _/ _/_/_/_/_/ _/_/_/_/
_/ _/ _/_/ _/ _/
_/_/_/ _/ _/ _/ _/
_/ _/ _/_/_/_/ _/ _/
_/ _/_/ _/ _/ _/_/_/_/
http://www.geocities.com/CollegePark/lab/2276/
Global SchoolNet Foundation -
Linking Kids Around the World!
Copyright GSN - All Rights Reserved
- Comments
& Questions
Visit GSN's
Global
Schoolhouse for more exciting learning resources!
Search our Site
-
Home