Professional Documents
Culture Documents
LINEAR ALGEBRA
Project - Class CC11
June, 2021
CONTENTS
INTRODUCTION
PROBLEM
REFERENCES
INTRODUCTION
This report is a list of 3 problems that have been designed to understand
linear algebra in combination with Matlab programs that are customarily designed
to solve the problems
Problem 2: Write a program to input any number of vector in R n and return the
orthogonal basis and orthonormal basis of the subspace spanned by these vectors.
(Use Gram - Schmidt process)
A vector operation that allows us to define length and angle for vectors in
an arbitrary vector space. This operation is called the “inner product between two
vectors”, and is a generalization of the dot product that was introduced in the
Matrices lecture.
〈·,·〉:V ×V →R
(x, y) −→ 〈x, y〉− which is called inner product of 2 vectors.
The following 4 axioms are satisfied
1.〈x,y〉=〈y,x〉, ∀x,y ∈V
2.〈x + y, z〉 = 〈x, z〉 + 〈y, z〉, ∀x, y, z ∈ V
Let f : U → V be a linear transformation. Let E = {e 1, e2, ..., en} and F = {f1, f2,
..., fm} be bases of U and V , respectively.An m × n matrix whose the i -th column
is the coordinate vector of f (ei ) with respect to the basis F is called the
transformation matrix of f with respect to E,F. Denote:
AEF =F−1.f(E)
AE =E−1.f(E)
2. Solve in matlab
Ex 1: Plan (P): x - 2y + 5z = 4
Answer the question:
Ex 2: Plan (P): 9x + 2y - z = -3
1. Theory
2.1.1 Introduction
Orthogonality can help us sove the problem of checking whether the angle
𝜋
between vectos is 2 . Accordingly, we make the following definition which is
applicable even if one or both of the vectorss is zero.
〈u,v〉
proju(v) = 〈u,u〉
where 〈u, v〉 denotes the inner product of the vectors u and v. This operator projects
the vector v orthogonally onto the line spanned by vector u
uk
uk = Vk - ∑𝑘−1
𝑗=1 proju(vk) ek = ‖uk‖
1. f1 = e1
(𝑒2,𝑓1)
2. f2=e2 − prf (e2)=e2− (𝑓1,𝑓1) f1
(𝑒3,𝑓1) (𝑒3,𝑓2)
3. f3=e3−prf (e3)−prf (e3)=e3− (𝑓1,𝑓1) f1− (𝑓2,𝑓2) f2
4. fn = en − prf1 (en) − prf2 (en) − ...prfn−1 (en)
2. Solve in matlab
Problem : Write a program to input any number of vector in R n and return the
orthogonal basis and orthonormal basis of the subspace spanned by these vectors.
(Use Gram - Schmidt process)
Explain: the codes have one biggest con that is it is unable to generate a set of
orthogonal or orthonormal vectors if the matrix has LD vectors. Therefore, the user
has to choose a matrix that its rank equals to the number of vectors.
Ex 1(Square matrix) : 3 vectors (1, 3, 5), (7, 9, 11), (13, 17, 19)
In real arithmetic every nonzero number a has a reciprocal A−1(= 1/A) with
the property A.A−1 = A−1.A= 1
The number A−1 is sometimes called the multiplicative inverse of A. Our next
objective is to develop an analog of this result for matrix arithmetic. For this purpose
we make the following definition.
one another.
1. A is invertible
2. A ⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗
Elementary Row Operations I n
3. r(A) = n
Inversion Algorithm:
(A|I) ⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗
Elementary Row Operations (I|A ) En.En-1.....E2E1.A = I -1
-1
⇒ A = En.En-1.....E2E1.
Suppose that A,B are 2 invertible matrices of order n. We have :
2. Solve in matlab
Problem : Write a program to find the inverse of a given matrix
Explain:
8=>9: If matrix cannot inverse => Print “ not invertable “ on the screen