Lab 3.2
Interpretable Linear Transformations
Lab goal
Read a transformation matrix as an action on vectors and distinguish what rotation, projection, and reflection preserve or remove.
- Linear transformation
- Images of basis vectors
- Projection
- Reflection
Code extensionThe full notebook applies many angles to a point cloud and extends projection to three dimensions.
Key ideas
Terms you will use
- Matrix as a map
A[x₁, x₂]ᵀ = x₁a₁ + x₂a₂ The columns of a matrix show where the standard basis vectors move; every other vector follows by linearity.
- Projection
P = uuᵀ for a unit vector u Projection keeps the component along a chosen subspace and removes the perpendicular component.
- Reflection
H = 2P − I Reflection across span(u) keeps the projected component and reverses the perpendicular component.
Lab 3.2 · Guided example
Watch one vector move three different ways
Random point clouds are replaced by one vector, so each matrix entry can be connected directly to a visible geometric change.
Select a line to see its action, array shape, and concrete operation.
After a 90° counterclockwise turn, which quadrant contains v?
Start with one visible input
The same vector v = [2,1] will make rotation, projection, and reflection directly comparable.
Reveal to compare.
v.shapenot stored → ?A NumPy 1-D vector.thetanot stored → ?A 90° angle in radians.