LOGO Challenge - Circles as bugs
Here are some circle bugs to try to replicate with some elegant
programming, plus some sequences generated elegantly in LOGO.
This builds on the Challenge Circles as Animals .
The idea of 'bugs' that grow with each successive generation and (when this problem was written) thoughts of the Y2K bugs- which if the newspapers were to be believedwould be here, there, everywhere. Surely some mistake! And it was!
However below are some bugs for the new millennium that can be replicated with some elegant programming.
Image
Image
Image
You might like to think about, discuss with others and try evaluating before copying out the following procedures and experimenting further
TO FIB :X :Y
PR :Y
WAIT 15
FIB :Y :X +:Y
END
Try FIB 0 1
TO POW :X :Y
PR :Y
WAIT 15
POW :X :X * :Y
END
Try POW 2 1
TO TRI :X :Y
PR :Y
WAIT 15
TRI :X + 1 :X + :Y
END
Try TRI 1 0
You may even like to consider sending us other procedures that generate other special sequences of numbers.
Some of these circle designs are very attractive, especially with the colour, and also very demanding. Close attention to detail is needed, but if you have done some of the other challenges involving circles you might feel quite confident. Otherwise why not go back and look at LOGO Challenges 10 , 11 and 12 .
The WAIT < n> command simply asks LOGO to WAIT before carrying out the next command so that you have time to see what is happening!!
These sequences should look very familiar using the values for the variables that are suggested but what is happening when you change the starting value of the variable?
You might also like to begin by thinking about a procedure that was sent to us.
TO FIBUPM :X :Y :M
IF :M = 0 [PR :Y STOP]
FIBUPM :Y :X + :Y :M - 1
END
What is going on here?
Remember - be patient and change only one variable at a time to begin to see what is happening.