Preface
Why another linear algebra textbook?
There are already excellent linear algebra textbooks. So before you invest a semester of your life in this one, you deserve a straight answer to a fair question: why does this book exist, and why should you read it instead of one of the established ones?
The honest answer is that the existing options force a trade-off you should not have to make. The gold-standard books are, for most students, either expensive or inaccessible — and often both. Gilbert Strang's Introduction to Linear Algebra is a genuinely great book, full of geometric insight, and it runs around a hundred dollars. Sheldon Axler's Linear Algebra Done Right is rigorous and beautiful, but it is proof-first by design — it famously postpones the determinant and builds the theory from abstract foundations, which is illuminating for a future mathematician and bewildering for someone who just needs to understand why their neural network is a stack of matrix multiplications. David Lay's Linear Algebra and Its Applications, a standard in engineering courses, lists for something like a hundred and eighty dollars. None of these is bad. But "pick rigor or affordability or the answer to why does this matter" is a bad menu, and it is the menu most students are handed.
This book is an attempt to refuse that trade-off. It is free, it is rigorous, and it never loses sight of why you are here. It is released under a Creative Commons license so that no student ever has to choose between a textbook and a textbook they can afford. And it is built around three commitments that show up not in a special chapter but in every chapter.
Three things this book does differently
Geometry first. Most linear algebra courses teach the algebra and hope the geometry shows up later. This book reverses that order on purpose. Every concept opens with a picture — what does this operation actually do to space? — before a single formula appears. When you meet matrix multiplication, you will first see it as one transformation followed by another, two motions of the plane composed into one, and only then meet the row-times-column rule that computes it. When you meet the determinant, you will first see it as the factor by which a transformation stretches or shrinks area, and watch it go to zero exactly when the transformation collapses the plane onto a line. A single recurring tool — a 2D transformation visualizer, introduced in Chapter 1 and reused throughout — makes this concrete: you will literally see what each matrix does to the unit square. The claim underneath all of this is that linear algebra is not a bag of computational recipes. It is a theory of how space can be transformed, and the pictures are not decoration; they are the subject.
Python alongside the math. Every concept in this book is demonstrated with a short piece of numpy — typically five to fifteen lines — that you can read, run, and verify. This is not a programming book, and the code never replaces the mathematics. You will still compute things by hand, because doing a Gaussian elimination with a pencil is how you come to understand Gaussian elimination. But after you have done it by hand, you will see the same result fall out of np.linalg.solve, and you will learn to trust the machine precisely because you know what it is doing. The code serves three purposes: it confirms your hand calculations, it lets you experiment with examples far too large to do by hand, and it connects the abstract theory to the tools you will actually use in research or industry. Alongside the inline snippets, you will build your own linear algebra library from scratch — a toolkit/ of pure-Python implementations of elimination, inversion, QR, eigenvalues, and the SVD — so that none of these operations ever feels like a black box.
Real applications in every chapter. Linear algebra is, somewhat paradoxically, the most applied branch of pure mathematics, and this book treats applications as core material rather than as an afterthought tucked into the final chapter. You will see how Google's PageRank algorithm is, at heart, the search for a single dominant eigenvector. You will compress an image with the singular value decomposition and watch a blurry rank-10 approximation sharpen into something indistinguishable from the original by rank 200. You will see why every layer of a neural network is a matrix multiplication, how principal component analysis finds the directions of greatest variation in data, how a rotation in computer graphics is an orthogonal matrix, why a quantum state is a vector and a quantum gate is a unitary matrix, and how a Fourier series is nothing more than a projection onto an orthogonal basis of functions. These applications span computer science, data science, machine learning, graphics, signal processing, physics, and economics — deliberately, because linear algebra belongs to all of them and not to physics alone. The recurring lesson is the one that makes the subject worth your time: the same SVD that compresses an image also denoises a signal, finds principal components, and solves a least-squares problem. Learn it once, use it everywhere.
The one idea to hold onto
If you forget everything else in this preface, hold onto this: a matrix is a function that transforms space.
A matrix is not fundamentally a grid of numbers, even though that is how we write it down. It is a linear transformation — a rule that takes every vector and moves it somewhere else, while keeping the grid of space evenly spaced and the origin fixed. Multiplying matrices is composing those transformations. The columns of a matrix tell you exactly where the basis vectors land. The determinant tells you how the transformation scales area or volume. Eigenvectors are the special directions the transformation leaves pointing the same way. Every major theorem in this book — rank–nullity, the spectral theorem, the SVD — is ultimately a statement about what transformations can and cannot do. Once you genuinely see matrices this way, the formulas stop being arbitrary and start being inevitable. That shift, from "grid of numbers" to "function that transforms space," is the single most important thing this book is trying to give you.
A word about difficulty
Linear algebra is often the first course where you are asked to reason about abstract structures rather than compute specific answers, and that transition is genuinely hard. You will hit ideas — vector spaces, linear independence, the four fundamental subspaces, the meaning of an eigenvalue — that do not click on the first reading, or the second. That is normal. It is not a sign that you are bad at math; it is a sign that you are encountering ideas that require a second and third pass. The discomfort of not-yet-understanding is part of how mathematical maturity is built, and we would rather tell you that honestly than pretend the material is easier than it is.
What we can promise is that the book is built to help you through those moments. The three-track structure means that when the abstract algebra resists you, there is always a geometric picture and a runnable piece of code to approach the same idea from another side. The pacing assumes you will get stuck and tells you what to do about it. And the payoff is real: linear algebra is one of the highest-leverage subjects you will ever learn, because nearly every quantitative field downstream of it — machine learning, graphics, quantum mechanics, optimization, statistics, control theory — is built on the ideas in these pages.
So take it slowly, draw the pictures, run the code, do the proofs, and do not measure your progress by how easy it feels. Measure it by what you can do. Let's begin.