Lecture 8 Com 1033
Lecture 8 Com 1033
Part 2
COM1033 - Foundations of Computing II
Learning Resources
Chapter 8, Sections 8.5: F. Neri, Linear Algebra for
Computational Sciences and Engineering, 2019, pages 304-319
1
Basis of a Vector Space
Definition of Basis
Definition
Let (𝐸, +, ·) be a finite-dimensional vector space. A basis
𝐵 = {v1 , v2 , . . . , vn } of (𝐸, +, ·) is a set of vectors ∈ 𝐸 that verify
the following properties.
Example
Let us consider the vector space ℝ3 . A basis 𝐵 of ℝ3
© 0 ª © 0 ª © 1 ª
0 ®, 1 ®, 0 ®
® ® ®
« 1 ¬ « 0 ¬ « 0 ¬
as they are linearly independent and all the numbers in ℝ3
can be derived by their linear combination. 3
Example: Basis of a Vector Space
Example
The following vectors span ℝ3
© 0 ª © 0 ª © 1 ª © 1 ª
0 ®, 1 ®, 0 ®, 2 ®
® ® ® ®
« 1 ¬ « 0 ¬ « 0 ¬ « 3 ¬
as they still allow to generate all the numbers in ℝ3 but are not
linearly independent, thus not a basis.
4
Steinitz’s Lemma
Lemma
Corollary
Let (𝐸, +, ·) be a finite-dimensional vector space and
𝐿 (v1 , v2 , . . . , vn ) = 𝐸 its span and 𝐵 = {w1 , w2 , . . . , ws } be its
basis. It follows that 𝑠 ≤ 𝑛.
5
Steinitz’ Lemma
Example
The following four vectors span ℝ3
© 0 ª © 0 ª © 1 ª © 1 ª
v1 = 0 ®, v2 = 1 ®, v3 = 0 ®, v4 = 2 ®®
® ® ®
« 1 ¬ « 0 ¬ « 0 ¬ « 3 ¬
while the following vectors are linearly independent ∈ ℝ3
© 1 ª © 0 ª © 0 ª
w1 = 4 ®, w2 = 5 ®, w3 = 2 ®®.
® ®
« 0 ¬ « 0 ¬ « 1 ¬
Steinitz’s lemma says that any set of linearly independent
vectors belonging to a set 𝐸 cannot be more numerous than a
any set of vectors spanning 𝐸.
6
Dimension of a Vector Space
Order of a Basis
Definition
The number of vectors composing a basis is said order of a basis.
Theorem
Example
If we consider two bases of ℝ3 , they will have the same order.
We know that in ℝ3 at most three vectors can be linearly
independent, thus a basis of ℝ3 can be composed of at most
three vectors. We have seen that at least three vectors are
needed to span ℝ3 . Thus each basis must have three vectors.
8
Dimension of a Vector Space
Definition
Let (𝐸, +, ·) be a finite-dimensional vector space. The order of
a basis of (𝐸, +, ·) is said dimension of (𝐸, +, ·) and is indicated
with dim (𝐸, +, ·) or simply with dim (𝐸).
Theorem
9
Dimension of a Vector Space
Proof.
If dim (𝐸, +, ·) = 𝑛, then let 𝐵 = {v1 , v2 , . . . , vn } be it basis. Let
us assume, by contradiction, that there exist 𝑛 + 1 linearly
independent vectors in 𝐸 (those 𝑛 vectors in 𝐵 plus one). Since
𝐵 is a basis, its 𝑛 vectors span 𝐸. For Steinitz Lemma,
𝑛 + 1 ≤ 𝑛, that is a contradiction.
Let us assume, by contradiction, that 𝑛 − 1 vectors are enough
to span 𝐸. Since 𝐵 is a basis then its 𝑛 vectors are linearly
independent. For Steinitz’s Lemma, 𝑛 ≤ 𝑛 − 1, that is a
contradiction.
□
10
Dimension of a Vector space
Example
Let us consider the vector space (𝐸, +, ·) where
𝐸 = {(𝑥, 𝑦, 𝑧) ∈ ℝ3 |𝑥 − 3𝑦 − 7𝑧 = 0}.
Example
Let us consider now the vector space (𝐸, +, ·) where
𝑥−𝑦=0
𝐸 = (𝑥, 𝑦, 𝑧) ∈ ℝ3 𝑦+𝑧=0 .
3𝑥 + 𝑧 = 0
Since the incomplete matrix is non-singular, the only solution
of the linear system is (0, 0, 0). Hence, 𝐿 ((0, 0, 0)) = 𝐸. In this
special case, the vector space is composed only of the null
vector. Since there are no linearly independent vectors,
dim (𝐸, +, ·) = 0.
12
Dimension of a Vector Space
Example
More generally, if a vector subspace of ℝ3 is identified by 3
linear equations in 3 variables
Lemma
15
Example: Unique representation
Example
Let us consider the following linearly dependent vectors ∈ ℝ3 :
© 1 ª © 1 ª © 2 ª
v1 = 0 ®, v2 = 1 ®, v3 = 1 ®®.
® ®
« 1 ¬ « 1 ¬ « 2 ¬
Any pair of them is linearly independent. Let us express v3 as
a linear combination of the other two vectors:
© 2 ª © 1 ª © 1 ª
1 ® = 𝜆1 0 ® + 𝜆2 1 ®
® ® ®
2
« ¬ 1
« ¬ « 1 ¬
which results in the system
16
Example: Unique representation
Example
𝜆1 + 𝜆2 = 2
𝜆 =1
2
𝜆1 + 𝜆2 = 2
that is determined and its only solution is 𝜆1 , 𝜆2 = 1, 1.
Lemma
Basis Extension theorem. Any list of linearly independent
vectors ∈ 𝑈 but not spanning 𝑈 can be extended to a basis of 𝑈.
Example
The vectors of ℝ3 , (0, 0, 1) and (1, 0, 0) are linearly
independent. We can add (1, 4, 1) to the list and obtain a basis.
17
Grassmann’s Formula
Theorem
Grassmann’s Formula. Let (𝐸, +, ·) be a finite-dimensional vector
space. Let (𝑈 , +, ·) and (𝑉 , +, ·) be vector subspaces of (𝐸, +, ·).
Then, dim (𝑈 + 𝑉) + dim (𝑈 ∩ 𝑉) = dim (𝑈) + dim (𝑉).
Proof.
Let us suppose that dim (𝑈) = 𝑟 and dim (𝑉) = 𝑠. (𝑈 ∩ 𝑉 , +, ·)
is a vector subspace and let 𝐵𝑈∩𝑉 = {t1 , t2 , . . . , tl } be its basis.
Since all the vectors contained in 𝐵𝑈∩𝑉 are also vectors in 𝑈,
for the basis extension theorem, we can obtain 𝐵𝑈 and 𝐵𝑉
from 𝐵𝑈∩𝑉 :
𝑆 = 𝑈 + 𝑉 = {w ∈ 𝐸|∃u ∈ 𝑈 , v ∈ 𝑉 |w = u + v}
w=u+v=
𝜆1 t1 + 𝜆2 t2 + . . . + 𝜆 𝑙 tl + 𝑎 𝑙+1 ul+1 + 𝑎 𝑙+2 ul+2 + . . . + 𝑎 𝑟 ur
+𝜇1 t1 + 𝜇2 t2 + . . . + 𝜇𝑙 tl + 𝑏 𝑙+1 vl+1 + 𝑏 𝑙+2 vl+2 + . . . + 𝑏 𝑠 vs =
= (𝜆1 + 𝜇1 ) t1 + (𝜆2 + 𝜇2 ) t2 + . . . (𝜆 𝑙 + 𝜇𝑙 ) tl +
+𝑎 𝑙+1 ul+1 + 𝑎 𝑙+2 ul+2 + . . . + 𝑎 𝑟 ur + 𝑏 𝑙+1 vl+1 + . . . + 𝑏 𝑠 vs
This means that 𝑟 + 𝑠 − 𝑙 vectors span 𝑈 + 𝑉
19
Grassmann’s Formula
Proof.
Let us now check the linear independence of these 𝑟 + 𝑠 − 𝑙
vectors. Let us impose that
𝛼 1 t1 + 𝛼 2 t2 + . . . + 𝛼 𝑙 tl +
+𝛽 𝑙+1 ul+1 + 𝛽 𝑙+2 ul+2 + . . . + 𝛽 𝑟 ur +
+𝛾𝑙+1 vl+1 + 𝛾𝑙+2 vl+2 + . . . + 𝛾𝑠 vs = o.
Hence,
𝛼1 t1 + 𝛼 2 t2 + . . . + 𝛼 𝑙 tl +
+𝛽 𝑙+1 ul+1 + 𝛽 𝑙+2 ul+2 + . . . + 𝛽 𝑟 ur = d =
= − (𝛾𝑙+1 vl+1 + 𝛾𝑙+2 vl+2 + . . . + 𝛾𝑠 vs )
𝛼 1 t1 + 𝛼 2 t2 + . . . + 𝛼 𝑙 tl +
+𝛾𝑙+1 vl+1 + 𝛾𝑙+2 vl+2 + . . . + 𝛾𝑠 vs = o.
Proof.
Thus these 𝑟 + 𝑠 − 𝑙 vectors compose a basis 𝐵𝑈+𝑉 :
22
Example: Grassmann’s Formula
Example
Let us consider the vector space ℝ3 , +, · and two vector
23
Example: Grassmann’s Formula
Example
⊚ If the dimension of both 𝑈 and 𝑉 is 1, i.e. only one linearly
independent vector and thus one line, we can distinguish
two subcases
◦ the two vectors in 𝑈 and 𝑉, respectively, represent two lines
passing through the origin. The intersection
𝑈 ∩ 𝑉 = (0, 0, 0) is the origin, while the sum 𝑈 + 𝑉 is the
plane that contains the two vectors. It follows that
dim (𝑈 + 𝑉)+dim (𝑈 ∩ 𝑉) = 2+0 = dim (𝑈)+dim (𝑉) = 1+1
◦ the two vectors in 𝑈 and 𝑉, respectively, represent two
coinciding lines. Both intersection and sum coincide with
the vector, i.e. 𝑈 ∩ 𝑉 = 𝑈 + 𝑉 = 𝑈 = 𝑉. It follows that
dim (𝑈 + 𝑉)+dim (𝑈 ∩ 𝑉) = 1+1 = dim (𝑈)+dim (𝑉) = 1+1
24
Example: Grassmann’s Formula
Example
⊚ if the dimension of 𝑈 is 1 while that of 𝑉 is 2, i.e. one line
passing through the origin and one plane passing through
the origin, we can distinguish two subcases:
◦ the line does not lay in the plane. It follows that
𝑈 ∩ 𝑉 = (0, 0, 0) and 𝑈 + 𝑉 = ℝ3 . Hence,
dim (𝑈 + 𝑉)+dim (𝑈 ∩ 𝑉) = 3+0 = dim (𝑈)+dim (𝑉) = 1+2
◦ the line lays in the plane. It follows that 𝑈 ∩ 𝑉 = 𝑈 and
𝑈 + 𝑉 = 𝑉. Hence,
dim (𝑈 + 𝑉)+dim (𝑈 ∩ 𝑉) = 2+1 = dim (𝑈)+dim (𝑉) = 1+2
25
Example: Grassmann’s Formula
Example
⊚ If the dimension of both 𝑈 and 𝑉 is 2, i.e. two linearly
independent vectors and thus two planes passing through
the origin, we can distinguish two subcases
◦ the planes do not coincide. It follows that 𝑈 ∩ 𝑉 is a line
while 𝑈 + 𝑉 = ℝ3 . Hence,
dim (𝑈 + 𝑉)+dim (𝑈 ∩ 𝑉) = 3+1 = dim (𝑈)+dim (𝑉) = 2+2
◦ the planes coincide. It follows that 𝑈 ∩ 𝑉 = 𝑈 + 𝑉 and
𝑈 + 𝑉 = 𝑈 = 𝑉, i.e. intersection and sum are the same
coinciding plane. Hence,
dim (𝑈 + 𝑉)+dim (𝑈 ∩ 𝑉) = 2+2 = dim (𝑈)+dim (𝑉) = 2+2
26
Summary and next lecture
Summary
⊚ A basis of a vector space is a set of linearly independent
vectors spanning the set of the vector space
⊚ The number of vectors in a basis is a special number that
characterises the dimension of a problem and is the
maximum number of linearly independent vectors and the
minimum number of vectors spanning the set
⊚ Grassmann’s formula states that if we sum two sets, its
resulting dimension depends on each set separately and
their intersection
1. Determine a basis of 𝑈
2. Determine the dimension of 𝑈
3. Determine a basis of 𝑉
4. Determine the dimension of 𝑉
5. Determine a basis of 𝑈 ∩ 𝑉
6. Determine the dimension of 𝑈 ∩ 𝑉
7. Determine the dimension of 𝑈 + 𝑉
8. Provide a geometrical interpretation of 𝑈, 𝑉, 𝑈 ∩ 𝑉, and
𝑈 +𝑉 29
Exercise
1. Determine a basis of 𝑈
2. Determine the dimension of 𝑈
3. Determine a basis of 𝑉
4. Determine the dimension of 𝑉
5. Determine a basis of 𝑈 ∩ 𝑉
6. Determine the dimension of 𝑈 ∩ 𝑉
7. Determine the dimension of 𝑈 + 𝑉
8. Provide a geometrical interpretation of 𝑈, 𝑉, 𝑈 ∩ 𝑉, 𝑈 + 𝑉 30
Exercise
1. Determine a basis of 𝑈
2. Determine the dimension of 𝑈
3. Determine a basis of 𝑉
4. Determine the dimension of 𝑉
5. Determine a basis of 𝑈 ∩ 𝑉
6. Determine the dimension of 𝑈 ∩ 𝑉
7. Determine the dimension of 𝑈 + 𝑉
8. Provide a geometrical interpretation of 𝑈, 𝑉, 𝑈 ∩ 𝑉, 𝑈 + 𝑉
31
Exercise
𝐿 (v1 , v2 , . . . , vn ) = 𝑈 ⊂ 𝐸
32
Exercise
33
THANK
YOU