NO. 47 · Mathematics

Linear Algebra for Machine Learning

Machine learning is linear algebra in production. Build vectors, systems, matrices, and determinants from first principles, take the working toolkit of bases, maps, and eigenvalues at survey speed, then watch the algebra earn its keep: principal components and gradient descent on real geoscience data.

You can solve linear systems by elimination and read the determinant's verdict on them, work with bases, linear maps, rank, and eigenvalues without ceremony, and explain what PCA and gradient descent actually do to a data matrix, because you can do the algebra they are made of.

13 competencies · 3 interactive widget challenges · 6 to 8.5 hours of guided study
For anyone bound for machine learning who wants to own the linear algebra underneath it

Vectors and systems

Vectors on the plane

Every dataset a model touches is a list of vectors and every layer moves them; the parallelogram law and the plane's transformations are where that picture first becomes honest.

Systems in two unknownswidget challenge

Two lines and one crossing, plus the two ways it can fail; the smallest linear system already contains the entire solvability story that determinants will later referee.

Systems in three unknownswidget challenge

Three unknowns is where solving by inspection dies and systematic elimination earns its keep; this is Gaussian elimination in miniature, the algorithm your future library calls a thousand times a second.

Matrices and determinants

Matrix algebra

The bookkeeping that turns a whole system into one object you can add, scale, and multiply; every forward pass in every model is this arithmetic at scale.

The 2x2 determinant

One number that decides whether a system is solvable and by how much a map stretches area; small enough to compute by hand until it becomes instinct.

The 3x3 determinant

Cofactor expansion done honestly at the last size where hand computation still teaches; the properties, not the arithmetic, are what survive to n dimensions.

Cramer's rule

Determinants solving systems directly: elegant, instructive, and worth knowing exactly why nobody computes this way at scale, which is itself a lesson in numerical cost.

The toolkit at speed

The vector space view

Why linearity is the universal first approximation, and what R^n actually is; the survey names the game every previous section was already playing.

Maps, bases, dimension

A matrix is a linear map written in a chosen basis; once span, basis, and dimension are yours, the matrix stops being the object and becomes the notation.

Determinant and rank-nullity

Rank-nullity is the conservation law of linear algebra: what a map kills plus what it keeps is everything it was given. The determinant referees invertibility.

Eigenvalues and change of basis

Choose the right basis and a hard matrix turns diagonal; eigenvalues are that basis's own directions, and PCA is about to use exactly this trick on data.

Where ML uses it

Gradient descent

Training is optimization: one gradient loop fits everything from a regression line to a deep network, and the learning rate is a quantity you can now read as geometry.

PCA and dimensionalitywidget challenge

PCA is the eigendecomposition of a covariance matrix wearing field clothes: the axes of maximum variance in a well-log suite are eigenvectors you can now compute and defend.

This page is prerendered for SEO and accessibility. With JavaScript, it hydrates into the live guided path: placement quiz, spaced practice, and interactive widget challenges.