4.2. Matrices II#

This section deals with the concepts of vector spaces associated with matrices, span, rank, invertible matrices, similar matrices, gram matrices, pseudo inverses, traces and determinants.

4.2.1. Spaces Associated with a Matrix#

Definition 4.32 (Column space)

The column space of a matrix is defined as the vector space spanned by columns of the matrix. Let A be an m×n matrix with

A=[a1a2an]

Then the column space is given by

C(A)={xFm|x=i=1nαiaifor some αiF}.

Definition 4.33 (Row space)

The row space of a matrix is defined as the vector space spanned by rows of the matrix.

Let A be an m×n matrix with

A=[a1Ta2TamT]

Then the row space is given by

R(A)={xFn|x=i=1mαiaifor some αiF}.

4.2.2. Rank#

Definition 4.34 (Column rank)

The column rank of a matrix is defined as the maximum number of columns which are linearly independent. In other words column rank is the dimension of the column space of a matrix.

Definition 4.35 (Row rank)

The row rank of a matrix is defined as the maximum number of rows which are linearly independent. In other words row rank is the dimension of the row space of a matrix.

Theorem 4.21 (Equality of row and column rank)

The column rank and row rank of a matrix are equal.

Definition 4.36 (Rank)

The rank of a matrix is defined to be equal to its column rank which is equal to its row rank.

Lemma 4.1 (Rank bounds)

For an m×n matrix A

0rank(A)min(m,n).

Lemma 4.2 (Zero rank matrix)

The rank of a matrix is 0 if and only if it is a zero matrix.

Definition 4.37 (Full rank matrix)

An m×n matrix A is called full rank if

rank(A)=min(m,n).

In other words it is either a full column rank matrix or a full row rank matrix or both.

Lemma 4.3 (Rank of product of two matrices)

Let A be an m×n matrix and B be an n×p matrix then

rank(AB)min(rank(A),rank(B)).

Lemma 4.4 (Full rank post multiplication)

Let A be an m×n matrix and B be an n×p matrix. If B is of rank n then

rank(AB)=rank(A).

Lemma 4.5 (Full rank pre multiplication)

Let A be an m×n matrix and B be an n×p matrix. If A is of rank n then

rank(AB)=rank(B).

Lemma 4.6 (Rank of a diagonal matrix)

The rank of a diagonal matrix is equal to the number of nonzero elements on its main diagonal.

Proof. The columns which correspond to diagonal entries which are zero are zero columns. Other columns are linearly independent. The number of linearly independent rows is also the same. Hence their count gives us the rank of the matrix.

4.2.3. Invertible Matrices#

We say that an m×n matrix A is left-invertible if there exists an n×m matrix B such that BA=I. We say that an m×n matrix A is right-invertible if there exists an n×m matrix B such that AB=I.

We say that a square matrix A is invertible when there exists another square matrix B of same size such that AB=BA=I. A square matrix is invertible iff it is both left and right invertible. Inverse of a square invertible matrix is denoted by A1.

A special left or right inverse is the pseudo inverse, which is denoted by A.

Column space of a matrix is denoted by C(A), the null space by N(A), and the row space by R(A).

We say that a matrix is symmetric when A=AT, conjugate symmetric or Hermitian when AH=A.

When a square matrix is not invertible, we say that it is singular. A non-singular matrix is invertible.

Definition 4.38 (Invertible matrix)

A square matrix A is called invertible if there exists another square matrix B of same size such that

AB=BA=I.

The matrix B is called the inverse of A and is denoted as A1.

Lemma 4.7 (Invertibility of the inverse)

If A is invertible then its inverse A1 is also invertible and the inverse of A1 is nothing but A.

Lemma 4.8 (Invertibility of identity matrix)

Identity matrix I is invertible.

Proof. We can see that

II=II1=I.

Lemma 4.9 (Linear independence of columns of invertible matrices)

If A is invertible then columns of A are linearly independent.

Proof. Assume A is invertible, then there exists a matrix B such that

AB=BA=I.

Assume that columns of A are linearly dependent. Then there exists u0 such that

Au=0BAu=0Iu=0u=0

a contradiction. Hence columns of A are linearly independent.

Lemma 4.10 (Span of columns of invertible matrix)

If an n×n matrix A is invertible then columns of A span Fn.

Proof. Assume A is invertible, then there exists a matrix B such that

AB=BA=I.
  1. Now let xFn be any arbitrary vector.

  2. We need to show that there exists aFn such that

    x=Aa.
  3. But

    x=Ix=ABx=A(Bx).
  4. Thus if we choose a=Bx, then

    x=Aa.
  5. Thus columns of A span Fn.

Lemma 4.11 (Columns of invertible matrix as basis)

If A is invertible, then columns of A form a basis for Fn.

Proof. In Fn a basis is a set of vectors which is linearly independent and spans Fn. By Lemma 4.9 and Lemma 4.10, columns of an invertible matrix A satisfy both conditions. Hence they form a basis.

Lemma 4.12 (Invertibility of transpose)

If A is invertible than AT is invertible.

Proof. Assume A is invertible, then there exists a matrix B such that

AB=BA=I.

Applying transpose on both sides we get

BTAT=ATBT=I.

Thus BT is inverse of AT and AT is invertible.

Lemma 4.13 (Invertibility of Hermitian transpose)

If A is invertible than AH is invertible.

Proof. Assume A is invertible, then there exists a matrix B such that

AB=BA=I.

Applying conjugate transpose on both sides we get

BHAH=AHBH=I.

Thus BH is inverse of AH and AH is invertible.

Lemma 4.14 (Invertibility of matrix product)

If A and B are invertible then AB is invertible.

Proof. We note that

(AB)(B1A1)=A(BB1)A1=AIA1=I.

Similarly

(B1A1)(AB)=B1(A1A)B=B1IB=I.

Thus B1A1 is the inverse of AB.

Lemma 4.15 (Group of invertible matrices)

The set of n×n invertible matrices under the matrix multiplication operation form a group.

Proof. We verify the properties of a group

  • [Closure] If A and B are invertible then AB is invertible. Hence the set is closed.

  • [Associativity] Matrix multiplication is associative.

  • [Identity element] I is invertible and AI=IA=A for all invertible matrices.

  • [Inverse element] If A is invertible then A1 is also invertible.

Thus the set of invertible matrices is indeed a group under matrix multiplication.

Lemma 4.16 (Rank of an invertible matrix)

An n×n matrix A is invertible if and only if it is full rank i.e.

rank(A)=n.

Corollary 4.5 (Equality of rank of a matrix and its inverse)

The rank of an invertible matrix and its inverse are same.

4.2.4. Similar Matrices#

Definition 4.39 (Similar matrix)

An n×n matrix B is similar to an n×n matrix A if there exists an n×n non-singular matrix C such that

B=C1AC.

Lemma 4.17 (Symmetry of similarity)

If B is similar to A then A is similar to B. Thus similarity is a symmetric relation.

Proof. We have

B=C1ACA=CBC1A=(C1)1BC1

Thus there exists a matrix D=C1 such that

A=D1BD.

Thus A is similar to B.

Lemma 4.18 (Rank of similar matrices)

Similar matrices have same rank.

Proof. Let B be similar to A. Then their exists an invertible matrix C such that

B=C1AC.

Since C is invertible hence we have rank(C)=rank(C1)=n. Now using Lemma 4.4

rank(AC)=rank(A)

and using Lemma 4.5 we have

rank(C1(AC))=rank(AC)=rank(A).

Thus

rank(B)=rank(A).

Lemma 4.19 (Similarity as equivalence relation)

Similarity is an equivalence relation on the set of n×n matrices.

Proof. Let A,B,C be n×n matrices.

  1. A is similar to itself through an invertible matrix I.

  2. If A is similar to B then B is similar to itself.

  3. If B is similar to A via P s.t. B=P1AP and C is similar to B via Q s.t. C=Q1BQ then C is similar to A via PQ such that C=(PQ)1A(PQ).

  4. Thus similarity is an equivalence relation on the set of square matrices and if A is any n×n matrix then the set of n×n matrices similar to A forms an equivalence class.

4.2.5. Gram Matrices#

Definition 4.40 (Gram matrix)

The Gram matrix of columns of A is given by

G=AHA.

Definition 4.41 (Frame operator)

The frame operator is the Gram matrix of rows of A is given by

F=AAH

Usually when we talk about Gram matrix of a matrix we are looking at the Gram matrix of its column vectors.

Remark 4.3 (Gram matrix and frame operators for real matrices)

For real matrix ARm×n, the Gram matrix of its column vectors is given by ATA and the frame operator for its row vectors is given by AAT.

Following results apply equally well for the real case.

Lemma 4.20 (Linear dependence of columns and Gram matrix)

The columns of a matrix are linearly dependent if and only if the Gram matrix of its column vectors AHA is not invertible.

Proof. Let A be an m×n matrix and G=AHA be the Gram matrix of its columns.

  1. If columns of A are linearly dependent, then there exists a vector u0 such that

    Au=0.
  2. Thus

    Gu=AHAu=0.
  3. Hence the columns of G are also linearly dependent.

  4. Hence G is not invertible.

Conversely let us assume that G is not invertible.

  1. Thus columns of G are dependent.

  2. There exists a vector v0 such that

    Gv=0.
  3. Now

    vHGv=vHAHAv=(Av)H(Av)=Av22.
  4. From previous equation, we have

    Av22=0Av=0.
  5. Since v0 hence columns of A are also linearly dependent.

Corollary 4.6 (Linear independence of columns and Gram matrix)

The columns of a matrix are linearly independent if and only if the Gram matrix of its column vectors AHA is invertible.

Proof. Columns of A can be dependent only if its Gram matrix is not invertible. Thus if the Gram matrix is invertible, then the columns of A are linearly independent.

The Gram matrix is not invertible only if columns of A are linearly dependent. Thus if columns of A are linearly independent then the Gram matrix is invertible.

Corollary 4.7

Let A be a full column rank matrix. Then AHA is invertible.

Lemma 4.21

The null space of A and its Gram matrix AHA coincide; i.e.,

N(A)=N(AHA).

Proof. Let uN(A). Then

Au=0AHAu=0.

Thus

uN(AHA)N(A)N(AHA).

Now let uN(AHA). Then

AHAu=0uHAHAu=0Au22=0Au=0.

Thus we have

N(AHA)N(A).

Lemma 4.22

The rows of a matrix A are linearly dependent if and only if the Gram matrix of its row vectors AAH is not invertible.

Proof. Rows of A are linearly dependent, if and only if columns of AH are linearly dependent.

There exists a vector v0 s.t.

AHv=0.

Thus

Gv=AAHv=0.

Since v0 hence G is not invertible.

Converse: assuming that G is not invertible, there exists a vector u0 s.t.

Gu=0.

Now

uHGu=uHAAHu=(AHu)H(AHu)=AHu22=0AHu=0.

Since u0 hence columns of AH and consequently rows of A are linearly dependent.

Corollary 4.8

The rows of a matrix A are linearly independent if and only if the Gram matrix of its row vectors AAH is invertible.

Corollary 4.9

Let A be a full row rank matrix. Then AAH is invertible.

4.2.6. Pseudo Inverses#

Definition 4.42 (Moore Penrose pseudo inverse)

Let A be an m×n matrix. An n×m matrix A is called its Moore-Penrose pseudo-inverse if it satisfies all of the following criteria:

  • AAA=A.

  • AAA=A.

  • (AA)H=AA i.e. AA is Hermitian.

  • (AA)H=AA i.e. AA is Hermitian.

Theorem 4.22 (Existence and uniqueness of Moore Penrose pseudo inverse)

For any matrix A there exists precisely one matrix A which satisfies all the requirements in Definition 4.42.

We omit the proof for this. The pseudo-inverse can actually be obtained by the singular value decomposition of A. This is shown in Lemma 4.79.

Lemma 4.23 (Moore Penrose pseudo inverse of a diagonal matrix)

Let D=diag(d1,d2,,dn) be an n×n diagonal matrix. Then its Moore-Penrose pseudo-inverse is D=diag(c1,c2,,cn) where

ci={1diif di0;0if di=0.

Proof. We note that DD=DD=F=diag(f1,f2,fn) where

fi={1if di0;0if di=0.

We now verify the requirements in Definition 4.42.

DDD=FD=D.
DDD=FD=D.

DD=DD=F is a diagonal hence Hermitian matrix.

Lemma 4.24 (Moore Penrose pseudo inverse of a rectangular diagonal matrix)

Let D=diag(d1,d2,,dp) be an m×n rectangular diagonal matrix where p=min(m,n). Then its Moore-Penrose pseudo-inverse is an n×m rectangular diagonal matrix D=diag(c1,c2,,cp) where

ci={1diif di0;0if di=0.

Proof. We note that

F=DD=diag(f1,f2,fn)

is an n×n matrix where

fi={1if di0;0if di=0;0if i>p.

G=DD=diag(g1,g2,gn) is an m×m matrix where

gi={1if di0;0if di=0;0if i>p.

We now verify the requirements in Definition 4.42.

DDD=DF=D.
DDD=DG=D.

F=DD and G=DD are both real diagonal hence Hermitian matrices.

Lemma 4.25 (Moore Penrose pseudo inverse of full column rank matrices)

If A is full column rank then its Moore-Penrose pseudo-inverse is given by

A=(AHA)1AH.

It is a left inverse of A.

Proof. By Corollary 4.7 AHA is invertible. First of all we verify that it is a left inverse.

AA=(AHA)1AHA=I.

We now verify all the properties.

AAA=AI=A.
AAA=IA=A.

Hermitian properties:

(AA)H=(A(AHA)1AH)H=(A(AHA)1AH)=AA.
(AA)H=IH=I=AA.

Lemma 4.26 (Moore Penrose pseudo inverse of full row rank matrices)

If A is full row rank then its Moore-Penrose pseudo-inverse is given by

A=AH(AAH)1.

It is a right inverse of A.

Proof. By Corollary 4.9 AAH is invertible. First of all we verify that it is a right inverse.

AA=AAH(AAH)1=I.

We now verify all the properties.

AAA=IA=A.
AAA=AI=A.

Hermitian properties:

(AA)H=IH=I=AA.
(AA)H=(AH(AAH)1A)H=AH(AAH)1A=AA.

4.2.7. Trace#

Definition 4.43 (Trace of a square matrix)

The trace of a square matrix is defined as the sum of the entries on its main diagonal. Let A be an n×n matrix, then

tr(A)=i=1naii

where tr(A) denotes the trace of A.

Lemma 4.27

The trace of a square matrix and its transpose are equal.

tr(A)=tr(AT).

Lemma 4.28

Trace of sum of two square matrices is equal to the sum of their traces.

tr(A+B)=tr(A)+tr(B).

Lemma 4.29 (Trace product rule)

Let A be an m×n matrix and B be an n×m matrix. Then

tr(AB)=tr(BA).

Proof. Let AB=C=[cij]. Then

cij=k=1naikbkj.

Thus

cii=k=1naikbki.

Now

tr(C)=i=1mcii=i=1mk=1naikbki=k=1ni=1maikbki=k=1ni=1mbkiaik.

Let BA=D=[dij]. Then

dij=k=1mbikakj.

Thus

dii=k=1mbikaki.

Hence

tr(D)=i=1ndii=i=1nk=1mbikaki=i=1mk=1nbkiaik.

This completes the proof.

Lemma 4.30 (Trace triple product rule)

Let AFm×n, BFn×p, CFp×m be three matrices. Then

tr(ABC)=tr(BCA)=tr(CAB).

Proof. Let AB=D. Then

tr(ABC)=tr(DC)=tr(CD)=tr(CAB).

Similarly the other result can be proved.

Lemma 4.31

Trace of similar matrices is equal.

Proof. Let B be similar to A. Thus

B=C1AC

for some invertible matrix C. Then

tr(B)=tr(C1AC)=tr(CC1A)=tr(A).

We used Lemma 4.29.

4.2.8. Determinants#

Following are some results on determinant of a square matrix A.

Lemma 4.32 (Determinant and scalar multiplication)

det(αA)=αndet(A).

Lemma 4.33

Determinant of a square matrix and its transpose are equal.

det(A)=det(AT).

Lemma 4.34

Let A be a complex square matrix. Then

det(AH)=det(A).

Proof. We proceed as follows:

det(AH)=det(AT)=det(A)=det(A).

Lemma 4.35 (Determinant product rule)

Let A and B be two n×n matrices. Then

det(AB)=det(A)det(B).

Lemma 4.36 (Determinant of inverse)

Let A be an invertible matrix. Then

det(A1)=1det(A).

Lemma 4.37 (Determinant power rule)

det(Ap)=(det(A))p.

Lemma 4.38 (Determinant of triangular matrices)

Determinant of a triangular matrix is the product of its diagonal entries; i.e., if A is upper or lower triangular matrix then

det(A)=i=1naii.

Lemma 4.39 (Determinant of diagonal matrices)

Determinant of a diagonal matrix is the product of its diagonal entries; i.e., if A is a diagonal matrix then

det(A)=i=1naii.

Lemma 4.40 (Determinants of similar matrices)

Determinant of similar matrices is equal.

Proof. Let B be similar to A. Thus

B=C1AC

for some invertible matrix C. Hence

det(B)=det(C1AC)=det(C1)det(A)det(C).

Now

det(C1)det(A)det(C)=1det(C)det(A)det(C)=det(A).

We used Lemma 4.35 and Lemma 4.36.

Lemma 4.41

Let u and v be vectors in Fn. Then

det(I+uvT)=1+uTv.

Lemma 4.42 (Determinant of perturbation of an identity matrix)

Let A be a square matrix and let ϵ0. Then

det(I+ϵA)1+ϵtr(A).