Oregon Curriculum Network
Discovering Math with Python


We only need to talk about three types of transformation in this chapter: translation, rotation, and scaling.

To translate a polyhedron is to slide it around in space without having it turn around an axis. Just adding the same translation vector to every vertex vector effectively slides it.

Rotation is most easily defined about the origin, i.e. we center our polyhedron around the center of our coordinate system before applying our rotation algorithm.

If the polyhedron was not at centered at the origin to begin with, we may translated it (slide it without rotation), do the rotation, and translate it back to where we found it.

We'll be looking at two ways to rotate our polyhedron:

  • applying a rotation matrix to each vertex vector
  • applying a quaternion to each vertex vector, and then its inverse

The second technique will be the topic of Chapter 11.

Scaling means having the polyhedron grow or shrink. The same translation trick may be applied, as once a polyhedron is centered at the origin, we need only multiply each vertex vector by a scaler, thereby elongating or shortening all the vectors. See Chapter 6.

In [1]:
class Vector:

Back to Chapter 7: Polyhedrons
Continue to Chapter 9: Symmetry Groups
Introduction / Table of Contents