Mathematical Methods Handbook

Vector spaces and linear maps

Bases, matrices, determinants, linear systems and inner products.

In this chapter 7

Tick a unit to add it to your PDF basket.

  1. Spaces, maps and determinants
  2. Inner products and orthogonality

Spaces, maps and determinants

4

Definition

Vector spaces and bases

Adapted

The axioms of a vector space over the real or complex scalars, and the facts that make coordinates possible: a finitely spanned space has a basis, all its bases have the same size, and coordinates in a fixed ordered basis are unique.

Prerequisites: Zorn's lemma and the axiom of choice

Definition(Vector space and subspace)AdaptedAdapted from Lee (2013), App. B, p. 617; Kreyszig (1978), §2.1, Def. 2.1-1, pp. 50–51, and subspace, p. 53

Write F\mathbb{F} for the scalar field, which in this handbook is R\mathbb{R} or C\mathbb{C} unless stated otherwise.

A vector space over F\mathbb{F} is a set VV carrying an addition V×V→VV\times V\to V and a scalar multiplication F×V→V\mathbb{F}\times V\to V subject to three groups of axioms:

  • VV is an abelian group under addition: u+v=v+uu+v = v+u and (u+v)+w=u+(v+w)(u+v)+w = u+(v+w) for all u,v,w∈Vu,v,w\in V, there is an element 0∈V0\in V with v+0=vv+0 = v for all vv, and each v∈Vv\in V has an inverse −v-v with v+(−v)=0v+(-v)=0;
  • a(bv)=(ab)va(bv) = (ab)v and 1v=v1v = v for all a,b∈Fa,b\in\mathbb{F} and v∈Vv\in V;
  • (a+b)v=av+bv(a+b)v = av+bv and a(v+w)=av+awa(v+w) = av+aw for all a,b∈Fa,b\in\mathbb{F} and v,w∈Vv,w\in V.

Members of VV are vectors. The axioms force 0v=00v = 0, a0=0a0 = 0 and (−1)v=−v(-1)v = -v.

A subspace of VV is a nonempty subset W⊆VW\subseteq V with av+bw∈Wav+bw\in W whenever v,w∈Wv,w\in W and a,b∈Fa,b\in\mathbb{F}. With the restricted operations WW is then a vector space over F\mathbb{F} in its own right, and 0∈W0\in W.

Definition(Span, independence, basis, dimension)AdaptedAdapted from Lee (2013), App. B, pp. 618–619; Kreyszig (1978), §2.1, Def. 2.1-6, p. 53, Def. 2.1-7, p. 54; Hassani (2013), §2.1, Thm 2.1.6, p. 22, and Defs. 2.1.7–2.1.9, p. 23

Let VV be a vector space over F\mathbb{F} and let S⊆VS\subseteq V.

  • A linear combination of SS is a finite sum ∑i=1kaivi\sum_{i=1}^{k} a_i v_i with k≥0k\ge 0, ai∈Fa_i\in\mathbb{F} and v1,…,vkv_1,\dots,v_k distinct elements of SS; the empty sum is 00. The set span⁡S\operatorname{span} S of all of them is a subspace, indeed the smallest subspace containing SS, and span⁡∅={0}\operatorname{span}\varnothing = \{0\}. If span⁡S=V\operatorname{span} S = V we say SS spans VV.
  • SS is linearly dependent if ∑i=1kaivi=0\sum_{i=1}^{k} a_i v_i = 0 for some distinct v1,…,vk∈Sv_1,\dots,v_k \in S and some scalars aia_i that are not all zero, and linearly independent otherwise. So ∅\varnothing is independent, and any SS containing 00 is dependent.
  • An ordered tuple (v1,…,vk)(v_1,\dots,v_k) of elements of VV is linearly independent if ∑i=1kaivi=0\sum_{i=1}^{k}a_iv_i = 0 holds only for a1=⋯=ak=0a_1=\dots=a_k=0. A repeated entry makes a tuple dependent, although the underlying set may be independent.
  • A basis of VV is a linearly independent subset that spans VV; an ordered basis is a basis together with a choice of ordering, written (e1,…,en)(e_1,\dots,e_n). VV is finite-dimensional if it has a finite basis and infinite-dimensional otherwise.
Definition(Standard spaces)AdaptedAdapted from Hassani (2013), §2.1, Example 2.1.2, pp. 20–21; Kreyszig (1978), §2.1, Examples 2.1-2 to 2.1-5, pp. 52–53

The spaces used throughout, all with pointwise operations:

Space Elements Dimension over F\mathbb{F}
Fn\mathbb{F}^n nn-tuples (x1,…,xn)(x_1,\dots,x_n) nn
Mm×n(F)M_{m\times n}(\mathbb{F}) m×nm\times n matrices mnmn
Pn(F)\mathcal{P}_n(\mathbb{F}) polynomials of degree ≤n\le n n+1n+1
P(F)\mathcal{P}(\mathbb{F}) all polynomials infinite
Ck([a,b],F)C^k([a,b],\mathbb{F}), 0≤k≤∞0\le k\le\infty kk times continuously differentiable functions on [a,b][a,b] infinite
ℓ2(F)\ell^2(\mathbb{F}) sequences (xn)n∈N(x_n)_{n\in\mathbb{N}} with ∑n∣xn∣2<∞\sum_n \lvert x_n\rvert^2<\infty infinite

A function space is a subspace of the space of all functions from a set XX to F\mathbb{F}; the last three rows are of this kind. Here a<ba<b are real and [a,b][a,b] is the closed interval.

Definition(Bases and dimension)AdaptedAdapted from Lee (2013), App. B, Lemma B.2 and Prop. B.3, pp. 619–620, Exercises B.4–B.5, p. 620; Dummit & Foote (2004), §11.1, Prop. 1 and Cor. 2, pp. 409–410; Kreyszig (1978), §2.1, p. 55 and Thm 2.1-8, p. 55; Riley, Hobson & Bence (2006), §8.1.1, eqs. (8.10)–(8.11), pp. 243–244

Let VV be a vector space over F\mathbb{F}.

  1. Exchange bound. If some set of nn vectors spans VV, then every subset of VV with more than nn elements is linearly dependent.
  2. Every finite spanning set of VV contains a basis of VV. In particular, if VV is spanned by finitely many vectors then VV is finite-dimensional.
  3. Invariance of dimension. If VV is finite-dimensional, all its bases are finite and have the same number of elements. That number is the dimension dim⁡FV\dim_{\mathbb{F}} V, and dim⁡FV=0\dim_{\mathbb{F}} V = 0 exactly when V={0}V = \{0\}.
  4. Coordinates. If (e1,…,en)(e_1,\dots,e_n) is an ordered basis of VV, then for each v∈Vv\in V there is exactly one tuple (x1,…,xn)∈Fn(x_1,\dots,x_n)\in\mathbb{F}^n with v=∑i=1nxieiv = \sum_{i=1}^{n} x_i e_i. The xix_i are the components of vv in that basis.
  5. Suppose dim⁡FV=n<∞\dim_{\mathbb{F}} V = n < \infty. Any independent set in VV can be enlarged to a basis of VV by adjoining further vectors. Every subspace W⊆VW\subseteq V is again finite-dimensional, with dim⁡FW≤n\dim_{\mathbb{F}} W \le n, and dim⁡FW=n\dim_{\mathbb{F}} W = n holds if and only if W=VW = V.
  6. Every vector space has a basis, and any two bases of the same vector space have the same cardinality. For infinite-dimensional VV the proof uses Zorn's lemma.
Idea of the proofOriginal

Two mechanisms carry all six items. The first is an exchange move: if a list of nn vectors spans VV, then any vector of an independent set can be traded for one of the listed vectors without losing the spanning property, because when it is expanded in the current list some listed vector must occur with a nonzero coefficient - otherwise the new vector would be a combination of the independent vectors already traded in, which independence forbids. After nn trades the independent vectors alone span, and the (n+1)(n+1)-st is then a combination of them, which is the contradiction behind part 1. The second mechanism is minimality: a spanning set with as few members as possible has to be independent, since a dependency would let one member be discarded. Part 2 is that observation, parts 3 and 5 are part 1 used to count, part 4 is the definition of independence read as a uniqueness statement, and part 6 replaces "as few as possible" by "maximal", which is what Zorn's lemma supplies.

ProofAdaptedAdapted from Lee (2013), App. B, Lemma B.2 and Prop. B.3, pp. 619–620, and Exercises B.4–B.5, p. 620; Dummit & Foote (2004), §11.1, Prop. 1, Cor. 2 and Thm 3, pp. 409–410; Kreyszig (1978), §2.1, p. 55 and Thm 2.1-8, p. 55

1, the exchange bound. Let S={v1,…,vn}S = \{v_1, \dots, v_n\} span VV and let W⊆VW \subseteq V have more than nn elements. A set with a dependent subset is itself dependent, the same relation serving both, so it is enough to produce a dependency among n+1n+1 distinct members w1,…,wn+1w_1, \dots, w_{n+1} of WW. Suppose instead that {w1,…,wn+1}\{w_1, \dots, w_{n+1}\} is independent.

We show by induction on kk that for k=0,1,…,nk = 0, 1, \dots, n there is an index set Jk⊆{1,…,n}J_k \subseteq \{1, \dots, n\} with n−kn - k elements such that {w1,…,wk}∪{vj:j∈Jk}\{w_1, \dots, w_k\} \cup \{v_j : j \in J_k\} spans VV. For k=0k = 0 take J0={1,…,n}J_0 = \{1, \dots, n\}, where the assertion is the hypothesis on SS.

Assume it for some kk with 0≤k≤n−10 \le k \le n - 1, so that JkJ_k has n−k≥1n - k \ge 1 elements, and expand the next of the ww's in the current spanning set:

wk+1=∑i=1kaiwi+∑j∈Jkbjvj.w_{k+1} = \sum_{i=1}^{k} a_i w_i + \sum_{j \in J_k} b_j v_j .

Not every bjb_j can vanish: otherwise wk+1−∑i≤kaiwi=0w_{k+1} - \sum_{i \le k} a_i w_i = 0 would be a relation among the distinct vectors w1,…,wk+1w_1, \dots, w_{k+1} whose coefficient at wk+1w_{k+1} is 11, contradicting independence. Fix m∈Jkm \in J_k with bm≠0b_m \neq 0 and solve:

vm=bm−1(wk+1−∑i=1kaiwi−∑j∈Jk, j≠mbjvj).v_m = b_m^{-1}\Bigl( w_{k+1} - \sum_{i=1}^{k} a_i w_i - \sum_{j \in J_k,\, j \neq m} b_j v_j \Bigr) .

So vmv_m lies in the span of T={w1,…,wk+1}∪{vj:j∈Jk∖{m}}T = \{w_1, \dots, w_{k+1}\} \cup \{v_j : j \in J_k \setminus \{m\}\}. Every other member of the old spanning set lies in TT itself, so span⁡T\operatorname{span} T contains the old spanning set and hence contains its span, which is VV. Taking Jk+1=Jk∖{m}J_{k+1} = J_k \setminus \{m\} completes the induction step.

At k=nk = n the set JnJ_n is empty and {w1,…,wn}\{w_1, \dots, w_n\} spans VV. Then wn+1=∑i≤nciwiw_{n+1} = \sum_{i \le n} c_i w_i for some scalars, which is again a nontrivial relation among w1,…,wn+1w_1, \dots, w_{n+1}. This contradiction shows {w1,…,wn+1}\{w_1, \dots, w_{n+1}\} is dependent, and with it WW.

2, a finite spanning set contains a basis. Let SS be finite with span⁡S=V\operatorname{span} S = V. The subsets of SS that span VV are finite in number and include SS, so one of them, BB, has fewest elements. If BB were dependent there would be distinct b1,…,bk∈Bb_1, \dots, b_k \in B and scalars aia_i, not all zero, with ∑iaibi=0\sum_i a_i b_i = 0; choosing aj≠0a_j \neq 0 gives bj=−aj−1∑i≠jaibib_j = -a_j^{-1}\sum_{i \neq j} a_i b_i, so bj∈span⁡(B∖{bj})b_j \in \operatorname{span}(B \setminus \{b_j\}). Then B∖{bj}B \setminus \{b_j\} has every member of BB in its span, so it spans VV as well, and it is smaller than BB - impossible. Hence BB is independent and spans: a basis. In particular a space spanned by finitely many vectors has a finite basis and is finite-dimensional. (For V={0}V = \{0\} the smallest spanning subset is ∅\varnothing, which is independent with span⁡∅={0}\operatorname{span}\varnothing = \{0\}.)

3, invariance of dimension. Let VV be finite-dimensional and let EE be a finite basis, with nn elements. Since EE spans VV, part 1 makes every subset of VV with more than nn elements dependent; a basis is independent, so no basis has more than nn elements, and in particular every basis is finite. If FF is a basis with mm elements then m≤nm \le n; exchanging the roles of EE and FF in the same sentence gives n≤mn \le m. So all bases have nn elements, and dim⁡FV=n\dim_{\mathbb{F}} V = n is well defined. Finally ∅\varnothing is a basis of {0}\{0\}, so dim⁡F{0}=0\dim_{\mathbb{F}}\{0\} = 0; and if dim⁡FV=0\dim_{\mathbb{F}} V = 0 then some basis is empty, whence V=span⁡∅={0}V = \operatorname{span}\varnothing = \{0\}.

4, coordinates. The basis spans, so vv is a linear combination of distinct basis vectors; adding the missing basis vectors with coefficient 00 writes v=∑i=1nxieiv = \sum_{i=1}^{n} x_i e_i. If also v=∑iyieiv = \sum_i y_i e_i then ∑i(xi−yi)ei=0\sum_i (x_i - y_i) e_i = 0. The entries of an ordered basis are distinct, so (e1,…,en)(e_1, \dots, e_n) is an independent tuple, and therefore every coefficient xi−yix_i - y_i vanishes.

5, enlarging an independent set. Let dim⁡FV=n\dim_{\mathbb{F}} V = n and let A⊆VA \subseteq V be independent; by part 1, AA has at most nn elements. If span⁡A≠V\operatorname{span} A \neq V, choose v∈V∖span⁡Av \in V \setminus \operatorname{span} A. Then A∪{v}A \cup \{v\} is independent: in a relation ∑iaiui+cv=0\sum_i a_i u_i + c v = 0 with distinct ui∈Au_i \in A, the coefficient cc must vanish, since otherwise v=−c−1∑iaiuiv = -c^{-1}\sum_i a_i u_i would lie in span⁡A\operatorname{span} A, and with c=0c = 0 independence of AA kills the remaining coefficients. The enlarged set has one more element, and sizes cannot exceed nn, so after at most n−∣A∣n - |A| such steps the set spans VV and is a basis containing AA.

5, subspaces. Let W⊆VW \subseteq V be a subspace. An independent subset of WW is independent in VV, hence has at most nn elements, so among the independent subsets of WW there is one, AA, of greatest size. It spans WW: otherwise the previous paragraph, applied inside WW to a vector of W∖span⁡AW \setminus \operatorname{span} A, would produce a larger independent subset of WW. So WW is finite-dimensional with dim⁡FW=∣A∣≤n\dim_{\mathbb{F}} W = |A| \le n. If dim⁡FW=n\dim_{\mathbb{F}} W = n, take a basis BB of WW: it is an independent subset of VV with nn elements, so enlarging it to a basis of VV adds nothing, every basis of VV having exactly nn elements by part 3; hence BB is a basis of VV and W=span⁡B=VW = \operatorname{span} B = V. The converse is immediate.

6, existence of a basis. Partially order the independent subsets of VV by inclusion. The collection is nonempty, containing ∅\varnothing. A chain C\mathcal{C} of independent sets has its union UU as an upper bound, and UU is independent: a relation involves finitely many distinct vectors of UU, each lying in some member of C\mathcal{C}, and since C\mathcal{C} is totally ordered the largest of those finitely many members contains all of them, so independence there forces the coefficients to vanish. By Zorn's lemma there is a maximal independent B⊆VB \subseteq V. It spans: a vector outside span⁡B\operatorname{span} B could be adjoined with independence preserved, by the computation in part 5, contradicting maximality. So BB is a basis. □\square

Note(The one part proved only in finite dimensions)AdaptedAdapted from Kreyszig (1978), §2.1, p. 55; Lee (2013), App. B, Exercise B.5(b), p. 620

The second half of part 6 - that any two bases of the same space have the same cardinality, infinite cardinalities included - is taken from the sources and not proved here. Kreyszig records it on p. 55 as a statement whose proof needs more set theory than he develops, referring to the literature; Lee poses it as Exercise B.5(b), p. 620, with a hint sketching the argument. Part 3 above proves the finite-dimensional case, which is what the rest of the handbook uses.

Note(What it means)Original

These axioms isolate exactly what is needed to add objects and rescale them, so that one argument covers arrows in space, nn-tuples of numbers, matrices, and functions at once. Parts 3 and 4 are what let you replace a vector by a column of numbers without ambiguity: a basis turns abstract vectors into coordinates, and a different basis gives different coordinates for the same vector. Reach for this unit whenever you need to know that a set of objects you can add is "nn-dimensional", or that a representation in coordinates is unique.

Remark(Where the hypotheses are used, and conventions)AdaptedAdapted from Hassani (2013), §2.1, Example 2.1.2 items 2–4, p. 20, Example 2.1.5, p. 22, and Def. 2.1.9, p. 23; Kreyszig (1978), §2.1, p. 55; Stakgold & Holst (2011), §4.6, pp. 276–277
  • The scalar field is part of the data. C\mathbb{C} is one-dimensional over C\mathbb{C} but two-dimensional over R\mathbb{R}, with basis {1,i}\{1,i\}. Hassani therefore writes dim⁡C\dim_{\mathbb{C}} and dim⁡R\dim_{\mathbb{R}}, and we keep the subscript whenever both are in play. Also, R\mathbb{R} is not a vector space over C\mathbb{C}: scalar multiplication would leave the set.
  • Where finiteness enters. Parts 1 and 2 each assume a finite spanning set, and for different reasons: part 1 needs the number nn to count against, and part 2 needs the subsets of the spanning set to be finite in number, so that a smallest spanning one can be selected. Parts 3 and 5 then rest on part 1, which is what caps the size of an independent set; part 4 needs only that the ordered basis it is given is finite. Part 6 drops finiteness altogether and pays for it with Zorn's lemma, which is why the cardinality half of it is harder than part 3. The exchange step used in part 1 is the replacement argument of Dummit and Foote (Dummit & Foote (2004), §11.1, Thm 3, p. 410), which swaps independent vectors into a basis one at a time.
  • Two meanings of "basis" in infinite dimensions. The basis defined here allows only finite linear combinations; Kreyszig calls it a Hamel basis. A Schauder basis of a normed space instead expands each vector as a convergent infinite series. The sequences en=(0,…,0,1,0,… )e_n = (0,\dots,0,1,0,\dots) form a Schauder basis of ℓ2\ell^2 but not a Hamel basis, because their finite combinations give only the sequences with finitely many nonzero terms. The distinction matters from normed and Banach spaces onwards; see also orthonormal bases.
  • Subspaces. An intersection of subspaces is a subspace, but a union need not be: the two coordinate axes in R2\mathbb{R}^2 are subspaces whose union is not closed under addition. Requiring a subspace to be nonempty is not cosmetic: ∅\varnothing satisfies the closure condition vacuously yet is not a vector space, since it has no zero element.
Example(A basis of the cubic polynomials, and the coordinates it assigns)Original

Work in P3(R)\mathcal{P}_3(\mathbb{R}), the real polynomials of degree at most 33, and take the ordered list

B=( 1+x,  x+x2,  x2+x3,  x3 ).B = \bigl(\, 1 + x,\; x + x^{2},\; x^{2} + x^{3},\; x^{3} \,\bigr) .

BB is a basis, by solving once and for all. Let p(x)=p0+p1x+p2x2+p3x3p(x) = p_0 + p_1 x + p_2 x^{2} + p_3 x^{3} be arbitrary and look for a,b,c,da, b, c, d with a(1+x)+b(x+x2)+c(x2+x3)+dx3=pa(1 + x) + b(x + x^{2}) + c(x^{2} + x^{3}) + d x^{3} = p. Comparing coefficients of 1,x,x2,x31, x, x^{2}, x^{3} gives the system

a=p0,a+b=p1,b+c=p2,c+d=p3,a = p_0, \qquad a + b = p_1, \qquad b + c = p_2, \qquad c + d = p_3 ,

which is solved from the top down, with no choice at any stage:

a=p0,b=p1−p0,c=p2−p1+p0,d=p3−p2+p1−p0.a = p_0, \quad b = p_1 - p_0, \quad c = p_2 - p_1 + p_0, \quad d = p_3 - p_2 + p_1 - p_0 .

A solution exists for every pp, so BB spans; taking p=0p = 0 gives a=b=c=d=0a = b = c = d = 0, so BB is independent. Hence BB is a basis of P3(R)\mathcal{P}_3(\mathbb{R}), and part 3 confirms the entry n+1=4n + 1 = 4 of the table of standard spaces, since the obvious basis (1,x,x2,x3)(1, x, x^{2}, x^{3}) also has four elements.

Coordinates of one polynomial. For p(x)=2−3x+x2+5x3p(x) = 2 - 3x + x^{2} + 5x^{3} the formulas give a=2a = 2, b=−3−2=−5b = -3 - 2 = -5, c=1+3+2=6c = 1 + 3 + 2 = 6 and d=5−1−3−2=−1d = 5 - 1 - 3 - 2 = -1, so the component tuple of pp in the ordered basis BB is (2,−5,6,−1)(2, -5, 6, -1). Expanding back:

2(1+x)−5(x+x2)+6(x2+x3)−x3=2+(2−5)x+(−5+6)x2+(6−1)x3=2−3x+x2+5x3,2(1 + x) - 5(x + x^{2}) + 6(x^{2} + x^{3}) - x^{3} = 2 + (2 - 5)x + (-5 + 6)x^{2} + (6 - 1)x^{3} = 2 - 3x + x^{2} + 5x^{3} ,

as part 4 promises, and no other tuple does it.

Five vectors must be dependent, and here is the relation. Since P3(R)\mathcal{P}_3(\mathbb{R}) is spanned by four vectors, part 1 says that any five of its elements are dependent - before any computation. Take

q1=1,q2=1+x,q3=1+x+x2,q4=1+x+x2+x3,q5=x3.q_1 = 1, \quad q_2 = 1 + x, \quad q_3 = 1 + x + x^{2}, \quad q_4 = 1 + x + x^{2} + x^{3}, \quad q_5 = x^{3} .

The first four are independent (the same top-down solve applies), yet the five together satisfy q4−q3−q5=0q_4 - q_3 - q_5 = 0, because q4−q3=x3=q5q_4 - q_3 = x^{3} = q_5. One relation is all that part 1 predicts, and one is what appears.

Example(The same set of vectors, two scalar fields, two dimensions)Original

Regard C\mathbb{C} as a vector space and consider {1+i, 1−i}\{1 + i,\, 1 - i\}.

Over R\mathbb{R} it is a basis, so dim⁡RC=2\dim_{\mathbb{R}} \mathbb{C} = 2. Independence: a(1+i)+b(1−i)=(a+b)+(a−b)ia(1 + i) + b(1 - i) = (a + b) + (a - b)i vanishes only if a+b=0a + b = 0 and a−b=0a - b = 0, that is a=b=0a = b = 0. Spanning: given z=x+iyz = x + iy with x,y∈Rx, y \in \mathbb{R}, the choice a=(x+y)/2a = (x + y)/2, b=(x−y)/2b = (x - y)/2 works. For z=3+5iz = 3 + 5i this gives a=4a = 4 and b=−1b = -1, and indeed 4(1+i)−(1−i)=3+5i4(1 + i) - (1 - i) = 3 + 5i.

Over C\mathbb{C} it is dependent, and dim⁡CC=1\dim_{\mathbb{C}} \mathbb{C} = 1. Now −i-i is an admissible scalar, and −i(1+i)=−i−i2=1−i-i(1 + i) = -i - i^{2} = 1 - i, so (1−i)−(−i)(1+i)=0(1 - i) - (-i)(1 + i) = 0 is a nontrivial relation. The single vector 1+i1 + i already spans, since z=(z/(1+i))(1+i)z = \bigl(z/(1 + i)\bigr)(1 + i), and it is independent as a nonzero vector, so {1+i}\{1 + i\} is a basis over C\mathbb{C}.

The underlying set of vectors never changed; what changed is which coefficients are allowed. This is why the subscript on dim⁡F\dim_{\mathbb{F}} is not decoration.

ApplicationOriginal

Counting modes before solving anything. The small displacements of an NN-atom molecule form a real vector space of dimension 3N3N, one coordinate per atom per direction. Inside it, the rigid motions span a subspace of dimension 66 for a bent molecule - three translations and three rotations - and 55 for a linear one, a rotation about the molecular axis producing no displacement. The vibrations are what is left, so a bent molecule has 3N−63N - 6 vibrational modes and a linear one 3N−53N - 5: three for water and four for carbon dioxide, both with N=3N = 3. These numbers are dimensions, fixed by part 3 before any frequency is computed, and they tell a spectroscopist how many lines to look for. See Normal modes.

Why there is no third independent harmonic solution. The solutions of y¨+ω2y=0\ddot y + \omega^{2} y = 0 form a vector space with basis (cos⁡ωt,sin⁡ωt)(\cos \omega t, \sin \omega t), of dimension 22. The amplitude-phase form cos⁡(ωt−φ)\cos(\omega t - \varphi) is a solution too, and part 1 says in advance that it cannot be independent of the first two: a space spanned by two vectors has every three-element subset dependent. The explicit relation is the addition formula, cos⁡(ωt−φ)=cos⁡φcos⁡ωt+sin⁡φsin⁡ωt\cos(\omega t - \varphi) = \cos\varphi \cos \omega t + \sin\varphi \sin \omega t. More generally, for a linear homogeneous equation of order nn the solution space has dimension nn, so nn independent solutions give every solution and any n+1n + 1 of them satisfy a relation. See Linear ODE theory.

Coordinates are what make a computer able to solve a field problem. A Galerkin or finite-element method replaces an infinite-dimensional function space by a subspace of dimension nn with a chosen basis; part 4 is what makes the vector of nn coefficients an unambiguous name for the approximate field, and part 3 is what makes "nn degrees of freedom" independent of which basis the implementation happens to use. The warning in the remark above belongs here too: in the infinite-dimensional space itself, finite combinations of a basis in the present sense do not exhaust the space, which is why the convergence of the approximation is a separate question from the algebra. See Finite elements and orthonormal bases.

The scalar field is physics, not convention. A quantum state space is a complex vector space: a spin-jj particle has dim⁡C=2j+1\dim_{\mathbb{C}} = 2j + 1, which is 22 for a spin-12\tfrac12 particle. Regarded over R\mathbb{R} the same space has twice that dimension, and the extra real parameters are the relative phases, which interference experiments measure. Writing dim⁡C\dim_{\mathbb{C}} rather than dim⁡\dim is thus a statement that multiplication by ii is part of the structure being used.

Definition

Linear maps and matrices

Adapted

Linear maps, their kernel and image, the matrix of a map in a chosen pair of ordered bases, and the rules by which composition becomes matrix multiplication and a change of basis becomes a similarity transformation.

Prerequisites: Vector spaces and bases

Definition(Linear map, kernel, image)AdaptedAdapted from Lee (2013), App. B, p. 622; Hassani (2013), §2.3, Def. 2.3.2, p. 39; Kreyszig (1978), p. 50

Fix the scalar field F\mathbb{F} (R\mathbb{R} or C\mathbb{C}), and let VV and WW both be vector spaces over it. A map T ⁣:V→WT\colon V\to W is linear if

T(av+bw)=a Tv+b Twfor all v,w∈V and a,b∈F.T(av + bw) = a\,Tv + b\,Tw \qquad \text{for all } v,w\in V \text{ and } a,b\in\mathbb{F}.

The same scalars must act on both sides, so VV and WW having a common scalar field is part of the definition. We write TvTv rather than T(v)T(v) except where brackets are needed for grouping.

  • The kernel is ker⁡T={v∈V:Tv=0}\ker T = \{v\in V : Tv = 0\} and the image is im⁡T={Tv:v∈V}\operatorname{im} T = \{Tv : v\in V\}. Both are subspaces, of VV and of WW respectively, and TT is injective if and only if ker⁡T={0}\ker T = \{0\}.
  • TT is an isomorphism if it is linear and bijective; then T−1T^{-1} is linear as well, and VV and WW are isomorphic.
  • A linear map V→VV\to V is a linear operator on VV, or an endomorphism of VV; a linear map V→FV\to\mathbb{F} is a linear functional.
  • L(V,W)L(V,W) denotes the set of linear maps V→WV\to W. With (S+T)v=Sv+Tv(S+T)v = Sv+Tv and (cT)v=c(Tv)(cT)v = c(Tv) it is itself a vector space over F\mathbb{F}.
Definition(The matrix of a linear map)AdaptedAdapted from Lee (2013), App. B, pp. 623–624; Riley, Hobson & Bence (2006), §8.2, eqs. (8.23)–(8.24), pp. 247–248

Let E=(e1,…,en)E = (e_1,\dots,e_n) be an ordered basis of VV and F=(f1,…,fm)F = (f_1,\dots,f_m) one of WW, and let T∈L(V,W)T\in L(V,W). Each TejTe_j expands uniquely in FF, and the coefficients define the matrix of TT in the bases EE and FF, written [T]F←E=A∈Mm×n(F)[T]_{F\leftarrow E} = A \in M_{m\times n}(\mathbb{F}):

Tej=∑i=1mAij fi(j=1,…,n).T e_j = \sum_{i=1}^{m} A_{ij}\, f_i \qquad (j = 1,\dots,n).

So the jjth column of AA holds the components of TejTe_j. Writing [v]E∈Fn[v]_E\in\mathbb{F}^n for the column of components of vv in EE,

[Tv]F=A [v]E,that is(Tv)i=∑j=1nAijvj.[Tv]_F = A\,[v]_E, \qquad\text{that is}\qquad (Tv)_i = \sum_{j=1}^{n} A_{ij} v_j .

For an operator on VV we take F=EF = E and write [T]E[T]_E. The product of A∈Mm×n(F)A\in M_{m\times n}(\mathbb{F}) and B∈Mn×p(F)B\in M_{n\times p}(\mathbb{F}) is (AB)ik=∑j=1nAijBjk(AB)_{ik} = \sum_{j=1}^{n} A_{ij}B_{jk}, and InI_n is the matrix with 11 on the diagonal and 00 elsewhere. A square matrix AA is invertible (nonsingular) if AB=BA=InAB = BA = I_n for some BB, which is then unique and written A−1A^{-1}.

Definition(Matrices represent linear maps faithfully)AdaptedAdapted from Lee (2013), App. B, pp. 623–626, Exercises B.13 and B.19, pp. 623, 625; Hassani (2013), §2.3, Box 2.3.6, p. 40

Let VV, WW and UU be finite-dimensional over F\mathbb{F}, carrying ordered bases EE, FF and GG of lengths nn, mm and pp.

  1. A linear map is determined by its values on a basis: given any w1,…,wn∈Ww_1,\dots,w_n\in W there is exactly one T∈L(V,W)T\in L(V,W) with Tej=wjTe_j = w_j for j=1,…,nj=1,\dots,n.
  2. T↦[T]F←ET\mapsto [T]_{F\leftarrow E} is an isomorphism of vector spaces L(V,W)→Mm×n(F)L(V,W)\to M_{m\times n}(\mathbb{F}). In particular dim⁡FL(V,W)=mn\dim_{\mathbb{F}} L(V,W) = mn.
  3. Composition is multiplication. If T∈L(V,W)T\in L(V,W) and S∈L(W,U)S\in L(W,U) then [S∘T]G←E=[S]G←F [T]F←E[S\circ T]_{G\leftarrow E} = [S]_{G\leftarrow F}\,[T]_{F\leftarrow E}, and [idV]E=In[\mathrm{id}_V]_E = I_n.
  4. For n=mn = m, T∈L(V,W)T\in L(V,W) is an isomorphism if and only if [T]F←E[T]_{F\leftarrow E} is invertible, and then [T−1]E←F=([T]F←E)−1[T^{-1}]_{E\leftarrow F} = \bigl([T]_{F\leftarrow E}\bigr)^{-1}.
Idea of the proofOriginal

Two facts do all the work. A vector has exactly one expansion in a given basis, so "a vector of VV" and "a column of nn scalars" carry the same information; and a linear map respects linear combinations, so "a map V→WV\to W" and "a list of nn vectors of WW", namely the images of the basis, also carry the same information. Compose the two translations and a map becomes a table of mnmn scalars. Only part 3 needs a calculation, and that calculation is just the definition of the matrix product read backwards; parts 2 and 4 then follow because a bijection that respects addition, scalars and composition must carry invertibility to invertibility.

ProofAdaptedAdapted from Lee (2013), App. B, pp. 623–624, Exercises B.13 and B.19, pp. 623, 625; Hassani (2013), §2.3, Box 2.3.6, p. 40

Throughout, write A=[T]F←EA = [T]_{F\leftarrow E}, and recall that every v∈Vv\in V has one and only one expansion v=∑jvjejv = \sum_j v_j e_j because EE is a basis (Vector spaces and bases).

Step 0: the matrix acts on components. Apply TT to that expansion. Linearity, used n−1n-1 times, gives Tv=∑jvj TejTv = \sum_j v_j\,Te_j, and inserting Tej=∑iAijfiTe_j = \sum_i A_{ij}f_i and collecting the coefficient of each fif_i gives

Tv  =  ∑i=1m(∑j=1nAijvj)fi.Tv \;=\; \sum_{i=1}^{m}\Bigl(\sum_{j=1}^{n} A_{ij}v_j\Bigr) f_i .

Since the expansion in FF is unique, the iith component of TvTv is ∑jAijvj\sum_j A_{ij}v_j, which is the identity [Tv]F=A[v]E[Tv]_F = A[v]_E asserted in the definition. Every part below rests on it.

Part 1, uniqueness. If S,T∈L(V,W)S,T\in L(V,W) satisfy Sej=TejSe_j = Te_j for all jj, then for any v=∑jvjejv = \sum_j v_j e_j linearity gives Sv=∑jvjSej=∑jvjTej=TvSv = \sum_j v_j Se_j = \sum_j v_j Te_j = Tv, so S=TS = T. Only linearity and the spanning half of "basis" were used here.

Part 1, existence. Given w1,…,wn∈Ww_1,\dots,w_n\in W, define TT by Tv=∑jvjwjTv = \sum_j v_j w_j, where (v1,…,vn)(v_1,\dots,v_n) are the components of vv in EE. This is a well-defined map because those components exist and are unique. It is linear because components are: the components of av+bv′av + bv' are avj+bvj′av_j + bv'_j, whence T(av+bv′)=∑j(avj+bvj′)wj=aTv+bTv′T(av+bv') = \sum_j (av_j+bv'_j)w_j = aTv + bTv'. Finally eje_j has components δkj\delta_{kj}, so Tej=wjTe_j = w_j.

Part 2. Write Φ(T)=[T]F←E\Phi(T) = [T]_{F\leftarrow E}. It is linear: (aS+bT)ej=a Sej+b Tej(aS+bT)e_j = a\,Se_j + b\,Te_j by the definition of the operations on L(V,W)L(V,W), and expanding both sides in FF and using uniqueness of the expansion gives Φ(aS+bT)=aΦ(S)+bΦ(T)\Phi(aS+bT) = a\Phi(S)+b\Phi(T) entry by entry. It is injective: if Φ(T)=0\Phi(T) = 0 then Tej=0Te_j = 0 for every jj, and the zero map also sends every eje_j to 00, so T=0T = 0 by the uniqueness half of part 1. It is surjective: given A∈Mm×n(F)A\in M_{m\times n}(\mathbb{F}), apply the existence half of part 1 to wj=∑iAijfiw_j = \sum_i A_{ij}f_i; the resulting TT has Φ(T)=A\Phi(T) = A. Hence Φ\Phi is an isomorphism. The mnmn matrices with a single entry 11 and the rest 00 are a basis of Mm×n(F)M_{m\times n}(\mathbb{F}) — they span it, since A=∑i,jAijA = \sum_{i,j}A_{ij} times the (i,j)(i,j) one, and a vanishing combination has every coefficient zero because each coefficient is an entry of the combination — so dim⁡FMm×n(F)=mn\dim_{\mathbb{F}}M_{m\times n}(\mathbb{F}) = mn, and an isomorphism preserves dimension.

Part 3. Let B=[S]G←FB = [S]_{G\leftarrow F}, so Sfi=∑kBkigkSf_i = \sum_k B_{ki}g_k. Then

(S∘T)ej  =  S(∑iAijfi)  =  ∑iAij Sfi  =  ∑iAij∑kBkigk  =  ∑k(∑iBkiAij)gk,(S\circ T)e_j \;=\; S\Bigl(\sum_{i} A_{ij} f_i\Bigr) \;=\; \sum_i A_{ij}\,Sf_i \;=\; \sum_i A_{ij}\sum_k B_{ki} g_k \;=\; \sum_k \Bigl(\sum_i B_{ki}A_{ij}\Bigr) g_k ,

the second equality by linearity of SS and the last by exchanging two finite sums. The bracket is (BA)kj(BA)_{kj}, so by uniqueness of the expansion in GG the matrix of S∘TS\circ T is BABA, which is the claim. For the identity, idVej=ej=∑iδijei\mathrm{id}_V e_j = e_j = \sum_i \delta_{ij}e_i, so [idV]E=In[\mathrm{id}_V]_E = I_n.

Part 4, forwards. Let TT be an isomorphism, so T−1T^{-1} exists and is linear. Apply part 3 to T−1∘T=idVT^{-1}\circ T = \mathrm{id}_V and to T∘T−1=idWT\circ T^{-1} = \mathrm{id}_W:

[T−1]E←F A=In,A [T−1]E←F=Im.[T^{-1}]_{E\leftarrow F}\,A = I_n, \qquad A\,[T^{-1}]_{E\leftarrow F} = I_m .

With n=mn = m these say that AA is invertible with A−1=[T−1]E←FA^{-1} = [T^{-1}]_{E\leftarrow F}.

Part 4, backwards. Let AA be invertible. By the surjectivity shown in part 2, applied to the pair of bases FF and EE, there is an S∈L(W,V)S\in L(W,V) with [S]E←F=A−1[S]_{E\leftarrow F} = A^{-1}. Part 3 gives [S∘T]E=A−1A=In=[idV]E[S\circ T]_E = A^{-1}A = I_n = [\mathrm{id}_V]_E and [T∘S]F=AA−1=Im=[idW]F[T\circ S]_F = AA^{-1} = I_m = [\mathrm{id}_W]_F, so by the injectivity shown in part 2 we get S∘T=idVS\circ T = \mathrm{id}_V and T∘S=idWT\circ S = \mathrm{id}_W. Hence TT is bijective, with inverse SS. The hypothesis n=mn=m entered when AA was required to be square. □\square

Definition(Change of basis and similarity)AdaptedAdapted from Riley, Hobson & Bence (2006), §8.15, eqs. (8.90)–(8.94), pp. 283–284; Lee (2013), App. B, Change of Basis, eqs. (B.1)–(B.2), pp. 625–626

Let E~=(e~1,…,e~n)\tilde E = (\tilde e_1,\dots,\tilde e_n) be a second ordered basis of VV and define the transition matrix P∈Mn×n(F)P\in M_{n\times n}(\mathbb{F}) by expanding the new basis in the old one,

e~j=∑i=1nPij ei(j=1,…,n).\tilde e_j = \sum_{i=1}^{n} P_{ij}\, e_i \qquad (j=1,\dots,n).

Then PP is invertible, and:

  1. [v]E=P [v]E~[v]_E = P\,[v]_{\tilde E} for every v∈Vv \in V; equivalently [v]E~=P−1[v]E[v]_{\tilde E} = P^{-1}[v]_E. Components therefore transform by P−1P^{-1} while the basis vectors transform by PP.

  2. If F~\tilde F is a second ordered basis of WW with transition matrix QQ, then for every T∈L(V,W)T\in L(V,W)

    [T]F~←E~=Q−1 [T]F←E P.[T]_{\tilde F\leftarrow \tilde E} = Q^{-1}\,[T]_{F\leftarrow E}\,P .
  3. For an operator TT on VV, taking the same change of basis in domain and codomain gives [T]E~=P−1[T]E P[T]_{\tilde E} = P^{-1}[T]_E\,P. Two matrices A,A~∈Mn×n(F)A, \tilde A\in M_{n\times n}(\mathbb{F}) are called similar when A~=P−1AP\tilde A = P^{-1}AP for some invertible PP, and the passage from AA to P−1APP^{-1}AP is a similarity transformation. So the matrices representing one operator in different bases are exactly the matrices similar to any one of them.

Idea of the proofOriginal

A change of basis changes no vector and no map; it changes only the dictionary used to write them down. The dictionary itself is a map — the identity of VV, read from the new basis into the old one — so the transition matrix PP is nothing but [idV]E←E~[\mathrm{id}_V]_{E\leftarrow\tilde E}. Once that is seen, there is nothing left to prove: insert identity maps on either side of TT and apply the composition rule of the previous statement. The inverse P−1P^{-1} appears on the domain side because the dictionary has to be read backwards there.

ProofAdaptedAdapted from Riley, Hobson & Bence (2006), §8.15, eqs. (8.90)–(8.94), pp. 283–284; Lee (2013), App. B, eqs. (B.1)–(B.2), pp. 625–626

The transition matrix is the matrix of the identity, and is invertible. The defining relation e~j=∑iPijei\tilde e_j = \sum_i P_{ij}e_i says exactly that idV e~j\mathrm{id}_V\,\tilde e_j expands in EE with coefficients PijP_{ij}, that is,

P=[idV]E←E~.P = [\mathrm{id}_V]_{E\leftarrow\tilde E} .

Since idV\mathrm{id}_V is an isomorphism and both bases have the same length nn, part 4 of the previous statement makes PP invertible, with P−1=[idV]E~←EP^{-1} = [\mathrm{id}_V]_{\tilde E\leftarrow E}.

Part 1. By Step 0 of the previous proof applied to idV\mathrm{id}_V with domain basis E~\tilde E and codomain basis EE,

[v]E=[idVv]E=[idV]E←E~ [v]E~=P [v]E~,[v]_E = [\mathrm{id}_V v]_E = [\mathrm{id}_V]_{E\leftarrow\tilde E}\,[v]_{\tilde E} = P\,[v]_{\tilde E},

and multiplying on the left by P−1P^{-1} gives the second form. The contrast with the display defining PP is the whole content of the last sentence of part 1: the same matrix PP sends new basis vectors to old-basis data and old components to new components only after inversion.

Part 2. Write T=idW∘T∘idVT = \mathrm{id}_W\circ T\circ \mathrm{id}_V and read each factor in the bases that make the composition rule applicable:

[T]F~←E~=[idW]F~←F [T]F←E [idV]E←E~=Q−1 [T]F←E P,[T]_{\tilde F\leftarrow\tilde E} = [\mathrm{id}_W]_{\tilde F\leftarrow F}\,[T]_{F\leftarrow E}\,[\mathrm{id}_V]_{E\leftarrow\tilde E} = Q^{-1}\,[T]_{F\leftarrow E}\,P ,

using part 3 of the previous statement twice, and then the identification of the two outer factors as Q−1Q^{-1} and PP established above. Nothing here requires n=mn = m.

Part 3, the formula. Put W=VW = V, F=EF = E and F~=E~\tilde F = \tilde E, so Q=PQ = P.

Part 3, "exactly the matrices similar to it". One inclusion is the formula just proved: any two matrices of one operator TT, in bases EE and E~\tilde E, are related by [T]E~=P−1[T]EP[T]_{\tilde E} = P^{-1}[T]_E P, hence similar. For the other, let A=[T]EA = [T]_E and let PP be any invertible matrix; we must produce a basis in which TT has matrix P−1APP^{-1}AP. Define e~j=∑iPijei\tilde e_j = \sum_i P_{ij}e_i. These nn vectors are linearly independent: if ∑jcje~j=0\sum_j c_j\tilde e_j = 0 then ∑i(∑jPijcj)ei=0\sum_i\bigl(\sum_j P_{ij}c_j\bigr)e_i = 0, so Pc=0Pc = 0 by uniqueness of the expansion in EE, so c=0c = 0 because PP is invertible. Being n=dim⁡Vn = \dim V independent vectors, they are a basis (Vector spaces and bases), their transition matrix is PP by construction, and part 3 gives [T]E~=P−1AP[T]_{\tilde E} = P^{-1}AP. □\square

Note(What it means)Original

Linearity is the property that lets you compute a map's effect on any vector from its effect on nn basis vectors, and the matrix is just the table of those nn answers. Everything matrices do they do because of this: multiplying matrices is doing one map after another, and inverting a matrix is undoing a map. The change-of-basis rule is the other half of the story: a matrix is a map plus a choice of coordinates, so the matrix changes when the coordinates do while the map does not. Quantities built from a matrix that survive A↦P−1APA\mapsto P^{-1}AP — the determinant, the trace, the eigenvalues — belong to the operator itself.

Remark(Conventions that differ between books)AdaptedAdapted from Riley, Hobson & Bence (2006), §8.2, eq. (8.23), p. 248, and §8.15, eqs. (8.90), (8.94), pp. 283–284; Lee (2013), App. B, eqs. (B.1)–(B.2), pp. 624–626; Hassani (2013), §2.3, p. 39
  • Index placement. We write AijA_{ij} for the entry in row ii and column jj, as Riley, Hobson and Bence (Riley, Hobson & Bence (2006), §8.3, p. 249) do. Lee writes AjiA^i_j, with the row index raised, to fit the summation convention of tensor analysis; the matrix is the same. This handbook raises indices only in the tensor units.
  • Direction of the transition matrix. The formulas above depend on which basis is expanded in which. We expand the new basis in the old one, so e~j=∑iPijei\tilde e_j = \sum_i P_{ij} e_i and [T]E~=P−1[T]EP[T]_{\tilde E} = P^{-1}[T]_E P; this is the convention of Riley, Hobson and Bence (Riley, Hobson & Bence (2006), §8.15, eqs. (8.90), (8.94), pp. 283–284), whose SS is our PP. Lee's transition matrix BB goes the other way, ei=∑jBije~je_i = \sum_j B^j_i \tilde e_j, so Lee's change-of-basis formula reads A~=BAB−1\tilde A = BAB^{-1}. The two matrices are inverse to each other, and quoting either formula with the other book's PP gives the wrong answer. Check which convention a source uses before substituting.
  • Operator versus matrix. Riley, Hobson and Bence distinguish the operator A\mathsf{A} from its matrix A\mathsf{A} of components in a basis; Hassani calls an operator on VV an endomorphism. We keep the distinction in the notation [T]F←E[T]_{F\leftarrow E}, because the change-of-basis statement is about it.
  • Infinite dimensions. Parts 2–4 of the representation statement use finite bases and fail without them: an injective linear operator on an infinite-dimensional space need not be surjective (shifting a sequence one place to the right), so "injective implies invertible" is a finite-dimensional fact. See bounded operators.
Example(Two operators on quadratic polynomials, in two bases)Original

Let VV be the real polynomials of degree at most 22, with the ordered basis E=(1, t, t2)E = (1,\,t,\,t^2), and let

Tp=(1+t) p′+p,Sp=p′.Tp = (1+t)\,p' + p, \qquad Sp = p' .

Both send VV to VV: p′p' has degree at most 11, so (1+t)p′(1+t)p' has degree at most 22. Both are linear, since differentiation and multiplication by a fixed polynomial are.

Step 1: the matrices in EE. Apply each operator to the three basis vectors and read off the coefficients, which by the definition are the columns:

T1=1,Tt=(1+t)+t=1+2t,Tt2=2t(1+t)+t2=2t+3t2,T1 = 1, \quad Tt = (1+t)+t = 1+2t, \quad Tt^2 = 2t(1+t)+t^2 = 2t+3t^2,S1=0,St=1,St2=2t,S1 = 0, \quad St = 1, \quad St^2 = 2t,

so

[T]E=(110022003),[S]E=(010002000).[T]_E = \begin{pmatrix} 1 & 1 & 0\\ 0 & 2 & 2\\ 0 & 0 & 3\end{pmatrix}, \qquad [S]_E = \begin{pmatrix} 0 & 1 & 0\\ 0 & 0 & 2\\ 0 & 0 & 0\end{pmatrix}.

Step 2: composition is the product. Directly, (S∘T)1=S1=0(S\circ T)1 = S1 = 0, (S∘T)t=S(1+2t)=2(S\circ T)t = S(1+2t) = 2 and (S∘T)t2=S(2t+3t2)=2+6t(S\circ T)t^2 = S(2t+3t^2) = 2+6t, so

[S∘T]E=(022006000),[S\circ T]_E = \begin{pmatrix} 0 & 2 & 2\\ 0 & 0 & 6\\ 0 & 0 & 0\end{pmatrix},

and multiplying the two matrices of step 1 in the order [S]E[T]E[S]_E[T]_E gives the rows (0,2,2)(0,2,2), (0,0,6)(0,0,6), (0,0,0)(0,0,0) — the same matrix. The reversed product [T]E[S]E[T]_E[S]_E has first row (0,1,2)(0,1,2) and is a different matrix, as it must be, because T∘S≠S∘TT\circ S \ne S\circ T here: (T∘S)t2=T(2t)=2+4t(T\circ S)t^2 = T(2t) = 2+4t while (S∘T)t2=2+6t(S\circ T)t^2 = 2+6t.

Step 3: a second basis. Take E~=(1, 1+t, (1+t)2)\tilde E = \bigl(1,\,1+t,\,(1+t)^2\bigr). Expanding the new basis in the old one, 1+t=1+t1+t = 1 + t and (1+t)2=1+2t+t2(1+t)^2 = 1+2t+t^2, so

P=(111012001),P−1=(1−1101−2001),P = \begin{pmatrix} 1 & 1 & 1\\ 0 & 1 & 2\\ 0 & 0 & 1\end{pmatrix}, \qquad P^{-1} = \begin{pmatrix} 1 & -1 & 1\\ 0 & 1 & -2\\ 0 & 0 & 1\end{pmatrix},

the inverse being checked by multiplying out. In the variable s=1+ts = 1+t we have d/dt=d/ds\mathrm{d}/\mathrm{d}t = \mathrm{d}/\mathrm{d}s and 1+t=s1+t = s, so TT acts on sks^k by Tsk=s⋅ksk−1+sk=(k+1)skT s^k = s\cdot k s^{k-1} + s^k = (k+1)s^k: the new basis vectors are eigenvectors, and

[T]E~=(100020003).[T]_{\tilde E} = \begin{pmatrix} 1 & 0 & 0\\ 0 & 2 & 0\\ 0 & 0 & 3\end{pmatrix}.

The change-of-basis statement predicts this from [T]E[T]_E alone. Computing P−1[T]EPP^{-1}[T]_E P: first

[T]EP=(123026003),thenP−1([T]EP)=(100020003),[T]_E P = \begin{pmatrix} 1 & 2 & 3\\ 0 & 2 & 6\\ 0 & 0 & 3\end{pmatrix}, \qquad\text{then}\qquad P^{-1}\bigl([T]_E P\bigr) = \begin{pmatrix} 1 & 0 & 0\\ 0 & 2 & 0\\ 0 & 0 & 3\end{pmatrix},

as claimed. Note tr⁡=6\operatorname{tr} = 6 and det⁡=6\det = 6 for both matrices, while the matrices themselves differ.

Step 4: a vector, both ways. Let v=3−t+2t2v = 3 - t + 2t^2, so [v]E=(3,−1,2)T[v]_E = (3,-1,2)^{\mathsf T}. Then P−1[v]E=(3+1+2, −1−4, 2)T=(6,−5,2)TP^{-1}[v]_E = (3+1+2,\,-1-4,\,2)^{\mathsf T} = (6,-5,2)^{\mathsf T}, which is right: substituting t=s−1t = s-1 gives v=6−5s+2s2v = 6 - 5s + 2s^2. Now compute TvTv in each description. In EE,

[T]E [v]E=(3−1, −2+4, 6)T=(2,2,6)T ⟷ 2+2t+6t2,[T]_E\,[v]_E = (3-1,\,-2+4,\,6)^{\mathsf T} = (2,2,6)^{\mathsf T} \ \longleftrightarrow\ 2 + 2t + 6t^2 ,

which agrees with Tv=(1+t)(−1+4t)+(3−t+2t2)=(−1+3t+4t2)+(3−t+2t2)Tv = (1+t)(-1+4t) + (3-t+2t^2) = (-1+3t+4t^2)+(3-t+2t^2). In E~\tilde E,

[T]E~ [v]E~=(1⋅6, 2⋅(−5), 3⋅2)T=(6,−10,6)T ⟷ 6−10s+6s2,[T]_{\tilde E}\,[v]_{\tilde E} = (1\cdot 6,\,2\cdot(-5),\,3\cdot 2)^{\mathsf T} = (6,-10,6)^{\mathsf T} \ \longleftrightarrow\ 6 - 10s + 6s^2 ,

and expanding 6−10(1+t)+6(1+t)2=2+2t+6t26-10(1+t)+6(1+t)^2 = 2+2t+6t^2 recovers the same polynomial. The two matrices are different tables; the map they tabulate is one map.

ApplicationOriginal

Optical systems multiply. In the paraxial approximation a light ray crossing a reference plane is described by two numbers, its height yy above the axis and its slope θ\theta, and every element of a rotationally symmetric system acts linearly on the pair (y,θ)(y,\theta). Free propagation through a distance dd and a thin lens of focal length ff have the ray-transfer matrices

F(d)=(1d01),L(f)=(10−1/f1),F(d) = \begin{pmatrix} 1 & d\\ 0 & 1\end{pmatrix}, \qquad L(f) = \begin{pmatrix} 1 & 0\\ -1/f & 1\end{pmatrix},

the first because yy grows by dθd\theta while θ\theta is unchanged, the second because a thin lens bends the ray without displacing it. Because composition of maps is multiplication of matrices, a whole instrument is the ordered product of its elements' matrices — right to left, in the order the light meets them. For an object at distance uu in front of the lens and a screen at distance vv behind it,

F(v) L(f) F(u)=(1−v/fu+v−uv/f−1/f1−u/f).F(v)\,L(f)\,F(u) = \begin{pmatrix} 1 - v/f & u+v-uv/f \\ -1/f & 1-u/f \end{pmatrix}.

A sharp image means that the final height does not depend on the initial slope — all rays leaving one object point arrive at one screen point — that is, that the top-right entry vanishes. Dividing u+v−uv/f=0u+v-uv/f = 0 by uvuv gives the thin-lens equation 1/u+1/v=1/f1/u+1/v = 1/f, and at that setting the top-left entry becomes 1−v/f=−v/u1-v/f = -v/u, the transverse magnification. With f=10f = 10 cm and u=15u = 15 cm this gives v=30v = 30 cm and a magnification of −2-2: twice the size, inverted. The handbook's "composition is multiplication" is thus the whole design calculus for lens systems, and the same algebra, with other 2×22\times 2 matrices, is how laser resonators, electron-optical columns and beam transport lines in accelerators are analysed.

Why physical tensors are given by their transformation law. The moment of inertia of a rigid body is an operator II on R3\mathbb{R}^3: it sends an angular velocity to the corresponding angular momentum, L=Iω\mathbf{L} = I\boldsymbol{\omega}. That is a statement about the body, not about anyone's coordinate axes. Choosing orthonormal axes turns it into a matrix of nine numbers, and rotating the axes replaces that matrix by P−1[I]PP^{-1}[I]P — which is why textbooks define a Cartesian tensor by how its components change, and why the familiar questions about a body are asked in the similarity-invariant language of this unit. The principal moments are the eigenvalues of II, the principal axes a basis in which [I][I] is diagonal, and the rotational kinetic energy 12(ω,Iω)\tfrac12(\boldsymbol{\omega}, I\boldsymbol{\omega}) a basis-independent number. The same remark applies verbatim to the stress and strain tensors of continuum mechanics, to the dielectric tensor of an anisotropic crystal, and — with unitary rather than merely invertible PP — to a change of basis in quantum mechanics, where the matrix of an observable changes but its spectrum does not.

Theorem

Determinants

Adapted

The determinant as the unique alternating multilinear function of the columns taking the value one at the identity, with its behaviour under transposition, elementary operations, cofactor expansion and products, the non-vanishing criterion for invertibility, and its reading as a signed volume.

Prerequisites: Vector spaces and bases, Linear maps and matrices, Vector algebra and index notation, Multiple integrals and change of variables, Lebesgue measure

Definition(Sign of a permutation, and the determinant)AdaptedAdapted from Lee (2013), App. B, Prop. B.26 and eq. (B.3), pp. 628–629, and Props. B.35–B.37 (minor, cofactor, transposed cofactor matrix, upper triangular), pp. 633–634; Arfken, Weber & Harris (2013), §2.1, pp. 85–86; Dummit & Foote (2004), §11.4, p. 436 (alternating multilinear) and p. 437 (the determinant axioms); Riley, Hobson & Bence (2006), §8.9 (minor, cofactor, Laplace expansion), pp. 259–260

Let SnS_n be the group of bijections of {1,…,n}\{1,\dots,n\} under composition. Every σ∈Sn\sigma\in S_n is a composition of finitely many transpositions, and the number of factors is even for every such decomposition or odd for every such decomposition; accordingly sgn⁡σ=+1\operatorname{sgn}\sigma = +1 or −1-1. The map sgn⁡ ⁣:Sn→{±1}\operatorname{sgn}\colon S_n\to\{\pm 1\} is a group homomorphism.

For A∈Mn×n(F)A\in M_{n\times n}(\mathbb{F}), with F=R\mathbb{F} = \mathbb{R} or C\mathbb{C}, the determinant is

det⁡A=∑σ∈Sn(sgn⁡σ) A1σ(1)A2σ(2)⋯Anσ(n).\det A = \sum_{\sigma\in S_n} (\operatorname{sgn}\sigma)\, A_{1\sigma(1)}A_{2\sigma(2)}\cdots A_{n\sigma(n)} .

When it is the columns that matter we write det⁡(a1,…,an)\det(a_1,\dots,a_n), meaning det⁡A\det A for the AA whose jjth column is aj∈Fna_j\in\mathbb{F}^n; ∣A∣\lvert A\rvert is another common notation for det⁡A\det A. For n=0n=0 the sum is not empty: S0S_0 has exactly one element, the empty bijection, whose empty product of entries is 11, so det⁡A=1\det A = 1.

Auxiliary notions. A function D ⁣:(Fn)n→FD\colon(\mathbb{F}^n)^n\to\mathbb{F} is multilinear if it is linear in each argument when the others are held fixed, and alternating if D(a1,…,an)=0D(a_1,\dots,a_n) = 0 whenever ai=aja_i = a_j for some i≠ji\neq j. For A∈Mn×n(F)A\in M_{n\times n}(\mathbb{F}) and 1≤i,j≤n1\le i,j\le n, the minor MijM_{ij} is the (n−1)×(n−1)(n-1)\times(n-1) matrix left after deleting row ii and column jj of AA, and the cofactor is Cij=(−1)i+jdet⁡MijC_{ij} = (-1)^{i+j}\det M_{ij}. The adjugate adj⁡A\operatorname{adj}A is the n×nn\times n matrix with entries (adj⁡A)ij=Cji(\operatorname{adj}A)_{ij} = C_{ji}. The matrix AA is upper triangular if Aij=0A_{ij} = 0 whenever i>ji > j.

Theorem(Properties of the determinant)AdaptedAdapted from Dummit & Foote (2004), §11.4, Thm 24, p. 437, Cor. 25, p. 438, Cor. 27, pp. 438–439, Thms 28–29, p. 439; Lee (2013), App. B, Prop. B.28, pp. 629–631, Thm B.31 and Cors. B.32–B.34, p. 632, p. 633, Props. B.35–B.37, pp. 633–634; Riley, Hobson & Bence (2006), §8.9.1, properties (i)–(vii), pp. 261–262

Let A,B∈Mn×n(F)A, B\in M_{n\times n}(\mathbb{F}) with n≥1n\ge 1.

  1. Characterisation. (a1,…,an)↦det⁡(a1,…,an)(a_1,\dots,a_n)\mapsto \det(a_1,\dots,a_n) is multilinear and alternating, and det⁡In=1\det I_n = 1. It is the only function (Fn)n→F(\mathbb{F}^n)^n\to\mathbb{F} with these three properties.

  2. Transpose. det⁡AT=det⁡A\det A^{\mathsf T} = \det A. Consequently every statement below about columns holds verbatim for rows.

  3. Elementary operations. Multiplying one column of AA by c∈Fc\in\mathbb{F} multiplies det⁡A\det A by cc; interchanging two columns reverses the sign of det⁡A\det A; adding a scalar multiple of one column to a different column leaves det⁡A\det A unchanged. Hence det⁡(cA)=cndet⁡A\det(cA) = c^n\det A, and det⁡A=0\det A = 0 if AA has a zero column or two equal columns.

  4. Triangular matrices. If AA is upper triangular (or lower triangular), then det⁡A=A11A22⋯Ann\det A = A_{11}A_{22}\cdots A_{nn}.

  5. Cofactor (Laplace) expansion. For each fixed row index ii and each fixed column index jj,

    det⁡A=∑k=1nAikCik=∑k=1nAkjCkj.\det A = \sum_{k=1}^{n} A_{ik}C_{ik} = \sum_{k=1}^{n} A_{kj}C_{kj} .
  6. Product rule. det⁡(AB)=(det⁡A)(det⁡B)\det(AB) = (\det A)(\det B), hence also det⁡(AB)=det⁡(BA)\det(AB) = \det(BA).

  7. Invertibility. The following are equivalent: AA is invertible; det⁡A≠0\det A \neq 0; the columns of AA are linearly independent. When det⁡A≠0\det A\neq 0,

    A−1=1det⁡Aadj⁡A,det⁡(A−1)=1det⁡A,A^{-1} = \frac{1}{\det A}\operatorname{adj}A, \qquad \det(A^{-1}) = \frac{1}{\det A},

    and in general Aadj⁡A=(adj⁡A)A=(det⁡A) InA\operatorname{adj}A = (\operatorname{adj}A)A = (\det A)\,I_n whether or not AA is invertible.

  8. Similarity invariance. det⁡(PAP−1)=det⁡A\det(PAP^{-1}) = \det A for every invertible P∈Mn×n(F)P\in M_{n\times n}(\mathbb{F}). Therefore, if VV is a vector space over F\mathbb{F} with dim⁡FV=n<∞\dim_{\mathbb{F}}V = n<\infty and TT is a linear operator on VV, the number det⁡T:=det⁡[T]E\det T := \det [T]_E is the same for every ordered basis EE of VV, and TT is an isomorphism if and only if det⁡T≠0\det T\neq 0.

Idea of the proofOriginal

Three properties are read straight off the defining sum: it is linear in each column, because each of its n!n! terms takes exactly one factor from each column; it reverses sign when two columns are swapped, because swapping composes every permutation with one transposition; and it equals 11 at the identity, because only the identity permutation contributes. Four more parts are read off the same sum with no extra machinery: reindexing it by σ−1\sigma^{-1} gives the transpose rule, the three elementary operations are the first two properties plus one cancellation, a triangular matrix kills every permutation but the identity, and the cofactor expansion is column linearity, followed by the observation that a last column equal to ene_n may simply be deleted and a count of the interchanges that move a chosen row and column into that position. Two parts need an idea beyond the sum, and both come from one lemma: a multilinear alternating function of nn columns is completely determined by its value on the standard basis, since expanding each column in that basis and discarding the terms with a repeated basis vector leaves exactly the permutation sum. Uniqueness is the lemma applied to a rival determinant function and the product rule is the lemma applied to (b1,…,bn)↦det⁡(Ab1,…,Abn)(b_1,\dots,b_n)\mapsto\det(Ab_1,\dots,Ab_n); the adjugate identity, the inverse and the invertibility criterion are then bookkeeping with the cofactor expansion.

ProofAdaptedAdapted from Lee (2013), App. B, Prop. B.28, pp. 629–631, Thm B.31, p. 632, Props. B.35 and B.37, pp. 633–634; Dummit & Foote (2004), §11.4, Props. 22–23, pp. 436–437, Thm 24, p. 437, Cor. 25, p. 438, Thms 28–30, pp. 439–440

Step 1: the sum is linear in each column. Fix qq and a permutation σ\sigma. Among the factors A1σ(1),…,Anσ(n)A_{1\sigma(1)},\dots,A_{n\sigma(n)} of the corresponding term, exactly one comes from column qq, namely Aσ−1(q) qA_{\sigma^{-1}(q)\,q}, because σ\sigma is a bijection. The term is therefore that entry times a product of entries from the other columns, so it is a linear function of column qq with the remaining columns fixed; a sum of such functions is again one.

Step 2: det⁡In=1\det I_n = 1. If σ≠id\sigma\neq\mathrm{id} there is an ii with σ(i)≠i\sigma(i)\neq i, and then the factor (In)iσ(i)(I_n)_{i\sigma(i)} is 00. Only σ=id\sigma=\mathrm{id} survives, contributing sgn⁡(id)⋅1⋯1=1\operatorname{sgn}(\mathrm{id})\cdot 1\cdots 1 = 1.

Step 3: interchanging two columns reverses the sign. Let τ∈Sn\tau\in S_n be the transposition of p≠qp\neq q and let A′A' be AA with columns pp and qq exchanged, so that Aij′=Ai τ(j)A'_{ij} = A_{i\,\tau(j)} for all i,ji,j. Then

det⁡A′=∑σ∈Sn(sgn⁡σ)∏i=1nAi τ(σ(i)).\det A' = \sum_{\sigma\in S_n}(\operatorname{sgn}\sigma)\prod_{i=1}^{n} A_{i\,\tau(\sigma(i))} .

Substitute ρ=τσ\rho = \tau\sigma. As σ\sigma runs once through SnS_n, so does ρ\rho, and sgn⁡σ=sgn⁡(τ−1ρ)=(sgn⁡τ)(sgn⁡ρ)=−sgn⁡ρ\operatorname{sgn}\sigma = \operatorname{sgn}(\tau^{-1}\rho) = (\operatorname{sgn}\tau)(\operatorname{sgn}\rho) = -\operatorname{sgn}\rho, because sgn⁡\operatorname{sgn} is a homomorphism and a transposition is odd. The sum becomes −det⁡A-\det A.

Step 4: equal columns give 00. If columns p≠qp\neq q of AA coincide, then exchanging them returns the same matrix, so step 3 gives det⁡A=−det⁡A\det A = -\det A, that is 2det⁡A=02\det A = 0. Here the hypothesis F=R\mathbb{F} = \mathbb{R} or C\mathbb{C} is used: 22 is invertible, so det⁡A=0\det A = 0. With steps 1 and 2 this proves the first sentence of part 1.

Step 5: part 2. By definition (AT)ij=Aji(A^{\mathsf T})_{ij} = A_{ji}, so

det⁡AT=∑σ(sgn⁡σ)∏i=1nAσ(i) i.\det A^{\mathsf T} = \sum_{\sigma}(\operatorname{sgn}\sigma)\prod_{i=1}^{n} A_{\sigma(i)\,i} .

In each product reindex the factors by j=σ(i)j = \sigma(i), which is legitimate because multiplication in F\mathbb{F} is commutative and σ\sigma is a bijection: the product equals ∏jAj σ−1(j)\prod_{j} A_{j\,\sigma^{-1}(j)}. Writing τ=σ−1\tau = \sigma^{-1} and using (sgn⁡σ)(sgn⁡σ−1)=sgn⁡(id)=1(\operatorname{sgn}\sigma)(\operatorname{sgn}\sigma^{-1}) = \operatorname{sgn}(\mathrm{id}) = 1 with values in {±1}\{\pm 1\}, so that sgn⁡τ=sgn⁡σ\operatorname{sgn}\tau = \operatorname{sgn}\sigma, and letting τ\tau run through SnS_n in place of σ\sigma, the sum becomes det⁡A\det A.

Step 6 (the key lemma): a multilinear alternating function is its value at the standard basis, times the determinant. Let D ⁣:(Fn)n→FD\colon(\mathbb{F}^n)^n\to\mathbb{F} be multilinear and alternating. First, DD reverses sign when two arguments are exchanged: with all other arguments fixed and x,yx,y in slots pp and qq, expanding 0=D(…,x+y,…,x+y,… )0 = D(\dots,x+y,\dots,x+y,\dots) by linearity in both slots gives

0=D(…,x,…,x,… )+D(…,x,…,y,… )+D(…,y,…,x,… )+D(…,y,…,y,… ),0 = D(\dots,x,\dots,x,\dots) + D(\dots,x,\dots,y,\dots) + D(\dots,y,\dots,x,\dots) + D(\dots,y,\dots,y,\dots),

whose first and last terms vanish because DD is alternating. Consequently D(eσ(1),…,eσ(n))=(sgn⁡σ) D(e1,…,en)D(e_{\sigma(1)},\dots,e_{\sigma(n)}) = (\operatorname{sgn}\sigma)\,D(e_1,\dots,e_n): write σ\sigma as a composition of transpositions and apply the sign reversal once per factor, the parity of the count being well defined by the definition of sgn⁡\operatorname{sgn}. Now expand each argument of D(a1,…,an)D(a_1,\dots,a_n) in the standard basis, aj=∑iAijeia_j = \sum_i A_{ij}e_i, and use multilinearity in each slot in turn:

D(a1,…,an)=∑i1,…,inAi11⋯Ainn D(ei1,…,ein).D(a_1,\dots,a_n) = \sum_{i_1,\dots,i_n} A_{i_1 1}\cdots A_{i_n n}\, D(e_{i_1},\dots,e_{i_n}).

Every term in which two of the indices agree has two equal arguments and so vanishes; the surviving index tuples are precisely (σ(1),…,σ(n))(\sigma(1),\dots,\sigma(n)) for σ∈Sn\sigma\in S_n. Hence

D(a1,…,an)=(∑σ(sgn⁡σ)∏jAσ(j) j)D(e1,…,en)=(det⁡AT) D(e1,…,en)=(det⁡A) D(e1,…,en),D(a_1,\dots,a_n) = \Bigl(\sum_{\sigma}(\operatorname{sgn}\sigma)\prod_{j} A_{\sigma(j)\,j}\Bigr) D(e_1,\dots,e_n) = (\det A^{\mathsf T})\,D(e_1,\dots,e_n) = (\det A)\,D(e_1,\dots,e_n),

the last equality by step 5.

Step 7: part 1, uniqueness. If DD is multilinear, alternating and D(In)=D(e1,…,en)=1D(I_n) = D(e_1,\dots,e_n) = 1, step 6 gives D(A)=det⁡AD(A) = \det A for every AA. So no second such function exists.

Step 8: part 3. Scaling column ii by cc multiplies det⁡A\det A by cc, by linearity in that slot (step 1); doing it to all nn columns gives det⁡(cA)=cndet⁡A\det(cA) = c^n\det A, and taking c=0c=0 in one column shows that a zero column forces det⁡A=0\det A = 0. The sign change under an interchange is step 3 and the vanishing for two equal columns is step 4. Finally, for q≠pq\neq p, linearity in slot qq gives

det⁡(…,ap,…,aq+c ap,… )=det⁡(…,ap,…,aq,… )+cdet⁡(…,ap,…,ap,… ),\det(\dots,a_p,\dots,a_q + c\,a_p,\dots) = \det(\dots,a_p,\dots,a_q,\dots) + c\det(\dots,a_p,\dots,a_p,\dots),

and the second determinant has columns pp and qq equal, so it is 00 by step 4. The restriction q≠pq\neq p is essential: adding cc times a column to itself is scaling by 1+c1+c.

Step 9: part 4. Let AA be upper triangular, so Aij=0A_{ij} = 0 whenever i>ji>j. A term of the defining sum is nonzero only if Aiσ(i)≠0A_{i\sigma(i)}\neq 0 for every ii, hence only if σ(i)≥i\sigma(i)\ge i for every ii. Summing these nn inequalities gives ∑iσ(i)≥∑ii\sum_i\sigma(i)\ge\sum_i i, with the two sides equal because σ\sigma permutes {1,…,n}\{1,\dots,n\}; so every inequality is an equality and σ=id\sigma = \mathrm{id}. The single surviving term is A11⋯AnnA_{11}\cdots A_{nn}. If instead AA is lower triangular, ATA^{\mathsf T} is upper triangular with the same diagonal, and step 5 applies.

Step 10: part 5. (a) A last column equal to ene_n may be deleted. Let BB be n×nn\times n with Bin=δinB_{in} = \delta_{in}. The factor of a term that comes from column nn is Bσ−1(n) nB_{\sigma^{-1}(n)\,n}, which vanishes unless σ(n)=n\sigma(n) = n; and for such σ\sigma that factor is 11. The permutations fixing nn are exactly those of {1,…,n−1}\{1,\dots,n-1\}, with the same sign computed there, so det⁡B\det B equals the determinant of BB with its last row and last column removed.

(b) Expansion along a column. Fix jj and expand aj=∑iAijeia_j = \sum_i A_{ij}e_i in the jjth slot. By step 1,

det⁡A=∑i=1nAij det⁡Yij,\det A = \sum_{i=1}^{n} A_{ij}\,\det Y_{ij},

where YijY_{ij} is AA with its jjth column replaced by eie_i.

(c) Identifying det⁡Yij\det Y_{ij}. Move column jj of YijY_{ij} to the last position by n−jn-j interchanges of adjacent columns, then move row ii to the last position by n−in-i interchanges of adjacent rows. Each column interchange reverses the sign by step 3; each row interchange does too, by step 3 applied to the transpose together with step 5. None of these moves changes the relative order of the other rows and columns, so the result is a matrix whose last column is ene_n and whose first n−1n-1 rows and columns form exactly AA with row ii and column jj deleted, that is MijM_{ij}. By (a) its determinant is det⁡Mij\det M_{ij}, so

det⁡Yij=(−1)(n−j)+(n−i)det⁡Mij=(−1)i+jdet⁡Mij=Cij.\det Y_{ij} = (-1)^{(n-j)+(n-i)}\det M_{ij} = (-1)^{i+j}\det M_{ij} = C_{ij}.

Substituting into (b) gives det⁡A=∑kAkjCkj\det A = \sum_{k} A_{kj}C_{kj}, the expansion along column jj. For the expansion along a row, note from the definitions that Mij(AT)=(Mji(A))TM_{ij}(A^{\mathsf T}) = \bigl(M_{ji}(A)\bigr)^{\mathsf T}, so by step 5 the cofactors satisfy Cij(AT)=Cji(A)C_{ij}(A^{\mathsf T}) = C_{ji}(A); expanding det⁡AT\det A^{\mathsf T} along its column ii and using step 5 once more yields det⁡A=∑kAikCik\det A = \sum_k A_{ik}C_{ik}.

Step 11: part 6. Fix AA and define D(b1,…,bn)=det⁡(Ab1,…,Abn)D(b_1,\dots,b_n) = \det(Ab_1,\dots,Ab_n). It is multilinear, because b↦Abb\mapsto Ab is linear and det⁡\det is multilinear, and alternating, because bp=bqb_p = b_q forces Abp=AbqAb_p = Ab_q and step 4 applies. The jjth column of ABAB is AbjAb_j, so D(B)=det⁡(AB)D(B) = \det(AB), while step 6 gives

D(B)=(det⁡B) D(e1,…,en)=(det⁡B) det⁡(Ae1,…,Aen)=(det⁡B)(det⁡A),D(B) = (\det B)\,D(e_1,\dots,e_n) = (\det B)\,\det(Ae_1,\dots,Ae_n) = (\det B)(\det A),

since AejAe_j is the jjth column of AA. Hence det⁡(AB)=(det⁡A)(det⁡B)\det(AB) = (\det A)(\det B), and the right-hand side is symmetric in AA and BB, so det⁡(AB)=det⁡(BA)\det(AB) = \det(BA).

Step 12: part 7. (a) The adjugate identity. Fix ii and jj and consider ∑kAikCjk\sum_k A_{ik}C_{jk}. For i=ji=j this is the row expansion of step 10, namely det⁡A\det A. For i≠ji\neq j, let A′A' be AA with row jj replaced by a copy of row ii. Then A′A' has two equal rows, so det⁡A′=0\det A' = 0 by steps 4 and 5. The minors MjkM_{jk} delete row jj — the only row that was altered — so A′A' and AA have the same cofactors along row jj, while Ajk′=AikA'_{jk} = A_{ik}. Expanding det⁡A′\det A' along its row jj therefore gives 0=∑kAikCjk0 = \sum_k A_{ik}C_{jk}. In both cases

∑kAik Cjk=δijdet⁡A,\sum_{k} A_{ik}\,C_{jk} = \delta_{ij}\det A ,

and since (adj⁡A)kj=Cjk(\operatorname{adj}A)_{kj} = C_{jk} the left-hand side is (Aadj⁡A)ij(A\operatorname{adj}A)_{ij}. Hence Aadj⁡A=(det⁡A)InA\operatorname{adj}A = (\det A)I_n for every AA. Applying this to ATA^{\mathsf T}, and using Cij(AT)=Cji(A)C_{ij}(A^{\mathsf T}) = C_{ji}(A) from step 10 — which says adj⁡(AT)=(adj⁡A)T\operatorname{adj}(A^{\mathsf T}) = (\operatorname{adj}A)^{\mathsf T} — and transposing, gives (adj⁡A)A=(det⁡A)In(\operatorname{adj}A)A = (\det A)I_n.

(b) det⁡A≠0\det A\neq 0 implies AA invertible. Divide (a) by det⁡A\det A: the matrix (det⁡A)−1adj⁡A(\det A)^{-1}\operatorname{adj}A is a two-sided inverse, so AA is invertible and A−1=(det⁡A)−1adj⁡AA^{-1} = (\det A)^{-1}\operatorname{adj}A.

(c) AA invertible implies det⁡A≠0\det A\neq 0. By part 6 and step 2, (det⁡A)(det⁡A−1)=det⁡(AA−1)=det⁡In=1(\det A)(\det A^{-1}) = \det(AA^{-1}) = \det I_n = 1, so neither factor is zero and det⁡(A−1)=(det⁡A)−1\det(A^{-1}) = (\det A)^{-1}.

(d) Dependent columns give det⁡A=0\det A = 0. If aq=∑p≠qcpapa_q = \sum_{p\neq q}c_p a_p, then linearity in slot qq writes det⁡A\det A as ∑p≠qcp\sum_{p\neq q}c_p times determinants each of which has the column apa_p in two different slots; all vanish by step 4.

(e) Independent columns give det⁡A≠0\det A\neq 0. The nn columns are then nn independent vectors in the nn-dimensional space Fn\mathbb{F}^n, hence a basis of it (Vector spaces and bases). So each standard basis vector expands as ei=∑jBjiaje_i = \sum_j B_{ji}a_j for some scalars BjiB_{ji}; comparing columns, this says AB=InAB = I_n for B=(Bji)B = (B_{ji}). By part 6, (det⁡A)(det⁡B)=1(\det A)(\det B) = 1, so det⁡A≠0\det A\neq 0.

Items (b)–(e) give the three-way equivalence of part 7.

Step 13: part 8. By part 6 and step 12(c), det⁡(PAP−1)=(det⁡P)(det⁡A)(det⁡P)−1=det⁡A\det(PAP^{-1}) = (\det P)(\det A)(\det P)^{-1} = \det A. By part 3 of the change-of-basis statement in Linear maps and matrices, any two matrices of one operator TT in ordered bases of VV are similar, so det⁡[T]E\det[T]_E does not depend on the basis and det⁡T\det T is well defined. Finally TT is an isomorphism exactly when [T]E[T]_E is invertible (part 4 of the representation statement there), which by part 7 is exactly when det⁡T≠0\det T\neq 0. □\square

Theorem(Determinant as a signed volume)AdaptedAdapted from Riley, Hobson & Bence (2006), §8.9, eq. (8.48), p. 261; Lee (2013), Ch. 16, p. 401

Work over F=R\mathbb{F} = \mathbb{R} and let λn\lambda_n be Lebesgue measure on Rn\mathbb{R}^n.

  1. For a1,…,an∈Rna_1,\dots,a_n\in\mathbb{R}^n, the parallelepiped they span,

    P(a1,…,an)={∑i=1ntiai  :  0≤ti≤1},P(a_1,\dots,a_n) = \Bigl\{\textstyle\sum_{i=1}^{n} t_i a_i \;:\; 0\le t_i\le 1 \Bigr\},

    satisfies λn(P(a1,…,an))=∣det⁡(a1,…,an)∣\lambda_n\bigl(P(a_1,\dots,a_n)\bigr) = \lvert\det(a_1,\dots,a_n)\rvert. It has zero volume exactly when the aia_i are linearly dependent.

  2. More generally, if T ⁣:Rn→RnT\colon\mathbb{R}^n\to\mathbb{R}^n is linear and E⊆RnE\subseteq\mathbb{R}^n is Lebesgue measurable, then T(E)T(E) is measurable and λn(T(E))=∣det⁡T∣ λn(E)\lambda_n(T(E)) = \lvert\det T\rvert\,\lambda_n(E), read with the convention 0⋅∞=00\cdot\infty = 0 in the one case where it is needed, det⁡T=0\det T = 0 and λn(E)=∞\lambda_n(E) = \infty. So ∣det⁡T∣\lvert\det T\rvert is the factor by which TT scales every volume, and the sign of det⁡T\det T records whether TT preserves or reverses orientation.

  3. For n=3n=3, if aa, bb, cc are the rows of AA (or, equally, its columns), then det⁡A=a⋅(b×c)\det A = a\cdot(b\times c), the scalar triple product, which is the signed volume of P(a,b,c)P(a,b,c).

Idea of the proofOriginal

A linear map is its own derivative, so the change-of-variables formula applies to it with a constant Jacobian factor and immediately gives part 2 for invertible TT: the integral that measures T(E)T(E) is ∣det⁡T∣\lvert\det T\rvert times the one that measures EE. A singular TT squashes space into a hyperplane, which has no volume at all, so both sides vanish. Part 1 is then the special case E=[0,1]nE = [0,1]^n, because the parallelepiped spanned by the columns of AA is precisely the image of the unit cube under AA. Part 3 is a two-line computation with the cofactor expansion.

ProofAdaptedAdapted from Folland (1999), §2.6, Thm 2.44, pp. 73–74

Throughout, identify the linear map TT with its matrix in the standard basis of Rn\mathbb{R}^n (Linear maps and matrices), so that det⁡T\det T is the determinant of that matrix, its jjth column is TejTe_j, and its image is the span of those columns; part 8 of the properties statement says the number det⁡T\det T does not depend on this choice of basis.

Part 2, the invertible case. Suppose det⁡T≠0\det T\neq 0. As a map Rn→Rn\mathbb{R}^n\to\mathbb{R}^n, TT is of class C1C^1 (its components are linear in the coordinates), it is bijective — part 7 of the properties statement makes the matrix TT invertible, and the linear map given by T−1T^{-1} is then a two-sided inverse of it — and its derivative at every point is TT itself, because a linear map is already its own best linear approximation. So TT is a C1C^1 diffeomorphism of Rn\mathbb{R}^n onto Rn\mathbb{R}^n with det⁡DuT=det⁡T\det D_uT = \det T for every uu. The volume rule of Multiple integrals and change of variables then says that T(E)T(E) is Lebesgue measurable for measurable EE and

λn(T(E))=∫E∣det⁡DuT∣ dnu=∣det⁡T∣ λn(E),\lambda_n\bigl(T(E)\bigr) = \int_E \lvert\det D_uT\rvert\,\mathrm{d}^n u = \lvert\det T\rvert\,\lambda_n(E),

the integrand being the constant ∣det⁡T∣\lvert\det T\rvert. This is Folland's Theorem 2.44, whose proof factors TT into elementary maps and treats each with the Fubini-Tonelli theorem.

Part 2, the singular case. Suppose det⁡T=0\det T = 0. By part 7 of the properties statement the columns of TT are dependent, so im⁡T\operatorname{im}T has dimension at most n−1n-1 and is contained in the span HH of some n−1n-1 independent vectors b1,…,bn−1b_1,\dots,b_{n-1}, which may be extended by a bnb_n to a basis of Rn\mathbb{R}^n (Vector spaces and bases). Let RR be the invertible linear map with Rbi=eiRb_i = e_i, so that R(H)={x:xn=0}R(H) = \{x : x_n = 0\}. That hyperplane is Lebesgue null: for every N∈NN\in\mathbb{N} and every ε>0\varepsilon>0 the set {x:xn=0, ∣xi∣≤N}\{x : x_n = 0,\ \lvert x_i\rvert\le N\} sits inside the box [−N,N]n−1×[−ε,ε][-N,N]^{n-1}\times[-\varepsilon,\varepsilon], of measure (2N)n−1 2ε(2N)^{n-1}\,2\varepsilon, so by monotonicity its measure is 00; and {xn=0}\{x_n=0\} is the countable union over NN of these sets, so it too is null (Lebesgue measure). Applying the invertible case to R−1R^{-1} gives λn(H)=∣det⁡R−1∣⋅0=0\lambda_n(H) = \lvert\det R^{-1}\rvert\cdot 0 = 0. Hence T(E)⊆im⁡T⊆HT(E)\subseteq\operatorname{im}T\subseteq H is a subset of a null set, so it is measurable with λn(T(E))=0\lambda_n(T(E)) = 0, while ∣det⁡T∣λn(E)=0⋅λn(E)=0\lvert\det T\rvert\lambda_n(E) = 0\cdot\lambda_n(E) = 0 as well, with the usual convention 0⋅∞=00\cdot\infty = 0 when EE has infinite measure.

Part 2, the orientation clause. Call an ordered basis (v1,…,vn)(v_1,\dots,v_n) of Rn\mathbb{R}^n positively oriented when det⁡(v1,…,vn)>0\det(v_1,\dots,v_n)>0, which is the standard convention and makes (e1,…,en)(e_1,\dots,e_n) positively oriented. If TT is invertible then (Tv1,…,Tvn)(Tv_1,\dots,Tv_n) is again a basis, and the jjth column of the matrix T⋅(v1 ⋯ vn)T\cdot(v_1\ \cdots\ v_n) is TvjTv_j, so the product rule gives

det⁡(Tv1,…,Tvn)=(det⁡T) det⁡(v1,…,vn).\det(Tv_1,\dots,Tv_n) = (\det T)\,\det(v_1,\dots,v_n).

Thus TT preserves the orientation of every basis when det⁡T>0\det T>0 and reverses the orientation of every basis when det⁡T<0\det T<0 — which is the content of the clause.

Part 1. Let AA be the matrix with columns a1,…,ana_1,\dots,a_n. For t∈Rnt\in\mathbb{R}^n the vector AtAt is ∑itiai\sum_i t_i a_i, so P(a1,…,an)=A([0,1]n)P(a_1,\dots,a_n) = A\bigl([0,1]^n\bigr). The unit cube is measurable with λn([0,1]n)=1\lambda_n([0,1]^n) = 1, so part 2 gives λn(P)=∣det⁡A∣\lambda_n(P) = \lvert\det A\rvert. By part 7 of the properties statement this vanishes exactly when the columns a1,…,ana_1,\dots,a_n are linearly dependent.

Part 3. Let a,b,ca,b,c be the rows of AA. Expanding along the first row (part 5 of the properties statement) and writing the three 2×22\times 2 minors out,

det⁡A=a1(b2c3−b3c2)−a2(b1c3−b3c1)+a3(b1c2−b2c1).\det A = a_1(b_2c_3-b_3c_2) - a_2(b_1c_3-b_3c_1) + a_3(b_1c_2-b_2c_1).

The three brackets, with the signs as shown, are the components (b×c)1(b\times c)_1, (b×c)2(b\times c)_2, (b×c)3(b\times c)_3 of the cross product (Vector algebra and index notation), so the right-hand side is a⋅(b×c)a\cdot(b\times c). Reading the same three vectors as the columns of a matrix gives the transpose, whose determinant is the same by part 2 of the properties statement. Finally, ∣det⁡A∣\lvert\det A\rvert is the volume of P(a,b,c)P(a,b,c) by part 1, and its sign is the orientation of the triple (a,b,c)(a,b,c) by the clause just proved, so det⁡A\det A is the signed volume. □\square

Note(What it means)Original

A single number decides whether a square system can be solved: det⁡A≠0\det A\ne 0 says the columns of AA are independent, so AA is invertible. The reason one number can do this is part 1 — demanding multilinearity, vanishing on repeated columns, and the value 11 at the identity leaves no freedom at all, so every identity about determinants is forced. Geometrically ∣det⁡A∣\lvert\det A\rvert is the volume of the box spanned by the columns, which is why it vanishes exactly when the box is flat. Reach for the determinant for small matrices, for symbolic work, for the characteristic polynomial, and for Jacobians in change-of-variables formulas — not for deciding numerically whether a large matrix is close to singular.

Remark(Where the hypotheses are used, and conventions)AdaptedAdapted from Dummit & Foote (2004), §11.4, the definition of alternating and Prop. 22(1),(3), p. 436, the determinant axioms, p. 437, and Cor. 27, pp. 438–439; Arfken, Weber & Harris (2013), §2.1, eq. (2.10), p. 86; Lee (2013), App. B, eq. (B.3), p. 629
  • Which "alternating". We take alternating to mean vanishing whenever two arguments coincide. Dummit and Foote (Dummit & Foote (2004), §11.4, p. 436) define the word by the apparently weaker requirement that the value vanish whenever two consecutive arguments are equal, and then derive the any-pair form as part (3) of their Prop. 22 on the same page; it is in that sense that the word enters their determinant axioms on p. 437. For a multilinear function the two requirements are therefore the same condition, and we use the any-pair form as the axiom in part 1. Over R\mathbb{R} and C\mathbb{C} it is in turn equivalent to changing sign under an interchange of two arguments — step 6 of the proof derives the sign change from the vanishing, and setting x=yx=y in the sign change recovers 2D=02D = 0 and so the vanishing. The last equivalence fails over a field of characteristic 22, where −1=1-1 = 1 makes every symmetric function sign-changing and only the vanishing condition gives the determinant.
  • Scalars. Everything above except part 7 holds verbatim over any commutative ring, which is the setting of Dummit and Foote. There part 7 reads: AA is invertible if and only if det⁡A\det A is a unit of the ring. Over an integral domain, det⁡A=0\det A = 0 still holds exactly when the columns are linearly dependent. Our restriction to F=R,C\mathbb{F}=\mathbb{R},\mathbb{C} loses nothing here.
  • Which index runs over the permutation. We sum over permutations of the column index with the row index ascending. So does Arfken, Weber and Harris (Arfken, Weber & Harris (2013), §2.1, eq. (2.10), p. 86), whose Dn=∑ij…εij…a1ia2j⋯D_n = \sum_{ij\ldots}\varepsilon_{ij\ldots}a_{1i}a_{2j}\cdots is our sum written with the Levi-Civita symbol εij…\varepsilon_{ij\ldots} in place of sgn⁡σ\operatorname{sgn}\sigma, and with the indices allowed to range freely because ε\varepsilon kills the non-permutations. Dummit and Foote (Dummit & Foote (2004), §11.4, Thm 24, p. 437) do the opposite, permuting the row index: det⁡A=∑σε(σ)Aσ(1)1⋯Aσ(n)n\det A = \sum_\sigma \varepsilon(\sigma)A_{\sigma(1)1}\cdots A_{\sigma(n)n}. That is the one genuine difference, and it changes nothing, by part 2.
  • Part 5 at n=1n=1 needs the convention det⁡( )=1\det(\,) = 1 for the empty 0×00\times 0 matrix; with it, the expansion of a 1×11\times1 determinant reads det⁡(a)=a\det(a) = a.
  • Not a numerical tool. The defining sum has n!n! terms and cofactor expansion is nearly as expensive, so determinants of large matrices are computed from an LU factorisation (see Linear systems and rank). The size of det⁡A\det A is also a bad proxy for conditioning: Arfken, Weber and Harris (Arfken, Weber & Harris (2013), §2.1, p. 86) exhibit a 3×33\times3 integer matrix with entries near 1010 whose determinant is 11, and det⁡(εIn)=εn\det(\varepsilon I_n) = \varepsilon^n is tiny for a perfectly well-conditioned matrix. Use the singular value decomposition or a condition number instead.
Example(A 3×33\times3 determinant four ways, and a 4×44\times4 by elimination)Original

Part A: the matrix

B=(2101−12031).B = \begin{pmatrix} 2 & 1 & 0\\ 1 & -1 & 2\\ 0 & 3 & 1\end{pmatrix}.

From the definition. With n=3n=3 there are 3!=63! = 6 terms. Writing each as (sgn⁡σ)B1σ(1)B2σ(2)B3σ(3)(\operatorname{sgn}\sigma)B_{1\sigma(1)}B_{2\sigma(2)}B_{3\sigma(3)} and listing σ\sigma by its values (σ(1),σ(2),σ(3))(\sigma(1),\sigma(2),\sigma(3)):

(1,2,3),sgn⁡=+1:+ 2⋅(−1)⋅1=−2(1,3,2),sgn⁡=−1:− 2⋅2⋅3=−12(2,1,3),sgn⁡=−1:− 1⋅1⋅1=−1(3,2,1),sgn⁡=−1:− 0⋅(−1)⋅0=0(2,3,1),sgn⁡=+1:+ 1⋅2⋅0=0(3,1,2),sgn⁡=+1:+ 0⋅1⋅3=0\begin{array}{llr} (1,2,3), & \operatorname{sgn} = +1: & +\,2\cdot(-1)\cdot 1 = -2\\ (1,3,2), & \operatorname{sgn} = -1: & -\,2\cdot 2\cdot 3 = -12\\ (2,1,3), & \operatorname{sgn} = -1: & -\,1\cdot 1\cdot 1 = -1\\ (3,2,1), & \operatorname{sgn} = -1: & -\,0\cdot(-1)\cdot 0 = 0\\ (2,3,1), & \operatorname{sgn} = +1: & +\,1\cdot 2\cdot 0 = 0\\ (3,1,2), & \operatorname{sgn} = +1: & +\,0\cdot 1\cdot 3 = 0 \end{array}

Adding, det⁡B=−2−12−1=−15\det B = -2-12-1 = -15.

By cofactor expansion along the first row. The three minors are

M11=(−1231),M12=(1201),M13=(1−103),M_{11} = \begin{pmatrix} -1 & 2\\ 3 & 1\end{pmatrix},\quad M_{12} = \begin{pmatrix} 1 & 2\\ 0 & 1\end{pmatrix},\quad M_{13} = \begin{pmatrix} 1 & -1\\ 0 & 3\end{pmatrix},

with determinants −7-7, 11 and 33, so C11=−7C_{11} = -7, C12=−1C_{12} = -1, C13=3C_{13} = 3 and

det⁡B=2(−7)+1(−1)+0⋅3=−15.\det B = 2(-7) + 1(-1) + 0\cdot 3 = -15 .

By the triple product. The rows are a=(2,1,0)a = (2,1,0), b=(1,−1,2)b = (1,-1,2), c=(0,3,1)c = (0,3,1). Then

b×c=((−1)(1)−(2)(3),  (2)(0)−(1)(1),  (1)(3)−(−1)(0))=(−7,−1,3),b\times c = \bigl((-1)(1)-(2)(3),\; (2)(0)-(1)(1),\; (1)(3)-(-1)(0)\bigr) = (-7,-1,3),

which is exactly the row of cofactors just computed — as part 3 of the volume statement says it must be — and a⋅(b×c)=−14−1+0=−15a\cdot(b\times c) = -14-1+0 = -15. So the parallelepiped on a,b,ca,b,c has volume 1515, and the triple is negatively oriented.

By the inverse. The nine cofactors are

(Cij)=(−7−13−12−62−4−3),soadj⁡B=(Cji)=(−7−12−12−43−6−3).(C_{ij}) = \begin{pmatrix} -7 & -1 & 3\\ -1 & 2 & -6\\ 2 & -4 & -3\end{pmatrix}, \qquad\text{so}\qquad \operatorname{adj}B = (C_{ji}) = \begin{pmatrix} -7 & -1 & 2\\ -1 & 2 & -4\\ 3 & -6 & -3\end{pmatrix}.

Multiplying out, Badj⁡B=adj⁡B B=−15 I3B\operatorname{adj}B = \operatorname{adj}B\,B = -15\,I_3, confirming part 7 and giving

B−1=1−15adj⁡B=115(71−21−24−363).B^{-1} = \frac{1}{-15}\operatorname{adj}B = \frac{1}{15}\begin{pmatrix} 7 & 1 & -2\\ 1 & -2 & 4\\ -3 & 6 & 3\end{pmatrix}.

Part B: a 4×44\times4 determinant by elimination. Let

A=(21031−121031−24011).A = \begin{pmatrix} 2 & 1 & 0 & 3\\ 1 & -1 & 2 & 1\\ 0 & 3 & 1 & -2\\ 4 & 0 & 1 & 1\end{pmatrix}.

Row-reduce with partial pivoting, counting interchanges. Column 1: the largest entry in modulus is 44, in row 4, so interchange rows 1 and 4 (first interchange). Subtracting 14\tfrac14 and 12\tfrac12 of the new first row from rows 2 and 4 clears the column:

(40110−17/43/4031−201−1/25/2).\begin{pmatrix} 4 & 0 & 1 & 1\\ 0 & -1 & 7/4 & 3/4\\ 0 & 3 & 1 & -2\\ 0 & 1 & -1/2 & 5/2\end{pmatrix}.

Column 2: the largest remaining entry is 33, in row 3, so interchange rows 2 and 3 (second interchange), then add 13\tfrac13 of the new second row to row 3 and subtract 13\tfrac13 of it from row 4:

(4011031−20025/121/1200−5/619/6).\begin{pmatrix} 4 & 0 & 1 & 1\\ 0 & 3 & 1 & -2\\ 0 & 0 & 25/12 & 1/12\\ 0 & 0 & -5/6 & 19/6\end{pmatrix}.

Column 3: ∣25/12∣>∣−5/6∣\lvert 25/12\rvert > \lvert -5/6\rvert, so no interchange; adding 25\tfrac25 of row 3 to row 4 gives the last entry 196+25⋅112=196+130=165\tfrac{19}{6}+\tfrac25\cdot\tfrac1{12} = \tfrac{19}{6}+\tfrac1{30} = \tfrac{16}{5}. The result is upper triangular with diagonal 4, 3, 2512, 1654,\,3,\,\tfrac{25}{12},\,\tfrac{16}{5}.

By part 3, the determinant is left alone when a multiple of some row is added to a different row, and it flips sign at every interchange; by part 4, a triangular matrix has the product of its diagonal for determinant. Two interchanges were used, so the two sign flips cancel and

det⁡A=(−1)2⋅4⋅3⋅2512⋅165=80.\det A = (-1)^2\cdot 4\cdot 3\cdot\frac{25}{12}\cdot\frac{16}{5} = 80 .

As a check, expand along the first row of AA. Deleting row 1 and columns 1, 2, 4 gives minors of determinant −6-6, −17-17 and −25-25 (column 3 need not be touched, since A13=0A_{13}=0), so C11=−6C_{11} = -6, C12=+17C_{12} = +17, C14=+25C_{14} = +25 and

det⁡A=2(−6)+1(17)+0+3(25)=−12+17+75=80.\det A = 2(-6) + 1(17) + 0 + 3(25) = -12+17+75 = 80 .

The two routes agree. They cost very differently. Elimination needed one multiplier per row cleared, five in all here, and a handful of multiply-and-subtract steps; its general cost is of order n3n^3. The defining sum for a 4×44\times4 already has 4!=244! = 24 signed products, and cofactor expansion is no better asymptotically. At n=20n = 20 the comparison is 20!≈2.4×101820!\approx 2.4\times 10^{18} terms against a few thousand arithmetic operations, which is why determinants of anything but small matrices are computed by elimination.

ApplicationOriginal

The Jacobian factor in every change of variables is a determinant because volume is. Part 2 of the volume statement is the linear case of the rule that an integral picks up the factor ∣det⁡DuG∣\lvert\det D_uG\rvert under a substitution x=G(u)x = G(u) (Multiple integrals and change of variables): a smooth map is locally linear, and the determinant of its derivative is the local volume stretch. That is the whole reason that dx dy=r dr dφ\mathrm{d}x\,\mathrm{d}y = r\,\mathrm{d}r\,\mathrm{d}\varphi in the plane and d3x=r2sin⁡θ dr dθ dφ\mathrm{d}^3x = r^2\sin\theta\,\mathrm{d}r\,\mathrm{d}\theta\,\mathrm{d}\varphi in space — the numbers rr and r2sin⁡θr^2\sin\theta are determinants — and why a vanishing Jacobian flags a coordinate system that has collapsed, as spherical coordinates do on the polar axis. The same reading explains the sign: orientation-reversing substitutions are exactly those with negative determinant, which is why the absolute value appears in volume formulas but not in the oriented integrals of differential forms.

Antisymmetry of fermions is the alternating property. The state of NN identical fermions must change sign when any two particles are exchanged. Given NN one-particle orbitals φ1,…,φN\varphi_1,\dots,\varphi_N and particle coordinates x1,…,xNx_1,\dots,x_N (position and spin), the Slater determinant

Ψ(x1,…,xN)=1N!det⁡[φi(xj)]i,j=1N\Psi(x_1,\dots,x_N) = \frac{1}{\sqrt{N!}}\det\bigl[\varphi_i(x_j)\bigr]_{i,j=1}^{N}

does exactly that: exchanging two particles exchanges two columns, and part 3 says the value changes sign. The Pauli exclusion principle is then not an extra postulate but part 3 again — if two orbitals are equal, two rows coincide and Ψ≡0\Psi\equiv 0, so that state does not exist. The product rule has a physical reading too: a change of the one-particle basis, φ↦Uφ\varphi\mapsto U\varphi, replaces the matrix [φi(xj)][\varphi_i(x_j)] by U[φi(xj)]U[\varphi_i(x_j)], so part 6 multiplies Ψ\Psi by det⁡U\det U, and with UU unitary ∣det⁡U∣=1\lvert\det U\rvert = 1 leaves the state unchanged up to a phase — which is why a Slater determinant describes an occupied subspace rather than a particular list of orbitals.

Determinants decide when a homogeneous problem has a non-trivial solution. Setting a determinant to zero is the standard route to an eigenvalue condition: the frequencies of a vibrating system come from a secular determinant det⁡(K−ω2M)=0\det(K-\omega^2M) = 0 (Generalized eigenproblems and normal modes), the allowed modes of a waveguide or the energy levels in a tight-binding model come from the same kind of condition, and the independence of solutions of a linear differential equation is tested by the Wronskian determinant (Structure of linear equations and the Wronskian). In each case the underlying fact is part 7: a square homogeneous system has a solution other than zero exactly when its determinant vanishes.

Method

Linear systems and rank

Adapted

Gaussian elimination with partial pivoting as a recipe for the rank and the complete solution set of Ax = b, together with the rank-nullity law and the Fredholm alternative that say in advance how many solutions and how many consistency conditions there are.

Prerequisites: Vector spaces and bases, Linear maps and matrices, Determinants

Definition(Rank, nullity, echelon form)AdaptedAdapted from Lee (2013), App. B, pp. 626–627; Riley, Hobson & Bence (2006), §8.18.1, pp. 293–294

Let F=R\mathbb{F} = \mathbb{R} or C\mathbb{C}, let A∈Mm×n(F)A\in M_{m\times n}(\mathbb{F}) and read AA as the linear map Fn→Fm\mathbb{F}^n\to\mathbb{F}^m, x↦Axx\mapsto Ax.

  • The rank of AA is rank⁡A=dim⁡Fim⁡A\operatorname{rank}A = \dim_{\mathbb{F}}\operatorname{im}A and its nullity is dim⁡Fker⁡A\dim_{\mathbb{F}}\ker A. Riley, Hobson and Bence call im⁡A\operatorname{im}A the range and ker⁡A\ker A the null space. The column rank is the dimension of the span of the columns of AA in Fm\mathbb{F}^m, the row rank that of the span of its rows in Fn\mathbb{F}^n.
  • For b∈Fmb\in\mathbb{F}^m the augmented matrix [A∣b]∈Mm×(n+1)(F)[A \mid b]\in M_{m\times (n+1)}(\mathbb{F}) is AA with bb appended as an extra column. The system Ax=bAx = b is homogeneous if b=0b = 0 and inhomogeneous otherwise, and consistent if it has at least one solution.
  • The three elementary row operations are: interchanging two rows; scaling a row by a nonzero scalar; adding a scalar multiple of some row to a different row.
  • A matrix is in row echelon form if every zero row lies below every nonzero row and, in each nonzero row, the first nonzero entry (its pivot) stands strictly to the right of the pivot of the row above. A variable xjx_j is free if column jj holds no pivot.
  • A∗∈Mn×m(F)A^{*}\in M_{n\times m}(\mathbb{F}) is the adjoint (conjugate transpose) of AA, (A∗)ji=Aij‾(A^{*})_{ji} = \overline{A_{ij}}; for real AA it is ATA^{\mathsf T}. On Fk\mathbb{F}^k we use (u,v)=∑i=1kuivi‾(u,v) = \sum_{i=1}^{k} u_i\overline{v_i}, and S⊥={v:(v,s)=0 for all s∈S}S^{\perp} = \{v : (v,s) = 0 \text{ for all } s\in S\}.
Method(Rank and the rank-nullity law)AdaptedAdapted from Lee (2013), App. B, Cor. B.21, p. 627, Exercise B.22, p. 627, Prop. B.24, p. 627, Prop. B.25, p. 628; Riley, Hobson & Bence (2006), §8.18.1, eq. (8.119), p. 293

Let A∈Mm×n(F)A\in M_{m\times n}(\mathbb{F}) and put r=rank⁡Ar = \operatorname{rank}A.

  1. Rank-nullity. r+dim⁡Fker⁡A=nr + \dim_{\mathbb{F}}\ker A = n. More generally, if T ⁣:V→WT\colon V\to W is linear and dim⁡FV<∞\dim_{\mathbb{F}}V<\infty, then dim⁡Fim⁡T+dim⁡Fker⁡T=dim⁡FV\dim_{\mathbb{F}}\operatorname{im}T + \dim_{\mathbb{F}}\ker T = \dim_{\mathbb{F}}V; note that it is the dimension of the domain that is split, with no hypothesis on WW.
  2. Row rank equals column rank, and both equal rr; hence rank⁡AT=rank⁡A∗=r\operatorname{rank}A^{\mathsf T} = \operatorname{rank}A^{*} = r.
  3. r≤min⁡(m,n)r \le \min(m,n), with r=nr = n exactly when AA is injective and r=mr = m exactly when AA is surjective.
  4. r≥kr\ge k if and only if some k×kk\times k submatrix of AA (chosen by deleting rows and columns) has nonzero determinant.
  5. Elementary row operations change neither the rank of a matrix nor the solution set of the system it represents when they are applied to [A∣b][A\mid b]. If [U∣c][U\mid c] is any row echelon form reached from [A∣b][A\mid b], then rank⁡A\operatorname{rank}A is the number of pivots of UU.
Idea of the proofOriginal

The rank-nullity law is one basis construction: glue a basis of the kernel to vectors whose images form a basis of the image, and check that the glued list is a basis of the domain. Dimension then has nowhere else to go. The other parts are that law seen from different sides. Row rank meets column rank by factoring AA through its own image, which writes AA as a product of a tall and a wide matrix and bounds the rank of the transpose. And an elementary row operation is multiplication on the left by an invertible matrix, which can change neither the kernel nor the solution set — so elimination may be trusted to report the rank, which in echelon form is visible as the number of pivots.

ProofAdaptedAdapted from Lee (2013), App. B, Thm B.20 and Cor. B.21, pp. 626–627, Prop. B.24, pp. 627–628, Prop. B.25, p. 628; Riley, Hobson & Bence (2006), §8.18.1, pp. 293–294

Part 1. Let T ⁣:V→WT\colon V\to W be linear with dim⁡FV=N<∞\dim_{\mathbb{F}}V = N<\infty. For any basis (z1,…,zN)(z_1,\dots,z_N) of VV, linearity gives im⁡T=span⁡(Tz1,…,TzN)\operatorname{im}T = \operatorname{span}(Tz_1,\dots,Tz_N), so im⁡T\operatorname{im}T is finite-dimensional; write r=dim⁡im⁡Tr = \dim\operatorname{im}T and k=dim⁡ker⁡Tk = \dim\ker T. Choose a basis (u1,…,uk)(u_1,\dots,u_k) of ker⁡T\ker T and a basis (w1,…,wr)(w_1,\dots,w_r) of im⁡T\operatorname{im}T, and for each ii pick vi∈Vv_i\in V with Tvi=wiTv_i = w_i, which is possible by the definition of the image. We claim (v1,…,vr,u1,…,uk)(v_1,\dots,v_r,u_1,\dots,u_k) is a basis of VV.

Independence. Suppose ∑iaivi+∑jbjuj=0\sum_i a_i v_i + \sum_j b_j u_j = 0. Applying TT and using Tuj=0Tu_j = 0 gives ∑iaiwi=0\sum_i a_i w_i = 0, so every ai=0a_i = 0 because the wiw_i are independent. The relation collapses to ∑jbjuj=0\sum_j b_j u_j = 0, so every bj=0b_j = 0 because the uju_j are independent.

Spanning. Let v∈Vv\in V. Since Tv∈im⁡TTv\in\operatorname{im}T, write Tv=∑iciwiTv = \sum_i c_i w_i and put v′=∑iciviv' = \sum_i c_i v_i. Then T(v−v′)=0T(v-v') = 0, so v−v′∈ker⁡Tv - v'\in\ker T is a combination of the uju_j, and v=v′+(v−v′)v = v' + (v-v') is a combination of the whole list.

Hence N=r+kN = r+k, which is the general form; taking TT to be x↦Axx\mapsto Ax on V=FnV = \mathbb{F}^n gives r+dim⁡ker⁡A=nr + \dim\ker A = n. The argument never mentioned dim⁡W\dim W, which is the point of the closing remark of part 1.

Part 2. The columns of AA are the vectors AejAe_j, so they span im⁡A\operatorname{im}A and the column rank is rank⁡A=r\operatorname{rank}A = r. Choose a basis of the rr-dimensional subspace im⁡A\operatorname{im}A. Writing the map x↦Axx\mapsto Ax as the composition of A~ ⁣:Fn→im⁡A\tilde A\colon\mathbb{F}^n\to\operatorname{im}A (the same formula, with the codomain cut down) and the inclusion ι ⁣:im⁡A→Fm\iota\colon\operatorname{im}A\to\mathbb{F}^m, the composition rule of Linear maps and matrices gives a factorisation

A=B C,C∈Mr×n(F),B∈Mm×r(F),A = B\,C, \qquad C\in M_{r\times n}(\mathbb{F}),\quad B\in M_{m\times r}(\mathbb{F}),

with CC the matrix of A~\tilde A and BB the matrix of ι\iota in the chosen basis. Transposing, AT=CTBTA^{\mathsf T} = C^{\mathsf T}B^{\mathsf T}. Now im⁡(CTBT)⊆im⁡CT\operatorname{im}(C^{\mathsf T}B^{\mathsf T})\subseteq\operatorname{im}C^{\mathsf T}, and im⁡CT\operatorname{im}C^{\mathsf T} is spanned by the rr columns of CTC^{\mathsf T}, so rank⁡AT≤r=rank⁡A\operatorname{rank}A^{\mathsf T}\le r = \operatorname{rank}A. Applying this inequality to ATA^{\mathsf T} in place of AA gives rank⁡A=rank⁡(AT)T≤rank⁡AT\operatorname{rank}A = \operatorname{rank}(A^{\mathsf T})^{\mathsf T}\le\operatorname{rank}A^{\mathsf T}, so the two are equal. The row rank of AA is by definition the column rank of ATA^{\mathsf T}, that is rank⁡AT=r\operatorname{rank}A^{\mathsf T} = r. Finally A∗A^{*} is obtained from ATA^{\mathsf T} by conjugating every entry, and conjugating a vanishing linear combination conjugates its coefficients, so a family of vectors in Ck\mathbb{C}^k is independent exactly when the conjugated family is; hence rank⁡A∗=rank⁡AT=r\operatorname{rank}A^{*} = \operatorname{rank}A^{\mathsf T} = r.

Part 3. Part 1 gives r=n−dim⁡ker⁡A≤nr = n - \dim\ker A\le n, with equality exactly when ker⁡A={0}\ker A = \{0\}, which is exactly injectivity (Linear maps and matrices). And im⁡A\operatorname{im}A is a subspace of Fm\mathbb{F}^m, so r≤mr\le m, with equality exactly when im⁡A=Fm\operatorname{im}A = \mathbb{F}^m — a subspace of the same finite dimension as the ambient space is the whole space (Vector spaces and bases) — which is surjectivity.

Part 4. Suppose r≥kr\ge k. Then AA has kk independent columns; the m×km\times k submatrix A′A' they form has rank kk, so by part 2 it has kk independent rows. The k×kk\times k submatrix A′′A'' cut from those rows has row rank kk, hence by part 2 again column rank kk, so its columns are independent and det⁡A′′≠0\det A''\neq 0 by part 7 of the properties statement in Determinants. Conversely, let some k×kk\times k submatrix A′′A'' have det⁡A′′≠0\det A''\neq 0; its kk columns are then independent, by the same part 7. The kk columns of AA it was cut from are independent too: a vanishing combination of them restricts, on the chosen rows, to a vanishing combination of the columns of A′′A'', forcing all coefficients to be zero. Hence r≥kr\ge k.

Part 5. Each elementary row operation on a matrix with mm rows is left multiplication by an invertible E∈Mm×m(F)E\in M_{m\times m}(\mathbb{F}): interchanging rows p,qp,q uses the EE got from ImI_m by that interchange, which is its own inverse; scaling row pp by c≠0c\neq 0 uses the diagonal EE with cc in place pp, whose inverse has c−1c^{-1} there; and adding cc times row pp to row q≠pq\neq p uses E=Im+cFE = I_m + cF, where FF has a single entry 11 in position (q,p)(q,p), whose inverse is Im−cFI_m - cF because F2=0F^2 = 0 when q≠pq\neq p. Since EE is invertible, EAx=0EAx = 0 holds exactly when Ax=0Ax = 0, so ker⁡(EA)=ker⁡A\ker(EA) = \ker A and part 1 gives rank⁡(EA)=n−dim⁡ker⁡(EA)=rank⁡A\operatorname{rank}(EA) = n - \dim\ker(EA) = \operatorname{rank}A. Likewise Ax=bAx = b and (EA)x=Eb(EA)x = Eb have the same solutions, and applying the operation to the augmented matrix produces exactly [EA∣Eb][EA\mid Eb]. Finitely many operations compose, so both invariances survive.

For the pivot count, let [U∣c][U\mid c] be a row echelon form obtained from [A∣b][A\mid b]; deleting the last column commutes with row operations, so UU is obtained from AA by the same operations and rank⁡U=rank⁡A\operatorname{rank}U = \operatorname{rank}A. The nonzero rows of UU are independent. Indeed, suppose a vanishing combination ∑iλi (row i)=0\sum_i\lambda_i\,(\text{row }i) = 0 had some λi≠0\lambda_i\neq 0; let i0i_0 be the smallest index with λi0≠0\lambda_{i_0}\neq 0 — necessarily a nonzero row — and let j0j_0 be the column of its pivot. Every nonzero row below i0i_0 has its first nonzero entry strictly to the right of column j0j_0, by the echelon condition, so its entry in column j0j_0 vanishes; the rows above i0i_0 carry coefficient 00; and zero rows contribute nothing. So the entry of the combination in column j0j_0 is λi0Ui0j0≠0\lambda_{i_0}U_{i_0j_0}\neq 0, a contradiction. Hence the row rank of UU is its number of nonzero rows, which is its number of pivots, and by part 2 this equals rank⁡U=rank⁡A\operatorname{rank}U = \operatorname{rank}A. □\square

Method(Solvability of Ax = b)AdaptedAdapted from Riley, Hobson & Bence (2006), §8.18.1, pp. 293–295, and §8.18.2, p. 295; Arfken, Weber & Harris (2013), §2.1, pp. 83–84

Let A∈Mm×n(F)A\in M_{m\times n}(\mathbb{F}), b∈Fmb\in\mathbb{F}^m and r=rank⁡Ar = \operatorname{rank}A.

  1. Ax=bAx = b is consistent exactly when b∈im⁡Ab\in\operatorname{im}A, equivalently when rank⁡[A∣b]=r\operatorname{rank}[A\mid b] = r. In the remaining case rank⁡[A∣b]=r+1\operatorname{rank}[A\mid b] = r+1 and no solution exists.
  2. If xpx_{\mathrm p} is one solution, the solution set is exactly the coset xp+ker⁡Ax_{\mathrm p} + \ker A, so it is an affine subspace of Fn\mathbb{F}^n of dimension n−rn-r. It is a single point when r=nr = n and is infinite when r<nr<n.
  3. The homogeneous system Ax=0Ax = 0 always has the solution x=0x=0, and has a nonzero solution if and only if r<nr<n. If m<nm<n then r≤m<nr\le m<n, so a homogeneous system with fewer equations than unknowns always has nonzero solutions.
  4. For a square system (m=nm = n) the following are equivalent: r=nr = n; det⁡A≠0\det A\neq 0; ker⁡A={0}\ker A = \{0\}; Ax=bAx = b has exactly one solution for every b∈Fnb\in\mathbb{F}^n. If instead det⁡A=0\det A = 0, then for each bb the system has either no solution or infinitely many.
Idea of the proofOriginal

Read the system columnwise: Ax=bAx = b says that bb is the combination of the columns of AA with coefficients xx. Existence then asks whether bb lies in the column span, which is why appending bb as an extra column and comparing ranks settles it. Uniqueness asks whether the columns satisfy a relation, that is whether ker⁡A\ker A is trivial, and rank-nullity converts that into the count n−rn-r. The square case is special only because a single number, the determinant, detects r=nr=n.

ProofAdaptedAdapted from Riley, Hobson & Bence (2006), §8.18.1, pp. 293–295, and §8.18.2, p. 295; Arfken, Weber & Harris (2013), §2.1, pp. 83–84

Part 1. Writing a1,…,ana_1,\dots,a_n for the columns of AA, the definition of the matrix product gives Ax=∑jxjajAx = \sum_j x_j a_j. So the right-hand sides that can be achieved are exactly the elements of span⁡(a1,…,an)=im⁡A\operatorname{span}(a_1,\dots,a_n) = \operatorname{im}A: the system is consistent precisely when b∈im⁡Ab\in\operatorname{im}A. The columns of [A∣b][A\mid b] span span⁡(a1,…,an,b)\operatorname{span}(a_1,\dots,a_n,b). If b∈im⁡Ab\in\operatorname{im}A this is im⁡A\operatorname{im}A, of dimension rr. If b∉im⁡Ab\notin\operatorname{im}A then bb is independent of a basis of im⁡A\operatorname{im}A — a relation would express bb in terms of it — so adjoining it raises the dimension by exactly one and rank⁡[A∣b]=r+1\operatorname{rank}[A\mid b] = r+1.

Part 2. Let Axp=bAx_{\mathrm p} = b. For any xx, linearity gives Ax−b=A(x−xp)Ax - b = A(x - x_{\mathrm p}), so Ax=bAx = b holds exactly when x−xp∈ker⁡Ax - x_{\mathrm p}\in\ker A, that is exactly when x∈xp+ker⁡Ax\in x_{\mathrm p}+\ker A. This coset is an affine subspace whose dimension is dim⁡ker⁡A=n−r\dim\ker A = n-r by rank-nullity. If r=nr = n then ker⁡A={0}\ker A = \{0\} and the coset is the single point xpx_{\mathrm p}. If r<nr<n then ker⁡A\ker A contains a nonzero yy, hence all its scalar multiples tyty, t∈Ft\in\mathbb{F}, which are distinct because F\mathbb{F} is infinite; so the solution set is infinite.

Part 3. A0=0A0 = 0, so the homogeneous system is always consistent. A nonzero solution exists exactly when ker⁡A≠{0}\ker A\neq\{0\}, that is when n−r>0n - r>0 by rank-nullity. If m<nm<n then part 3 of the rank statement gives r≤m<nr\le m<n, so this happens automatically.

Part 4. Let m=nm=n. By rank-nullity, r=nr=n is equivalent to ker⁡A={0}\ker A = \{0\}. By part 7 of the properties statement in Determinants, det⁡A≠0\det A\neq 0 is equivalent to the nn columns of AA being independent, which — the columns spanning im⁡A\operatorname{im}A — is equivalent to r=nr = n. If r=nr=n then AA is invertible, so x=A−1bx = A^{-1}b solves the system and is its only solution by part 2; conversely, if for some bb there is exactly one solution, then by part 2 the coset xp+ker⁡Ax_{\mathrm p}+\ker A is a single point, so ker⁡A={0}\ker A=\{0\} and r=nr=n. Finally, if det⁡A=0\det A = 0 then r<nr<n and ker⁡A≠{0}\ker A\neq\{0\}; for a given bb, either b∉im⁡Ab\notin\operatorname{im}A and there is no solution, or b∈im⁡Ab\in\operatorname{im}A and part 2 makes the solution set an infinite coset. □\square

Method(The Fredholm alternative in finite dimensions)AdaptedAdapted from Stakgold & Holst (2011), §3.4, Alternative Theorem, pp. 206–208

Let A∈Mm×n(F)A\in M_{m\times n}(\mathbb{F}) and b∈Fmb\in\mathbb{F}^m.

  1. Adjoint identity. (Ax,v)=(x,A∗v)(Ax, v) = (x, A^{*}v) for all x∈Fnx\in\mathbb{F}^n and v∈Fmv\in\mathbb{F}^m, and A∗A^{*} is the only matrix with this property.
  2. im⁡A=(ker⁡A∗)⊥\operatorname{im}A = (\ker A^{*})^{\perp}. Hence Ax=bAx = b is consistent if and only if (b,v)=0(b,v) = 0 for every v∈Fmv\in\mathbb{F}^m satisfying A∗v=0A^{*}v = 0. These m−rank⁡Am - \operatorname{rank}A independent consistency conditions are the whole obstruction.
  3. The alternative. Exactly one of the following holds: (i) Ax=bAx = b has a solution; (ii) there exists v∈Fmv\in\mathbb{F}^m with A∗v=0A^{*}v = 0 and (b,v)≠0(b,v)\neq 0.
  4. For m=nm = n, either A∗v=0A^{*}v = 0 forces v=0v = 0, in which case Ax=bAx = b has exactly one solution for every bb; or A∗v=0A^{*}v = 0 has d≥1d\ge 1 independent solutions, in which case Ax=bAx=b is solvable precisely for the bb in a subspace of dimension n−dn-d, and then has a dd-dimensional set of solutions.
Idea of the proofOriginal

One identity carries the whole theorem: (Ax,v)=(x,A∗v)(Ax,v) = (x,A^{*}v). Read from left to right it says that any vv annihilated by A∗A^{*} is orthogonal to everything AA can produce, so a vv with A∗v=0A^{*}v = 0 and (b,v)≠0(b,v)\neq 0 is a certificate that Ax=bAx=b has no solution. What has to be proved is that there are no obstructions beyond these, and that is a dimension count: the orthogonal complement of the image of a matrix is the kernel of its adjoint, and taking the complement of a subspace twice returns something of the original dimension, hence the original subspace.

ProofAdaptedAdapted from Stakgold & Holst (2011), §3.4, Alternative Theorem and its proof, pp. 207–208

Part 1. With the convention (u,v)=∑iuivi‾(u,v) = \sum_i u_i\overline{v_i} fixed in the definition block,

(Ax,v)=∑i=1m(∑j=1nAijxj)vi‾=∑j=1nxj (∑i=1mAij‾ vi)‾=∑j=1nxj (A∗v)j‾=(x,A∗v),(Ax,v) = \sum_{i=1}^{m}\Bigl(\sum_{j=1}^{n}A_{ij}x_j\Bigr)\overline{v_i} = \sum_{j=1}^{n}x_j\,\overline{\Bigl(\sum_{i=1}^{m}\overline{A_{ij}}\,v_i\Bigr)} = \sum_{j=1}^{n}x_j\,\overline{(A^{*}v)_j} = (x,A^{*}v),

the middle step being the exchange of two finite sums together with z‾ w‾=zw‾\overline{\overline{z}\,w} = z\overline{w} and the definition (A∗)ji=Aij‾(A^{*})_{ji} = \overline{A_{ij}}. For uniqueness, suppose B∈Mn×m(F)B\in M_{n\times m}(\mathbb{F}) also satisfies (Ax,v)=(x,Bv)(Ax,v) = (x,Bv) for all x,vx,v. Subtracting, (x,(A∗−B)v)=0(x,(A^{*}-B)v) = 0 for all xx and vv; taking x=(A∗−B)vx = (A^{*}-B)v gives ∑j∣((A∗−B)v)j∣2=0\sum_j\lvert((A^{*}-B)v)_j\rvert^2 = 0, so (A∗−B)v=0(A^{*}-B)v = 0 for every vv, that is B=A∗B = A^{*}.

A lemma on orthogonal complements. For every subspace SS of Fk\mathbb{F}^k, dim⁡S⊥=k−dim⁡S\dim S^{\perp} = k - \dim S and (S⊥)⊥=S(S^{\perp})^{\perp} = S. Put s=dim⁡Ss = \dim S, choose a basis of SS and let C∈Mk×s(F)C\in M_{k\times s}(\mathbb{F}) have those vectors as its columns, so that S=im⁡CS = \operatorname{im}C. A vector vv lies in S⊥S^{\perp} exactly when (v,Cx)=0(v,Cx) = 0 for all x∈Fsx\in\mathbb{F}^s, equivalently — conjugating — when (Cx,v)=0(Cx,v) = 0 for all xx, which by part 1 is (x,C∗v)=0(x,C^{*}v) = 0 for all xx, which as above means C∗v=0C^{*}v = 0. So

S⊥=ker⁡C∗,S^{\perp} = \ker C^{*},

and rank-nullity applied to C∗∈Ms×k(F)C^{*}\in M_{s\times k}(\mathbb{F}), together with rank⁡C∗=rank⁡C=s\operatorname{rank}C^{*} = \operatorname{rank}C = s (part 2 of the rank statement), gives dim⁡S⊥=k−s\dim S^{\perp} = k - s. Next, S⊆(S⊥)⊥S\subseteq(S^{\perp})^{\perp}: if y∈Sy\in S and v∈S⊥v\in S^{\perp} then (v,y)=0(v,y) = 0 by definition of S⊥S^{\perp}, hence (y,v)=(v,y)‾=0(y,v) = \overline{(v,y)} = 0. Applying the dimension formula twice, dim⁡(S⊥)⊥=k−(k−s)=s=dim⁡S\dim(S^{\perp})^{\perp} = k - (k-s) = s = \dim S, and a subspace of the same finite dimension as the space containing it is that space, so (S⊥)⊥=S(S^{\perp})^{\perp} = S.

Part 2. Taking C=AC = A in the lemma's computation gives (im⁡A)⊥=ker⁡A∗(\operatorname{im}A)^{\perp} = \ker A^{*}. Taking complements and using the lemma with S=im⁡AS = \operatorname{im}A,

im⁡A=((im⁡A)⊥)⊥=(ker⁡A∗)⊥.\operatorname{im}A = \bigl((\operatorname{im}A)^{\perp}\bigr)^{\perp} = (\ker A^{*})^{\perp}.

Combined with part 1 of the solvability statement, Ax=bAx = b is consistent exactly when b∈(ker⁡A∗)⊥b\in(\ker A^{*})^{\perp}, that is exactly when (b,v)=0(b,v) = 0 for every vv with A∗v=0A^{*}v = 0. Let v(1),…,v(d)v^{(1)},\dots,v^{(d)} be a basis of ker⁡A∗\ker A^{*}; since (b,v)(b,v) is linear in bb and conjugate-linear in vv, the whole family of conditions is equivalent to the dd equations (b,v(i))=0(b,v^{(i)}) = 0. Here d=m−rank⁡A∗=m−rank⁡Ad = m - \operatorname{rank}A^{*} = m - \operatorname{rank}A by rank-nullity and part 2 of the rank statement. These dd conditions are independent: the map b↦((b,v(1)),…,(b,v(d)))b\mapsto\bigl((b,v^{(1)}),\dots,(b,v^{(d)})\bigr) is linear from Fm\mathbb{F}^m to Fd\mathbb{F}^d with matrix V∗V^{*}, where VV has the v(i)v^{(i)} as columns, and rank⁡V∗=rank⁡V=d\operatorname{rank}V^{*} = \operatorname{rank}V = d, so it is surjective and no condition is implied by the others.

Part 3. By part 2, statement (i) fails exactly when some v∈ker⁡A∗v\in\ker A^{*} has (b,v)≠0(b,v)\neq 0, which is statement (ii). So (i) and (ii) are negations of each other and exactly one holds.

Part 4. Let m=nm=n. If A∗v=0A^{*}v=0 forces v=0v=0 then ker⁡A∗={0}\ker A^{*} = \{0\}, so rank⁡A∗=n\operatorname{rank}A^{*} = n by rank-nullity and rank⁡A=n\operatorname{rank}A = n by part 2 of the rank statement; part 4 of the solvability statement then gives exactly one solution for every bb. Otherwise d=dim⁡ker⁡A∗≥1d = \dim\ker A^{*}\ge 1. By part 2 the solvable right-hand sides are exactly those in (ker⁡A∗)⊥=im⁡A(\ker A^{*})^{\perp} = \operatorname{im}A, a subspace of dimension n−dn - d by the lemma. For such a bb, part 2 of the solvability statement makes the solution set a coset of ker⁡A\ker A, whose dimension is n−rank⁡A=n−(n−d)=dn - \operatorname{rank}A = n-(n-d) = d. □\square

Method(Gaussian elimination with partial pivoting)AdaptedAdapted from Riley, Hobson & Bence (2006), §27.3.1, pp. 995–996, and §8.18.1, pp. 293–295

Given A∈Mm×n(F)A\in M_{m\times n}(\mathbb{F}) and b∈Fmb\in\mathbb{F}^m, this returns rank⁡A\operatorname{rank}A and the complete solution set of Ax=bAx = b. Work on the augmented matrix [A∣b][A\mid b] throughout, so that every row operation is applied to bb as well.

  1. Set the current row i←1i\leftarrow 1 and the current column j←1j\leftarrow 1.

  2. Choose a pivot. Among rows i,…,mi,\dots,m pick one, say row kk, whose entry in column jj has the largest modulus. If that modulus is zero, column jj carries no pivot: set j←j+1j\leftarrow j+1 and repeat this step (stop the elimination if j>nj>n).

  3. Interchange. Swap rows ii and kk. The entry pp in position (i,j)(i,j) is now nonzero; it is the pivot of row ii.

  4. Eliminate. For each k>ik>i, replace row kk by (row kk) − (Akj/p)⋅-\,(A_{kj}/p)\cdot(row ii). Column jj is now zero below row ii.

  5. Set i←i+1i\leftarrow i+1, j←j+1j\leftarrow j+1 and go back to step 2, stopping when i>mi>m or j>nj>n.

  6. Read the rank. The result [U∣c][U\mid c] is in row echelon form. The number rr of pivots is rank⁡A\operatorname{rank}A, and the pivot columns j1<⋯<jrj_1<\dots<j_r identify rr linearly independent columns of the original AA.

  7. Test consistency. If some row of [U∣c][U\mid c] has all its first nn entries zero but a nonzero last entry, then rank⁡[A∣b]=r+1\operatorname{rank}[A\mid b] = r+1: there is no solution. Stop.

  8. Back-substitute. Give the n−rn-r free variables arbitrary values. Then for i=r,r−1,…,1i = r, r-1,\dots,1 solve the iith pivot row for its pivot variable,

    xji=1Uiji(ci−∑k>jiUikxk),x_{j_i} = \frac{1}{U_{i j_i}}\Bigl(c_i - \sum_{k>j_i} U_{ik}x_k\Bigr),

    every xkx_k on the right being already known.

  9. Describe all solutions. Running step 8 with all free variables 00 gives one solution xpx_{\mathrm p}. Running it with the homogeneous right-hand side, one free variable set to 11 and the rest to 00, gives n−rn-r vectors that form a basis of ker⁡A\ker A. By part 2 of the solvability statement, the solution set is xpx_{\mathrm p} plus their span.

When it works, and how it fails. In exact arithmetic over any field the recipe always terminates, after at most min⁡(m,n)\min(m,n) pivots and about 23n3\tfrac23 n^3 operations for a square system, and the rank and solution set it returns are exact; step 2 may then pick any nonzero entry. In floating point the choice in step 2 matters: a zero pivot halts plain elimination and a merely small one divides by a near-zero number, amplifying rounding error. Two failure modes survive pivoting. First, the computed rank is unreliable when AA is close to a matrix of lower rank, since whether a pivot counts as zero is then a judgement about rounding noise; use the singular value decomposition. Second, partial pivoting holds every multiplier to ∣Akj/p∣≤1\lvert A_{kj}/p\rvert\le 1 yet still permits the entries of UU to grow by a factor 2 n−12^{\,n-1} over those of AA, and matrices attaining that bound exist; such growth is essentially never seen in practice, but it does mean the method is not unconditionally stable. See Numerical linear systems and Matrix norms and conditioning.

Note(What it means)Original

The rank is the number of genuinely independent equations in the system, and the rank-nullity law turns it into a count: n−rn-r dimensions' worth of freedom in the unknowns, m−rm-r conditions the data must satisfy. The Fredholm alternative names those conditions explicitly — the right-hand side must be orthogonal to every solution of the homogeneous adjoint system — and that form of the answer is what generalises, unchanged in spirit, to differential and integral operators. Elimination is the way all of this is actually computed: one sweep produces the rank, the consistency test and a basis of the null space at once.

Remark(Where the hypotheses are used, and conventions)AdaptedAdapted from Stakgold & Holst (2011), §3.4, pp. 206–208; Riley, Hobson & Bence (2006), §8.18.1, p. 293; Arfken, Weber & Harris (2013), §2.1, pp. 83–84
  • Real versus complex adjoint. Stakgold and Holst state the alternative for real matrices, where A∗A^{*} is the transpose. Over C\mathbb{C} the conjugate is required: with the convention (u,v)=∑iuivi‾(u,v) = \sum_i u_i\overline{v_i} used here, (Ax,v)=(x,A∗v)(Ax,v) = (x,A^{*}v) holds for the conjugate transpose and fails for the plain transpose. Taking the transpose by mistake gives wrong consistency conditions as soon as AA has non-real entries.
  • Finite dimensions. Part 2 of the Fredholm statement uses that im⁡A\operatorname{im}A is finite-dimensional, hence closed. For operators on infinite-dimensional spaces the clean equality im⁡A=(ker⁡A∗)⊥\operatorname{im}A = (\ker A^{*})^{\perp} becomes im⁡A‾=(ker⁡A∗)⊥\overline{\operatorname{im}A} = (\ker A^{*})^{\perp}, and a closed-range hypothesis is needed to recover the finite-dimensional form; this is the content of the Fredholm theory of compact operators.
  • "Fewer equations than unknowns" is about rank, not shape. Part 3 of the solvability statement uses m<nm<n only through r≤mr\le m. A system with many more equations than unknowns can still be underdetermined, if its rank is small.
  • The square case is not the general case. The determinant test in part 4 of the solvability statement needs m=nm=n; for rectangular AA its determinantal substitute is part 4 of the rank statement.
  • Cramer's rule is not a method. Arfken, Weber and Harris (Arfken, Weber & Harris (2013), §2.1, pp. 83–84) solve small systems by ratios of determinants, which suits 2×22\times2 and 3×33\times3 systems and symbolic work; its cost grows factorially, so beyond that elimination is the method.
Example(Three equations, five unknowns, one consistency condition)Original

Take F=R\mathbb{F} = \mathbb{R} and

A=(12−10324−11536−218),b=(134).A = \begin{pmatrix} 1 & 2 & -1 & 0 & 3\\ 2 & 4 & -1 & 1 & 5\\ 3 & 6 & -2 & 1 & 8\end{pmatrix}, \qquad b = \begin{pmatrix} 1\\ 3\\ 4\end{pmatrix}.

(The third row of AA is the sum of the first two, which is what will make the system degenerate; the recipe does not need to be told this.)

Steps 1–3: the first pivot. In column 1 the entry of largest modulus among rows 1,2,31,2,3 is the 33 in row 3, so interchange rows 1 and 3 of [A∣b][A\mid b]:

(36−218424−115312−1031).\left(\begin{array}{ccccc|c} 3 & 6 & -2 & 1 & 8 & 4\\ 2 & 4 & -1 & 1 & 5 & 3\\ 1 & 2 & -1 & 0 & 3 & 1\end{array}\right).

Step 4: eliminate. Subtract 23\tfrac23 of the first row from the second and 13\tfrac13 of it from the third:

(36−2184001/31/3−1/31/300−1/3−1/31/3−1/3).\left(\begin{array}{ccccc|c} 3 & 6 & -2 & 1 & 8 & 4\\ 0 & 0 & 1/3 & 1/3 & -1/3 & 1/3\\ 0 & 0 & -1/3 & -1/3 & 1/3 & -1/3\end{array}\right).

Step 2 again: a column with no pivot. Column 2 is now zero in rows 2 and 3, so it carries no pivot and we move to column 3. There the two candidates 1/31/3 and −1/3-1/3 have equal modulus; take the first, in row 2, as the pivot. Adding row 2 to row 3 clears it:

[U∣c]=(36−2184001/31/3−1/31/3000000).[U\mid c] = \left(\begin{array}{ccccc|c} 3 & 6 & -2 & 1 & 8 & 4\\ 0 & 0 & 1/3 & 1/3 & -1/3 & 1/3\\ 0 & 0 & 0 & 0 & 0 & 0\end{array}\right).

Step 6: the rank. UU is in row echelon form with two pivots, so rank⁡A=2\operatorname{rank}A = 2 by part 5 of the rank statement, and the pivot columns j1=1j_1 = 1, j2=3j_2 = 3 pick out two independent columns of the original AA, namely (1,2,3)T(1,2,3)^{\mathsf T} and (−1,−1,−2)T(-1,-1,-2)^{\mathsf T}. Rank-nullity then predicts dim⁡ker⁡A=5−2=3\dim\ker A = 5-2 = 3 before any solving is done, and part 4 of the rank statement gives an independent check: the 2×22\times2 submatrix of AA in rows 1,21,2 and columns 1,31,3 is (1−12−1)\begin{pmatrix}1 & -1\\ 2 & -1\end{pmatrix} with determinant 1≠01\neq 0, so rank⁡A≥2\operatorname{rank}A\ge 2, while rank⁡A=2\operatorname{rank}A = 2 says every 3×33\times3 submatrix is singular.

Step 7: consistency. The zero row of UU has a zero entry in the last column, so the system is consistent.

Step 8: back-substitution. The free variables are x2x_2, x4x_4, x5x_5 — the non-pivot columns. The second pivot row gives

13x3=13−13x4+13x5,sox3=1−x4+x5,\tfrac13 x_3 = \tfrac13 - \tfrac13 x_4 + \tfrac13 x_5, \qquad\text{so}\qquad x_3 = 1 - x_4 + x_5 ,

and the first pivot row then gives

3x1=4−6x2+2x3−x4−8x5=6−6x2−3x4−6x5,sox1=2−2x2−x4−2x5.3x_1 = 4 - 6x_2 + 2x_3 - x_4 - 8x_5 = 6 - 6x_2 - 3x_4 - 6x_5, \qquad\text{so}\qquad x_1 = 2 - 2x_2 - x_4 - 2x_5 .

Step 9: all solutions. Setting the free variables to zero gives xp=(2,0,1,0,0)Tx_{\mathrm p} = (2,0,1,0,0)^{\mathsf T}, and indeed Axp=(2−1, 4−1, 6−2)T=(1,3,4)T=bAx_{\mathrm p} = (2-1,\,4-1,\,6-2)^{\mathsf T} = (1,3,4)^{\mathsf T} = b. Setting one free variable to 11 and the others to 00 with bb replaced by 00 gives three kernel vectors,

k1=(−21000),k2=(−10−110),k3=(−20101),k_1 = \begin{pmatrix}-2\\ 1\\ 0\\ 0\\ 0\end{pmatrix},\quad k_2 = \begin{pmatrix}-1\\ 0\\ -1\\ 1\\ 0\end{pmatrix},\quad k_3 = \begin{pmatrix}-2\\ 0\\ 1\\ 0\\ 1\end{pmatrix},

so the solution set is {xp+t1k1+t2k2+t3k3:ti∈R}\{x_{\mathrm p}+t_1k_1+t_2k_2+t_3k_3 : t_i\in\mathbb{R}\}, a three-dimensional affine subspace of R5\mathbb{R}^5 as predicted. Checking k2k_2: Ak2=(−1+1+0, −2+1+1, −3+2+1)T=0Ak_2 = (-1+1+0,\,-2+1+1,\,-3+2+1)^{\mathsf T} = 0. The three are independent because their last three entries form the identity pattern (1,0,0)(1,0,0), (0,1,0)(0,1,0), (0,0,1)(0,0,1) in the free positions.

The consistency condition, found two ways. Since AA is real, A∗=ATA^{*} = A^{\mathsf T}, and ATv=0A^{\mathsf T}v = 0 says v1ρ1+v2ρ2+v3ρ3=0v_1\rho_1+v_2\rho_2+v_3\rho_3 = 0 for the rows ρi\rho_i of AA. As ρ3=ρ1+ρ2\rho_3 = \rho_1+\rho_2 and ρ1,ρ2\rho_1,\rho_2 are independent, this forces v1=v2=−v3v_1 = v_2 = -v_3, so ker⁡AT=span⁡{(1,1,−1)T}\ker A^{\mathsf T} = \operatorname{span}\{(1,1,-1)^{\mathsf T}\} — of dimension m−r=3−2=1m - r = 3-2 = 1, as part 2 of the Fredholm statement requires. The single consistency condition is therefore

(b,v)=b1+b2−b3=0,(b,v) = b_1+b_2-b_3 = 0,

satisfied by b=(1,3,4)Tb = (1,3,4)^{\mathsf T}. Elimination finds the same covector by itself: tracking the operations, the final zero row was formed as ρ1+ρ2−ρ3\rho_1+\rho_2-\rho_3, so the last entry of that row is exactly b1+b2−b3b_1+b_2-b_3. Replace bb by (1,3,5)T(1,3,5)^{\mathsf T}, for which b1+b2−b3=−1b_1+b_2-b_3 = -1, and the same elimination ends with the row (0  0  0  0  0∣−1)(0\;0\;0\;0\;0\mid -1): step 7 reports no solution, with rank⁡[A∣b]=3=r+1\operatorname{rank}[A\mid b] = 3 = r+1.

ApplicationOriginal

A resistor network: why the ground node must be chosen, and why the currents must balance. Join each pair of three nodes by a 1 Ω1\,\Omega resistor and inject currents I1,I2,I3I_1,I_2,I_3 from outside. Ohm's law on each resistor and current conservation at each node give, for the node potentials viv_i,

Lv=I,L=(2−1−1−12−1−1−12),L v = I, \qquad L = \begin{pmatrix} 2 & -1 & -1\\ -1 & 2 & -1\\ -1 & -1 & 2\end{pmatrix},

the iith equation being ∑j≠i(vi−vj)=Ii\sum_{j\neq i}(v_i-v_j) = I_i. Every row of LL sums to zero, so L(1,1,1)T=0L(1,1,1)^{\mathsf T} = 0: the matrix is singular, and the physics says why — adding the same constant to every potential changes no current. Part 2 of the solvability statement is then the statement that the potentials are determined exactly up to that one constant, which is what "choosing a ground" means. Because LL is symmetric, ker⁡L∗=ker⁡L=span⁡{(1,1,1)T}\ker L^{*} = \ker L = \operatorname{span}\{(1,1,1)^{\mathsf T}\}, and the Fredholm alternative gives the solvability condition

(I,(1,1,1)T)=I1+I2+I3=0:(I,(1,1,1)^{\mathsf T}) = I_1+I_2+I_3 = 0 :

Kirchhoff's current law for the network as a whole. Inject I=(1,0,−1)TI = (1,0,-1)^{\mathsf T}, which satisfies it. By the symmetry v↦−vv\mapsto -v under swapping nodes 1 and 3, try v=(a,0,−a)Tv = (a,0,-a)^{\mathsf T}; the first equation reads a+2a=1a+2a = 1, so a=13a = \tfrac13 and v=(13,0,−13)Tv = (\tfrac13,0,-\tfrac13)^{\mathsf T}, which satisfies all three equations. The effective resistance between nodes 1 and 3 is (v1−v3)/1=23 Ω(v_1-v_3)/1 = \tfrac23\,\Omega — correct, since the direct 1 Ω1\,\Omega resistor is in parallel with the 2 Ω2\,\Omega path through node 2, giving (1⋅2)/(1+2)(1\cdot 2)/(1+2). The whole pattern — a one-dimensional kernel, one consistency condition, a solution fixed up to a gauge choice — is generic for a connected network, and LL is its graph Laplacian.

The same alternative, for differential operators. The shape of the answer here is what survives into infinite dimensions, and it is the reason the Fredholm alternative is stated at all rather than just "row-reduce and see". The Neumann problem ∇2u=f\nabla^2u = f in Ω\Omega with ∂u/∂n=g\partial u/\partial n = g on ∂Ω\partial\Omega has constants in the kernel of its adjoint, so it is solvable only if ∫Ωf dV=∮∂Ωg dS\int_\Omega f\,\mathrm{d}V = \oint_{\partial\Omega}g\,\mathrm{d}S, and then only up to an additive constant (Green's identities); a Fredholm integral equation with a degenerate kernel reduces to exactly the finite system treated here (Separable kernels); and for compact operators the alternative holds in the same form, with a closed-range hypothesis replacing finite dimension (Compact operators). In each case the consistency conditions are orthogonality to the solutions of the homogeneous adjoint problem.

When the conditions fail: measurement data. An overdetermined system Ax=bAx = b built from measurements almost never satisfies its m−rm-r consistency conditions, because bb carries noise. The Fredholm alternative then says plainly that no solution exists, and the practical response is to replace "solve" by "minimise ∥Ax−b∥\lVert Ax-b\rVert", which projects bb onto im⁡A\operatorname{im}A along ker⁡A∗\ker A^{*} — the same two subspaces, now used constructively (Orthogonal projection and least squares).

Inner products and orthogonality

3

Definition

Inner products and norms

Adapted

Real and complex inner products in the convention used throughout this handbook, the norm they induce, and the Cauchy-Schwarz and triangle inequalities with their exact cases of equality.

Prerequisites: Vector spaces and bases

Definition(Inner product space)AdaptedAdapted from Kreyszig (1978), §3.1, Def. 3.1-1, pp. 128–129, and p. 130; Lee (2013), App. B, pp. 635–636; Reed & Simon (1980), §II.1, p. 36; Hassani (2013), §2.2, p. 31 (the words sesquilinear and hermitian)

Let VV be a vector space over F\mathbb{F}, where F=R\mathbb{F} = \mathbb{R} or C\mathbb{C}. An inner product on VV is a map V×V→FV\times V\to\mathbb{F}, written (x,y)(x,y), with, for all x,y,z∈Vx,y,z\in V and a∈Fa\in\mathbb{F}:

(x+y, z)=(x,z)+(y,z),(ax, y)=a (x,y),(y,x)=(x,y)‾,(x+y,\,z) = (x,z)+(y,z), \qquad (ax,\,y) = a\,(x,y), \qquad (y,x) = \overline{(x,y)},(x,x) ≥ 0,and(x,x)=0  ⟺  x=0.(x,x)\ \ge\ 0, \qquad\text{and}\qquad (x,x) = 0 \iff x = 0 .

The third condition makes (x,x)(x,x) real, so the fourth is well posed; a vector space with a chosen inner product is an inner product space. Combining the first three conditions,

(ax+by, z)=a(x,z)+b(y,z),(x, ay+bz)=a‾ (x,y)+b‾ (x,z),(ax+by,\,z) = a(x,z)+b(y,z), \qquad (x,\,ay+bz) = \overline{a}\,(x,y)+\overline{b}\,(x,z),

so the product is linear in its first slot and conjugate-linear in its second — sesquilinear, or hermitian. Over R\mathbb{R} the bars vanish: the third condition becomes symmetry, (x,y)=(y,x)(x,y) = (y,x), and the product is bilinear.

Definition(Norm, orthogonality, orthogonal complement)AdaptedAdapted from Lee (2013), App. B, pp. 636–637; Kreyszig (1978), §3.1, eq. (1), p. 129, and Def. 3.1-2, p. 131; Hassani (2013), §2.2, Def. 2.2.4, p. 32; Stakgold & Holst (2011), §4.5, pp. 264–266

A norm on a vector space VV over F\mathbb{F} is a map ∥⋅∥ ⁣:V→R\lVert\cdot\rVert\colon V\to\mathbb{R} with: ∥x∥≥0\lVert x\rVert\ge 0 and ∥x∥=0\lVert x\rVert = 0 only for x=0x=0; ∥ax∥=∣a∣ ∥x∥\lVert ax\rVert = \lvert a\rvert\,\lVert x\rVert for a∈Fa\in\mathbb{F}; and ∥x+y∥≤∥x∥+∥y∥\lVert x+y\rVert\le\lVert x\rVert+\lVert y\rVert. A vector space with a chosen norm is a normed space, metrized by d(x,y)=∥x−y∥d(x,y) = \lVert x-y\rVert.

On an inner product space the induced norm is ∥x∥=(x,x)1/2\lVert x\rVert = (x,x)^{1/2}; part 3 below shows it is a norm. In the real case ∥x∥\lVert x\rVert is the length of xx, and the angle θ∈[0,π]\theta\in[0,\pi] between nonzero x,yx,y is fixed by cos⁡θ=(x,y)/(∥x∥∥y∥)\cos\theta = (x,y)/(\lVert x\rVert\lVert y\rVert), legitimate because Cauchy-Schwarz confines that quotient to [−1,1][-1,1].

Vectors x,yx,y are orthogonal, written x⊥yx\perp y, if (x,y)=0(x,y) = 0; a set is orthogonal if its elements are pairwise orthogonal, and orthonormal if in addition every element has norm 11. For S⊆VS\subseteq V the orthogonal complement is

S⊥={ v∈V:(v,s)=0 for every s∈S },S^{\perp} = \{\,v\in V : (v,s) = 0\ \text{for every } s\in S\,\},

always a subspace of VV, whatever SS is. An inner product space that is complete in the induced metric is a Hilbert space; completeness is not assumed here.

Definition(The standard inner products)AdaptedAdapted from Kreyszig (1978), §3.1, Examples 3.1-3 and 3.1-4, eqs. (5)–(6), pp. 131–132; Hassani (2013), §2.2, Example 2.2.3, eq. (2.10), pp. 31–32
  • On Fn\mathbb{F}^n: (x,y)=∑i=1nxiyi‾(x,y) = \sum_{i=1}^{n} x_i\overline{y_i}. For F=R\mathbb{F}=\mathbb{R} this is the Euclidean dot product, and the induced norm is ∥x∥=(∑i∣xi∣2)1/2\lVert x\rVert = \bigl(\sum_i\lvert x_i\rvert^2\bigr)^{1/2}.

  • On a space of F\mathbb{F}-valued functions on an interval, a weighted inner product

    (f,g)=∫abw(t) f(t) g(t)‾ dt,(f,g) = \int_a^b w(t)\,f(t)\,\overline{g(t)}\,\mathrm{d}t ,

    where the weight ww is real-valued, continuous and strictly positive on (a,b)(a,b), and the space is small enough that the integral converges for all its members. Two cases where it does: C([a,b],F)C([a,b],\mathbb{F}) with −∞<a<b<∞-\infty<a<b<\infty and ww integrable on [a,b][a,b]; and the polynomials, with a weight whose moments ∫abw(t) ∣t∣k dt\int_a^b w(t)\,\lvert t\rvert^k\,\mathrm{d}t all converge, k=0,1,2,…k = 0,1,2,\dots — for instance w(t)=e−tw(t) = e^{-t} on (0,∞)(0,\infty), where the kk-th moment is k!k!. Strict positivity of ww on the open interval is what makes (f,f)=0(f,f) = 0 force f=0f = 0. Different weights give different inner products.

Definition(The induced norm and the two basic inequalities)AdaptedAdapted from Kreyszig (1978), §3.2, Lemma 3.2-1, pp. 136–138, p. 130, and Lemma 3.2-2, p. 138; Stakgold & Holst (2011), §4.5, p. 264; Reed & Simon (1980), §II.1, p. 37, and Problem 4, p. 63; Lee (2013), App. B, Exercise B.39, p. 636

Let VV be an inner product space over F\mathbb{F} and ∥x∥=(x,x)1/2\lVert x\rVert = (x,x)^{1/2}. Parts 1–3, 5 and 6 hold for all x,y∈Vx,y\in V, and so does the first sentence of part 4, whose second sentence covers every finite family x1,…,xN∈Vx_1,\dots,x_N\in V, N∈NN\in\mathbb{N}. Parts 7 and 8 carry their own hypotheses: part 7 is about a vector space WW over F\mathbb{F} equipped with an arbitrary norm, not assumed to come from an inner product, and part 8 is about sequences in VV.

  1. Expansion. ∥x+y∥2=∥x∥2+2Re⁡(x,y)+∥y∥2\lVert x+y\rVert^2 = \lVert x\rVert^2 + 2\operatorname{Re}(x,y) + \lVert y\rVert^2.

  2. Cauchy-Schwarz inequality. ∣(x,y)∣≤∥x∥ ∥y∥\lvert(x,y)\rvert \le \lVert x\rVert\,\lVert y\rVert, with equality exactly when one of x,yx,y is a scalar multiple of the other, that is, when y=0y = 0 or x=cyx = cy for some c∈Fc\in\mathbb{F}.

  3. Triangle inequality. ∥x+y∥≤∥x∥+∥y∥\lVert x+y\rVert \le \lVert x\rVert+\lVert y\rVert, with equality exactly when y=0y = 0, or else x=cyx = cy for some real c≥0c\ge 0. Consequently ∥⋅∥\lVert\cdot\rVert is a norm on VV.

  4. Pythagoras. If x⊥yx\perp y then ∥x+y∥2=∥x∥2+∥y∥2\lVert x+y\rVert^2 = \lVert x\rVert^2+\lVert y\rVert^2. More generally, if x1,…,xN∈Vx_1,\dots,x_N\in V are pairwise orthogonal, with N∈NN\in\mathbb{N}, then ∥∑n=1Nxn∥2=∑n=1N∥xn∥2\bigl\lVert\sum_{n=1}^{N} x_n\bigr\rVert^2 = \sum_{n=1}^{N}\lVert x_n\rVert^2.

  5. Parallelogram law. ∥x+y∥2+∥x−y∥2=2∥x∥2+2∥y∥2\lVert x+y\rVert^2+\lVert x-y\rVert^2 = 2\lVert x\rVert^2+2\lVert y\rVert^2.

  6. Polarization identity. The inner product is recovered from the norm: over C\mathbb{C},

    4 (x,y)=(∥x+y∥2−∥x−y∥2)+i(∥x+iy∥2−∥x−iy∥2),4\,(x,y) = \bigl(\lVert x+y\rVert^2-\lVert x-y\rVert^2\bigr) + i\bigl(\lVert x+iy\rVert^2-\lVert x-iy\rVert^2\bigr),

    and over R\mathbb{R}, 4(x,y)=∥x+y∥2−∥x−y∥24(x,y) = \lVert x+y\rVert^2-\lVert x-y\rVert^2. In particular two inner products with the same induced norm are equal.

  7. Characterisation by the parallelogram law. A norm on a vector space WW over F\mathbb{F} is induced by some inner product on WW if and only if it satisfies the identity of part 5 for all x,y∈Wx,y\in W.

  8. Continuity. If xn→xx_n\to x and yn→yy_n\to y in the induced metric, then (xn,yn)→(x,y)(x_n,y_n)\to(x,y).

Idea of the proofOriginal

One expansion does most of the work: ∥x+y∥2\lVert x+y\rVert^2 opened out by sesquilinearity is part 1, and parts 4, 5 and 6 are that same expansion with yy replaced by −y-y, by iyiy, or by orthogonal pieces. Cauchy-Schwarz comes from applying it to x−ayx - ay and choosing the aa that makes the result smallest — geometrically, subtracting from xx its component along yy, leaving a vector whose squared length is the slack in the inequality. The triangle inequality is then Cauchy-Schwarz together with Re⁡z≤∣z∣\operatorname{Re}z\le\lvert z\rvert, and the two equality cases are exactly the two places where those steps can be tight: the leftover component must vanish, and the inner product must be real and non-negative. Part 7 is the one genuine converse, and it is proved by taking the formula of part 6 as a definition and checking the axioms, where the parallelogram law is what makes the candidate additive.

ProofAdaptedAdapted from Kreyszig (1978), §3.1, p. 130, §3.2, Lemma 3.2-1, pp. 136–138, and Lemma 3.2-2, p. 138; Reed & Simon (1980), §II.1, p. 37, and Problem 4, p. 63

Throughout, sesquilinearity means the two displayed identities of the first definition block: additive and homogeneous in the first slot, additive and conjugate-homogeneous in the second. Note first that (x,0)=0(x,0) = 0 for every xx, because (x,0)=(x,0+0)=(x,0)+(x,0)(x,0) = (x,0+0) = (x,0)+(x,0).

Part 1. Expanding by additivity in each slot and then using (y,x)=(x,y)‾(y,x) = \overline{(x,y)},

∥x+y∥2=(x+y,x+y)=(x,x)+(x,y)+(y,x)+(y,y)=∥x∥2+2Re⁡(x,y)+∥y∥2,\lVert x+y\rVert^2 = (x+y,x+y) = (x,x)+(x,y)+(y,x)+(y,y) = \lVert x\rVert^2 + 2\operatorname{Re}(x,y) + \lVert y\rVert^2 ,

since z+z‾=2Re⁡zz+\overline{z} = 2\operatorname{Re}z. Replacing yy by −y-y, which changes (x,y)(x,y) into −(x,y)-(x,y) and leaves ∥y∥\lVert y\rVert alone, gives the companion identity

∥x−y∥2=∥x∥2−2Re⁡(x,y)+∥y∥2,\lVert x-y\rVert^2 = \lVert x\rVert^2 - 2\operatorname{Re}(x,y) + \lVert y\rVert^2 ,

used repeatedly below.

Part 2, the inequality. If y=0y=0 both sides are 00. So let y≠0y\neq 0, whence (y,y)>0(y,y)>0 by strict positivity. For any a∈Fa\in\mathbb{F}, expanding as in part 1,

0 ≤ ∥x−ay∥2=(x,x)−a‾(x,y)−a(y,x)+∣a∣2(y,y),0\ \le\ \lVert x-ay\rVert^2 = (x,x) - \overline{a}(x,y) - a(y,x) + \lvert a\rvert^2(y,y),

where the first inequality is (u,u)≥0(u,u)\ge 0. Take a=(x,y)/(y,y)a = (x,y)/(y,y), legitimate because (y,y)≠0(y,y)\neq 0 and real. Then a‾(x,y)=a(y,x)=∣(x,y)∣2/(y,y)\overline{a}(x,y) = a(y,x) = \lvert(x,y)\rvert^2/(y,y) and ∣a∣2(y,y)=∣(x,y)∣2/(y,y)\lvert a\rvert^2(y,y) = \lvert(x,y)\rvert^2/(y,y), so three of the four terms collapse to one:

0 ≤ ∥x∥2−∣(x,y)∣2∥y∥2.0\ \le\ \lVert x\rVert^2 - \frac{\lvert(x,y)\rvert^2}{\lVert y\rVert^2}.

Multiplying by ∥y∥2>0\lVert y\rVert^2>0 and taking non-negative square roots gives ∣(x,y)∣≤∥x∥∥y∥\lvert(x,y)\rvert\le\lVert x\rVert\lVert y\rVert.

Part 2, the equality case. With y≠0y \ne 0 and aa as chosen, the display is an equality exactly when ∥x−ay∥2=0\lVert x-ay\rVert^2 = 0, which by strict definiteness means x=ayx = ay — so equality forces xx to be a multiple of yy. Conversely, if y=0y=0 equality holds, and if x=cyx = cy then ∣(x,y)∣=∣c∣∥y∥2\lvert(x,y)\rvert = \lvert c\rvert\lVert y\rVert^2 while ∥x∥∥y∥=∣c∣∥y∥2\lVert x\rVert\lVert y\rVert = \lvert c\rvert\lVert y\rVert^2 by homogeneity, so equality holds again. This is the condition as stated: y=0y=0, or x=cyx = cy for some c∈Fc\in\mathbb{F}.

Part 3, the inequality and the norm axioms. By part 1, then Re⁡z≤∣z∣\operatorname{Re}z\le\lvert z\rvert, then part 2,

∥x+y∥2≤∥x∥2+2∣(x,y)∣+∥y∥2≤∥x∥2+2∥x∥∥y∥+∥y∥2=(∥x∥+∥y∥)2,\lVert x+y\rVert^2 \le \lVert x\rVert^2 + 2\lvert(x,y)\rvert + \lVert y\rVert^2 \le \lVert x\rVert^2 + 2\lVert x\rVert\lVert y\rVert + \lVert y\rVert^2 = (\lVert x\rVert+\lVert y\rVert)^2,

and taking square roots of non-negative numbers gives the triangle inequality. For the remaining norm axioms: ∥x∥=(x,x)1/2≥0\lVert x\rVert = (x,x)^{1/2}\ge 0, and it vanishes only for x=0x=0 by strict definiteness — this is the one clause of part 3 that needs more than (x,x)≥0(x,x)\ge0 — while

∥ax∥2=(ax,ax)=aa‾ (x,x)=∣a∣2∥x∥2\lVert ax\rVert^2 = (ax,ax) = a\overline{a}\,(x,x) = \lvert a\rvert^2\lVert x\rVert^2

by homogeneity in the first slot and conjugate-homogeneity in the second.

Part 3, the equality case. Equality in the triangle inequality forces equality at both steps above, that is Re⁡(x,y)=∣(x,y)∣\operatorname{Re}(x,y) = \lvert(x,y)\rvert and ∣(x,y)∣=∥x∥∥y∥\lvert(x,y)\rvert = \lVert x\rVert\lVert y\rVert. By part 2 the second gives y=0y=0 or x=cyx=cy. Suppose y≠0y\neq 0 and x=cyx = cy; then (x,y)=c∥y∥2(x,y) = c\lVert y\rVert^2, so the first condition says Re⁡c=∣c∣\operatorname{Re}c = \lvert c\rvert, which holds exactly when cc is real and ≥0\ge 0. Conversely y=0y = 0, or x=cyx = cy with cc real and ≥0\ge0, makes both steps equalities. So equality holds exactly when y=0y=0 or x=cyx = cy with c≥0c\ge 0 real.

Part 4. If (x,y)=0(x,y)=0 then Re⁡(x,y)=0\operatorname{Re}(x,y)=0 and part 1 gives ∥x+y∥2=∥x∥2+∥y∥2\lVert x+y\rVert^2 = \lVert x\rVert^2+\lVert y\rVert^2. For a finite pairwise-orthogonal family, additivity in each slot expands the square of the norm into N2N^2 terms,

∥∑n=1Nxn∥2=∑n=1N∑k=1N(xn,xk),\Bigl\lVert\sum_{n=1}^{N}x_n\Bigr\rVert^2 = \sum_{n=1}^{N}\sum_{k=1}^{N}(x_n,x_k),

and every term with n≠kn\neq k vanishes: (xn,xk)=0(x_n,x_k) = 0 by hypothesis when n<kn<k, and (xk,xn)=(xn,xk)‾=0(x_k,x_n) = \overline{(x_n,x_k)} = 0 as well. The diagonal leaves ∑n∥xn∥2\sum_n\lVert x_n\rVert^2. Finiteness is what allows the expansion; no convergence question arises.

Part 5. Add the two identities of part 1: the terms ±2Re⁡(x,y)\pm2\operatorname{Re}(x,y) cancel, leaving ∥x+y∥2+∥x−y∥2=2∥x∥2+2∥y∥2\lVert x+y\rVert^2+\lVert x-y\rVert^2 = 2\lVert x\rVert^2+2\lVert y\rVert^2.

Part 6. Subtracting the two identities of part 1 gives

∥x+y∥2−∥x−y∥2=4Re⁡(x,y),\lVert x+y\rVert^2-\lVert x-y\rVert^2 = 4\operatorname{Re}(x,y),

which over R\mathbb{R} is already the claim, since there (x,y)(x,y) is real. Over C\mathbb{C}, apply the same identity with iyiy in place of yy and use conjugate-homogeneity, (x,iy)=i‾(x,y)=−i(x,y)(x,iy) = \overline{i}(x,y) = -i(x,y):

∥x+iy∥2−∥x−iy∥2=4Re⁡(−i(x,y))=4Im⁡(x,y),\lVert x+iy\rVert^2-\lVert x-iy\rVert^2 = 4\operatorname{Re}\bigl(-i(x,y)\bigr) = 4\operatorname{Im}(x,y),

because −i(u+iv)=v−iu-i(u+iv) = v-iu has real part vv. Adding ii times the second display to the first gives 4Re⁡(x,y)+4iIm⁡(x,y)=4(x,y)4\operatorname{Re}(x,y)+4i\operatorname{Im}(x,y) = 4(x,y). For the last clause, if two inner products induce the same norm then the right-hand sides agree, so the products agree.

Part 7, the easy direction. A norm induced by an inner product satisfies the identity of part 5, which was just proved from the axioms alone.

Part 7, the converse: the real case. This is the Jordan-von Neumann theorem, stated as Problem 4(b) of Reed and Simon (Reed & Simon (1980), p. 63); here is the construction. Let ∥⋅∥\lVert\cdot\rVert be a norm on WW satisfying the parallelogram identity, and define the real-valued

s(x,y)=14(∥x+y∥2−∥x−y∥2),s(x,y) = \tfrac14\bigl(\lVert x+y\rVert^2-\lVert x-y\rVert^2\bigr),

which is the expression part 6 would have to give. Then s(x,x)=14∥2x∥2=∥x∥2s(x,x) = \tfrac14\lVert 2x\rVert^2 = \lVert x\rVert^2, so ss is positive and vanishes only at 00; and ss is symmetric, since ∥y−x∥=∥−(x−y)∥=∥x−y∥\lVert y-x\rVert = \lVert{-(x-y)}\rVert = \lVert x-y\rVert by homogeneity. Also s(0,y)=0s(0,y) = 0.

Additivity. The parallelogram identity in the form ∥u∥2+∥v∥2=12(∥u+v∥2+∥u−v∥2)\lVert u\rVert^2+\lVert v\rVert^2 = \tfrac12(\lVert u+v\rVert^2+\lVert u-v\rVert^2), applied once with u=x+zu = x+z, v=y+zv = y+z and once with u=x−zu = x-z, v=y−zv = y-z, gives

∥x+z∥2+∥y+z∥2=12(∥x+y+2z∥2+∥x−y∥2),\lVert x+z\rVert^2+\lVert y+z\rVert^2 = \tfrac12\bigl(\lVert x+y+2z\rVert^2+\lVert x-y\rVert^2\bigr),∥x−z∥2+∥y−z∥2=12(∥x+y−2z∥2+∥x−y∥2).\lVert x-z\rVert^2+\lVert y-z\rVert^2 = \tfrac12\bigl(\lVert x+y-2z\rVert^2+\lVert x-y\rVert^2\bigr).

Subtracting, the terms ∥x−y∥2\lVert x-y\rVert^2 cancel and

4s(x,z)+4s(y,z)=12(∥x+y+2z∥2−∥x+y−2z∥2)=2 s(x+y, 2z).4s(x,z)+4s(y,z) = \tfrac12\bigl(\lVert x+y+2z\rVert^2-\lVert x+y-2z\rVert^2\bigr) = 2\,s(x+y,\,2z).

Putting y=0y = 0 in this and using s(0,z)=0s(0,z)=0 gives s(x,2z)=2s(x,z)s(x,2z) = 2s(x,z) for all x,zx,z; substituting that back into the right-hand side turns it into 4s(x+y,z)4s(x+y,z). Hence s(x+y,z)=s(x,z)+s(y,z)s(x+y,z) = s(x,z)+s(y,z).

Homogeneity. Additivity gives s(kx,y)=k s(x,y)s(kx,y) = k\,s(x,y) for k∈Nk\in\mathbb{N} by induction, and s(−x,y)=−s(x,y)s(-x,y) = -s(x,y) because s(x,y)+s(−x,y)=s(0,y)=0s(x,y)+s(-x,y) = s(0,y) = 0, so the identity holds for every k∈Zk\in\mathbb{Z}. For q=p/kq = p/k with p∈Zp\in\mathbb{Z}, k∈Nk\in\mathbb{N}, applying it twice gives k s(qx,y)=s(px,y)=p s(x,y)k\,s(qx,y) = s(px,y) = p\,s(x,y), so s(qx,y)=q s(x,y)s(qx,y) = q\,s(x,y) for every rational qq. Finally c↦s(cx,y)c\mapsto s(cx,y) is continuous, because ∣∥u∥−∥v∥∣≤∥u−v∥\lvert\lVert u\rVert-\lVert v\rVert\rvert\le\lVert u-v\rVert (a consequence of the triangle inequality) makes c↦∥cx±y∥c\mapsto\lVert cx\pm y\rVert continuous; two continuous functions of cc that agree on the dense set Q\mathbb{Q} agree everywhere, so s(cx,y)=c s(x,y)s(cx,y) = c\,s(x,y) for all real cc. Over R\mathbb{R}, then, ss is a symmetric positive-definite bilinear form with s(x,x)=∥x∥2s(x,x) = \lVert x\rVert^2: an inner product inducing the given norm.

Part 7, the converse: the complex case. Let WW be over C\mathbb{C}. Viewing it as a real vector space, the previous paragraphs give a real-bilinear symmetric ss with s(x,x)=∥x∥2s(x,x) = \lVert x\rVert^2. Homogeneity of the norm gives ∥iu∥=∥u∥\lVert i u\rVert = \lVert u\rVert, hence s(ix,iy)=s(x,y)s(ix,iy) = s(x,y) for all x,yx,y. Define

(x,y):=s(x,y)+i s(x,iy).(x,y) := s(x,y) + i\,s(x,iy).

Four checks finish the proof.

  • s(x,ix)=14(∣1+i∣2−∣1−i∣2)∥x∥2=0s(x,ix) = \tfrac14\bigl(\lvert 1+i\rvert^2-\lvert 1-i\rvert^2\bigr)\lVert x\rVert^2 = 0, so (x,x)=∥x∥2(x,x) = \lVert x\rVert^2, which is ≥0\ge0 and vanishes only at x=0x=0.
  • (x,y)(x,y) is additive in the first slot and (cx,y)=c (x,y)(cx,y) = c\,(x,y) for real cc, both inherited from ss.
  • s(ix,y)=s(i(ix),iy)=s(−x,iy)=−s(x,iy)s(ix,y) = s\bigl(i(ix),iy\bigr) = s(-x,iy) = -s(x,iy), so
(ix,y)=s(ix,y)+i s(ix,iy)=−s(x,iy)+i s(x,y)=i(s(x,y)+i s(x,iy))=i (x,y);(ix,y) = s(ix,y)+i\,s(ix,iy) = -s(x,iy)+i\,s(x,y) = i\bigl(s(x,y)+i\,s(x,iy)\bigr) = i\,(x,y);

together with real homogeneity and additivity this gives (ax,y)=a(x,y)(ax,y) = a(x,y) for every a=α+iβ∈Ca = \alpha+i\beta\in\mathbb{C}.

  • s(y,ix)=s(iy,i(ix))=s(iy,−x)=−s(x,iy)s(y,ix) = s\bigl(iy,i(ix)\bigr) = s(iy,-x) = -s(x,iy), so (y,x)=s(y,x)+i s(y,ix)=s(x,y)−i s(x,iy)=(x,y)‾(y,x) = s(y,x)+i\,s(y,ix) = s(x,y)-i\,s(x,iy) = \overline{(x,y)}.

Hermitian symmetry plus additivity in the first slot gives additivity in the second, so (⋅,⋅)(\cdot,\cdot) satisfies every axiom and induces ∥⋅∥\lVert\cdot\rVert.

Part 8. Insert and remove a term, then use the triangle inequality in F\mathbb{F} and part 2 twice:

∣(xn,yn)−(x,y)∣=∣(xn, yn−y)+(xn−x, y)∣≤∥xn∥ ∥yn−y∥+∥xn−x∥ ∥y∥.\lvert(x_n,y_n)-(x,y)\rvert = \lvert(x_n,\,y_n-y)+(x_n-x,\,y)\rvert \le \lVert x_n\rVert\,\lVert y_n-y\rVert + \lVert x_n-x\rVert\,\lVert y\rVert .

The sequence ∥xn∥\lVert x_n\rVert is bounded, since ∥xn∥≤∥x∥+∥xn−x∥\lVert x_n\rVert\le\lVert x\rVert+\lVert x_n-x\rVert and the last term tends to 00; and ∥yn−y∥→0\lVert y_n-y\rVert\to0, ∥xn−x∥→0\lVert x_n-x\rVert\to0 by hypothesis. So the right-hand side tends to 00. □\square

Note(What it means)Original

An inner product is the least extra structure that lets you speak of length, angle and perpendicularity, so Euclidean geometry carries over to matrices, functions and sequences. Cauchy-Schwarz is the one inequality that makes this work: it bounds cos⁡θ\cos\theta by 11, yields the triangle inequality, and makes the inner product continuous. The equality cases say when such an estimate is sharp.

Remark(Where the hypotheses are used, and conventions)AdaptedAdapted from Reed & Simon (1980), §II.1, p. 37, and Problem 4(b), p. 63; Kreyszig (1978), §3.1, p. 130, and §3.2, Lemma 3.2-1 with footnote 2, p. 137; Hassani (2013), §2.2 with footnote 8, p. 31, and Thm 2.2.7, p. 35; Riley, Hobson & Bence (2006), §8.1.2, p. 244, and §8.1.3, p. 246; Stakgold & Holst (2011), §4.5, p. 264
  • Which slot is linear. This handbook follows Kreyszig (Kreyszig (1978), §3.1, p. 130): linear in the first slot, conjugate-linear in the second. Much of the physics literature is the reverse — Hassani (Hassani (2013), §2.2, p. 31), Riley, Hobson and Bence (Riley, Hobson & Bence (2006), §8.1.2, p. 244) and Reed and Simon (Reed & Simon (1980), §II.1, p. 37), who flag the clash explicitly. The two conventions give complex-conjugate values, so (x,y)(x,y) here is ⟨y∣x⟩\langle y\mid x\rangle in Dirac notation and part 6 appears conjugated in Reed and Simon's Problem 4(a). Over R\mathbb{R} they agree.
  • Equality in Cauchy-Schwarz. Kreyszig (Kreyszig (1978), §3.2, Lemma 3.2-1(a), p. 137) phrases this case as "{x,y}\{x,y\} is a linearly dependent set"; part 2 puts it on the pair, because under the definition in Vector spaces and bases the singleton {x}\{x\} with x≠0x\ne 0 is independent, so the set form would wrongly exclude x=y≠0x = y \ne 0. The pair condition is still symmetric in xx and yy (if y=cxy = cx with c≠0c\ne 0 then x=c−1yx = c^{-1}y), and still covers y=0y = 0, where both sides vanish. Part 3's condition is one-sided in appearance only: it too is symmetric, as Kreyszig (Kreyszig (1978), §3.2, footnote 2, p. 137) points out, since x=0x = 0 is the case c=0c = 0, and x=cyx = cy with c>0c>0 gives y=c−1xy = c^{-1}x with c−1>0c^{-1}>0. It has to be, because ∥x+y∥=∥x∥+∥y∥\lVert x+y\rVert = \lVert x\rVert+\lVert y\rVert is itself symmetric in xx and yy. Hassani (Hassani (2013), Thm 2.2.7, p. 35) states only the "holds when" direction, though his proof on the same page gives both; the "if and only if" as stated here is Kreyszig's.
  • How much positivity each part needs. (x,x)≥0(x,x)\ge 0 is what makes ∥x∥=(x,x)1/2\lVert x\rVert = (x,x)^{1/2} real, and it is all that parts 1, 4, 5 and 6 need — they are algebraic identities in a hermitian sesquilinear form — and all that the two inequalities of parts 2 and 3 need. The proof below does not quite show the last point, since it divides by (y,y)(y,y), but one extra line closes the gap. Suppose the form is only semi-definite and y≠0y\neq 0 has (y,y)=0(y,y) = 0; we may assume (x,y)≠0(x,y)\neq 0, or there is nothing to prove. In the display of the proof of part 2 the term ∣a∣2(y,y)\lvert a\rvert^2(y,y) now vanishes, so taking a=t (x,y)/∣(x,y)∣a = t\,(x,y)/\lvert(x,y)\rvert with t>0t>0 real, for which a‾(x,y)=t∣(x,y)∣\overline{a}(x,y) = t\lvert(x,y)\rvert is real, leaves 0≤∥x∥2−2t∣(x,y)∣0\le\lVert x\rVert^2 - 2t\lvert(x,y)\rvert for every t>0t>0 — impossible unless ∣(x,y)∣=0\lvert(x,y)\rvert = 0. Hence ∣(x,y)∣=0=∥x∥∥y∥\lvert(x,y)\rvert = 0 = \lVert x\rVert\lVert y\rVert, Schwarz holds (with equality), and part 3's inequality follows from it and part 1 exactly as written. Strict definiteness is needed in exactly three places: the clause "∥⋅∥\lVert\cdot\rVert is a norm" in part 3, and the two equality characterisations in parts 2 and 3. The proof of part 2 also calls on it for convenience, at "whence (y,y)>0(y,y)>0 by strict positivity", to divide by (y,y)(y,y); that is the step the preceding sentences replace. Riley, Hobson and Bence (Riley, Hobson & Bence (2006), §8.1.3, p. 246) introduce Schwarz and the triangle inequality for "a linear vector space in which ⟨a∣a⟩≥0\langle a\mid a\rangle\ge 0 for all aa", but this is not a statement under semi-definiteness alone: on p. 244, cited in the first bullet above, they attach to that very condition the assertion that ⟨a∣a⟩=0\langle a\mid a\rangle = 0 implies a=0a = 0, so strict definiteness is in force by the time they reach the inequalities. Take the semi-definite form (x,y)=x1y1‾(x,y) = x_1\overline{y_1} on F2\mathbb{F}^2: there ∥(0,1)∥=0\lVert(0,1)\rVert = 0, and x=(1,0)x = (1,0), y=(1,5)y = (1,5) give ∣(x,y)∣=1=∥x∥ ∥y∥\lvert(x,y)\rvert = 1 = \lVert x\rVert\,\lVert y\rVert with neither vector a multiple of the other. Parts 7 and 8 presuppose a norm and the induced metric, so they need it too.
  • What actually breaks Cauchy-Schwarz is indefiniteness. If (x,x)(x,x) is allowed to be negative, the inequality itself fails: for (x,y)=x1y1−x2y2(x,y) = x_1y_1-x_2y_2 on R2\mathbb{R}^2, the vectors x=(1,12)x = (1,\tfrac12) and y=(1,−12)y = (1,-\tfrac12) give (x,y)=54(x,y) = \tfrac54 against ((x,x)(y,y))1/2=34\bigl((x,x)(y,y)\bigr)^{1/2} = \tfrac34. These are Hassani (Hassani (2013), §2.2, p. 31)'s pseudo-Euclidean products; as his footnote 8 there notes, in the space-time of relativity a nonzero vector can have (x,x)=0(x,x) = 0. In such a space ∥⋅∥\lVert\cdot\rVert is not a norm, and cos⁡θ\cos\theta is undefined.
  • Not every norm comes from an inner product. Part 7 is the test: on F2\mathbb{F}^2 the norm ∣x1∣+∣x2∣\lvert x_1\rvert+\lvert x_2\rvert fails part 5 at x=(1,0)x=(1,0), y=(0,1)y=(0,1), where the left side is 22+22=82^2+2^2 = 8 and the right side 2+2=42+2 = 4.
  • Completeness is a separate hypothesis. Nothing above needs it: the polynomials with a weighted inner product form an incomplete inner product space. It enters only where limits must exist, as in the projection theorem; in Orthogonal projection and least squares finite dimension plays that role instead.
Example(Two polynomials under the weight e−te^{-t})Original

Let VV be the real polynomials with the weighted inner product of the third definition block,

(f,g)=∫0∞e−tf(t)g(t) dt,(f,g) = \int_0^\infty e^{-t}f(t)g(t)\,\mathrm{d}t ,

whose moments are ∫0∞e−ttk dt=k!\int_0^\infty e^{-t}t^k\,\mathrm{d}t = k! for k=0,1,2,…k = 0,1,2,\dots (repeated integration by parts). Take

f(t)=t,g(t)=1+t.f(t) = t, \qquad g(t) = 1+t .

Step 1: the three numbers. Expanding the integrands into powers of tt and reading off factorials,

(f,f)=∫0∞e−tt2=2!=2,(g,g)=∫0∞e−t(1+2t+t2)=0!+2⋅1!+2!=5,(f,f) = \int_0^\infty e^{-t}t^2 = 2! = 2, \qquad (g,g) = \int_0^\infty e^{-t}(1+2t+t^2) = 0!+2\cdot 1!+2! = 5,(f,g)=∫0∞e−t(t+t2)=1!+2!=3.(f,g) = \int_0^\infty e^{-t}(t+t^2) = 1!+2! = 3 .

So ∥f∥=2\lVert f\rVert = \sqrt2 and ∥g∥=5\lVert g\rVert = \sqrt5.

Step 2: Cauchy-Schwarz and the angle. Part 2 predicts 3=∣(f,g)∣≤2⋅5=10=3.162277…3 = \lvert(f,g)\rvert\le\sqrt2\cdot\sqrt5 = \sqrt{10} = 3.162277\ldots, and the inequality is strict, as the equality case requires: gg is not a multiple of ff, since g(0)=1g(0) = 1 while f(0)=0f(0) = 0. The angle between them is therefore well defined,

cos⁡θ=310=0.9486832…,θ=arctan⁡13=18.4349∘,\cos\theta = \frac{3}{\sqrt{10}} = 0.9486832\ldots, \qquad \theta = \arctan\tfrac13 = 18.4349^\circ ,

the second form because sin⁡θ=1−9/10=1/10\sin\theta = \sqrt{1-9/10} = 1/\sqrt{10}. Equality is attained for a multiple: with g~=4f\tilde g = 4f, ∣(f,g~)∣=8=2⋅42\lvert(f,\tilde g)\rvert = 8 = \sqrt2\cdot 4\sqrt2.

Step 3: the triangle inequality. Here f+g=1+2tf+g = 1+2t and f−g=−1f-g = -1, so

∥f+g∥2=∫0∞e−t(1+4t+4t2)=1+4+8=13,∥f−g∥2=∫0∞e−t=1.\lVert f+g\rVert^2 = \int_0^\infty e^{-t}(1+4t+4t^2) = 1+4+8 = 13, \qquad \lVert f-g\rVert^2 = \int_0^\infty e^{-t} = 1 .

Thus ∥f+g∥=13=3.605551…\lVert f+g\rVert = \sqrt{13} = 3.605551\ldots against ∥f∥+∥g∥=2+5=3.650282…\lVert f\rVert+\lVert g\rVert = \sqrt2+\sqrt5 = 3.650282\ldots: strict, again as part 3 requires, since ff is not a non-negative multiple of gg.

Step 4: the two identities. The parallelogram law of part 5 reads 13+1=2⋅2+2⋅513+1 = 2\cdot 2+2\cdot 5, that is 14=1414 = 14. The real polarization identity of part 6 recovers the product from the four norms already computed:

(f,g)=14(∥f+g∥2−∥f−g∥2)=14(13−1)=3,(f,g) = \tfrac14\bigl(\lVert f+g\rVert^2-\lVert f-g\rVert^2\bigr) = \tfrac14(13-1) = 3 ,

matching step 1.

Step 5: Pythagoras, and the exact slack in Cauchy-Schwarz. Subtract from gg its component along ff:

h=g−(g,f)∥f∥2 f=(1+t)−32t=1−t2.h = g - \frac{(g,f)}{\lVert f\rVert^2}\,f = (1+t) - \tfrac32 t = 1 - \tfrac{t}{2} .

Then (h,f)=∫0∞e−t(t−12t2)=1−1=0(h,f) = \int_0^\infty e^{-t}\bigl(t-\tfrac12 t^2\bigr) = 1-1 = 0, so g=32f+hg = \tfrac32 f + h is an orthogonal decomposition and part 4 applies:

∥g∥2=94∥f∥2+∥h∥2=94⋅2+∥h∥2,\lVert g\rVert^2 = \tfrac94\lVert f\rVert^2 + \lVert h\rVert^2 = \tfrac94\cdot 2 + \lVert h\rVert^2 ,

and indeed ∥h∥2=∫0∞e−t(1−t+14t2)=1−1+12=12\lVert h\rVert^2 = \int_0^\infty e^{-t}\bigl(1-t+\tfrac14 t^2\bigr) = 1-1+\tfrac12 = \tfrac12, which gives 92+12=5\tfrac92+\tfrac12 = 5, the value of ∥g∥2\lVert g\rVert^2 from step 1. This ∥h∥2\lVert h\rVert^2 is exactly the slack in the proof of part 2: there the key display was ∥x−ay∥2=∥x∥2−∣(x,y)∣2/∥y∥2\lVert x-ay\rVert^2 = \lVert x\rVert^2-\lvert(x,y)\rvert^2/\lVert y\rVert^2, and here

∥h∥2=∥g∥2−(f,g)2∥f∥2=5−92=12.\lVert h\rVert^2 = \lVert g\rVert^2-\frac{(f,g)^2}{\lVert f\rVert^2} = 5 - \frac{9}{2} = \frac12 .

Multiplying by ∥f∥2=2\lVert f\rVert^2 = 2 turns this into ∥f∥2∥g∥2−(f,g)2=10−9=1\lVert f\rVert^2\lVert g\rVert^2-(f,g)^2 = 10-9 = 1: the inequality of part 2 misses equality by precisely the squared length of the orthogonal remainder.

ApplicationOriginal

The correlation coefficient cannot exceed one, and that is Cauchy-Schwarz. For two data series x,y∈RNx,y\in\mathbb{R}^N with their means subtracted, the sample correlation is

r=(x,y)∥x∥ ∥y∥=∑ixiyi(∑ixi2)1/2(∑iyi2)1/2,r = \frac{(x,y)}{\lVert x\rVert\,\lVert y\rVert} = \frac{\sum_i x_iy_i}{\bigl(\sum_i x_i^2\bigr)^{1/2}\bigl(\sum_i y_i^2\bigr)^{1/2}},

so ∣r∣≤1\lvert r\rvert\le 1 by part 2 — with rr being exactly cos⁡θ\cos\theta for the angle of the second definition block. The equality case is informative rather than a curiosity: ∣r∣=1\lvert r\rvert = 1 says y=cxy = cx, that is that the two series are related exactly linearly, which in practice flags a duplicated or rescaled variable rather than a discovery. The same statement for random variables, ∣Cov⁡(X,Y)∣≤σXσY\lvert\operatorname{Cov}(X,Y)\rvert\le\sigma_X\sigma_Y, is part 2 for the form (X,Y)=E[(X−EX)(Y−EY)](X,Y) = \mathbb{E}[(X-\mathbb{E}X)(Y-\mathbb{E}Y)], which is only positive semi-definite — its null vectors are the almost-surely constant variables — so the inequality holds while the equality characterisation needs the degenerate cases handled separately, exactly as the remark above describes.

Quantum mechanics needs both the inequality and its equality case. States are unit vectors in a complex inner product space, and the Born rule assigns the number ∣(ψ,φ)∣2\lvert(\psi,\varphi)\rvert^2 to a measurement outcome; part 2 is what keeps that number in [0,1][0,1], so probabilities are probabilities. The Robertson uncertainty relation goes further. Writing a=(A−⟨A⟩)ψa = (A-\langle A\rangle)\psi and b=(B−⟨B⟩)ψb = (B-\langle B\rangle)\psi for two observables, the variances are ∥a∥2\lVert a\rVert^2 and ∥b∥2\lVert b\rVert^2, and part 2 gives

σAσB=∥a∥ ∥b∥ ≥ ∣(a,b)∣ ≥ ∣Im⁡(a,b)∣=12∣⟨[A,B]⟩∣,\sigma_A\sigma_B = \lVert a\rVert\,\lVert b\rVert \ \ge\ \lvert(a,b)\rvert\ \ge\ \lvert\operatorname{Im}(a,b)\rvert = \tfrac12\bigl\lvert\langle[A,B]\rangle\bigr\rvert ,

which for position and momentum is σxσp≥ℏ/2\sigma_x\sigma_p\ge\hbar/2. The states that achieve the bound are then read off from the equality cases: part 2 forces b=cab = ca for a scalar cc, and the second inequality forces cc to be purely imaginary. For xx and pp that proportionality is a first-order differential equation whose solutions are the Gaussian wave packets — so the minimum-uncertainty states are identified by the equality clause, not by the inequality.

Why the parallelogram law matters in analysis. Part 7 is a sharp test that separates the inner-product norms from all others, and that separation has consequences: the L2L^2 norm satisfies it and the LpL^p norms for p≠2p\neq2 do not. Every argument that projects a function onto a subspace and keeps the orthogonal remainder — least squares, Fourier coefficients as best approximations, the energy method for elliptic problems — runs on the geometry of this unit and is therefore available in L2L^2 and not in L1L^1 or L∞L^\infty (Hilbert spaces, Mean-square convergence and Parseval's identity). That is the practical reason the mean-square norm is the one physicists almost always choose.

Method

Orthonormal bases and Gram-Schmidt

Adapted

The Gram-Schmidt recipe that turns a linearly independent list into an orthonormal one spanning the same nested subspaces, the expansion of a vector in an orthonormal basis, and the QR factorization the recipe produces.

Prerequisites: Inner products and norms, Vector spaces and bases, Linear systems and rank

Definition(Orthonormal sets and bases)AdaptedAdapted from Kreyszig (1978), §3.4, Def. 3.4-1, eqs. (1)–(2), p. 152; Hassani (2013), §2.2, Def. 2.2.4, eq. (2.11), p. 32; Lee (2013), App. B, p. 636

Let VV be an inner product space over F=R\mathbb{F} = \mathbb{R} or C\mathbb{C}, with the convention of Inner products and norms: (⋅,⋅)(\cdot,\cdot) is linear in its first slot.

A family (eα)α∈I(e_\alpha)_{\alpha\in I} in VV is orthogonal if (eα,eβ)=0(e_\alpha,e_\beta) = 0 for α≠β\alpha\ne\beta, and orthonormal if moreover each eαe_\alpha has norm 11, that is

(eα,eβ)=δαβ={1α=β,0α≠β,(e_\alpha, e_\beta) = \delta_{\alpha\beta} = \begin{cases} 1 & \alpha = \beta,\\ 0 & \alpha\neq\beta,\end{cases}

δαβ\delta_{\alpha\beta} being the Kronecker delta. An orthonormal basis of VV is an orthonormal family that is also a basis of VV in the sense of Vector spaces and bases.

For a finite orthonormal family (e1,…,en)(e_1,\dots,e_n) and x∈Vx\in V, the scalars (x,ei)(x,e_i) are the Fourier coefficients of xx with respect to it, and ∑i=1n(x,ei)ei\sum_{i=1}^n (x,e_i)e_i is its Fourier sum.

A matrix R∈Mm×n(F)R\in M_{m\times n}(\mathbb{F}), of any shape, is upper triangular if Rik=0R_{ik} = 0 whenever i>ki>k; for m=nm=n this is the usual condition that everything below the diagonal vanishes. A matrix Q∈Mm×n(F)Q\in M_{m\times n}(\mathbb{F}) has orthonormal columns if Q∗Q=InQ^{*}Q = I_n, where Q∗Q^{*} is the conjugate transpose; for m=nm = n such a QQ is called unitary (F=C\mathbb{F}=\mathbb{C}) or orthogonal (F=R\mathbb{F}=\mathbb{R}).

Method(Gram-Schmidt)AdaptedAdapted from Lee (2013), App. B, Prop. B.40, eqs. (B.12)–(B.13), p. 636, and Exercise B.41, p. 636 (existence and the nested spans); Kreyszig (1978), §3.4, pp. 157–158 (existence and the nested spans); Hassani (2013), §2.2.2, eq. (2.13), pp. 33–35 (existence)

Let VV be an inner product space over F\mathbb{F} and let (a1,…,an)(a_1,\dots,a_n) be a linearly independent nn-tuple in VV, with n≥1n\ge 1.

  1. There is an orthonormal nn-tuple (q1,…,qn)(q_1,\dots,q_n) in VV with

    span⁡{q1,…,qk}=span⁡{a1,…,ak}for every k=1,…,n.\operatorname{span}\{q_1,\dots,q_k\} = \operatorname{span}\{a_1,\dots,a_k\} \qquad\text{for every } k = 1,\dots,n .

    Each qkq_k is a linear combination of a1,…,aka_1,\dots,a_k alone, and the method below constructs it.

  2. Such a tuple is unique up to replacing each qkq_k by λkqk\lambda_k q_k with ∣λk∣=1\lvert\lambda_k\rvert = 1: any two tuples with the property in part 1 differ by such a rescaling, and conversely every such rescaling of one of them is again orthonormal with the same nested spans. Imposing in addition that (ak,qk)(a_k,q_k) be real and positive for every kk makes it unique, and the method below produces that one.

  3. Consequently every inner product space VV with 1≤dim⁡FV=n<∞1\le\dim_{\mathbb{F}}V = n<\infty has an orthonormal basis, and any orthonormal basis of a subspace W⊆VW\subseteq V extends to one of VV.

Note(What is ours in that statement)Original

Part 1, and the first clause of part 3, are the content of the propositions cited on the block: Lee's Proposition B.40 and Exercise B.41, and the treatments in Kreyszig and Hassani, each of which gives the construction with its nested spans and, in finite dimensions, the existence of an orthonormal basis. Two things in the statement are not in any of them. The first is part 2: the uniqueness up to unit scalars and the normalisation (ak,qk)>0(a_k,q_k)>0 that pins the output down. The second is the extension clause of part 3, that an orthonormal basis of a subspace extends to one of VV; it is obtained here by feeding an extended basis to the method and checking that the method reproduces an orthonormal initial segment unchanged. Both, and their proofs below, are the handbook's own. Part 2 is what the uniqueness half of the QR factorization statement rests on, and the extension clause is used in part 3 of that statement and twice in the proof of the spectral theorem for Hermitian matrices.

Idea of the proofOriginal

The recipe does all the work; the proof has only to check three things at each stage, in this order: the new remainder is not zero, it is perpendicular to everything built so far, and it has not escaped the span of the inputs read so far. A zero remainder would exhibit aka_k inside the span of its predecessors, which linear independence forbids. Perpendicularity is one line of algebra, and it is short precisely because what gets subtracted is a combination of vectors that are already orthonormal. The spans match because every stage only adds and subtracts multiples of vectors already available. Uniqueness runs the same way: once the kkth span is fixed, qkq_k can only be the unit vector in it perpendicular to the (k−1)(k-1)st span, and that leaves a scalar of modulus one free.

ProofAdaptedAdapted from Kreyszig (1978), §3.4, eqs. (13)–(14) and the nested-span property, pp. 157–158, with Lemma 3.4-2, p. 153; Lee (2013), App. B, Prop. B.40 and eq. (B.13), p. 636, and Exercise B.41, p. 636

Part 1: the method produces such a tuple. Write q~k\tilde q_k, RikR_{ik}, qkq_k for the quantities the method below produces. We prove by induction on kk that for every k=1,…,nk = 1,\dots,n:

(i) q~k≠0\tilde q_k\ne 0, so Rkk>0R_{kk}>0 and qkq_k is defined; (ii) (q1,…,qk)(q_1,\dots,q_k) is orthonormal; (iii) qk∈span⁡{a1,…,ak}q_k\in\operatorname{span}\{a_1,\dots,a_k\}; (iv) span⁡{q1,…,qk}=span⁡{a1,…,ak}\operatorname{span}\{q_1,\dots,q_k\} = \operatorname{span}\{a_1,\dots,a_k\}.

Start. A list one of whose entries is the zero vector is linearly dependent, so the hypothesis that (a1,…,an)(a_1,\dots,a_n) is linearly independent gives a1≠0a_1\ne 0 and therefore R11=∥a1∥>0R_{11} = \lVert a_1\rVert>0. Then q1=a1/R11q_1 = a_1/R_{11} has norm 11, lies in span⁡{a1}\operatorname{span}\{a_1\}, and spans it, since a1=R11q1a_1 = R_{11}q_1.

Step. Let 2≤k≤n2\le k\le n and assume (i)–(iv) for all smaller indices.

  • Nothing vanishes. If q~k\tilde q_k were 00, step 2b would read ak=∑i<kRikqia_k = \sum_{i<k}R_{ik}q_i, placing aka_k in span⁡{q1,…,qk−1}\operatorname{span}\{q_1,\dots,q_{k-1}\}, which is span⁡{a1,…,ak−1}\operatorname{span}\{a_1,\dots,a_{k-1}\} by (iv) at k−1k-1. An entry of the list lying in the span of its predecessors contradicts linear independence. This is the only use of that hypothesis in the inductive step; it is used once more, in the form a1≠0a_1\ne0, in the Start paragraph. Hence Rkk=∥q~k∥>0R_{kk} = \lVert\tilde q_k\rVert>0, and qk=q~k/Rkkq_k = \tilde q_k/R_{kk} has norm 11.

  • Orthogonality. Fix j<kj<k. The inner product is linear in its first slot, so

    (q~k,qj)=(ak,qj)−∑i=1k−1Rik (qi,qj)=(ak,qj)−Rjk=0,(\tilde q_k, q_j) = (a_k,q_j)-\sum_{i=1}^{k-1}R_{ik}\,(q_i,q_j) = (a_k,q_j) - R_{jk} = 0 ,

    where the middle equality is orthonormality of (q1,…,qk−1)(q_1,\dots,q_{k-1}), which annihilates every term but i=ji=j, and the last is the definition Rjk=(ak,qj)R_{jk} = (a_k,q_j) of step 2a. Dividing by the positive number RkkR_{kk} gives (qk,qj)=0(q_k,q_j) = 0. Together with (ii) at k−1k-1 and ∥qk∥=1\lVert q_k\rVert = 1, this is (ii) at kk.

  • Spans. By step 2b, qk=Rkk−1(ak−∑i<kRikqi)q_k = R_{kk}^{-1}\bigl(a_k - \sum_{i<k}R_{ik}q_i\bigr), and each qiq_i with i<ki<k lies in span⁡{a1,…,ai}\operatorname{span}\{a_1,\dots,a_i\} by (iii); hence qk∈span⁡{a1,…,ak}q_k\in\operatorname{span}\{a_1,\dots,a_k\}, which is (iii) at kk, and consequently span⁡{q1,…,qk}⊆span⁡{a1,…,ak}\operatorname{span}\{q_1,\dots,q_k\}\subseteq\operatorname{span}\{a_1,\dots,a_k\}. Conversely ak=Rkkqk+∑i<kRikqia_k = R_{kk}q_k+\sum_{i<k}R_{ik}q_i lies in span⁡{q1,…,qk}\operatorname{span}\{q_1,\dots,q_k\}, and ai∈span⁡{q1,…,qk−1}a_i\in\operatorname{span}\{q_1,\dots,q_{k-1}\} for i<ki<k by (iv) at k−1k-1. This is (iv) at kk.

Since each qkq_k is a combination of a1,…,aka_1,\dots,a_k by (iii), part 1 is proved.

Part 2: uniqueness up to unit scalars. Let (q1′,…,qn′)(q_1',\dots,q_n') be any orthonormal tuple with span⁡{q1′,…,qk′}=span⁡{a1,…,ak}\operatorname{span}\{q_1',\dots,q_k'\} = \operatorname{span}\{a_1,\dots,a_k\} for every kk; we show by induction that qk′=λkqkq_k' = \lambda_kq_k with ∣λk∣=1\lvert\lambda_k\rvert=1.

At k=1k=1, q1′q_1' lies in span⁡{a1}=span⁡{q1}\operatorname{span}\{a_1\} = \operatorname{span}\{q_1\}, so q1′=λ1q1q_1' = \lambda_1q_1, and ∣λ1∣=∥q1′∥=1\lvert\lambda_1\rvert = \lVert q_1'\rVert = 1.

Assume qi′=λiqiq_i' = \lambda_iq_i with ∣λi∣=1\lvert\lambda_i\rvert = 1 for all i<ki<k; then qi=λi‾ qi′q_i = \overline{\lambda_i}\,q_i', because a scalar of modulus one has λi−1=λi‾\lambda_i^{-1} = \overline{\lambda_i}. By (iv), qk′∈span⁡{a1,…,ak}=span⁡{q1,…,qk}q_k'\in\operatorname{span}\{a_1,\dots,a_k\} = \operatorname{span}\{q_1,\dots,q_k\}, so qk′=∑i≤kciqiq_k' = \sum_{i\le k}c_iq_i for some scalars; pairing with qjq_j and using orthonormality of the unprimed tuple gives cj=(qk′,qj)c_j = (q_k',q_j). For j<kj<k, conjugate-linearity in the second slot and orthonormality of the primed tuple give

(qk′,qj)=(qk′,λj‾ qj′)=λj (qk′,qj′)=0.(q_k',q_j) = (q_k',\overline{\lambda_j}\,q_j') = \lambda_j\,(q_k',q_j') = 0 .

So qk′=ckqkq_k' = c_kq_k with ∣ck∣=∥qk′∥=1\lvert c_k\rvert = \lVert q_k'\rVert = 1, completing the induction.

Conversely, every such rescaling is admissible: if ∣λk∣=1\lvert\lambda_k\rvert = 1 for each kk then (λiqi,λjqj)=λiλj‾ δij=δij(\lambda_iq_i,\lambda_jq_j) = \lambda_i\overline{\lambda_j}\,\delta_{ij} = \delta_{ij}, so (λ1q1,…,λnqn)(\lambda_1q_1,\dots,\lambda_nq_n) is orthonormal, and span⁡{λ1q1,…,λkqk}=span⁡{q1,…,qk}\operatorname{span}\{\lambda_1q_1,\dots,\lambda_kq_k\} = \operatorname{span}\{q_1,\dots,q_k\} for every kk because each λk\lambda_k is a non-zero scalar. The tuples with the property of part 1 are therefore exactly the unit-scalar rescalings of any one of them.

It remains to see that the extra normalisation selects the method's tuple. By step 2b and orthonormality, (ak,qk)=(q~k+∑i<kRikqi, qk)=(q~k,qk)=Rkk>0(a_k,q_k) = \bigl(\tilde q_k+\sum_{i<k}R_{ik}q_i,\,q_k\bigr) = (\tilde q_k,q_k) = R_{kk}>0, so the method's output does satisfy it. Any admissible tuple has (ak,qk′)=(ak,λkqk)=λk‾Rkk(a_k,q_k') = (a_k,\lambda_kq_k) = \overline{\lambda_k}R_{kk}, which is real and positive exactly when λk‾>0\overline{\lambda_k}>0, that is when λk=1\lambda_k = 1. So exactly one admissible tuple survives the extra condition, and it is the method's.

Part 3: orthonormal bases and extensions. Let 1≤dim⁡FV=n<∞1\le\dim_{\mathbb F}V = n<\infty and pick any basis (a1,…,an)(a_1,\dots,a_n) of VV, which exists by Vector spaces and bases. Part 1 converts it into an orthonormal (q1,…,qn)(q_1,\dots,q_n) with span⁡{q1,…,qn}=span⁡{a1,…,an}=V\operatorname{span}\{q_1,\dots,q_n\} = \operatorname{span}\{a_1,\dots,a_n\} = V; an orthonormal spanning family is a basis, being linearly independent (part 1 of the expansion statement below), so VV has an orthonormal basis.

Now let W⊆VW\subseteq V be a subspace with an orthonormal basis (e1,…,ek)(e_1,\dots,e_k), where k=0k=0 and the empty list are allowed if W={0}W = \{0\}. Extend it to a basis (e1,…,ek,bk+1,…,bn)(e_1,\dots,e_k,b_{k+1},\dots,b_n) of VV, again by Vector spaces and bases, and feed that list to the method. We claim qi=eiq_i = e_i for i≤ki\le k, by induction on ii: granted qj=ejq_j = e_j for j<ij<i, step 2a gives Rji=(ei,ej)=0R_{ji} = (e_i,e_j) = 0 for j<ij<i because the ee's are orthonormal, so q~i=ei\tilde q_i = e_i and Rii=∥ei∥=1R_{ii} = \lVert e_i\rVert = 1, whence qi=eiq_i = e_i. The method's output is therefore an orthonormal basis of VV whose first kk members are e1,…,eke_1,\dots,e_k. □\square

Method(Expansion in an orthonormal family)AdaptedAdapted from Kreyszig (1978), §3.4, eqs. (3)–(4) and Lemma 3.4-2, pp. 152–153, eqs. (6)–(11), pp. 155–156, and Thm 3.4-6, p. 157; Reed & Simon (1980), §II.1, Thm II.1 and its corollary, pp. 37–38; Stakgold & Holst (2011), §4.6, eqs. (4.6.2) and (4.6.5), pp. 277–278

Let VV be an inner product space over F\mathbb{F}.

  1. Every orthonormal family in VV is linearly independent. Hence an orthonormal family in a space of dimension nn has at most nn members, and an orthonormal family of exactly nn members there is an orthonormal basis.

  2. Pythagoras and Bessel. Let (e1,…,eN)(e_1,\dots,e_N) be orthonormal and x∈Vx\in V. Put y=∑i=1N(x,ei)eiy = \sum_{i=1}^{N}(x,e_i)e_i. Then x−y⊥eix - y \perp e_i for every ii, hence x−y⊥yx-y\perp y, and

    ∥x∥2=∑i=1N∣(x,ei)∣2+∥x−y∥2,so∑i=1N∣(x,ei)∣2≤∥x∥2.\lVert x\rVert^2 = \sum_{i=1}^{N}\lvert (x,e_i)\rvert^2 + \lVert x - y\rVert^2 , \qquad\text{so}\qquad \sum_{i=1}^{N}\lvert (x,e_i)\rvert^2 \le \lVert x\rVert^2 .

    Equality in the second relation holds exactly when x∈span⁡{e1,…,eN}x\in\operatorname{span}\{e_1,\dots,e_N\}.

  3. Orthonormal basis. If (e1,…,en)(e_1,\dots,e_n) is an orthonormal basis of VV, then for all x,y∈Vx,y\in V

    x=∑i=1n(x,ei) ei,∥x∥2=∑i=1n∣(x,ei)∣2,(x,y)=∑i=1n(x,ei) (y,ei)‾.x = \sum_{i=1}^{n}(x,e_i)\,e_i , \qquad \lVert x\rVert^2 = \sum_{i=1}^{n}\lvert (x,e_i)\rvert^2 , \qquad (x,y) = \sum_{i=1}^{n}(x,e_i)\,\overline{(y,e_i)} .

    So in an orthonormal basis the components of a vector are obtained by taking nn inner products, with no linear system to solve, and the inner product takes the standard form of Fn\mathbb{F}^n. Neither holds in a basis that is not orthonormal.

Idea of the proofOriginal

One computation carries all three parts: subtract the Fourier sum and what is left over is perpendicular to every member of the family. Linear independence follows because pairing a vanishing combination with one member of the family reads off that member's coefficient. Pythagoras applied to the splitting of xx into the part the family captures and the part it misses gives the norm identity, and Bessel's inequality is nothing but the remark that the missed part has non-negative length. Part 3 is the case in which nothing can be missed.

ProofAdaptedAdapted from Kreyszig (1978), §3.4, Lemma 3.4-2, p. 153, and eqs. (8)–(12), pp. 155–157; Stakgold & Holst (2011), §4.6, eqs. (4.6.2) and (4.6.4)–(4.6.5), pp. 277–278; Reed & Simon (1980), §II.1, Thm II.1 and its corollary, pp. 37–38

Part 1. Let (eα)α∈I(e_\alpha)_{\alpha\in I} be orthonormal and let ∑i=1Ncieαi=0\sum_{i=1}^{N}c_ie_{\alpha_i} = 0 with α1,…,αN\alpha_1,\dots,\alpha_N distinct. Pairing with eαje_{\alpha_j} and using linearity in the first slot,

0=(∑i=1Ncieαi, eαj)=∑i=1Nci δαiαj=cj,0 = \Bigl(\sum_{i=1}^{N}c_ie_{\alpha_i},\,e_{\alpha_j}\Bigr) = \sum_{i=1}^{N}c_i\,\delta_{\alpha_i\alpha_j} = c_j ,

so every coefficient vanishes: the family is linearly independent. In a space of dimension nn a linearly independent family has at most nn members, and nn linearly independent vectors there form a basis (Vector spaces and bases), so an orthonormal family of exactly nn members is an orthonormal basis.

Part 2. Put y=∑i=1N(x,ei)eiy = \sum_{i=1}^{N}(x,e_i)e_i. For each j≤Nj\le N, by linearity in the first slot and orthonormality,

(x−y,ej)=(x,ej)−∑i=1N(x,ei)(ei,ej)=(x,ej)−(x,ej)=0,(x-y,e_j) = (x,e_j) - \sum_{i=1}^{N}(x,e_i)(e_i,e_j) = (x,e_j)-(x,e_j) = 0 ,

which is the claim x−y⊥ejx-y\perp e_j. Because yy is a combination of the eje_j and the inner product is conjugate-linear in its second slot,

(x−y,y)=∑j=1N(x,ej)‾ (x−y,ej)=0,(x-y,y) = \sum_{j=1}^{N}\overline{(x,e_j)}\,(x-y,e_j) = 0 ,

so x−y⊥yx-y\perp y as well. Expanding ∥x∥2=(y+(x−y), y+(x−y))\lVert x\rVert^2 = (y+(x-y),\,y+(x-y)) and discarding the two cross terms, which vanish by the previous line, gives ∥x∥2=∥y∥2+∥x−y∥2\lVert x\rVert^2 = \lVert y\rVert^2+\lVert x-y\rVert^2. The first term is

∥y∥2=(∑i(x,ei)ei, ∑j(x,ej)ej)=∑i∑j(x,ei)(x,ej)‾ (ei,ej)=∑i=1N∣(x,ei)∣2,\lVert y\rVert^2 = \Bigl(\sum_{i}(x,e_i)e_i,\ \sum_{j}(x,e_j)e_j\Bigr) = \sum_{i}\sum_{j}(x,e_i)\overline{(x,e_j)}\,(e_i,e_j) = \sum_{i=1}^{N}\lvert (x,e_i)\rvert^2 ,

by orthonormality again. This is the displayed identity, and the inequality follows from ∥x−y∥2≥0\lVert x-y\rVert^2\ge 0.

For the equality case: equality forces ∥x−y∥=0\lVert x-y\rVert = 0, hence x=y∈span⁡{e1,…,eN}x = y\in\operatorname{span}\{e_1,\dots,e_N\}. Conversely, if x∈span⁡{e1,…,eN}x\in\operatorname{span}\{e_1,\dots,e_N\}, write x=∑icieix = \sum_ic_ie_i; pairing with eje_j gives cj=(x,ej)c_j = (x,e_j), so x=yx = y and the remainder is 00.

Part 3. Let (e1,…,en)(e_1,\dots,e_n) be an orthonormal basis of VV. Every x∈Vx\in V lies in span⁡{e1,…,en}\operatorname{span}\{e_1,\dots,e_n\}, so the equality case of part 2 gives both x=∑i(x,ei)eix = \sum_i(x,e_i)e_i and ∥x∥2=∑i∣(x,ei)∣2\lVert x\rVert^2 = \sum_i\lvert (x,e_i)\rvert^2. For the third identity, substitute the expansion of yy and use conjugate-linearity in the second slot:

(x,y)=(x, ∑i=1n(y,ei)ei)=∑i=1n(y,ei)‾ (x,ei)=∑i=1n(x,ei) (y,ei)‾.□(x,y) = \Bigl(x,\ \sum_{i=1}^{n}(y,e_i)e_i\Bigr) = \sum_{i=1}^{n}\overline{(y,e_i)}\,(x,e_i) = \sum_{i=1}^{n}(x,e_i)\,\overline{(y,e_i)} . \qquad\square
Method(QR factorization)Original

Let A∈Mm×n(F)A\in M_{m\times n}(\mathbb{F}) with m≥nm\ge n, and give Fm\mathbb{F}^m its standard inner product.

  1. If rank⁡A=n\operatorname{rank}A = n, there are unique matrices Q∈Mm×n(F)Q\in M_{m\times n}(\mathbb{F}) with Q∗Q=InQ^{*}Q = I_n and R∈Mn×n(F)R\in M_{n\times n}(\mathbb{F}) upper triangular with all diagonal entries real and positive, such that A=QRA = QR. Running the method below on the columns a1,…,ana_1,\dots,a_n of AA produces them: the kkth column of QQ is qkq_k, and Rik=(ak,qi)R_{ik} = (a_k,q_i) for i<ki<k while Rkk=∥ak−∑i<k(ak,qi)qi∥R_{kk} = \lVert a_k - \sum_{i<k}(a_k,q_i)q_i\rVert.
  2. Then span⁡{q1,…,qk}\operatorname{span}\{q_1,\dots,q_k\} is the span of the first kk columns of AA for each kk; in particular the columns of QQ are an orthonormal basis of im⁡A\operatorname{im}A.
  3. Without the rank hypothesis a factorization A=QRA = QR with Q∈Mm×m(F)Q\in M_{m\times m}(\mathbb{F}) satisfying Q∗Q=ImQ^{*}Q = I_m — unitary, or orthogonal when F=R\mathbb{F} = \mathbb{R} — and R∈Mm×n(F)R\in M_{m\times n}(\mathbb{F}) upper triangular still exists. This wider form is never unique, whatever the rank of AA: the diagonal of RR is not required to be real and positive here, so (Q,R)(Q,R) may always be replaced by (QD,D∗R)(QD, D^{*}R) with DD diagonal and unimodular, and for m>nm>n the last m−nm-n columns of QQ do not enter the product at all. It is the rank hypothesis together with the shape of QQ and the positive diagonal of RR that pin down the factorization of part 1.
Idea of the proofOriginal

Part 1 is the Gram-Schmidt statement rewritten as one matrix equation. The relation ak=∑i≤kRikqia_k = \sum_{i\le k}R_{ik}q_i that the recipe leaves behind is, read column by column, exactly A=QRA = QR; orthonormality of the outputs is Q∗Q=InQ^{*}Q = I_n; and the fact that only indices i≤ki\le k occur is upper triangularity. Uniqueness is the uniqueness clause of that statement, once one checks that any such factorization forces the columns of QQ to have the nested spans and the positive inner products it asks for. Part 3 has no independence to lean on, so instead of building QQ one column at a time we clear one column of AA at a time: a single unitary matrix sends the first column to a multiple of the first standard basis vector and leaves a smaller problem of the same shape.

ProofOriginal

Part 1. If rank⁡A=n\operatorname{rank}A = n then the nn columns a1,…,ana_1,\dots,a_n of AA are linearly independent (Linear systems and rank), so the method applies to them. It returns an orthonormal (q1,…,qn)(q_1,\dots,q_n) in Fm\mathbb{F}^m and scalars RikR_{ik} with Rik=0R_{ik}=0 for i>ki>k, with Rkk>0R_{kk}>0 real, and with ak=∑i=1kRikqia_k = \sum_{i=1}^{k}R_{ik}q_i for every kk (step 3). Let QQ be the matrix whose columns are q1,…,qnq_1,\dots,q_n and let R=(Rik)R = (R_{ik}). Then

(Q∗Q)ij=∑l=1mQli‾ Qlj=(qj,qi)=δij,(Q^{*}Q)_{ij} = \sum_{l=1}^{m}\overline{Q_{li}}\,Q_{lj} = (q_j,q_i) = \delta_{ij} ,

so Q∗Q=InQ^{*}Q = I_n, and the kkth column of QRQR is ∑iRikqi=ak\sum_iR_{ik}q_i = a_k, so A=QRA = QR. This proves existence, with the formulas as stated.

For uniqueness, let A=QRA = QR be any factorization with Q∗Q=InQ^{*}Q = I_n and RR upper triangular with real positive diagonal, and let q1,…,qnq_1,\dots,q_n be the columns of QQ, which are orthonormal because Q∗Q=InQ^{*}Q = I_n. Reading column kk of A=QRA = QR gives ak=∑i≤kRikqia_k = \sum_{i\le k}R_{ik}q_i, so span⁡{a1,…,ak}⊆span⁡{q1,…,qk}\operatorname{span}\{a_1,\dots,a_k\}\subseteq\operatorname{span}\{q_1,\dots,q_k\}. Both spans have dimension kk — the aia_i because rank⁡A=n\operatorname{rank}A = n, the qiq_i because an orthonormal family is linearly independent by part 1 of the expansion statement — so the inclusion is an equality. Pairing the same relation with qkq_k and using orthonormality gives (ak,qk)=Rkk>0(a_k,q_k) = R_{kk}>0. So (q1,…,qn)(q_1,\dots,q_n) is an orthonormal tuple with the nested spans of the Gram-Schmidt statement and with (ak,qk)(a_k,q_k) real and positive, and part 2 of that statement identifies it as the tuple the method produces. The entries of RR are then forced as well: pairing ak=∑i≤kRikqia_k = \sum_{i\le k}R_{ik}q_i with qiq_i gives Rik=(ak,qi)R_{ik} = (a_k,q_i) for i≤ki\le k, and in particular Rkk=(ak,qk)=∥ak−∑i<k(ak,qi)qi∥R_{kk} = (a_k,q_k) = \lVert a_k-\sum_{i<k}(a_k,q_i)q_i\rVert.

Part 2. The nested spans of the Gram-Schmidt statement say span⁡{q1,…,qk}=span⁡{a1,…,ak}\operatorname{span}\{q_1,\dots,q_k\} = \operatorname{span}\{a_1,\dots,a_k\}, which is the span of the first kk columns of AA. At k=nk=n that span is the column space im⁡A\operatorname{im}A, and q1,…,qnq_1,\dots,q_n is an orthonormal family spanning it, hence an orthonormal basis of it.

Part 3. Throughout, "unitary" is short for Q∗Q=ImQ^{*}Q = I_m with QQ square, which for F=R\mathbb{F} = \mathbb{R} is the orthogonality of the definition block. First a construction used at every stage: given v∈Fmv\in\mathbb{F}^m there is a unitary Q1∈Mm×m(F)Q_1\in M_{m\times m}(\mathbb{F}) with Q1∗v=∥v∥ e1Q_1^{*}v = \lVert v\rVert\,e_1. For v=0v = 0 take Q1=ImQ_1 = I_m. For v≠0v\ne 0 set w1=v/∥v∥w_1 = v/\lVert v\rVert and extend (w1)(w_1) to an orthonormal basis (w1,…,wm)(w_1,\dots,w_m) of Fm\mathbb{F}^m by part 3 of the Gram-Schmidt statement; let Q1Q_1 have columns w1,…,wmw_1,\dots,w_m, so Q1∗Q1=ImQ_1^{*}Q_1 = I_m. Its entries are (Q1∗v)i=(v,wi)(Q_1^{*}v)_i = (v,w_i), which equals ∥v∥\lVert v\rVert for i=1i=1 and 00 for i≥2i\ge2 because vv is a multiple of w1w_1.

Now induct on the number of columns nn, with m≥nm\ge n throughout. For n=1n=1 take Q=Q1Q = Q_1 built from v=a1v = a_1 and R=∥a1∥e1∈Mm×1(F)R = \lVert a_1\rVert e_1\in M_{m\times 1}(\mathbb{F}), which is upper triangular; then QR=Q1Q1∗a1=a1=AQR = Q_1Q_1^{*}a_1 = a_1 = A, since Q1Q1∗=ImQ_1Q_1^{*} = I_m for a square matrix with Q1∗Q1=ImQ_1^{*}Q_1 = I_m.

Let n≥2n\ge 2 and assume the claim for matrices with n−1n-1 columns. Build Q1Q_1 from v=a1v = a_1, the first column of AA. The first column of Q1∗AQ_1^{*}A is then ∥a1∥e1\lVert a_1\rVert e_1, so

Q1∗A=(rc0A′),r=∥a1∥,Q_1^{*}A = \begin{pmatrix} r & c\\ 0 & A'\end{pmatrix}, \qquad r = \lVert a_1\rVert ,

where cc is a row of length n−1n-1 and A′∈M(m−1)×(n−1)(F)A'\in M_{(m-1)\times(n-1)}(\mathbb{F}) with m−1≥n−1m-1\ge n-1. By the induction hypothesis A′=Q′R′A' = Q'R' with Q′Q' unitary of size m−1m-1 and R′∈M(m−1)×(n−1)(F)R'\in M_{(m-1)\times(n-1)}(\mathbb{F}) upper triangular. Put

Q=Q1(100Q′),R=(rc0R′).Q = Q_1\begin{pmatrix}1&0\\0&Q'\end{pmatrix}, \qquad R = \begin{pmatrix} r& c\\ 0 & R'\end{pmatrix} .

Then QQ is unitary, being a product of two unitary matrices; RR is upper triangular, because the entry of RR in row i+1i+1 and column k+1k+1 is Rik′R'_{ik}, which vanishes for i>ki>k; and

QR=Q1(rc0Q′R′)=Q1Q1∗A=A.QR = Q_1\begin{pmatrix}r&c\\0&Q'R'\end{pmatrix} = Q_1Q_1^{*}A = A .

Uniqueness fails here for every AA, not only for the rank-deficient ones, because nothing now constrains the diagonal of RR. Let A=QRA = QR be a factorization of this form and let D=diag⁡(d1,…,dm)D = \operatorname{diag}(d_1,\dots,d_m) with ∣di∣=1\lvert d_i\rvert = 1 for each ii. Then (QD)∗(QD)=D∗Q∗QD=D∗D=Im(QD)^{*}(QD) = D^{*}Q^{*}QD = D^{*}D = I_m; the matrix D∗RD^{*}R is again upper triangular, since (D∗R)ik=di‾ Rik(D^{*}R)_{ik} = \overline{d_i}\,R_{ik} vanishes wherever RikR_{ik} does; and (QD)(D∗R)=QDD∗R=QR=A(QD)(D^{*}R) = QDD^{*}R = QR = A. A square QQ with Q∗Q=ImQ^{*}Q = I_m is invertible, so QD=QQD = Q forces D=ImD = I_m: every other choice of DD gives a genuinely different pair. When m>nm>n there is a second freedom. Rows n+1,…,mn+1,\dots,m of an upper triangular R∈Mm×n(F)R\in M_{m\times n}(\mathbb{F}) vanish, because i>n≥ki>n\ge k implies i>ki>k; so only the first nn columns of QQ contribute to QRQR, and the remaining m−nm-n may be replaced by those of any other orthonormal completion.

Two small rank-deficient instances, for concreteness: for m=n=1m=n=1 and A=(0)A = (0), both Q=(1)Q=(1) and Q=(−1)Q=(-1) serve with R=(0)R=(0); and for A=(1000)A = \begin{pmatrix}1&0\\0&0\end{pmatrix}, both Q=I2Q = I_2 and Q=diag⁡(1,−1)Q = \operatorname{diag}(1,-1) give A=QRA = QR with R=AR = A. □\square

Method(Gram-Schmidt orthonormalization)AdaptedAdapted from Arfken, Weber & Harris (2013), §5.2, eqs. (5.33)–(5.39), pp. 269–270; Hassani (2013), §2.2.2, eq. (2.13), pp. 33–35; Kreyszig (1978), §3.4, pp. 157–158

Input: a linearly independent tuple (a1,…,an)(a_1,\dots,a_n) in an inner product space. Output: an orthonormal (q1,…,qn)(q_1,\dots,q_n) with the nested spans of the statement above, and the coefficients RikR_{ik} of the QR factorization.

  1. Set q~1=a1\tilde q_1 = a_1, R11=∥q~1∥R_{11} = \lVert\tilde q_1\rVert and q1=q~1/R11q_1 = \tilde q_1/R_{11}. Here R11>0R_{11}>0 because a1≠0a_1\ne 0.
  2. For k=2,3,…,nk = 2,3,\dots,n in turn: a. compute the Fourier coefficients of aka_k along the vectors already produced, Rik=(ak,qi)R_{ik} = (a_k,q_i) for i=1,…,k−1i = 1,\dots,k-1; b. subtract that part off: q~k=ak−∑i=1k−1Rik qi\tilde q_k = a_k - \sum_{i=1}^{k-1}R_{ik}\,q_i; c. set Rkk=∥q~k∥R_{kk} = \lVert\tilde q_k\rVert and qk=q~k/Rkkq_k = \tilde q_k/R_{kk}.
  3. Set Rik=0R_{ik} = 0 for i>ki>k. Then ak=∑i=1kRikqia_k = \sum_{i=1}^{k} R_{ik}q_i for each kk, which is the factorization A=QRA = QR when the aka_k are the columns of a matrix AA.

Step 2a projects onto the qiq_i already computed rather than onto the original aia_i, which is what makes q~k\tilde q_k orthogonal to all of q1,…,qk−1q_1,\dots,q_{k-1} in one subtraction: for j<kj<k, (q~k,qj)=(ak,qj)−∑i<kRik(qi,qj)=(ak,qj)−Rjk=0(\tilde q_k,q_j) = (a_k,q_j) - \sum_{i<k}R_{ik}(q_i,q_j) = (a_k,q_j)-R_{jk} = 0 by orthonormality.

When it works, and how it fails.

  • Independence is exactly the hypothesis. Rkk=0R_{kk} = 0 in step 2c if and only if ak∈span⁡{a1,…,ak−1}a_k\in\operatorname{span}\{a_1,\dots,a_{k-1}\}, and then step 2c divides by zero. To orthonormalize a spanning list that is not independent, discard each aka_k for which q~k=0\tilde q_k = 0 and carry on; the surviving qq's are an orthonormal basis of span⁡{a1,…,an}\operatorname{span}\{a_1,\dots,a_n\}, and there are dim⁡Fspan⁡{a1,…,an}\dim_{\mathbb{F}}\operatorname{span}\{a_1,\dots,a_n\} of them.
  • The output depends on the order of the inputs. Re-ordering (a1,…,an)(a_1,\dots,a_n) generally produces a different orthonormal tuple, because the nested spans it must match are different. In particular q1q_1 is always a multiple of a1a_1.
Note(Numerical behaviour)Original

Everything above is exact arithmetic, which is all the three books cited on the method discuss. In floating point the recipe as written — classical Gram-Schmidt — loses orthogonality badly on ill-conditioned input: the departure of the computed Q∗QQ^{*}Q from InI_n grows like the square of the condition number of AA. The modified form, in which step 2 is rewritten as v←akv\leftarrow a_k followed by Rik←(v,qi)R_{ik}\leftarrow(v,q_i), v←v−Rikqiv\leftarrow v-R_{ik}q_i for i=1,…,k−1i=1,\dots,k-1 in sequence, is algebraically the same recipe but loses orthogonality only in proportion to the first power of the condition number, because each coefficient is taken against a vector from which the earlier components have already been removed. Where orthogonality must be guaranteed, QR is computed instead by Householder reflections, which build QQ as a product of exactly unitary factors; see Numerical linear systems and Matrix norms and conditioning.

Note(What it means)Original

An orthonormal basis is the one kind of basis in which coordinates are free: each component is a single inner product, and lengths and inner products are computed as if the space were Fn\mathbb{F}^n. Gram-Schmidt says such a basis always exists and shows how to build one, processing the given vectors one at a time and never looking ahead, so that the first kk outputs already span what the first kk inputs spanned. Written in matrix form the same computation is the QR factorization, which is the workhorse behind least squares and behind orthogonal polynomial families.

Remark(Where the hypotheses are used, and conventions)AdaptedAdapted from Arfken, Weber & Harris (2013), §5.2, pp. 269–270; Hassani (2013), §2.2.2, pp. 33–35; Kreyszig (1978), §3.4, pp. 152, 157; Lee (2013), App. B, Prop. B.40 and Exercise B.41, p. 636
  • Which slot the coefficient sits in. With the handbook's convention (linear in the first slot) the coefficient is Rik=(ak,qi)R_{ik} = (a_k,q_i), the new vector first. Arfken and Hassani, who are conjugate-linear in the first slot, write the same number as ⟨qi∣ak⟩\langle q_i\mid a_k\rangle with the already-orthonormalised vector first. Using the wrong order introduces a complex conjugate and breaks the orthogonality in step 2 as soon as the scalars are not real.
  • Finite dimension in part 3 of the Gram-Schmidt statement. Lee's Proposition B.40 is an induction on dim⁡V\dim V, so it gives an orthonormal basis only in finite dimensions. The recipe itself runs on any finite or countable independent list in any inner product space, as Hassani notes; what fails in infinite dimensions is the conclusion that the result spans, and recovering it needs completeness and a limit — see orthonormal bases.
  • Bessel is an equality plus a remainder. Part 2 of the expansion statement is stated as the identity ∥x∥2=∑i∣(x,ei)∣2+∥x−y∥2\lVert x\rVert^2 = \sum_i\lvert(x,e_i)\rvert^2+\lVert x-y\rVert^2, from which the inequality follows; the identity is the more useful form, because it names the defect. Riley, Hobson and Bence (Riley, Hobson & Bence (2006), §8.1.3(iii), pp. 246–247) state it as an inequality that becomes an equality when all basis vectors are included.
  • Real versus complex. Lee states Proposition B.40 for a real inner product and then asks in Exercise B.41 for the hermitian case; both are covered above, with the conjugations placed by our convention. The uniqueness in part 2 is weaker over C\mathbb{C} than over R\mathbb{R}: there the free factors λk\lambda_k run over the whole unit circle, not just {±1}\{\pm1\}.
Example(QR of a four-point sampling matrix)Original

Work in R4\mathbb{R}^4 with the standard inner product (x,y)=∑i=14xiyi(x,y) = \sum_{i=1}^{4}x_iy_i, and take the sample points t=1,2,3,4t = 1,2,3,4. Let

A=(1111241391416),A = \begin{pmatrix}1&1&1\\1&2&4\\1&3&9\\1&4&16\end{pmatrix},

whose columns a1,a2,a3a_1,a_2,a_3 are the values of 11, tt and t2t^2 at those four points. They are linearly independent (a non-zero polynomial of degree ≤2\le2 has at most two roots), so the method applies.

Stage 1. R11=∥a1∥=4=2R_{11} = \lVert a_1\rVert = \sqrt{4} = 2 and q1=12(1,1,1,1)q_1 = \tfrac12(1,1,1,1).

Stage 2. R12=(a2,q1)=12(1+2+3+4)=5R_{12} = (a_2,q_1) = \tfrac12(1+2+3+4) = 5, so

q~2=a2−5q1=(1,2,3,4)−52(1,1,1,1)=12(−3,−1,1,3),\tilde q_2 = a_2-5q_1 = (1,2,3,4)-\tfrac52(1,1,1,1) = \tfrac12(-3,-1,1,3) ,

R22=∥q~2∥=129+1+1+9=5R_{22} = \lVert\tilde q_2\rVert = \tfrac12\sqrt{9+1+1+9} = \sqrt5, and q2=125(−3,−1,1,3)q_2 = \frac{1}{2\sqrt5}(-3,-1,1,3).

Stage 3. R13=(a3,q1)=12(1+4+9+16)=15R_{13} = (a_3,q_1) = \tfrac12(1+4+9+16) = 15 and

R23=(a3,q2)=−3⋅1−1⋅4+1⋅9+3⋅1625=5025=55.R_{23} = (a_3,q_2) = \frac{-3\cdot1-1\cdot4+1\cdot9+3\cdot16}{2\sqrt5} = \frac{50}{2\sqrt5} = 5\sqrt5 .

Subtracting, with 15q1=152(1,1,1,1)15q_1 = \tfrac{15}{2}(1,1,1,1) and 55 q2=52(−3,−1,1,3)5\sqrt5\,q_2 = \tfrac52(-3,-1,1,3),

q~3=(1,4,9,16)−(152,152,152,152)−(−152,−52,52,152)=(1,−1,−1,1),\tilde q_3 = (1,4,9,16)-\bigl(\tfrac{15}{2},\tfrac{15}{2},\tfrac{15}{2},\tfrac{15}{2}\bigr)-\bigl(-\tfrac{15}{2},-\tfrac52,\tfrac52,\tfrac{15}{2}\bigr) = (1,-1,-1,1) ,

so R33=2R_{33} = 2 and q3=12(1,−1,−1,1)q_3 = \tfrac12(1,-1,-1,1).

The factorization.

Q=(12−3251212−125−1212125−121232512),R=(25150555002).Q = \begin{pmatrix} \tfrac12 & -\tfrac{3}{2\sqrt5} & \tfrac12\\ \tfrac12 & -\tfrac{1}{2\sqrt5} & -\tfrac12\\ \tfrac12 & \tfrac{1}{2\sqrt5} & -\tfrac12\\ \tfrac12 & \tfrac{3}{2\sqrt5} & \tfrac12 \end{pmatrix}, \qquad R = \begin{pmatrix}2&5&15\\0&\sqrt5&5\sqrt5\\0&0&2\end{pmatrix} .

Checks. The three columns of QQ have squared norms 4⋅14=14\cdot\tfrac14 = 1, 9+1+1+920=1\tfrac{9+1+1+9}{20} = 1 and 4⋅14=14\cdot\tfrac14 = 1; the three pairings are −3−1+1+345=0\frac{-3-1+1+3}{4\sqrt5} = 0, 1−1−1+14=0\frac{1-1-1+1}{4} = 0 and −3+1−1+345=0\frac{-3+1-1+3}{4\sqrt5} = 0. So QTQ=I3Q^{\mathsf T}Q = I_3. The third column of QRQR is

15q1+55 q2+2q3=(152,152,152,152)+(−152,−52,52,152)+(1,−1,−1,1)=(1,4,9,16)=a3,15q_1+5\sqrt5\,q_2+2q_3 = \bigl(\tfrac{15}{2},\tfrac{15}{2},\tfrac{15}{2},\tfrac{15}{2}\bigr)+\bigl(-\tfrac{15}{2},-\tfrac52,\tfrac52,\tfrac{15}{2}\bigr)+(1,-1,-1,1) = (1,4,9,16) = a_3 ,

and the other two columns check the same way. Finally ATA=RTRA^{\mathsf T}A = R^{\mathsf T}R predicts

det⁡(ATA)=(det⁡R)2=(2⋅5⋅2)2=80,\det(A^{\mathsf T}A) = (\det R)^2 = (2\cdot\sqrt5\cdot 2)^2 = 80 ,

which matches the direct computation from

ATA=(41030103010030100354).A^{\mathsf T}A = \begin{pmatrix}4&10&30\\10&30&100\\30&100&354\end{pmatrix} .

What the columns are. Column kk of QQ lists the values at t=1,2,3,4t=1,2,3,4 of

12,2t−525,t2−5t+52,\tfrac12, \qquad \frac{2t-5}{2\sqrt5}, \qquad \frac{t^2-5t+5}{2} ,

so running the recipe on the sampled monomials has produced a family of polynomials, of degrees 0,1,20,1,2 with positive leading coefficients, that are orthonormal for the sum over those four nodes. That is the discrete analogue of an orthogonal polynomial family, and the reason Gram-Schmidt and polynomial fitting keep meeting.

ApplicationOriginal

Fitting by polynomials, stably. The matrix of the example is what a least-squares fit of a quadratic to four measurements produces, and its QQ and RR are what the recommended algorithm for that fit uses: solving Rx=Q∗bRx = Q^{*}b instead of forming the normal equations avoids squaring the condition number. The connection is made precise in Orthogonal projection and least squares. In practice, fitting with the orthogonalised columns rather than with raw powers 1,t,t2,…1,t,t^2,\dots is what keeps a high-degree fit from collapsing numerically, and it also means that adding one more term to the fit does not change the coefficients already computed, since the new basis vector is orthogonal to the old ones.

Orthogonal polynomial families. Run the recipe on the monomials 1,x,x2,…1,x,x^2,\dots in an inner product (f,g)=∫−11f(x)g(x) w(x) dx(f,g) = \int_{-1}^{1}f(x)g(x)\,w(x)\,dx and it manufactures the classical orthogonal family belonging to the weight ww. Unit weight gives the Legendre polynomials, with the normalisation qn=(2n+1)/2 Pnq_n = \sqrt{(2n+1)/2}\,P_n; this is Arfken, Weber and Harris (Arfken, Weber & Harris (2013), §5.2, Example 5.2.1 and eq. (5.41), pp. 270–271). Here we take instead the Chebyshev weight w(x)=(1−x2)−1/2w(x) = (1-x^2)^{-1/2}, where x=cos⁡θx = \cos\theta turns every integral into one over θ\theta: ∫−11xnw(x) dx=∫0πcos⁡nθ dθ\int_{-1}^{1}x^nw(x)\,dx = \int_0^{\pi}\cos^n\theta\,d\theta, so the moments for n=0,1,…,6n = 0,1,\dots,6 are

π,0,π2,0,3π8,0,5π16.\pi,\quad 0,\quad \tfrac{\pi}{2},\quad 0,\quad \tfrac{3\pi}{8},\quad 0,\quad \tfrac{5\pi}{16} .

Four stages, each using only those numbers and the vanishing of an odd moment:

  • ∥1∥2=π\lVert1\rVert^2 = \pi, so q0=1/πq_0 = 1/\sqrt{\pi}.
  • (x,q0)=0(x,q_0) = 0 by parity and ∥x∥2=π/2\lVert x\rVert^2 = \pi/2, so q1=2/π xq_1 = \sqrt{2/\pi}\,x.
  • (x2,q0)=π/2(x^2,q_0) = \sqrt{\pi}/2 and (x2,q1)=0(x^2,q_1) = 0 by parity; the remainder is x2−12x^2-\tfrac12, whose squared norm is 3π8−π2+π4=π8\tfrac{3\pi}{8}-\tfrac{\pi}{2}+\tfrac{\pi}{4} = \tfrac{\pi}{8}, so q2=8/π (x2−12)q_2 = \sqrt{8/\pi}\,\bigl(x^2-\tfrac12\bigr).
  • (x3,q0)=(x3,q2)=0(x^3,q_0) = (x^3,q_2) = 0 by parity and (x3,q1)=2/π⋅3π8=382π(x^3,q_1) = \sqrt{2/\pi}\cdot\tfrac{3\pi}{8} = \tfrac38\sqrt{2\pi}; the remainder is x3−34xx^3-\tfrac34x, whose squared norm is 5π16−32⋅3π8+916⋅π2=π32\tfrac{5\pi}{16}-\tfrac32\cdot\tfrac{3\pi}{8}+\tfrac{9}{16}\cdot\tfrac{\pi}{2} = \tfrac{\pi}{32}, so q3=32/π (x3−34x)q_3 = \sqrt{32/\pi}\,\bigl(x^3-\tfrac34x\bigr).

Multiplying out the last two,

q2=2π (2x2−1),q3=2π (4x3−3x),q_2 = \sqrt{\tfrac{2}{\pi}}\,(2x^2-1), \qquad q_3 = \sqrt{\tfrac{2}{\pi}}\,(4x^3-3x) ,

so the outputs are 1/π T0\sqrt{1/\pi}\,T_0 and 2/π Tn\sqrt{2/\pi}\,T_n for n=1,2,3n = 1,2,3, where TnT_n is the Chebyshev polynomial of the first kind. Other weights produce the Hermite, Laguerre and Jacobi families the same way; see orthogonal polynomials. Physically these are the eigenfunction families in which a separable problem is expanded, and the nested-span property of the construction is what makes a truncated expansion the best approximation of its degree.

Orthonormalising a basis set. In electronic-structure calculations the trial orbitals supplied by chemistry are not orthogonal, and the overlap matrix Sij=(ϕj,ϕi)S_{ij} = (\phi_j,\phi_i) clutters every formula. Gram-Schmidt replaces them by an orthonormal set spanning the same space, after which the Hamiltonian matrix elements can be read off directly. If AA is the matrix whose columns are the coefficients of the orbitals in some orthonormal reference set, then S=A∗AS = A^{*}A, so A=QRA = QR gives S=R∗RS = R^{*}R with RR upper triangular and positive on the diagonal: Gram-Schmidt on the orbitals is the Cholesky factorization of their overlap matrix. The same step appears whenever a numerical scheme must keep a set of computed vectors from drifting into near-dependence: orthogonalising the Krylov vectors v,Av,A2v,…v, Av, A^2v,\dots is the Arnoldi and Lanczos iteration, and repeated QR factorization is the standard algorithm for the eigenvalues of a dense matrix.

Theorem

Orthogonal projection and least squares

Adapted

Orthogonal projection onto a finite-dimensional subspace, its characterisation as the nearest point of that subspace, and the normal equations that this turns into for the least-squares problem of minimising the norm of Ax minus b.

Prerequisites: Orthonormal bases and Gram-Schmidt, Linear systems and rank

Definition(Orthogonal projection)AdaptedAdapted from Stakgold & Holst (2011), §4.5, pp. 264–266; Lee (2013), App. B, p. 637; Hassani (2013), §4.4.1, Def. 4.4.2, p. 120

Let VV be an inner product space over F=R\mathbb{F} = \mathbb{R} or C\mathbb{C}, with (⋅,⋅)(\cdot,\cdot) linear in its first slot, and let M⊆VM\subseteq V be a subspace. Recall M⊥={v∈V:(v,u)=0 for all u∈M}M^{\perp} = \{v\in V : (v,u) = 0 \text{ for all } u\in M\}, itself a subspace.

Suppose every x∈Vx\in V can be written as x=p+wx = p+w with p∈Mp\in M and w∈M⊥w\in M^{\perp}, and that this decomposition is unique. Then pp is the orthogonal projection of xx on MM, and the map

P ⁣:V→V,Px=pP\colon V\to V, \qquad Px = p

is the orthogonal projection onto MM. An operator PP on VV is idempotent if P2=PP^2 = P, and self-adjoint if (Px,y)=(x,Py)(Px,y) = (x,Py) for all x,y∈Vx,y\in V.

Given A∈Mm×n(F)A\in M_{m\times n}(\mathbb{F}) and b∈Fmb\in\mathbb{F}^m, a least-squares solution of Ax=bAx = b is any x∈Fnx\in\mathbb{F}^n minimising ∥Ax−b∥\lVert Ax-b\rVert over Fn\mathbb{F}^n; the vector b−Axb-Ax is the residual. The normal equations are A∗Ax=A∗bA^{*}Ax = A^{*}b, with A∗A^{*} the conjugate transpose (ATA^{\mathsf T} when F=R\mathbb{F} = \mathbb{R}).

Theorem(Projection onto a finite-dimensional subspace)AdaptedAdapted from Kreyszig (1978), §3.3, Thm 3.3-1, pp. 144–145, Lemma 3.3-2, p. 145, Thm 3.3-4, pp. 146–147, and §9.5, Thm 9.5-1, pp. 480–481; Stakgold & Holst (2011), §4.5, Projection Theorem, pp. 266–267, and §4.6, p. 278; Lee (2013), App. B, Exercise B.45, p. 637

Let VV be an inner product space over F\mathbb{F} and let M⊆VM\subseteq V be a subspace with dim⁡FM=k<∞\dim_{\mathbb{F}}M = k<\infty. Completeness of VV is not assumed.

  1. Decomposition. V=M⊕M⊥V = M\oplus M^{\perp}: every x∈Vx\in V is x=p+wx = p+w with p∈Mp\in M and w∈M⊥w\in M^{\perp} in exactly one way. Hence the orthogonal projection PP onto MM is defined on all of VV.

  2. Best approximation. p=Pxp = Px is the unique nearest point of MM to xx:

    ∥x−p∥=min⁡u∈M∥x−u∥,\lVert x-p\rVert = \min_{u\in M}\lVert x-u\rVert ,

    and pp is the only u∈Mu\in M attaining the minimum. Equivalently, u∈Mu\in M attains it if and only if x−u⊥Mx-u\perp M.

  3. Pythagoras. ∥x∥2=∥Px∥2+∥x−Px∥2\lVert x\rVert^2 = \lVert Px\rVert^2+\lVert x-Px\rVert^2, so ∥Px∥≤∥x∥\lVert Px\rVert\le\lVert x\rVert, with equality exactly when x∈Mx\in M.

  4. Formula. If (e1,…,ek)(e_1,\dots,e_k) is an orthonormal basis of MM, then Px=∑i=1k(x,ei) eiPx = \sum_{i=1}^{k}(x,e_i)\,e_i: the projection is the Fourier sum of xx for that basis, and the value does not depend on which orthonormal basis of MM is used.

  5. Algebraic characterisation. PP is linear with im⁡P=M\operatorname{im}P = M and ker⁡P=M⊥\ker P = M^{\perp}, and it is idempotent and self-adjoint; I−PI-P is the orthogonal projection onto M⊥M^{\perp}. Conversely, if dim⁡FV<∞\dim_{\mathbb{F}}V<\infty and a linear operator PP on VV is idempotent and self-adjoint, then PP is the orthogonal projection onto im⁡P\operatorname{im}P.

Idea of the proofOriginal

Finite dimension of MM buys an orthonormal basis of it, and with that basis in hand the projection can simply be written down as the Fourier sum, instead of being obtained as the limit of a minimising sequence. Everything else follows from one computation: subtracting the Fourier sum leaves a remainder perpendicular to every basis vector of MM, hence to all of MM. The decomposition V=M⊕M⊥V = M\oplus M^{\perp} is then immediate, uniqueness comes from M∩M⊥={0}M\cap M^{\perp} = \{0\}, and the nearest-point property is Pythagoras applied to the right-angled triangle with vertices xx, pp and a competitor u∈Mu\in M: the distance to uu exceeds the distance to pp by exactly ∥p−u∥\lVert p-u\rVert in the squares. The algebraic characterisation is then bookkeeping with the same two facts.

ProofAdaptedAdapted from Kreyszig (1978), §3.3, Lemma 3.3-2, p. 145, Thm 3.3-4, pp. 146–147, and §9.5, Thm 9.5-1, pp. 480–481; Stakgold & Holst (2011), §4.5, Projection Theorem, part (c), p. 267, and §4.6, eqs. (4.6.4)–(4.6.5), p. 278

Throughout, dim⁡FM=k<∞\dim_{\mathbb F}M = k<\infty. If k=0k=0 then M={0}M = \{0\}, M⊥=VM^{\perp} = V, P=0P = 0, and every assertion is immediate; so assume k≥1k\ge1 and fix an orthonormal basis (e1,…,ek)(e_1,\dots,e_k) of MM, which exists by part 3 of the Gram-Schmidt statement in Orthonormal bases and Gram-Schmidt applied to the inner product space MM. Note first that

M∩M⊥={0},M\cap M^{\perp} = \{0\} ,

because zz in both satisfies (z,z)=0(z,z) = 0, hence z=0z=0 by definiteness of the inner product.

Parts 1 and 4. Given x∈Vx\in V, set p=∑i=1k(x,ei)ei∈Mp = \sum_{i=1}^{k}(x,e_i)e_i\in M and w=x−pw = x-p. By part 2 of the expansion statement in Orthonormal bases and Gram-Schmidt, w⊥eiw\perp e_i for every ii; since every u∈Mu\in M is a combination u=∑icieiu = \sum_ic_ie_i and the inner product is conjugate-linear in its second slot, (w,u)=∑ici‾(w,ei)=0(w,u) = \sum_i\overline{c_i}(w,e_i) = 0. So w∈M⊥w\in M^{\perp} and x=p+wx = p+w is a decomposition of the required kind. If x=p+w=p′+w′x = p+w = p'+w' are two of them, then p−p′=w′−wp-p' = w'-w lies in M∩M⊥={0}M\cap M^{\perp} = \{0\}, so p=p′p=p' and w=w′w=w'. Hence V=M⊕M⊥V = M\oplus M^{\perp}, the projection PP is defined on all of VV, and Px=pPx = p is the Fourier sum, which is part 4. The value does not depend on the orthonormal basis chosen, because PxPx is characterised basis-free as the unique element of MM with x−Px∈M⊥x-Px\in M^{\perp}.

Part 2. Let u∈Mu\in M. Then x−u=(x−p)+(p−u)x-u = (x-p)+(p-u) with x−p∈M⊥x-p\in M^{\perp} and p−u∈Mp-u\in M, so the two summands are orthogonal and

∥x−u∥2=∥x−p∥2+∥p−u∥2 ≥ ∥x−p∥2,\lVert x-u\rVert^2 = \lVert x-p\rVert^2+\lVert p-u\rVert^2 \ \ge\ \lVert x-p\rVert^2 ,

with equality precisely when ∥p−u∥=0\lVert p-u\rVert = 0, that is when u=pu = p. So pp attains the minimum and is the only element of MM that does. For the last clause: if u∈Mu\in M attains the minimum then u=pu=p by what was just shown, and x−p∈M⊥x-p\in M^{\perp}; conversely, if u∈Mu\in M and x−u∈M⊥x-u\in M^{\perp} then x=u+(x−u)x = u+(x-u) is a decomposition of the required kind, so u=pu = p by the uniqueness in part 1.

Part 3. Apply the same orthogonal splitting to u=0u=0: x=Px+(x−Px)x = Px+(x-Px) with the two terms orthogonal, so ∥x∥2=∥Px∥2+∥x−Px∥2\lVert x\rVert^2 = \lVert Px\rVert^2+\lVert x-Px\rVert^2. Hence ∥Px∥≤∥x∥\lVert Px\rVert\le\lVert x\rVert, with equality exactly when ∥x−Px∥=0\lVert x-Px\rVert = 0, that is when x=Px∈Mx = Px\in M.

Part 5. Linearity of PP is linearity of each coefficient map x↦(x,ei)x\mapsto (x,e_i), which holds because the inner product is linear in its first slot. PP maps into MM, and for u∈Mu\in M part 3 of the expansion statement applied inside MM gives u=∑i(u,ei)ei=Puu = \sum_i(u,e_i)e_i = Pu; so im⁡P=M\operatorname{im}P = M and, since Pu=uPu = u there, P2=PP^2 = P. Next, Px=0Px = 0 holds if and only if all the coefficients (x,ei)(x,e_i) vanish, which happens if and only if x⊥Mx\perp M; so ker⁡P=M⊥\ker P = M^{\perp}. Self-adjointness is a two-line computation:

(Px,y)=∑i=1k(x,ei)(ei,y),(x,Py)=∑i=1k(y,ei)‾ (x,ei),(Px,y) = \sum_{i=1}^{k}(x,e_i)(e_i,y) , \qquad (x,Py) = \sum_{i=1}^{k}\overline{(y,e_i)}\,(x,e_i) ,

and these agree because (ei,y)=(y,ei)‾(e_i,y) = \overline{(y,e_i)}. That I−PI-P is the orthogonal projection onto M⊥M^{\perp} follows from the decomposition x=(x−Px)+Pxx = (x-Px)+Px with x−Px∈M⊥x-Px\in M^{\perp} and Px∈M⊆(M⊥)⊥Px\in M\subseteq (M^{\perp})^{\perp}, together with M⊥∩(M⊥)⊥={0}M^{\perp}\cap (M^{\perp})^{\perp} = \{0\}, which gives uniqueness as before.

For the converse, let dim⁡FV<∞\dim_{\mathbb F}V<\infty and let PP be linear, idempotent and self-adjoint; put N=im⁡PN = \operatorname{im}P, a subspace. For x∈Vx\in V write x=Px+(x−Px)x = Px+(x-Px). The first term is in NN. For the second, take any u=Pv∈Nu = Pv\in N; then, using self-adjointness and P2=PP^2=P,

(x−Px, Pv)=(P(x−Px), v)=(Px−P2x, v)=0,(x-Px,\,Pv) = (P(x-Px),\,v) = (Px-P^2x,\,v) = 0 ,

so x−Px∈N⊥x-Px\in N^{\perp}. Uniqueness of the decomposition again follows from N∩N⊥={0}N\cap N^{\perp} = \{0\}. Hence PP is the orthogonal projection onto N=im⁡PN = \operatorname{im}P. □\square

Theorem(Least squares and the normal equations)AdaptedAdapted from Kreyszig (1978), §3.3, Thm 3.3-1 and Lemma 3.3-2, pp. 144–145; Stakgold & Holst (2011), §4.6, eqs. (4.6.4)–(4.6.5), p. 278

Let A∈Mm×n(F)A\in M_{m\times n}(\mathbb{F}) and b∈Fmb\in\mathbb{F}^m, let r=rank⁡Ar = \operatorname{rank}A, and let PP be the orthogonal projection of Fm\mathbb{F}^m onto im⁡A\operatorname{im}A.

  1. A minimiser always exists, because im⁡A\operatorname{im}A is a subspace of dimension r<∞r<\infty and part 2 of the projection statement applies to M=im⁡AM = \operatorname{im}A.

  2. Characterisation. For x∈Fnx\in\mathbb{F}^n the following are equivalent: xx minimises ∥Ax−b∥\lVert Ax-b\rVert; Ax=PbAx = Pb; the residual satisfies b−Ax∈(im⁡A)⊥=ker⁡A∗b-Ax\in(\operatorname{im}A)^{\perp} = \ker A^{*}; and xx solves the normal equations A∗Ax=A∗bA^{*}Ax = A^{*}b.

  3. Solution set. The normal equations are always consistent, and the set of least-squares solutions is a coset x0+ker⁡Ax_0+\ker A of dimension n−rn-r. The minimal residual b−Pbb-Pb is the same for all of them, and ∥b∥2=∥Pb∥2+∥b−Pb∥2\lVert b\rVert^2 = \lVert Pb\rVert^2+\lVert b-Pb\rVert^2.

  4. Uniqueness. ker⁡(A∗A)=ker⁡A\ker(A^{*}A) = \ker A, so A∗AA^{*}A is invertible if and only if r=nr = n (which requires m≥nm\ge n). In that case the least-squares solution is unique and

    x=(A∗A)−1A∗b.x = (A^{*}A)^{-1}A^{*}b .
  5. Via QR. If r=nr = n and A=QRA = QR is the factorization of Orthonormal bases and Gram-Schmidt, with Q∗Q=InQ^{*}Q = I_n and RR upper triangular with positive diagonal, then A∗A=R∗RA^{*}A = R^{*}R and the normal equations reduce to the triangular system

    Rx=Q∗b,with∥Ax−b∥2=∥b∥2−∥Q∗b∥2.Rx = Q^{*}b, \qquad\text{with}\qquad \lVert Ax-b\rVert^2 = \lVert b\rVert^2-\lVert Q^{*}b\rVert^2 .
Idea of the proofOriginal

The minimisation is over the vectors AxAx, and those are exactly the vectors of im⁡A\operatorname{im}A, a subspace of dimension r<∞r<\infty. So the previous statement already answers the geometric question: the closest attainable vector is PbPb, and the equation to solve is Ax=PbAx = Pb. Everything after that is a translation of "the residual is perpendicular to im⁡A\operatorname{im}A" into matrix language, and the translation is the single identity (Ay,v)=(y,A∗v)(Ay,v) = (y,A^{*}v), which turns (im⁡A)⊥(\operatorname{im}A)^{\perp} into ker⁡A∗\ker A^{*} and the orthogonality condition into A∗Ax=A∗bA^{*}Ax = A^{*}b. The two refinements then come for free: A∗AA^{*}A has the same kernel as AA, which decides uniqueness; and if A=QRA = QR then A∗A=R∗RA^{*}A = R^{*}R, so the normal equations are a triangular system in disguise.

ProofAdaptedAdapted from Kreyszig (1978), §3.3, Thm 3.3-1 and Lemma 3.3-2, pp. 144–145; Stakgold & Holst (2011), §4.6, Problem of Best Approximation, eqs. (4.6.4)–(4.6.5), p. 278

Throughout we use the standard inner products on Fn\mathbb{F}^n and Fm\mathbb{F}^m and the identity

(Ay,v)=(y,A∗v)(y∈Fn, v∈Fm),(Ay,v) = (y,A^{*}v) \qquad (y\in\mathbb{F}^n,\ v\in\mathbb{F}^m) ,

which holds because (x,y)=y∗x(x,y) = y^{*}x makes both sides equal to v∗Ayv^{*}Ay.

Part 1. im⁡A\operatorname{im}A is a subspace of Fm\mathbb{F}^m of dimension r=rank⁡A<∞r = \operatorname{rank}A<\infty (Linear systems and rank), so part 2 of the projection statement applies with M=im⁡AM = \operatorname{im}A and provides a unique nearest point Pb∈im⁡APb\in\operatorname{im}A to bb. Since {Ax:x∈Fn}=im⁡A\{Ax : x\in\mathbb{F}^n\} = \operatorname{im}A, the quantity ∥Ax−b∥\lVert Ax-b\rVert ranges over exactly the same values as ∥u−b∥\lVert u-b\rVert for u∈Mu\in M; the minimum is therefore attained, at any xx with Ax=PbAx = Pb, and at least one such xx exists because Pb∈im⁡APb\in\operatorname{im}A.

Part 2. The chain of equivalences:

  • xx minimises ∥Ax−b∥\lVert Ax-b\rVert if and only if AxAx is the nearest point of im⁡A\operatorname{im}A to bb, by the previous paragraph, and that nearest point is unique, so this holds if and only if Ax=PbAx = Pb.
  • Ax=PbAx = Pb holds exactly when b−Ax∈(im⁡A)⊥b-Ax\in(\operatorname{im}A)^{\perp}. Indeed Ax∈im⁡AAx\in\operatorname{im}A always, so the last clause of part 2 of the projection statement makes AxAx the nearest point precisely when b−Ax⊥im⁡Ab-Ax\perp\operatorname{im}A.
  • (im⁡A)⊥=ker⁡A∗(\operatorname{im}A)^{\perp} = \ker A^{*}: a vector vv has (Ay,v)=0(Ay,v) = 0 for every y∈Fny\in\mathbb{F}^n precisely when (y,A∗v)=0(y,A^{*}v) = 0 for every such yy, and the only vector orthogonal to the whole of Fn\mathbb{F}^n is 00; so the condition reads A∗v=0A^{*}v = 0.
  • Finally b−Ax∈ker⁡A∗b-Ax\in\ker A^{*} means A∗b−A∗Ax=0A^{*}b-A^{*}Ax = 0, which is the normal equations.

Part 3. By part 1 there is an x0x_0 with Ax0=PbAx_0 = Pb, and by part 2 it solves the normal equations, which are therefore consistent. Again by part 2, xx is a least-squares solution if and only if Ax=Pb=Ax0Ax = Pb = Ax_0, that is A(x−x0)=0A(x-x_0) = 0; so the solution set is the coset x0+ker⁡Ax_0+\ker A, whose dimension is n−rn-r by rank-nullity. For every such xx the residual is b−Ax=b−Pbb-Ax = b-Pb, the same vector. Finally ∥b∥2=∥Pb∥2+∥b−Pb∥2\lVert b\rVert^2 = \lVert Pb\rVert^2+\lVert b-Pb\rVert^2 is part 3 of the projection statement.

Part 4. If Ax=0Ax = 0 then A∗Ax=0A^{*}Ax = 0. Conversely, if A∗Ax=0A^{*}Ax = 0 then

∥Ax∥2=(Ax,Ax)=(x,A∗Ax)=(x,0)=0,\lVert Ax\rVert^2 = (Ax,Ax) = (x,A^{*}Ax) = (x,0) = 0 ,

so Ax=0Ax = 0. Hence ker⁡(A∗A)=ker⁡A\ker(A^{*}A) = \ker A. The matrix A∗AA^{*}A is n×nn\times n, so it is invertible if and only if its kernel is {0}\{0\}, that is if and only if ker⁡A={0}\ker A = \{0\}, that is r=nr = n — which forces n=r≤mn = r\le m. In that case the unique solution of the normal equations is x=(A∗A)−1A∗bx = (A^{*}A)^{-1}A^{*}b, and it is the unique least-squares solution by part 2.

Part 5. Let r=nr = n and A=QRA = QR as in the QR statement, so Q∗Q=InQ^{*}Q = I_n and RR is upper triangular with real positive diagonal. Then

A∗A=R∗Q∗QR=R∗R,A^{*}A = R^{*}Q^{*}QR = R^{*}R ,

and A∗b=R∗Q∗bA^{*}b = R^{*}Q^{*}b, so the normal equations read R∗(Rx−Q∗b)=0R^{*}(Rx-Q^{*}b) = 0. Now det⁡R=R11⋯Rnn>0\det R = R_{11}\cdots R_{nn}>0, so RR and hence R∗R^{*} are invertible, and the normal equations are equivalent to Rx=Q∗bRx = Q^{*}b, a triangular system solved by back substitution.

For the residual, the columns of QQ are an orthonormal basis of im⁡A\operatorname{im}A by part 2 of the QR statement, so part 4 of the projection statement gives Pb=∑i=1n(b,qi)qi=QQ∗bPb = \sum_{i=1}^{n}(b,q_i)q_i = QQ^{*}b. Hence Ax=QRx=QQ∗b=PbAx = QRx = QQ^{*}b = Pb for the least-squares solution, and

∥Ax−b∥2=∥b−Pb∥2=∥b∥2−∥Pb∥2=∥b∥2−∥Q∗b∥2,\lVert Ax-b\rVert^2 = \lVert b-Pb\rVert^2 = \lVert b\rVert^2-\lVert Pb\rVert^2 = \lVert b\rVert^2-\lVert Q^{*}b\rVert^2 ,

the middle equality by part 3 of the projection statement and the last because ∥Qz∥2=z∗Q∗Qz=∥z∥2\lVert Qz\rVert^2 = z^{*}Q^{*}Qz = \lVert z\rVert^2 for every z∈Fnz\in\mathbb{F}^n. □\square

Note(What it means)Original

Dropping a perpendicular is the whole content of both statements. The nearest point of a subspace to a given vector is found by removing the component that sticks out, and "sticking out" means orthogonal to the subspace; part 4 says that with an orthonormal basis in hand this costs kk inner products. The least-squares problem is the same picture in Fm\mathbb{F}^m with the subspace taken to be the column space of AA: an inconsistent system Ax=bAx = b is replaced by the consistent system Ax=PbAx = Pb, and demanding that the residual be orthogonal to every column of AA is literally the normal equations. Reach for this whenever there are more measurements than parameters.

Remark(Where the hypotheses are used, and conventions)AdaptedAdapted from Stakgold & Holst (2011), §4.5, Projection Theorem and Remarks on the Proof 1–3, pp. 266–268; Kreyszig (1978), §3.3, Thm 3.3-1, pp. 144–145
  • Finite dimension of MM is doing real work. A subspace of finite dimension is automatically closed, which is what makes the minimum in part 2 attained. Stakgold and Holst prove the projection theorem for a closed linear manifold of a complete space, and their first remark shows what goes wrong otherwise: in L2(a,b)L^2(a,b) take MM to be the set of all polynomials, which is a linear manifold but is not closed. For a u∈L2u\in L^2 that is not a polynomial the infimum inf⁡z∈M∥u−z∥\inf_{z\in M}\lVert u-z\rVert is 00 and is attained by no element of MM. So without closedness there may be no nearest point at all, and parts 1–5 all fail.
  • Only the parallelogram law makes the nearest point exist and be unique. Kreyszig's Theorem 3.3-1 obtains it from the parallelogram equality, which is special to inner product norms. Stakgold and Holst's second remark gives the Banach-space counterexample: in C[0,1]C[0,1] with the supremum norm, let MM be the continuous functions vanishing at 00; the function u≡1u\equiv 1 has no closest element in MM.
  • Convexity, not linearity, is what the minimisation needs. Kreyszig's Theorem 3.3-1 assumes only that MM is convex and complete; linearity is used afterwards, in Lemma 3.3-2, to get the orthogonality x−p⊥Mx-p\perp M. For a merely convex set the nearest point still exists and is unique, but the residual satisfies only a variational inequality.
  • Normal equations are not the recommended computation. Forming A∗AA^{*}A squares the condition number of AA, so part 4 as written loses about twice as many digits as part 5, where RR inherits the conditioning of AA. Use the QR route, or the singular value decomposition when r<nr<n: there the least-squares solutions form a positive-dimensional coset by part 3, and the pseudoinverse picks out the one of smallest norm. See also Matrix norms and conditioning.
  • Adjoint, not transpose. As in Linear systems and rank, the normal equations over C\mathbb{C} use the conjugate transpose; ATAx=ATbA^{\mathsf T}Ax = A^{\mathsf T}b is the wrong system unless AA and bb are real. The projection is self-adjoint, P=P∗=P2P = P^{*} = P^2, not merely symmetric.
Example(A straight line through four points, three ways)Original

Four measurements yy are taken at the times t=0,1,2,3t = 0,1,2,3:

(t,y)=(0,1), (1,3), (2,2), (3,6).(t,y) = (0,1),\ (1,3),\ (2,2),\ (3,6) .

Fitting y=c1+c2ty = c_1+c_2t means solving Ax=bAx = b with

A=(10111213),b=(1326),x=(c1c2),A = \begin{pmatrix}1&0\\1&1\\1&2\\1&3\end{pmatrix}, \qquad b = \begin{pmatrix}1\\3\\2\\6\end{pmatrix}, \qquad x = \begin{pmatrix}c_1\\c_2\end{pmatrix} ,

which has no solution: bb is not in the plane im⁡A⊂R4\operatorname{im}A\subset\mathbb{R}^4. Here m=4m=4, n=2n=2 and rank⁡A=2\operatorname{rank}A = 2, so part 4 applies and there is exactly one least-squares solution.

Route 1: the normal equations. With ATA=(46614)A^{\mathsf T}A = \begin{pmatrix}4&6\\6&14\end{pmatrix} and ATb=(1225)A^{\mathsf T}b = \begin{pmatrix}12\\25\end{pmatrix} (the entries are ∑yi=12\sum y_i = 12 and ∑tiyi=0+3+4+18=25\sum t_iy_i = 0+3+4+18 = 25), and det⁡(ATA)=56−36=20\det(A^{\mathsf T}A) = 56-36 = 20,

x=120(14−6−64)(1225)=120(1828)=(9/107/5).x = \frac{1}{20}\begin{pmatrix}14&-6\\-6&4\end{pmatrix}\begin{pmatrix}12\\25\end{pmatrix} = \frac{1}{20}\begin{pmatrix}18\\28\end{pmatrix} = \begin{pmatrix}9/10\\7/5\end{pmatrix} .

So the fitted line is y=0.9+1.4 ty = 0.9+1.4\,t.

Route 2: orthonormal basis and the Fourier sum. Gram-Schmidt on the columns of AA gives R11=2R_{11} = 2, q1=12(1,1,1,1)q_1 = \tfrac12(1,1,1,1), then R12=(a2,q1)=12(0+1+2+3)=3R_{12} = (a_2,q_1) = \tfrac12(0+1+2+3) = 3,

q~2=(0,1,2,3)−3q1=12(−3,−1,1,3),R22=5,q2=125(−3,−1,1,3).\tilde q_2 = (0,1,2,3)-3q_1 = \tfrac12(-3,-1,1,3), \qquad R_{22} = \sqrt5, \qquad q_2 = \frac{1}{2\sqrt5}(-3,-1,1,3) .

The Fourier coefficients of bb are (b,q1)=12(1+3+2+6)=6(b,q_1) = \tfrac12(1+3+2+6) = 6 and

(b,q2)=−3+(−1)(3)+1⋅2+3⋅625=1425=75,(b,q_2) = \frac{-3+(-1)(3)+1\cdot2+3\cdot6}{2\sqrt5} = \frac{14}{2\sqrt5} = \frac{7}{\sqrt5} ,

so by part 4 of the projection statement

Pb=6q1+75q2=(3,3,3,3)+710(−3,−1,1,3)=110(9,23,37,51).Pb = 6q_1+\frac{7}{\sqrt5}q_2 = (3,3,3,3)+\tfrac{7}{10}(-3,-1,1,3) = \tfrac{1}{10}(9,23,37,51) .

These are precisely the fitted values 0.9+1.4t0.9+1.4t at t=0,1,2,3t=0,1,2,3, as part 2 of the least-squares statement predicts.

Route 3: QR. With R=(2305)R = \begin{pmatrix}2&3\\0&\sqrt5\end{pmatrix} and QTb=(6, 7/5)Q^{\mathsf T}b = (6,\,7/\sqrt5), back substitution in Rx=QTbRx = Q^{\mathsf T}b gives 5 c2=7/5\sqrt5\,c_2 = 7/\sqrt5, so c2=7/5c_2 = 7/5, and then 2c1=6−3⋅75=952c_1 = 6-3\cdot\tfrac75 = \tfrac95, so c1=9/10c_1 = 9/10: the same answer, with no ATAA^{\mathsf T}A formed.

Checks. The residual is

b−Pb=110(1,7,−17,9),∥b−Pb∥2=1+49+289+81100=420100=215.b-Pb = \tfrac{1}{10}(1,7,-17,9), \qquad \lVert b-Pb\rVert^2 = \frac{1+49+289+81}{100} = \frac{420}{100} = \frac{21}{5} .

Part 2 says it must be orthogonal to both columns of AA: indeed 1+7−17+9=01+7-17+9 = 0 and 0+7−34+27=00+7-34+27 = 0. Part 5 predicts the same number without the residual vector,

∥b∥2−∥QTb∥2=(1+9+4+36)−(36+495)=50−2295=215,\lVert b\rVert^2-\lVert Q^{\mathsf T}b\rVert^2 = (1+9+4+36)-\Bigl(36+\frac{49}{5}\Bigr) = 50-\frac{229}{5} = \frac{21}{5} ,

and part 3 of the projection statement is the identity 50=∥Pb∥2+21550 = \lVert Pb\rVert^2+\tfrac{21}{5}, i.e. ∥Pb∥2=229/5\lVert Pb\rVert^2 = 229/5, which agrees with (92+232+372+512)/100=4580/100(9^2+23^2+37^2+51^2)/100 = 4580/100.

The projection matrix. From P=QQT=A(ATA)−1ATP = QQ^{\mathsf T} = A(A^{\mathsf T}A)^{-1}A^{\mathsf T},

P=120(1482−486422468−42814),P = \frac{1}{20}\begin{pmatrix}14&8&2&-4\\8&6&4&2\\2&4&6&8\\-4&2&8&14\end{pmatrix} ,

which is symmetric, as part 5 of the projection statement requires; one multiplication confirms P2=PP^2 = P; its trace is 14+6+6+1420=2=dim⁡im⁡A\tfrac{14+6+6+14}{20} = 2 = \dim\operatorname{im}A; and P(1,1,1,1)=(1,1,1,1)P(1,1,1,1) = (1,1,1,1) because (1,1,1,1)(1,1,1,1) is the first column of AA and so already lies in MM.

ApplicationOriginal

Fitting a model to more data than parameters. This is the everyday use: nn parameters, m≫nm\gg n measurements, a design matrix AA whose columns are the model's basis functions sampled at the measurement points, and a residual that the fit makes orthogonal to every one of them. The orthogonality is not a numerical accident but the definition of the fit, and it is what makes the residual a legitimate estimate of noise: it has no component along any direction the model could have explained. The same equations compute a calibration curve, a reaction rate from an Arrhenius plot, and the gravitational field coefficients of the Earth from satellite tracking — the problem Gauss invented the method for, when he recovered the orbit of Ceres from a short arc of observations.

Receivers and estimators. A GPS receiver sees more satellites than the four unknowns (three coordinates and a clock offset) require, and solves the linearised problem in the least-squares sense at every update; the matrix (A∗A)−1(A^{*}A)^{-1}, which part 4 produces anyway, is what the receiver reports as its position covariance, and its diagonal is the familiar dilution-of-precision figure. Recursive forms of the same computation, in which PbPb is updated as each new measurement arrives rather than recomputed, are the Kalman filter and the recursive least-squares algorithms of signal processing.

Projection as the definition of an approximation scheme. Part 2 says that a projection is a best approximation, which is why so many numerical methods are projections in disguise. A Galerkin or finite-element method replaces a differential equation by the demand that the residual be orthogonal to a finite-dimensional trial space, so the computed solution is the orthogonal projection of the true one in the energy inner product, and part 3 bounds its norm by the true solution's. Truncating a Fourier series after NN terms is the same statement in L2L^2: the truncation is the nearest trigonometric polynomial of that degree, not merely a convenient one (Mean-square convergence and Parseval's identity). In quantum mechanics, the Rayleigh-Ritz method projects the Hamiltonian onto the span of a chosen set of trial states, and the variational bound it gives is the same inequality ∥Px∥≤∥x∥\lVert Px\rVert\le\lVert x\rVert seen from the other side.