rank-nullity theorem
The rank-nullity theorem is a conservation law for matrices: rank + nullity = number of columns. The number of columns is the dimension of the input space, so every input direction must end up accounted for in one of two bins.
Picture the matrix sorting its input directions. Some directions survive the transformation and come out as genuine outputs; their count is the rank. The rest get crushed flat to zero and vanish; their count is the nullity. Nothing is lost and nothing is created, so the two counts must add back up to the number of inputs.
This single equation is the reason so many facts hang together. If a tall matrix has 5 columns and rank 3, then exactly 2 input directions collapse, so the solution set of A*x = b (when it has solutions) is a 2-dimensional family. Add a direction to the reach and you must subtract one from the freedom.
Three input directions survive as outputs, two collapse to zero, and 3 + 2 returns the 5 we started with.
Here number of columns means the input dimension, so for a matrix acting on R^n it is exactly n.