Linear Algebra
Linear Algebra
Jenish P.
1 Vector Spaces 1
1.1 Definitions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
1.2 Bases . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
1.3 Dimension of a Vector Space . . . . . . . . . . . . . . . . . . 3
1.4 Sums and Direct Sums . . . . . . . . . . . . . . . . . . . . . . 4
2 Matrices 7
2.1 Matrices and Arithmetic Operations on Them . . . . . . . . . 7
2.2 The Inverse of a Matrix . . . . . . . . . . . . . . . . . . . . . 9
3 Linear Mappings 13
5 Matrices 21
5.1 Subspaces of Rn . . . . . . . . . . . . . . . . . . . . . . . . . 21
6 Determinants 23
6.1 Determinants and some other Concepts . . . . . . . . . . . . 23
6.2 Properties of Determinants . . . . . . . . . . . . . . . . . . . 24
7 Vector Spaces 27
7.1 Coordinate Systems . . . . . . . . . . . . . . . . . . . . . . . 28
7.2 Rank . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29
7.3 Change of Basis . . . . . . . . . . . . . . . . . . . . . . . . . . 29
iii
iv CONTENTS
9 Orthogonality 33
9.1 Orthogonal Sets . . . . . . . . . . . . . . . . . . . . . . . . . . 33
9.2 Orthogonal Projections . . . . . . . . . . . . . . . . . . . . . . 34
Vector Spaces
1.1 Definitions
Definition. A vector space over a field F is a set V with two closed op-
erations, vector addition or simply addition and scalar multiplication, that
satisfy the following axioms:
1. Associativity of addition;
2. Commutativity of addition;
a(bv) = (ab)v
If a subspace only contains the zero vector 0, it is called a zero subspace and
written as {0}.
1
2 1. VECTOR SPACES
y = c1 v1 + · · · + cn vn
1.2 Bases
Definition. An indexed set of vectors {v1 , · · · , vp } ∈ V is said to be linearly
independent if the vector equation
c1 v1 + c2 v2 + · · · + cp vp = 0
has only the trivial solution. Otherwise it’s said to be linearly dependent.
Definition. A collection of linearly independent vectors that generated the
vector space V is called a basis of V .
Definition. Let V be a vector space and B be a basis for it. The coordinate
with respect to basis B of an element is a n-tuple of numbers such that the
desired element can be expressed with the linear combination of the n-tuple
and basis elements. By the definition of basis, the coordinate of any element
is unique.
Definition. The maximal subset of linearly independent elements is a subset
of any collection of vectors of a vector space that adding another element
from the original collection that is not in this maximal subset will result in
the loss of linearly independence.
Theorem 1.2.1. The maximal subset of linearly independent elements of
any collection of vectors that generate the vector space is a basis for it.
1.3. DIMENSION OF A VECTOR SPACE 3
Proof. Let the basis B be {v1 , · · · , vm } and the collection of n vectors(n >
m) in V be w1 , · · · , wn . Assume this collection of vectors are linearly inde-
pendent. Since B is a basis, the equation
w1 = a1 v1 + · · · + am vm
holds for some elements in the field K that are not all zero. Without loss
of generality, we can assume that a1 ̸= 0(otherwise we could just rearrange
the equation to make it so). Solve for v1
v1 = a−1 −1 −1
1 w1 − a1 a2 v2 − · · · a1 am vm
holds for some element in K. cr+1 , · · · , cm can’t be all zero, since then
we have expressed wr+1 as a linear combination of w1 , · · · , wr , contradict
out assumption. Without loss of generality, assume that cr+1 is not zero.
Repeat the same process when we solve for v1 to solve for vr+1 , we then find
that vr+1 is in the subspace generated by w1 , · · · , wr+1 , vr+2 , · · · , vm . By
the induction assumption, these vectors also generate V . Therefore vectors
w1 , · · · , wm generate V , and for n > m we can expressed wn as a linear
combination of w1 , · · · , wm . The theorem is then proved.
Corollary. Any two basis of the same vector space have the same number
of elements.
x0 w + x1 v1 + · · · + xn vn = 0
Theorem 1.3.3. The dimension of the subspace W that does not consist of
the zero vector alone of a vector space V is no greater than dim V .
Theorem 1.4.1. Let V be a vector space over the field K, and let U , W be
subspaces. If U + W = V and U ∩ W = {0}, then V = U ⊕ W .
Theorem 1.4.2. Let V be a finite dimensional vector space over the field K.
Let W be a subspace. Then there exists a subspace U such that V = W ⊕ U .
Definition. The direct product of two vector spaces U and W over the field
K is the cartesian product of elements in U and W , i.e (u1 , w1 ) ∈ U ×W . The
vector addition and scalar multiplication are defined to be componentwise.
Immediately, the direct product of two vector spaces over the same field
is a vector space.
Theorem 1.4.4.
Proof. For two basis in each space {u1 , · · · , un } and {w1 , · · · , wm }, the col-
lection of vectors in U ×W consists of {(u1 , 0), · · · , (un , 0), (0, w1 ), · · · , (0, wm )}
is a basis for U × W of n + m elements.
The notion of direct sum and direct product can be extended to several
factors with and . In this circumstance vector addition and scalar
P Q
Matrices
Definition. Two matrices are equal if they have the same size and each
entries are equal.
Theorem 2.1.1. The set of matrices of the same size with respect to matrix
addition and scalar multiplication over the field of real numbers is a vector
space.
• Associativity of multiplication;
7
8 2. MATRICES
• Left distribution;
• Right distribution;
• (AT )T = A;
• (A + B)T = AT + BT ;
AA−1 = In
• AT is an invertible matrix.
• Col A = Rn
• dim Col A = n
• rank A = n
• Nul A = {0}
• dim Nul A = 0
Row1 (B)
Row2 (B)
i
h
AB = Col1 (A) Col2 (A) · · · Coln (A) ..
.
Rown (B)
= Col1 (A) Row1 (B) + · · · Coln (A) Rown (B)
Definition. A block matrix is a partitioned matrix with zero blocks off the
main diagonal. Such matrix is invertible iff each block on the diagonal is
invertible.
Linear Mappings
2. F is injective.
Proof.
Proof. content...
dim V = dim W
13
14 3. LINEAR MAPPINGS
4
15
16 4. SOLVING LINEAR EQUATIONS
c1 v1 + · · · + cp vp
with c1 , c2 , · · · , cp scalars.
Ax = b
x1 a1 + x2 a1 + · · · + xn an = b
which has the same solution set as the system of linear equations whose
augmented matrix is h i
a1 a2 · · · an b
• A(u + v) = Au + Av.
• A(cu) = c(Au).
x = su + tv (s, t ∈ R)
x1 v1 + x2 v2 + · · · + xp vp = 0
has only the trivial solution. The set {v1 , · · · , vp } is said to be linearly
dependent if there exist weights c1 , · · · , cp , not all zero, such that
c1 v1 + c2 v2 + · · · + cp vp = 0
T (x) = Ax ∀x ∈ Rn
In fact, A is the m × n matrix whose jth column is the vector T (ej ), where
ej is the jth column of the identity matrix in Rn .
h i
A = T (e1 ) · · · T (en )
The matrix A is called the standard matrix for the linear transformation T .
Theorem 4.7.2. Let T : Rn → Rm be a linear transformation. Then T is
injective iff the equation T (x) = 0 has only the trivial solution.
Theorem 4.7.3. Let T : Rn → Rm be a linear transformation and let A be
the standard matrix for T . Then
20 4. SOLVING LINEAR EQUATIONS
then the equation above is called a linear difference equation (or recurrence
relation).
5
Matrices
5.1 Subspaces of Rn
Definition. A subspace of Rn is any set H ∈ Rn that has three properties:
Definition. The column space of a matrix A is the set Col A of all linear
combinations of the columns of A.
Definition. The null space of a matrix A is the set Nul A of all solutions
to the homogeneous equation Ax = 0.
1 0
0
0
e1 = , · · · , en = .
.
. .
. .
0 1
Theorem 5.1.2. The pivot columns of a matrix A form a basis for the
column space of A.
21
22 5. MATRICES
Determinants
denoted det A and equals ad − bc. Determinant is only defined for a square
matrix, but the procedure above can be repeated on higher dimension ma-
trices, for example
a b c d
e f g h e g h e f h e f g
f g h
det = a det j k l −b det i k l +c det i j l −d det i j k
i j k l
n o p m o p m n p m n o
m n o p
σ∈Sn i=1
Here the sum is computed over all permutations σ of the set {1, 2, . . . , n}.
A permutation is a function that reorders this set of integers. The value in
the ith position after the reordering σ is denoted by σi . For example, for
n = 3, the original sequence 1, 2, 3 might be reordered to σ = [2, 3, 1], with
σ1 = 2, σ2 = 3, and σ3 = 1. The set of all such permutations (also known
as the symmetric group on n elements) is denoted by Sn .
For each permutation σ, sgn(σ) denotes the signature of σ, a value that
is +1 whenever the reordering given by σ can be achieved by successively
interchanging two entries an even number of times, and −1 whenever it can
be achieved by an odd number of such interchanges.
23
24 6. DETERMINANTS
Adj(A) = CT
A Adj(A) = det(A)I
or equivalently
1
A−1 = Adj A
det A
Theorem 6.1.2. The determinant of an square matrix can be computed by
a cofactor expansion across any row or down any column. The expansion
across the ith row is
Theorem 6.2.3. If A and B are n×n matrices, then det AB = (det A)(det B).
Example 6.1. If all columns except one are held fixed in a square matrix,
then its determinant is a linear function of that one(vector) variable.
det Ai (b)
xi = , i = 1, 2, · · · , n
det A
Theorem 6.2.5. If A is a 2 × 2 matrix, the area of the parallelogram de-
termined by the columns of A is | det A|. If A is a 3 × 3 matrix, the volume
of the parallelepiped determined by the columns of A is | det A|.
Vector Spaces
27
28 7. VECTOR SPACES
Theorem 7.0.7. The pivot columns of a matrix A form a basis for Col A.
The vector
c1
..
[x]B = .
cn
is the coordinate vector of x(relative to B), or the B-coordinate vector of x.
The mapping x 7→ [x]B is the coordinate mapping(determined by B).
PB = [b1 , · · · , bp ]
x = PB [x]B
Theorem 7.1.2. Let B be a basis for a vector space V . Then the coordinate
mapping x 7→ [x]B is an injective linear transformation from V into Rn .
dim H ⩽ dim V
7.2 Rank
Definition. The set of all linear combinations of the row vectors in A is
called the row space of A and denoted Row A.
Theorem 7.2.1. If two matrices A and B are row equivalent, then their
row spaces are the same. If B is in echelon form, the nonzero rows of B
form a basis for the row space of A as well as B.
Theorem 7.2.2 (The Rank Theorem). The dimensions of the column space
and the row space of an m×n matrix A are equal. This common dimension,
the rank of A, also equals the number of pivot positions in A and satisfies
the equation
rank A + dim Nul A = n
[x]C = P [x]B
C←B
30 7. VECTOR SPACES
The columns of P are the C-coordinate vectors of the vectors in the basis
C←B
B, that is h i
P = [b1 ]C [b2 ]C · · · [bn ]C
C←B
Because the columns of this matrix are linearly independent, since they
are the coordinate vectors of the linearly independent set B, it follows that
P is invertible, and we have
C←B
( P )−1 = P
C←B B←C
8
8.1 Definition
Definition. An eigenvector of an n × n matrix A is a nonzero vector x
such that Ax = λx for some scalar λ. A scalar λ is called an eigenvalue
of A if there is a nontrivial solution x of Ax = λx; such an x is called an
eigenvector corresponding to λ.
Definition. The set of all solutions of
(A − λI)x = 0
is a subspace of Rn and is called the eigenspace of A corresponding to λ.
Theorem 8.1.1. The eigenvalues of a triangular matrix are the entries on
its main diagonal.
Theorem 8.1.2 (The Invertible Matrix Theorem). Let A be an n × n ma-
trix. Then A is invertible iff the number 0 is not an eigenvalue of A.
Theorem 8.1.3. If v1 , · · · , vr are eigenvectors that corresponding to dis-
tinct eigenvalues λ1 , · · · , λr of an n × n matrix A, then the set {v1 , · · · , vr }
is linearly independent.
Definition. The scalar equation det(A−λI) = 0 is called the characteristic
equation of A. If A is an n × n matrix, then det(A − λI) is a polynomial of
degree n called the characteristic polynomial of A.
Theorem 8.1.4. A scalar λ is an eigenvalue of an n × n matrix A iff λ
satisfies the characteristic equation.
Definition. If A and B are n × n matrices, then A and B are similar if
there is an invertible matrix P such that P−1 AP = B. Changing A into
P−1 AP is called a similarity transformation.
Theorem 8.1.5. If n × n matrices A and B are similar, then they have
the same characteristic polynomial and hence the same eigenvalues(with the
same multiplicities).
31
32 8. EIGENVALUES AND EIGENVECTORS
8.2 Diagonalization
Definition. A square matrix A is said to be diagonalizable if A is similar
to a diagonal matrix.
Theorem 8.2.1. An n × n matrix A is diagonalizable iff A has n linearly
independent eigenvectors. In other words, A is diagonalizable iff there are
enough eigenvectors to form a basis of Rn , and such basis is called an eigen-
vector basis.
Theorem 8.2.2. An n × n matrix with n distinct eigenvalues is diagonal-
izable.
Theorem 8.2.3. Let A be an n × n matrix whose distinct eigenvalues are
λ1 , · · · , λp .
1. For 1 ⩽ k ⩽ p, the dimension of the eigenspaces for λk is less than or
equal to the multiplicity of the eigenvalue λk .
2. The matrix A is diagonalizable iff the sum of the dimensions of the
distinct eigenspaces equals n, and this happens iff the dimension of the
eigenspace for each λk equals the multiplicity of λk .
3. If A is diagonalizable and Bk is a basis for the eigenspace correspond-
ing to λk for each k, then the total collection of vectors in the sets
B1 , · · · , Bp forms an eigenvector basis for Rn .
Definition. The matrix
h i
M = [T (b1 )]C [T (b2 )]C · · · [T (bn )]C
where B = {b1 , · · · , bn } is a basis for the vector space V , C is a basis in
W , and T is a linear transformation from V to W , is called the matrix for
T relative to the bases B and C. If W is the same as V and the basis C is
the same as B, the matrix M is called the matrix for T relative to B or the
B-matrix for T , and denoted [T ]B .
Theorem 8.2.4 (Diagonal Matrix Representation). Suppose A = PDP−1 ,
where D is a diagonal n × n matrix. If B is the basis for Rn formed from
the columns of P, then D is the B-matrix of the transformation x 7→ Ax.
Orthogonality
2. W ⊥ is a subspace of Rn .
33
34 9. ORTHOGONALITY
1. ∥Ux∥ = ∥x∥.
y = ŷ + z
projW y = UUT y
36 9. ORTHOGONALITY
10
3. indefinite iff the eigenvalues of A has both positive and negative eigen-
values.
Definition. A positive definite matrix A is a symmetric matrix for which
the quadratic form is positive definite. The matrix is a positive semidefi-
nite matrix if its quadratic form is nonnegative. Other terms are defined
analogously.
37