## Tuesday, 27 February 2018

### Wuforo Dua Pa A

Wuforo Dua Pa A means “when you climb a good tree”. It is the symbol of support, cooperation and encouragement.

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:

1. Lift up the pen
2. Set the pen size to 40
3. Move the pen to the location (40, 0)
4. Place the pen down
5. Move forward by 70 pixels
6. Lift up the pen
7. Move the pen to the location (-40, 0)
8. Set the heading of the pen to 180 degrees
9. Place the pen down
10. Move forward by 70 pixels
11. Lift up the pen
12. Move the pen to the position (-170, 50)
13. Set the heading of the pen to 90 degrees
14. Place the pen down
15. Move forward by 120 pixels
16. Set the heading of the pen to 0 degrees
17. Move forward by 120 pixels
18. Lift up the pen
19. Move the pen to the position (-170, 50)
20. Set the heading of the pen to 270 degrees
21. Place the pen down
22. Move forward by 120 pixels
23. Set the heading of the pen to 0 degrees
24. Move forward by 120 pixels
25. Lift up the pen
26. Move the pen to the position (170, 50)
27. Set the heading of the pen to 90 degrees
28. Place the pen down
29. Move forward by 120 pixels
30. Set the heading of the pen to 180 degrees
31. Move forward by 120 pixels
32. Lift up the pen
33. Move the pen to the position (170, -50)
34. Set the heading of the pen to 270 degrees
35. Place the pen down
36. Move forward by 120 pixels
37. Set the heading of the pen to 0 degrees
38. Move forward by 120 pixels

Using Turtle Graphics

We will use the template.py file and rename it to wuforo.py.

The code of the first five steps is given below:

turtle.penup()
turtle.pensize(40)
turtle.setposition(40, 0)
turtle.pendown()
turtle.forward()

The generated image is shown below:

The code for steps 6 to 10 is simply to repeat the initial steps. This is given below:

turtle.penup()
turtle.setposition(-40, 0)
turtle.pendown()
turtle.forward(70)

The generated image is shown below:

Drawing the rest of the symbol will involve lifting up the pen and moving around the shape. We will start with the upper left quadrant, move to the lower left quadrant and follow the same pattern in the right quadrant.

The code for steps 11 to 16 is shown below:

turtle.penup()
turtle.setposition(-170, 50)
turtle.pendown()
turtle.forward(120)
turtle.forward(120)

The generated image is shown below:

The code for steps 18 to 24 is shown below:

turtle.penup()
turtle.setposition(-170, -50)
turtle.pendown()
turtle.forward(120)
turtle.forward(120)

The generated image is shown below:

Steps 25 to 31 will draw the parts of the symbol at the upper right hand corner. The code to do this is shown below:

turtle.penup()
turtle.setposition(170, 50)
turtle.pendown()
turtle.forward(120)
turtle.forward(120)

The generated image is shown below:

To complete this symbol, the code for the lower left part is shown below:

turtle.penup()
turtle.setposition(170, -50)
turtle.pendown()
turtle.forward(120)
turtle.forward(120)

The generated image is shown below:

Conclusion

This shape wasn't much of a stretch to draw. It was based on repeating the patterns for drawing.