Real matrices come from applications and have structure. A graph with n nodes and m edges, each edge given a direction, has an m × n incidence matrix A: row k has −1 at the node edge k leaves and +1 at the node it enters. For Strang's graph with 4 nodes and 5 edges, Ax lists the potential differences across the edges, so Ax = 0 exactly when all potentials are equal: N(A) is the line through (1, 1, 1, 1), potentials are fixed only up to a constant (grounding a node removes it), and the rank is n − 1 = 3. Rows of A around a loop are dependent. Currents y on the edges satisfy Kirchhoff's current law Aᵀy = 0, a balance at each node; its solutions are currents around loops, and N(Aᵀ) has dimension m − r = 2, with one basis vector for each independent loop. The pivot rows of A (here edges 1, 2 and 4) form a tree, a graph with no loops. The count dim N(Aᵀ) = m − (n − 1) gives Euler's formula: nodes − edges + loops = 1. With Ohm's law y = Ce and current sources f, the three steps e = Ax, y = Ce, Aᵀy = f combine into AᵀCAx = f, the basic equation of applied mathematics in equilibrium; AᵀA is always symmetric.
Strang confesses that the matrices in his examples are invented on the spot, while real linear algebra uses matrices that come from somewhere and have structure; chemists, for instance, row reduce matrices that describe reactions (transcript, p. 1). This lecture takes the most important model in applied mathematics, whose discrete version is a graph (p. 2). It continues the four fundamental subspaces.
A graph has nodes and edges (transcript, p. 2). Strang's graph has n=4nodes and m=5edges, each given a direction by an arrow, chosen arbitrarily, to say which way a current counts as positive (pp. 2–3). The words will be those of an electrical network (potentials, currents), but the same model fits water or oil networks and structures such as bridges and domes (p. 3).
The incidence matrix has a row for each edge and a column for each node: −1 where the edge leaves, +1 where it arrives (pp. 3–5). With edge 1 from node 1 to 2, edge 2 from 2 to 3, edge 3 from 1 to 3, edge 4 from 1 to 4 and edge 5 from 3 to 4 (pp. 4–5):
The incidence matrix
A=−10−1−101−10000110−100011
In words
capital A equals minus 1 1 0 0; 0 minus 1 1 0; minus 1 0 1 0; minus 1 0 0 1; 0 0 minus 1 1
Edges 1, 2 and 3 form a loop, and their rows are dependent: row 1 plus row 2 gives row 3 (p. 5). Loops will correspond to dependent rows. A large graph gives a large but sparsematrix: each row has exactly two nonzeros, 2m in all (pp. 5–6).
Physically, potentials are determined only up to a constant: differences make current flow, and nothing moves if all potentials are equal, just as temperature can be measured from any zero point, or as an indefinite integral carries a +C (pp. 8–9). In practice one node is grounded, its potential set to zero; its column drops out, and the other three columns are independent (p. 9). So the rank is 3; any three columns are independent, so any node can be grounded (p. 10).
ATy=0 is perhaps the most fundamental equation of applied mathematics (transcript, p. 10). AT is 4×5, and its nullspace has dimensionm−r=5−3=2 (pp. 11–12). The picture (pp. 12–13): potentials x give potential differences e=Ax; Ohm's law gives currents on the edges, y=Ce, where C holds the conductances (one over the resistances); and ATy=0 is Kirchhoff's current law (p. 13). Written out (pp. 14–15):
capital A ^ capital T y equals 0: minus y one minus y three minus y four equals 0, y one minus y two equals 0, y two plus y three minus y five equals 0, y four plus y five equals 0
Each equation belongs to a node and says current in equals current out: a balance, a conservation law; charge does not pile up at the nodes (pp. 14–15). Elimination on AT would end in a zero row, as the rank is 3 (pp. 15–16). But the solutions can be found by thinking about the graph: send one unit of current around a loop (pp. 16–17):
Loop currents
y=11−100,y=001−11
In words
y equals 1; 1; minus 1; 0; 0, y equals 0; 0; 1; minus 1; 1
These two are a basis of N(AT). Current around the big outer loop, (1,1,0,−1,1), also satisfies the law, but it is their sum: on edge 3 the two currents cancel (pp. 17–18).
The row space of A has dimension 3 (transcript, p. 18). The first three columns of AT are not independent, since they come from a loop; the pivot columns are 1, 2 and 4, so edges 1, 2 and 4 give independent rows (p. 19). Those three edges connect all four nodeswithout a loop: such a graph is a tree (pp. 19–20). Dependencies come from loops.
loops equals dim capital N ( capital A ^ capital T ) equals m minus r equals edges minus the quantity nodes minus 1, which gives nodes minus edges plus loops equals 1
Euler's formula holds for every connected graph (Strang says every graph; a graph in several separate pieces has more constant vectors in N(A), and the right-hand side becomes the number of pieces): points, lines and areas, of dimension 0, 1 and 2 (p. 21). Here 4−5+2=1; Strang draws another graph with 5 nodes, 7 edges and 3 loops: again 5−7+3=1 (pp. 21–22). Linear algebra proves a fact of topology (p. 21).
Adding outside current sourcesf at the nodes (batteries in the edges would be the other way to drive the network) puts a right-hand side into the current law (transcript, pp. 22–23). The three steps combine (pp. 22–23):
The framework
e=Ax,y=Ce,ATy=f⇒ATCAx=f
In words
e equals capital A x, y equals capital C e, capital A ^ capital T y equals f which gives capital A ^ capital T capital C capital A x equals f
This is the equilibrium problem, with no time and no Newton's law, and solving it is the basic task of numericallinear algebra (p. 24). Strang's closing question: what is special about ATA? It is always symmetric (p. 24). (Strang's symbols are E for the potential differences and F for the sources; lowercase is used here. With this A, Ax is the rise in potential along each arrow, while current flows downhill; Strang leaves the minus sign out, and so does this page.)
Worked example
A square network of your own
Four nodes form a square with edges1→2, 2→3, 3→4 and 4→1. (a) Write A, find its rank and a basis of N(AT), and check Euler's formula. (b) For potentials x=(3,1,0,0), find Ax and add up its entries. Why is the sum 0?
(a) Matrix and subspaces
A=−10011−10001−10001−1. N(A) is still the constant vectors, so r=4−1=3, and dimN(AT)=4−3=1: one loop, with current y=(1,1,1,1) all the way round. Euler: 4−4+1=1.
(b) Differences around a loop
Ax=(1−3,0−1,0−0,3−0)=(−2,−1,0,3), which adds to 0. Adding the entries is yTAx with the loop current y=(1,1,1,1), and yTA=0T: going round a loop, the potential differences cancel.
A rectangular table of numbers, which acts on vectors to give new ones and so describes a linear change of coordinates. Explained in Planes through three points, and matrices.
The column space, nullspace, row space and left nullspace of a matrix, whose dimensions are all fixed by its rank. Explained in The four fundamental subspaces.
The family of all antiderivatives of a function, written ∫ f(x) dx = F(x) + c with an arbitrary constant c. Explained in Differentials and antiderivatives.
How strongly something opposes an electric current: the voltage across it divided by the current through it, measured in ohms. Explained in Current, resistance and DC circuits.
A set of independent vectors from which every vector in a space can be built, in exactly one way, as a combination. Explained in Independence, basis and dimension.
A column of a matrix that contains a pivot after elimination; the matching columns of the original matrix form a basis for its column space. Explained in Column space and nullspace.
A list of numbers written as a column, or more generally anything that can be added and multiplied by numbers. Explained in Orthogonal vectors and subspaces.
The branch of mathematics that studies the properties of shapes that survive stretching and bending without tearing, such as having holes. Explained in Simply connected regions.
Unchanged by some swap, reflection or turn; for an expression in two quantities, unchanged when they are exchanged. Explained in Introduction to Fourier series.
In terms of actual numbers rather than symbols; often worked out step by step, by computer, instead of from an exact formula.
Tap or click a word, here or in the text, for its meaning in this lesson. All words: the glossary. How many words are marked in the text: Reading options (the “Aa” button).