Matrix Spaces; Rank 1; Small World Graphs
Vector spaces whose vectors aren't columns of numbers — matrices, even solutions of a differential equation — obey the same rules of basis and dimension. Strang computes dimensions of matrix subspaces, discovers the formula relating intersections and sums, shows that every rank one matrix is a column times a row, and closes with the friendship graph behind "six degrees of separation."
Vector spaces that don’t contain vectors
At the end of lecture ten, Strang was working with vector spaces whose elements were not what we usually call vectors — they were matrices. This lecture picks that thread up, because the point deserves to sink in: we’ve been so specific about -dimensional space, and “you really want to see that the same ideas work as long as you can add and multiply by scalars.”
Take , the space of all matrices. You can add two of them; you can multiply one by a scalar. (You can also multiply two matrices together — but that’s not part of the vector space picture. The vector space part is just adding and scaling.) Inside sit interesting subspaces:
- — the symmetric matrices. Add two symmetric matrices and the sum is still symmetric. (Multiply two symmetric matrices and the product need not be symmetric — but we’re not multiplying, so we’re fine.)
- — the upper triangular matrices. Add two upper triangulars, still upper triangular.
Both pass the subspace test. Now the natural questions, the same ones we always ask: what is a basis, and what is the dimension?
Bases and dimensions of matrix spaces
How many numbers does it take to specify a matrix? Nine. So the dimension of is nine, and the most obvious basis is the “standard basis” of matrices with a single and eight zeros:
Nine of them. Our space is “practically the same as nine-dimensional space” — the nine numbers are just written in a square instead of a column. But it deserves to be thought of as natural for itself.
Now the subspaces. For a symmetric matrix, how many parameters do you choose freely? The three diagonal entries, plus the three entries above the diagonal — the three below are then forced. So . For an upper triangular matrix, you choose the three diagonal entries and the three above: as well.
Here’s a subtlety worth noticing. Of the nine standard basis matrices, six happen to be upper triangular — so the big basis accidentally contains a basis for . But only three of the nine are symmetric (the three diagonal ones), and three matrices can’t span a six-dimensional . The lesson: a basis for the big space generally does not hand you a basis for a subspace. You have to think it over again.
Intersections and sums of subspaces
What subspaces can we build from and ? First, their intersection — the matrices that are symmetric and upper triangular. Symmetric and upper triangular forces every off-diagonal entry to be zero, so , the diagonal matrices, and .
What about the union — matrices that are symmetric or upper triangular? That is not a subspace. It’s like taking a couple of lines in the plane and stopping there: two six-dimensional subspaces of a nine-dimensional space, headed in different directions. Add a symmetric matrix to an upper triangular one and you generally land outside both. We can’t just put the two subspaces together — we have to fill in.
What do you get from a symmetric plus an upper triangular? Anything — every matrix can be written that way. So and . And now Strang sees a nice formula sitting in the numbers: .
A vector space from a differential equation
One more vector space that doesn’t have vectors in it — this one comes from differential equations. Look at all solutions of
is a solution. is a solution. ( too, but you don’t need to add it separately — it’s already a combination of these.) The complete solution is
That set of solutions is a vector space. What Strang wants you to see: this is really a null space — the null space of a differential equation. And , are a basis: every solution is a combination of them, just as the special solutions were a basis for the null space of . The dimension of the solution space is two, because the equation is second order. ( and would be another perfectly good basis — lots of bases.)
Rank one matrices: the building blocks
Back to the key number attached to a matrix: its rank (never bigger than or ). Strang singles out rank one matrices because they ought to be simple — “if the rank is only one, the matrix can’t get away from us.”
Their determinants will be easy, their eigenvalues will be interesting — rank one matrices will keep coming back.
That raises a subspace question. Inside the space of all matrices, do the matrices of rank four (or less) form a subspace? No. If you add two rank four matrices, the sum is usually not rank four — in fact the general rule is
so the sum of two rank fours could go up to rank five here (never more than ). Same for rank one: add two rank one matrices and you most likely get rank two. Not a subspace.
One more subspace, all four ways
A more likely exam-style example. In , take
Is it a subspace? Yes: multiply a vector whose components add to zero by six and they still add to zero; add two such vectors and the sums add to zero. Its dimension? Three — and here’s the systematic way to see it. is exactly the null space of the matrix
since says precisely that the components add to zero. The rank of is one, so . A basis: the three special solutions. The pivot variable is ; the free variables are . Set each free variable to in turn, and a in the first slot makes the sum zero:
Not the only possible basis, but “those are the special three.”
Now kill the example by finding all four fundamental subspaces of . The row space is one-dimensional in : all multiples of . The null space is the three-dimensional ; check . The column space: the columns have only one component, so lives in — and all multiples of the column give all of , so , dimension one. The null space of : the only combination of the rows giving the zero row is the zero combination, so , dimension zero; check . And a nice point of hygiene: the subspace containing only the zero vector has dimension zero, and its basis is the empty set — zero members, dimension zero.
Small world graphs
Five minutes on the topic that leads into the next lecture. A graph here isn’t a sine curve from calculus — the word means something completely different: a set of nodes and edges connecting them. Strang draws five nodes and six edges, and promises that some matrix will tell us everything about that graph — next time.
The graph he’s interested in: let every person in the room be a node, with an edge between two people if they’re friends. Scale it up to the whole country — 260 million nodes, edges between friends. The question: how far apart can two people be in this friendship graph? Strang’s own distance to Clinton is two — he went to college with a senator who knows Clinton. Your distance to Clinton is then at most three, “I take credit for reducing your Clinton distance to three.”
That’s the meaning behind the phrase six degrees of separation (the movie title, the book title): in the friendship graph, roughly six steps connect almost anybody to anybody. Sit next to a stranger on an airplane, start hunting for mutual friends, and you’ll often connect in two or three or four steps — “it’s a small world,” and that’s where the expression comes from. The mathematical point, saved for lecture twelve: with a few shortcuts added, distances in such graphs come down dramatically. The graph of the World Wide Web — nodes are sites, edges are links — is the fantastic example everyone wants to model.
Problems
Work these before revealing the solutions. Everything you need is in the lecture.
In the space of all matrices, find the dimensions of: (a) the whole space ; (b) the subspace of symmetric matrices; (c) the subspace of upper triangular matrices; (d) ; (e) . Verify the formula .
Show solution
(a) A matrix has entries, so .
(b) A symmetric matrix is fixed by its diagonal ( entries) plus the entries above the diagonal ( entries): .
(c) Upper triangular: the diagonal and above, again , so .
(d) Symmetric and upper triangular forces all off-diagonal entries to zero: is the diagonal matrices, .
(e) Every matrix is a symmetric plus an upper triangular, so and .
Check: . ✓
Consider all solutions of . Show that they form a vector space, give a basis, and state the dimension. Then give a second basis for the same space.
Show solution
If and , then — combinations of solutions are solutions, so the solution set is a vector space (the “null space” of the operator ).
and are solutions, and every solution is . Since neither is a multiple of the other, they are independent: is a basis and the dimension is (a second order equation).
A second basis: and . Both solve the equation, they are independent, and shows they span the same space. Lots of bases.
Write the matrix
in the form . Then give bases for its row space and column space, and find the dimension of its null space.
Show solution
Every row is a multiple of — rows one, two, three are , , times it. So
The rank is one. Basis for the row space: . Basis for the column space: (every column is a multiple of it: , , times).
Null space dimension: .
Inside the space of all matrices, decide whether each subset is a subspace. Give a reason or a counterexample. (a) The matrices of rank one, together with the zero matrix. (b) The matrices whose nine entries add to zero.
Show solution
(a) Not a subspace. Take and — each has rank one, but has two independent rows, so its rank is two. Adding two rank one matrices most likely gives rank two; the set is not closed under addition. (In general , but the sum’s rank can exceed one.)
(b) A subspace. If the entries of add to zero and the entries of add to zero, the entries of add to , and the entries of add to . One linear condition on the nine entries — exactly like in — so it is a null space in disguise, of dimension .
Let , a matrix. Find the dimension of each of the four fundamental subspaces, and give a basis for the null space .
Show solution
The rank is (one nonzero row).
- Row space : dimension in ; basis .
- Null space : dimension .
- Column space : dimension — it is all of .
- Null space of : dimension — only the zero vector, with the empty set as basis.
For : the pivot variable is ; free variables are . The condition is . Special solutions: set giving ; set giving :
Check: and . ✓