VIETNAM GENERAL CONFEDERATION OF LABOR TON DUC THANG UNIVERSITY FACULTY OF INFORMATION TECHNOLOGY H Ồ NHẬT DUY 519H0285 – HUỲNH NG ỌC VĨ TRƯỜNG 519H0253 – FINAL REPORT APPLIED LINEAR A
Trang 1VIETNAM GENERAL CONFEDERATION OF LABOR
TON DUC THANG UNIVERSITY FACULTY OF INFORMATION TECHNOLOGY
H Ồ NHẬT DUY 519H0285 – HUỲNH NG ỌC VĨ TRƯỜNG 519H0253 –
FINAL REPORT
APPLIED LINEAR ALGEBRA FOR IT
HO CHI MINH CITY, 2024
Trang 2VIETNAM GENERAL CONFEDERATION OF LABOR
TON DUC THANG UNIVERSITY FACULTY OF INFORMATION TECHNOLOGY
HỒ NHẬT DUY 519H0285 – HUỲNH NG ỌC VĨ TRƯỜNG 519H0253 –
FINAL REPORT APPLIED LINEAR ALGEBRA FOR IT
Advised by MA.PH M KIM THUẠ Ỷ
HO CHI MINH CITY, 2024
Trang 3ACKNOWLEDGEMENT
We would like to express our sincere gratitude to MA Ph m Kim Thu , our ạ ỷ instructor and mentor, for his valuable guidance and support throughout the mid-term report of our final project on course Applied Linear Algebra IT She has been very helpful and patient in providing us with constructive feedback and suggestions to improve our work We have learned a lot from his expertise and experience in web development and software engineering We are honored and privileged to have him as our teacher and superviso r
Ho Chi Minh city, 25 May 2024 th
Author (Signature and full name)
Duy
Ho Nhat Duy
Truong
Huynh Ngoc Vi Truong
Trang 4DECLARATION OF AUTHORSHIP
We hereby declare that this is our own project and is guided by MA Phạm Kim Thu ; The content research and results contained herein are central and have not ỷ been published in any form before
In addition, the project also uses some comments, assessments as well as data of other authors, other organizations with citations and annotated sources
If something wrong happens, we’ll take full responsibility for the content
of my project Ton Duc Thang University is not related to the infringing rights, the copyrights that We give during the implementation process (if any)
Ho Chi Minh city, 25 May 2024 th
Author (Signature and full name)
Duy
Ho Nhat Duy
Truong
Huynh Ngoc Vi Truong
Trang 5Table of Contents
CHAPTER 1 Solutions _ 2
1.1 Question 1 (1.0 point) 2 1.2 Question 2 (1.0 point) 2 1.3 Question 3 (1.0 point) 3 1.4 Question 4 (2.0 point) 3 1.5 Question 5 (1.0 point) 5 1.6 Question 6 (1.0 point) 5
1.7 Question 7 (2.0 points) _ 6
1.7.1 Find the transition matrix from the basis to the basis 𝜀 𝜃 6 1.7.2 Find the transition matrix from the basis to the basis 𝜃 𝜀 7
REFERENCES _ 8
Trang 6CHAPTER 1 Solutions
1.1 Question 1 (1.0 point)
Given the matrix A = (𝟏 𝟐 −𝟏𝟐 𝟐 𝟏
𝟏 𝟐 𝒂) Find all values of a for which det(A) = 0
We have: det(A) = 1 2 a + 2 1 1 + 2 2 (-1) - 1 (-1) - 2∙ ∙ ∙ ∙ ∙ ∙ ∙2∙ ∙2∙ - 2 1 1 a ∙ ∙
= 2a + 2 4 + 2 - 4a - 2 = -2a 2 = 0 – –
⇒ a = -1
1.2 Question 2 (1.0 point)
Solve the following system of linear equations by using Gaussian Elimination method
a {3𝑥 − 𝑦 + 𝑧 = 3𝑥 + 5𝑦 − 2𝑧 = 4
5𝑥 + 𝑦 − 2𝑧 = 4
We have:
(1 53 −1
5 1
−2 4
1 3
−2 4)
3𝑅 1 −𝑅 2 →𝑅2
5𝑅 −𝑅 1 3 →𝑅3
→ (1 50 16
0 24
−2 4
−7 9
−8 16) 12𝑅 −8𝑅 2 3 →𝑅3
(1 50 16
0 0
−2 4
−7 9
−20 20− )
⇒ {𝑥 + 5𝑦 − 2𝑧 = 416𝑦 − 7𝑧 = 9
−20𝑧 = −20 ⇒ {
𝑥 + 5𝑦 − 2𝑧 = 4 16𝑦 − 7 = 9
𝑥 + 5 − 2 = 4
𝑦 = 1
𝑧 = 1 ⇒ {
𝑥 = 1
𝑦 = 1
𝑧 = 1
b {𝑥 − 2𝑦 + 2𝑧 = 4𝑥 + 3𝑦 − 𝑧 = 3
2𝑥 + 𝑦 + 𝑧 = 7
Trang 7(1 31 −2
2 1
−1 3
2 4
2 7)
𝑅 1 −𝑅 2 →𝑅2
2𝑅 −𝑅 1 3 →𝑅3
→ (1 30 5
0 5
−1 3
−3 −1
−4 −1)
𝑅 2 −𝑅 3 →𝑅3
(1 30 5
0 0
−1 3
−3 −1
1 0)
⇒ {𝑥 + 3𝑦 − 𝑧 = 35𝑦 − 3𝑧 = −1
𝑧 = 0 ⇒ {
𝑥 + 3 ∙ (−51) = 3
𝑦 = −15
𝑧 = 0
⇒ {𝑥 = 18 5
𝑦 = −15
𝑧 = 0
1.3 Question 3 (1.0 point)
Let 𝒗𝟏= (𝟏, 𝟏, 𝟏) , 𝒗 = (𝟐, −𝟓, 𝟏) , 𝒗𝟐 𝟑= (𝟑, 𝟎, 𝟓) Show that the set
B = {𝒗𝟏, 𝒗 , 𝒗𝟐 𝟑} is a basis of 𝑹𝟑
We have |𝐵| = 3 = dim𝑅3⇒ B spans 𝑅3 (1)
Linear Combination ∑ 𝑐 𝑣3 𝑖 𝑖
𝑖=1 = 0
We have: (1 −51 2
1 1
3 0
0 0
5 0) ⇒ {
𝑐1 = 0
𝑐 02 =
𝑐3 = 0
⇒ B is independent (2)
From (1) and (2) ⇒ B is basis of 𝑅3
1.4 Question 4 (2.0 point)
Find a matrix P that diagonalizes A = (𝟐 𝟏 𝟏𝟏 𝟐 𝟐
𝟎 𝟎 𝟏)
Let(λI − A) = λ(0 1 01 0 0
0 0 1)-(
1 2 2
2 1 1
0 0 1) = (
2 λ −1 1
0 0 λ −1) det(λI − A) = 0 ⇒ (λ −1)3− 4(λ −1) = (λ −1)((λ −1)2− 4) = 0
⇒ {(λ −λ −1)1 = 02− 4 = 0⇒ {
λ1= 1
λ2= 3
λ3= −1 With λ1=1 let x = (𝑥𝑥21
𝑥3
) ∈ 𝑅3is an eigenvector of A
So(I − A) 𝑥 = 0
Trang 8(0 2 22 0 1
0 0 0) ⇒ {
2𝑥2+2𝑥3= 0
2𝑥1+𝑥3= 0 ⇒ {
𝑥1= 𝑎
𝑥2= 2𝑎
𝑥3= −2𝑎𝑎 ∈ 𝑅\{0}
⇒ 𝐸1= {𝑎 (12
−2)| 𝑎 ∈ 𝑅\{0}} ⇒ 𝐸
A basis of 1is 𝑆1={(21
−2)}
With λ2=3 let y = (𝑦𝑦21
𝑦3
) ∈ 𝑅3is an eigenvector of A
So(3I − A) 𝑥 = 0
(2 2 22 2 1
0 0 2)
𝑅 1 −𝑅 2 →𝑅2
→ (0 0 12 2 2
0 0 2)
𝑅 3 −2𝑅 2 →𝑅3
→ (2 2 20 0 1
0 0 0)
⇒ {2𝑦1+2𝑦2+2𝑦3= 0
𝑦3= 0 ⇒ {
𝑦1= 𝑎
𝑦2= −𝑎
𝑦3= 0 𝑎 ∈ 𝑅\{0}
⇒ 𝐸3= {𝑎 (−11
0)| 𝑎 ∈ 𝑅\{0}} ⇒ A basis of 𝐸3is 𝑆2={(
1
−1
0)}
With λ3= -1 let z = (𝑧𝑧21
𝑧3
) ∈ 𝑅3is an eigenvector of A
So(−I − A) 𝑥 = 0
(−2 22 −2 12
0 0 −2)
𝑅 1 +𝑅 2 →𝑅2
→ (−2 2 20 0 3
0 0 2) 3𝑅 3 −2𝑅 2 →𝑅3
→ (−2 2 20 0 3
0 0 0)
⇒ {−2𝑧1+2𝑧2+2𝑧3= 0
3𝑧3= 0 ⇒ {
𝑧1= 𝑎
𝑧2= 𝑎
𝑧3= 0𝑎 ∈ 𝑅\{0}
⇒ 𝐸−1= {𝑎 (11
0)| 𝑎 ∈ 𝑅\{0}} ⇒ A basis of 𝐸−1is 𝑆3={(
1 1
0)}
⇒ 𝑃 = (12 −1 11 1
−2 0 0) is a matrix that diagonalizes A
Trang 91.5 Question 5 (1.0 point)
Let S = {𝒗𝟏= (𝟐, 𝟒, 𝟑) , 𝒗 = (𝟐, 𝟒, 𝟐) , 𝒗 = (−𝟔, 𝟒, 𝟐) 𝟐 𝟑 } Find the coordinate vector of v = (54, 12, 9) relative to S
We have |𝑆| = 3 = dim𝑅3⇒ S spans 𝑅3 (1)
Linear Combination ∑ 𝑐 𝑣3 𝑖 𝑖
𝑖=1 = 0
We have: (4 42 2
3 2
−6 0
4 0
2 0) ⇒ {
𝑐1 = 0
𝑐 02 =
𝑐3 = 0
⇒ S is independent (2)
From (1) and (2) ⇒ S is basis 𝑅3
Linear Combination ∑ 𝑐 𝑣3 𝑖 𝑖
𝑖=1 = v
We have: (4 42 2
3 2
−6 54
4 12
2 9) ⇒ {
𝑐1 = 3
𝑐 62 =
𝑐 − 63 =
⇒ [𝑣𝑆] = (36
−6)
1.6 Question 6 (1.0 point)
Use the Gram-Schmidt orthonormalization process to transform the basis S = {𝒖𝟏= (𝟒, −𝟖, 𝟖) , 𝒖 = (𝟖, 𝟖, 𝟒) , 𝒖𝟐 𝟑= (𝟖, −𝟒, −𝟖)} for 𝑹𝟑 into an orthonormal basis
Let 𝑣1 = 𝑢1 = (4, -8, 8)
𝑣1∙ 𝑢2 = 4 8 + (-8)∙ ∙8 + 8 4 = 0 ∙
‖𝑣1‖2 = 4 + (−8) + 8 = 144 2 2 2
⇒ 𝑣2= 𝑢2 − 𝑣1 ∙𝑢 2
‖ ‖ 𝑣 1 2∙ 𝑣1 = (8, 8, 4) - 0
144∙(4, -8, 8) = (8, 8, 4)
𝑣1∙ 𝑢3 = 4 8 + (-8)∙ ∙(-4) + 8 (-8) = 0 ∙
𝑣2∙ 𝑢3 = 8 8 + 8 (-4) + 4 (-8) = 0 ∙ ∙ ∙
‖𝑣2‖2 = 8 + 82 2 + 42 = 144
⇒ 𝑣3= 𝑢3 − (𝑣1 ∙𝑢3
‖ ‖ 𝑣1 2∙ 𝑣1 + 𝑣2 ∙𝑢 3
‖ ‖ 𝑣2 2∙ 𝑣2) = (8, -4, -8) - 1440∙(4, -8, 8) - 0
144∙(8, 8, 4)
= (8, -4, -8)
Trang 10‖𝑣1‖= √144 = 12
‖𝑣2‖= √144 = 12
‖𝑣3‖= √ 8 + 2 (−4)2 + ( )−8 2 = √144 = 12
Let
𝑤1 = ‖𝑣1
1 ‖∙ 𝑣1 = 1
12(4, -8, 8)
𝑤2 = ‖𝑣1
2 ‖∙ 𝑣2 = 1
12(8, 8, 4)
𝑤3 = ‖𝑣1
3 ‖∙ 𝑣3 = 1
12(8, -4, -8)
⇒ An orthonormal basis of S is w = {𝑤1, 𝑤2, 𝑤3}
1.7 Question 7 (2.0 points)
Consider the vector space 𝑅3with two bases:
𝜀 = {𝜀1, 𝜀 , 𝜀2 3} in which 𝜀1 = (1, 0, 0), = (0, 1, 0), = (0, 0, 1) 𝜀2 𝜀3
𝜃 = {𝜃1, 𝜃2, 𝜃3} in which 𝜃1 = (1, 1, 0), 𝜃2 = (0, 1, 1), 𝜃3 = (1, 0, 1)
We have |𝜀| = 3 = dim𝑅3⇒ 𝜀 spans 𝑅3 (1)
Linear Combination ∑ 𝑐 𝜀3 𝑖 𝑖
𝑖=1 = 0
We have: (0 11 0
0 0
0 0
0 0
1 0) ⇒ {
𝑐1 = 0
𝑐 02 =
𝑐 03 =
⇒ 𝜀 is independent (2)
From (1) and (2) ⇒ 𝜀 is basis 𝑅3
We have |𝜃| = 3 = dim𝑅3⇒ 𝜀 spans 𝑅3 (1)
Linear Combination ∑ 𝑐 𝜃3 𝑖 𝑖
𝑖=1 = 0
We have: (1 11 0
0 1
1 0
0 0
1 0) ⇒ {
𝑐1 = 0
𝑐 02 =
𝑐 03 =
⇒ 𝜃 is independent (2)
From (1) and (2) ⇒ 𝜃 is basis 𝑅3
1.7.1 Find the transition matrix from the basis to the basis 𝜺 𝜽 Linear Combination
𝜀1 = ∑ 𝑎3𝑖=1 𝑖𝜃, 𝑖𝜀2 = ∑ 𝑏3𝑖=1 𝑖𝜃𝑖, 𝜀3 = ∑ 𝑐3 𝑖𝜃𝑖
𝑖=1
Trang 11We have: (1 1 01 0 1
0 1 1|
1 0 0
0 1 0
0 0 1) ⇒
{
𝑎1 = 12
𝑎2 = −21
𝑎3 = 12
⇒ {
𝑏1 = 12
𝑏2 = 21
𝑏3 = −12
⇒ {
𝑐1 = −12
𝑐2 = 12
𝑐3 = 12 [𝜀1]𝜃 = 1
2(−11
1) [𝜀2]𝜃 =
1
2(11
−1) [𝜀3]𝜃 =
1
2(−11
1)
Transition matrix 𝑃𝜀→𝜃 = 21(−1 11 1 −11
1 −1 1) 1.7.2 Find the transition matrix from the basis to the basis 𝜽 𝜺 Linear Combination
𝜃1 = ∑ 𝑎3 𝑖𝜀𝑖
𝑖=1 , 𝜃2 = ∑ 𝑏3 𝑖𝜀𝑖
𝑖=1 , 𝜃3 = ∑ 𝑐3 𝑖𝜀𝑖
𝑖=1
We have: (0 1 01 0 0
0 0 1|
1 0 1
1 1 0
0 1 1) ⇒ {
𝑎1 = 1
𝑎2 = 1
𝑎3 = 0 ⇒ {
𝑏1 = 0
𝑏2 = 1
𝑏3 = 1 ⇒ {
𝑐1 = 1
𝑐 02 =
𝑐 13 = [𝜃1]𝜀 = (11
0) [𝜃2]𝜀 = (
0 1
1) [𝜃3]𝜀 = (
1 0
1) Transition matrix 𝑃𝜃→𝜀 = (1 1 01 0 1
0 1 1)
Trang 12REFERENCES
[1] Ma Siu Lun, [2012], Linear Algebra: Concepts and Techniques on Euclidean Spaces, McGrawHill, Singapore
[2] Steven J Leon, [2010], Linear Algebra with Applications Eighth Edition, Pearson Education, Inc, United States of America
[3] Howard Anton, Chris Rorres, [2005], Elementary Linear Algebra: Applications Version Tenth Edition, John Wiley & Son, Inc, USA
[4] [2005] Learning MATLAB 7, The MathWorks, Inc, USA
[5] Cesar P Lopez, [2014], MATLAB Linear Algebra, Apress