Matrix Transformations — Extended to Real 3D
The 2D original applies a 2×2 matrix to a lattice of points, drawing a line from each original point to its image so you can watch the plane stretch, rotate and shear. This companion ports the exact same idea one dimension further: a 3×3 matrix A is applied to a cubic lattice of points p=(x,y,z), and a line is drawn from every p to A·p, using the identical row-by-row multiplication (x'=a11x+a12y+a13z, and so on) as the flat version's x'=a11x+a12y.
Three colored arrows track where the basis vectors i, j and k land after the transform — the 3D generalization of the "how does the unit square deform" question the 2D grid answers implicitly. A yellow wireframe cube tracks the image of the unit cube [0,1]³; its enclosed volume equals |det(A)|, computed live via the standard 3×3 cofactor expansion. The trace and determinant readouts update on every slider drag, and the orientation indicator flips from "Preserved" to "Flipped" exactly when det(A) changes sign — the same invariant that governs whether a 2D transform mirrors the plane. Drag to orbit the camera; scroll to zoom.