In project 7, I used turtle library again to draw certain different shapes. However, the approach to drawing the shapes was very different from the previous projects that used turtle library. The following were the key differences: 1) I used L-system, which enabled me to draw an organized yet complex graphics/images without long turtle commands and 2) I used list and indexes to contain and manipulate information of different L-systems. Essentially, the idea of using list was recycled from the project 5. I think list is a good way of using different L-systems if one is attempting to assign different parameters to the systems such as color, thickness, scale, etc.
Solutions to tasks:
First of all, I assigned different values to the indexes that I used to draw different L-systems.
. The following list shows the actual values I assigned to those indexes.
How do I actually use this list information to draw L-systems? I just have to assign more parameters to the drawString() function and modify the function like below.
My abstract image had three L-systems that drew tree, sun, and snow. Below is the image.
I wrote my own tree L-system based on systemB.txt; snow and sun L-systems were based on the example that was given during the lecture by professor Skrien.
Sources, imported libraries, and collaborators: