How to Use This Book
This book is designed to be read in more than one way. A math major, a data scientist, and an engineering student can all use it well, but they should not all read it identically. This chapter explains how the book is built so you can navigate it according to your goals.
For students
How a chapter is organized
Every one of the 40 chapters lives in its own folder and contains the same seven files, so once you know the rhythm of one chapter you know all of them:
index.md— the main exposition. This is where the teaching happens. Each section follows a fixed rhythm: a motivating question or geometric picture comes first, then the precise definition or theorem, then (for the important results) a motivated proof, then a worked example you can follow by hand, then thenumpythat confirms it, and finally an application showing where the idea lives in the real world. Geometry always comes first. That order is the heart of the book and it never changes.exercises.md— about 25 problems in four difficulty tiers, marked with stars: ⭐ conceptual, ⭐⭐ computation by hand, ⭐⭐⭐ proof or coding, and ⭐⭐⭐⭐ application. Do the conceptual ones even when you are in a hurry; they are where understanding is tested.quiz.md— 10 to 12 short conceptual questions, each with a hidden answer and a one-line explanation. Use it to check yourself before moving on.case-study-01.mdandcase-study-02.md— two longer applied studies per chapter, each drawn from a different field, showing the chapter's ideas at work on a real problem.key-takeaways.md— a synthesis of the big ideas, the skills you should now have, the terms to know, and pointers forward. Read it after the chapter as a consolidation pass.further-reading.md— annotated references mapping the chapter to Strang, Axler, and Boyd–Vandenberghe, plus free online resources.
A good default loop is: read index.md actively (pencil in hand, running the code), check yourself with the quiz, work a selection of exercises across the tiers, skim at least one case study, then read the key takeaways to lock it in.
The three tracks: G, A, and C
The single most important thing to understand about this book is that every concept is taught on three parallel tracks, and you can choose how many of them to follow:
- G — Geometric intuition. The picture: what does this transformation do to space? Delivered through "Geometric Intuition" callouts,
matplotlibfigures, and the recurring 2D visualizer. The geometry always leads. - A — Algebraic rigor. The proofs: precise definitions, theorems stated with their conditions, and arguments you can follow step by step. The deepest material lives in clearly marked "Math-Major Sidebars" that you can skip without losing the thread.
- C — Computational. The code: short
numpysnippets that demonstrate each result, plus your own from-scratch implementation in thetoolkit/.
Here is how to use the tracks in practice. If you read at level G + C — geometry plus code, skipping the formal proofs and the Math-Major Sidebars — you will come away with a genuine, working understanding of linear algebra: you will know what every operation does and how to compute it, which is exactly what most users of the subject need. If you read all three tracks (G + A + C), you additionally get the rigorous why — the proofs that explain not just that a theorem is true but why it must be, which is what you need if you are going to prove things yourself or take more abstract mathematics later. Neither path is "the real book"; they are different valid readings, and the learning paths below tell you which one fits your field.
The recurring 2D transformation visualizer
Introduced in Chapter 1 and reused in every geometric chapter, the 2D transformation visualizer is a single small tool that draws what a $2\times 2$ matrix does to the unit square and to the basis vectors. It is deliberately the same tool every time — only the matrix and the narration change — so that as you move through the book you build one consistent mental picture instead of forty disconnected ones. You will watch it show a shear in Chapter 8, area-scaling-as-determinant in Chapter 11, re-gridding for a change of basis in Chapter 16, rotation and reflection in Chapter 21, the invariant directions that are eigenvectors in Chapter 23, and finally the rotate–stretch–rotate motion that is the SVD in Chapter 30. When a chapter says "using the visualizer from Chapter 1," it means this exact tool, which lives in toolkit/visualizer.py.
Running the code
Every code snippet in this book is real, runnable Python — numpy for the computation, scipy.linalg for a few specialized routines, and matplotlib for the figures. Each snippet is short (5 to 15 lines), carries a one-line comment explaining what it does, and prints its output so you can check the result even without running it. But you will learn far more by running them yourself: change the numbers, break things, and see what happens.
Appendix C walks you through installing Python and these libraries and running the examples in either a script or a Jupyter notebook. One reminder that will save you confusion: the mathematics indexes from 1 (the first component of $\mathbf{v}$ is $v_1$), while numpy indexes from 0 (that same component is v[0]). We flag this the first time it bites in each chapter.
The progressive toolkit/ project
Running across the whole book is a single project: you build your own linear algebra library, the toolkit/, from scratch in pure Python. Each chapter contributes one piece through a "Build Your Toolkit" callout — add and dot for vectors in Chapter 2, gaussian_elimination in Chapter 4, inverse in Chapter 9, gram_schmidt and qr_decompose in Chapter 20, power_iteration in Chapter 23, svd_from_scratch in Chapter 30, and so on. The rule that makes this valuable: your toolkit implementations use no numpy internally — you write the algorithm yourself — and then you verify your version against numpy to confirm it is correct. By Chapter 39, the capstone, you assemble the whole toolkit into one runnable application of your choosing (image compression, a recommender, PageRank, PCA, or a 3D renderer). Nothing in linear algebra stays a black box if you have built it once with your own hands.
What to do when you get stuck
You will get stuck. Linear algebra is the course where abstraction arrives in force, and getting stuck is part of the process, not a failure of it. When it happens:
- Switch tracks. If the algebra is opaque, go to the geometric picture and the visualizer. If the geometry feels vague, run the code on a concrete example. The three tracks exist precisely so a hard idea can be approached from a different side.
- Compute a small example by hand. Take a $2\times 2$ or $3\times 3$ case and grind through it with a pencil. Concreteness dissolves a surprising amount of confusion.
- Check the "Common Pitfall" and "Check Your Understanding" callouts. They target the exact mistakes students reliably make at that point.
- Read the proof's "Key idea" line, not the whole proof. Every significant proof states its crux in one plain-English sentence before the formal argument. Sometimes that sentence is all you needed.
- Move on and circle back. Some ideas only click once a later chapter gives them context. Mark it, keep going, and return. The dependency graph in this folder shows which chapters genuinely depend on which, so you know what is safe to defer.
The three learning paths
Read the book according to your field. Each path follows different tracks and emphasizes different chapters.
| Path | Tracks to follow | What to emphasize | What's optional |
|---|---|---|---|
| Math Major | G + A + C (all three) | Full proofs and every Math-Major Sidebar; abstract vector spaces; the spectral theorem; Jordan form; numerical theory | Nothing is truly optional; the application chapters are lighter for you but still worth a read |
| CS / Data Science | G + C (geometry + code) | Geometric intuition, the numpy, and the ML/data applications; the from-scratch toolkit |
The Math-Major Sidebars and the heaviest proofs (Jordan form, abstract spaces) |
| Physics / Engineering | G + A* + C | Geometry, the intuition-building proofs, and the physics/signals applications | The most abstract algebra (Jordan form details, general field theory); read proofs for understanding, not to reproduce |
*Physics/engineering readers should read the proofs that build intuition (why the spectral theorem holds, why orthogonality matters) without obsessing over the most abstract ones.
Chapter-emphasis guide by path:
- Math Major. Treat Parts I–V as the core and read them in full, with special care in Chapter 5 (vector spaces), Chapters 13–16 (the four fundamental subspaces and change of basis), and Chapter 27 (the spectral theorem). In Part VII, Chapter 35 (abstract linear transformations) and Chapter 36 (Jordan normal form) are for you — these are the chapters other paths may skip. The application chapters (12, 17, 22, 29, 31, 33) are enrichment.
- CS / Data Science. Anchor on the chapters that pay off immediately: Chapter 4 (Gaussian elimination), Chapter 7 (matrices as functions), Chapter 17 (linear regression), Chapters 18–20 (orthogonality, projection, QR), Chapters 23–25 and 29 (eigenvalues through PageRank), and especially Chapters 30–33 (SVD, image compression, PCA, machine learning) — this is the payload of the book for you. Read the proofs for the statements and skip the heaviest derivations. Build the toolkit; it is the best part for a programmer.
- Physics / Engineering. Emphasize Chapter 7 (transformations), Chapters 18–21 (orthogonality and orthogonal/rotation matrices), Chapters 23–28 (eigenvalues, complex eigenvalues, the spectral theorem, positive-definite and quadratic forms), and Chapter 37 (the matrix exponential and systems of ODEs) — that last one is squarely yours. Follow the quantum-mechanics thread (Chapters 1, 5, 21, 27, 34) and the Fourier chapter (22). Read proofs that explain why, especially for the spectral theorem.
For instructors
A complete instructor guide lives in the instructor-guide/ directory. It includes multiple syllabi (matched to the three learning paths and to one- versus two-semester sequences), per-chapter teaching notes, discussion guides, additional assessments and exams, and grading rubrics. Whether you are running a proof-based course for math majors or an applied course for a data-science program, the guide provides a ready starting point you can adapt. Start with its overview, then choose the syllabus that fits your students.