We will use the 5 pixel grid to trace out this image. The image of this is shown below:
The plan to draw this shape is given below:
- Lift up the pen
- Set the pensize to 15 pixels
- Move the turtle to the left position of the inner semi-circle of the upper part of the symbol
- Set the heading to 90 degrees
- Place the pen down
- Draw the inner semi-circle
- Lift up the pen
- Move the turtle to the left position of the middle semi-circle of the upper part of the symbol
- Set the heading to 90 degrees
- Place the pen down
- Draw the middle semi-circle
- Lift up the pen
- Move the turtle to the left position of the outer semi-circle of the upper part of the symbol
- Set the heading to 90 degrees
- Place the pen down
- Draw the outer semi-circle
- Lift up the pen
- Move the turtle to the right position of the inner semi-circle of the lower part of the symbol
- Set the heading to 270 degrees
- Place the pen down
- Draw the inner semi-circle
- Lift up the pen
- Move the turtle to the right position of the middle semi-circle of the lower part of the symbol
- Set the heading to 270 degrees
- Place the pen down
- Draw the middle semi-circle
- Lift up the pen
- Move the turtle to the right position of the outer semi-circle of the lower part of the symbol
- Set the heading to 270 degrees
- Place the pen down
- Draw the outer semi-circle
- Lift up the pen
- Place the pen at the location for the leftmost part of the upper part of the symbol
- Set the heading to 0 degrees
- Place the pen down
- Move forward to cover the leftmost part of the upper part of the symbol
- Lift up the pen
- Move the pen to the location of the innermost part of the upper part of the symbol
- Place the pen down
- Move forward to cover the right of the upper part of the symbol
- Lift up the pen
- Place the pen at the location for the leftmost part of the lower part of the symbol
- Place the pen down
- Move forward to cover the leftmost part of the lower part of the symbol
- Lift up the pen
- Move forward over the gap between the two parts
- Place the pen down
- Move forward to cover the right of the lower part of the symbol
- Lift up the pen
- Move the pen to the left location of the middle semi-circle
- Set the heading to 90 degrees
- Move forward to cover the gap
- Lift up the pen
- Move the pen to the right location of the middle semi-circle
- Move forward to cover the gap
Using Turtle Graphics
We will use the template.py file and rename it to mmara.py.
The coordinate left position of the inner semi-circle is (25, 50). Once we know this, we can write the code for steps 1 to 6.
The code for this is shown below:
turtle.penup()
turtle.pensize(30)
turtle.setposition(25, 50)
turtle.setheading(90)
turtle.pendown()
turtle.circle(25, 180)
The generated image is shown below:
The coordinate of the middle semi-circle is (75, 50). Knowing this value, we can draw the middle semi-circle. The code for steps 7 to 11 is shown below:
turtle.penup()
turtle.setposition(75, 50)
turtle.setheading(90)
turtle.pendown()
turtle.circle(75, 180)
The generated image is shown below:
turtle.penup()
turtle.setposition(125, 50)
turtle.setheading(90)
turtle.pendown()
turtle.circle(125, 180)
The generated image is shown below:
turtle.penup()
turtle.setposition(-25, -50)
turtle.setheading(270)
turtle.pendown()
turtle.circle(25, 180)
The generated image is shown below:
turtle.penup()
turtle.setposition(-75, -50)
turtle.setheading(270)
turtle.pendown()
turtle.circle(75, 180)
The generated image is shown below:
turtle.penup()
turtle.setposition(-125, -50)
turtle.setheading(270)
turtle.pendown()
turtle.circle(125, 180)
The generated image is shown below:
The code for steps 32 to 36 is shown below:
turtle.penup()
turtle.setposition(-125, 40)
turtle.setheading(0)
turtle.pendown()
turtle.forward(100)
The location of the innermost part of the upper part of the symbol is at (25, 40). The code for steps 37 to 40 is shown below:
turtle.penup()
turtle.setposition(25, 40)
turtle.pendown()
turtle.forward(100)
The generated image is shown below:
The code to draw the lower line is shown below:
turtle.penup()
turtle.setposition(-125, -40)
turtle.setheading(0)
turtle.pendown()
turtle.forward(100)
turtle.penup()
turtle.setposition(25, -40)
turtle.pendown()
turtle.forward(100)
The generated image is shown below:
The code to complete the shape is shown below:
turtle.penup()
turtle.setposition(-75, -40)
turtle.setheading(90)
turtle.pendown()
turtle.forward(80)
turtle.penup()
turtle.setposition(75, -40)
turtle.setheading(90)
turtle.pendown()
turtle.forward(80)
The final symbol is shown below:
At the end of this section, we have managed to draw the Mmara Krado symbol.
This post is part of the series: Drawing Adinkra Symbols using Python. The goal is to draw 40 Adinkra symbols using the Python programming language.
No comments:
Post a Comment