The Pythagoras tree is a fractal constructed from squares based on the Pythagorean theorem. It starts with the hypotenuse square and two cathetus squares which enclose a right triangle. In the next construction steps every cathetus square is seen as a new hypotenuse square, followed by suitable smaller cathetus squares. So the whole tree is formed.

Thanks

to Eric Rowell for KineticJS. The library was used to
create the interactions with the fractal tree.

The source code for the tree is turtle.js,
and you'll need the script embedded in the HTML page.

Build your own version of the Pythagoras tree

Use the red, black and blue circle to shape the tree.

- The red circle can be moved on the construction circle. This adjusts the angles of the right triangle.
- Move the black circle up and down to determine the position of the basic square.
- Move the black circle left and right to set the left upper corner of the basic square and resize it.
- Move the blue circle left and right to set the right upper corner of the basic square and resize it.

© 2021 Ulrich Schwebinghaus