Skip to content

Summary: Stepping up to 3D

For four lessons everything lived on a flat sheet. This one steps off the page into three dimensions, and the whole message is reassuring: 3D adds a dimension, not a difficulty. One more basis vector, one more column, one more number per vector, and every rule you already know runs unchanged. If you understood the plane, you already understand most of space, and the same leap takes you to the hundreds of dimensions a real model uses. This is the scan-it-in-five-minutes version.

  • A 3D transformation is linear under the same two requirements as 2D: the origin stays fixed, and grid lines stay straight, parallel, and evenly spaced, now in three directions. Stretch, rotate, shear, and flip are allowed; curving and uneven spacing are not.
  • There are now three standard basis vectors: i-hat = [1,0,0], j-hat = [0,1,0], and the new k-hat = [0,0,1], pointing along z. Every 3D vector is a combination of the three, for example [3,4,5] = 3·i-hat + 4·j-hat + 5·k-hat.
  • The basis-vector trick is unchanged: a transformation is fully determined by where it sends the three basis vectors, because L(v) = x·L(i-hat) + y·L(j-hat) + z·L(k-hat). A 3x3 matrix stores those three landing spots as columns, and M·v = x·col1 + y·col2 + z·col3, three terms instead of two.
  • In 3D, rotation requires naming an axis. Worked anchors applied to [3,4,5]: a quarter turn about z gives [-4,3,5] (x and y rotate, z fixed); a quarter turn about y gives [5,4,-3] (x and z trade with a sign flip, y fixed). A diagonal matrix scales each axis on its own: [[2,0,0],[0,3,0],[0,0,0.5]] sends [3,4,5] to [6,12,2.5].
  • You read a 3x3 matrix by sketching the unit cube. Plot the three columns as arrows from the origin; they are the edges of the transformed box, a parallelepiped. A cube stays a cube (rotation), becomes a rectangular box (axis scaling), slants (shear), or squashes nearly flat (columns nearly coplanar, a collapse toward a plane).
  • This is the bridge to high dimensions. The jump from 2D to 3D is the same jump that goes to 300 or 768 dimensions: add basis vectors, lengthen the columns, add terms to the product, and every rule holds. A “768-dimensional embedding” just means 768 basis directions and 768-entry vectors behaving exactly like [3,4,5]. High-dimensional means long list, not magic; 3D is simply the last list you can draw.

Before this lesson you might have suspected that 3D, and then the high dimensions models actually use, hid some new layer of difficulty. Now you know the opposite: the conceptual work was finished in the plane, and every higher dimension is just more of the same bookkeeping. When you next read that a model has a 768-dimensional space, you can picture it honestly, not as something mystical but as the [3,4,5] arithmetic with a longer list, governed by the rules you already trust. The next lesson asks a sharper question about any of these transformations: by how much does it stretch or squash the space it acts on? That single number is the determinant.