The interactive film is in the book's Companion

Play it, pause it, turn it and drag it with Mathematics for AI and Machine Learning.

Get the book

Woodbury Identity: a Rank-One Update of the Inverse

Chapter 10 · Mathematics for AI and Machine Learning · Advanced · 2:20

An interactive live film: a rank-one update c u u^T moves every point of the 3D ellipsoid of B^-1 along the single direction B^-1 u, leaves a seam fixed, and needs only a 1 x 1 inverse; drag u and c and compare the direct inverse with Woodbury.

Narration

Here is a diagonal matrix B, and the ellipsoid of its inverse: the unit sphere, sent through B inverse. Its axes lie along the coordinate axes, and their lengths are one over the diagonal entries.

Now add a rank one update, c times u times u transpose, with the vector u drawn in black. The new matrix is B plus c u u transpose, and its inverse sends the sphere to a new ellipsoid, in blue.

The rest of the narration is in the book's Companion.

More from Chapter 10

Interactive2:11Tensor Parallelism: Block Products Across DevicesChapter 10Preview1:24Block Diagonal Matrices: Separate WorldsChapter 10Preview1:28Block Multiplication: Blocks Multiply Like NumbersChapter 10Preview1:39Longer Contexts with Rotary PositionsChapter 10Preview1:40Schur Complement: What Is Left After Minimizing Out a BlockChapter 10Preview1:32Kronecker Product and the Vectorization IdentityChapter 10Preview1:40Block Cholesky: Two Steps to a CircleChapter 10Preview1:30Online Softmax, One Tile at a TimeChapter 10Preview1:56Mixture of Experts: Routing Tokens to a Few BlocksChapter 10