Lab Notebooks
Guided Python notebooks for computation, interpretation, and code-reading in linear algebra and optimization. Read the textbook.
-
U1
Vectors, Similarity, Attention, and Matrix Actions
Cosine similarity, document vectors, attention-style weighted averages, matrix actions, composition, and affine maps.
-
U2
Auditing a Linear Map
Reachable outputs, forgotten directions, rank, null space, and consistency checks for linear systems.
-
U3
Jacobians and Local Linearization
Jacobian matrices, shape checks, local predictions, and nonlinear functions read through linear approximations.
-
U4
Regression as Projection
Design matrices, projection, residual orthogonality, normal equations, and least-squares interpretation.
-
U5
Gradient Descent and Tiny Training
Gradient descent loops, learning-rate behavior, loss functions, and a small fixed-hidden-layer training model.
-
U6
SVD and Compression
Singular values, dominant directions, rank-k reconstruction, compression, and low-rank error.
-
U7
Polynomial Approximation
Polynomials as vectors, inner products, projection equations, Taylor approximation, and least squares.
-
A
Transformer Wrap-up Lab
A synthesis lab connecting token embeddings, attention scores, weighted averages, affine layers, nonlinear blocks, gradients, and low-rank updates.