At 01:58 PM 6/20/98 +0300, you wrote:
>Hi,
>
>A friend asked me how to reproduce in Logo this Celtic knot.
>
>Any idea?
>
>Regards...
>
>[[Yehuda]]
>Here's a challenge for you. This braided border produces a similar pattern.
How about changing this one?TO BORDER
CS HT
PU SETPOS [-455 -140] PD HT SETH 0
BRAID
ENDTO BRAID
(LOCAL "SQR2 "HFSQ2 "S2 "H2 "S2H2)
MAKE "SQR2 1.4 ; SQRT 2
MAKE "HFSQ2 0.7 ; :SQR2 * 0.5
MAKE "S2 8.5 ; :SQR2 * 6
MAKE "H2 4.2 ; :HFSQ2 * 6
MAKE "S2H2 12.7 ; :S2 + :H2
PU FD 24 RT 45 FD 4.2 SETH 0 PD
REPEAT 2 [STRIP 36 CORNER STRIP 72 CORNER]
ENDTO CORNER
LT 45 FD :H2 RT 45 FD 6
RT 45 FD :S2 RT 45 FD 18
RT 45 FD :S2H2 PU
RT 90 FD :H2 PD RT 90 FD :S2
LT 45 FD 18 LT 90 FD 6 PU
LT 45 FD :S2 PD LT 90 FD 17 PU
RT 90 FD :H2 PD RT 90 FD 17 PU
RT 45 FD 6 RT 90 FD 12 PD
RT 45 FD :H2 RT 45 FD 6
RT 45 FD :H2 PU RT 90 FD :H2 PD
RT 45 FD 6 PU BK 15 RT 90 FD 9 RT 90 PD
ENDTO START
; Here's a simple procedure that puts a braided border
; around the edge of the screen. Morf likes frames
; for his pictures.
;
; You can change the size of the border by changing the
; variable used by STRIP in the BRAID procedure.
BORDER
ENDTO STRIP :N
REPEAT :N [LT 45 FD :H2 RT 45 FD 6 RT 45 FD :S2H2 PU RT 90~
FD :H2 PD RT 90 FD :S2 LT 45 FD 6 PU LT 45 FD :S2H2 PD ~
LT 135 RT 45 FD :H2 LT 45 FD 6 LT 45 FD :S2H2 PU LT 90 ~
FD :H2 PD LT 90 FD :S2 RT 45 FD 6 PU RT 135 FD :S2H2 RT 45 FD 6 PD]
END
Hello Jim,
It's a great braided frame. The person who programmed it showed a real love, care and devotion to this project!
I played around with it, but all I could do is to make your above code somewhat clearer and more readable. Yet, I'm stil puzzeled by "my" knot, and how to produce it.
Regards...
[[Yehuda]]
to draw :high :wide
repeat 2[strip :high corner strip :wide corner]
end
to strip :times
repeat :times[knot]
end
to knot
lt 45 fd :3s rt 45 fd 6 rt 45 fd :9s
pu rt 90 fd :3s pd
rt 90 fd :6s lt 45 fd 6
pu lt 45 fd :9s pd
lt 135 rt 45 fd :3s lt 45 fd 6 lt 45 fd :9s
pu lt 90 fd :3s pd
lt 90 fd :6s rt 45 fd 6
pu rt 135 fd :9s rt 45 fd 6 pd
end
to corner
lt 45 fd :3s rt 45 fd 6 rt 45 fd :6s
rt 45 fd 18 rt 45 fd :9s
pu rt 90 fd :3s pd
rt 90 fd :6s lt 45 fd 18 lt 90 fd 6
pu lt 45 fd :6s pd
lt 90 fd 17
pu rt 90 fd :3s pd
rt 90 fd 17
pu rt 45 fd 6 rt 90 fd 12 pd
rt 45 fd :3s rt 45 fd 6 rt 45 fd :3s
pu rt 90 fd :3s pd
rt 45 fd 6
pu bk 15 rt 90 fd 9 rt 90 pd
end
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