Lecture 12 Math 221 

Linearly Independent and Basis for Subspaces 

 

We want to return to the model of the water towers that we look at in the previous lecture.   

At the end of the lecture we found that the span of a set of vectors formed a subspace of a vector space and since  

Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi( Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi( = Typesetting:-mrow(Typesetting:-mi( + Typesetting:-mrow(Typesetting:-mi( + Typesetting:-mrow(Typesetting:-mi( = Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi(
where the column matrix Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi( was a representation for the possible changes in the levels of the different tubs from hour k to hour k+1.  This means that all possible changes are in the subspace
 

span by the column matrices or vectors 

span{Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi(, Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi(,Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi(}  but we also learned that any change in the levels of the tubs could be written as a linear combination  Typesetting:-mrow(Typesetting:-mi( which by what we just learned say that  

the differences also are in the subspace defined by  

span{Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi(.Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi(} .  So do we have different subspace or are they the same subspace with different 

representations.   One way to check is to show that one set of spanning vectors can be written as a linear combination of the other set of spanning vectors.  How will we do this?  

You have all the tools necessary for the task and this can be done by looking systems of equations and seeing if you have a solution.  

 

 

> with(LinearAlgebra):
 

> A:=<<1,0,-1>|<0,1,-1>>;
 

`:=`(A, Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mtable(Typesetting:-mtr(Typesetting:-mtd(Typesetting:-mn(
 

> x:=<<a1,b1>>;
 

`:=`(x, Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mtable(Typesetting:-mtr(Typesetting:-mtd(Typesetting:-mi(
 

> A.x;
 

Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mtable(Typesetting:-mtr(Typesetting:-mtd(Typesetting:-mi(
 

> c1:=<<-1,1/2,1/2>>;
 

`:=`(c1, Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mtable(Typesetting:-mtr(Typesetting:-mtd(Typesetting:-mrow(Typesetting:-mo(
 

> BackwardSubstitute(GaussianElimination(<A|c1>));
 

Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mtable(Typesetting:-mtr(Typesetting:-mtd(Typesetting:-mrow(Typesetting:-mo(
 

This tells us that  

Typesetting:-mrow(Typesetting:-mi( +1/2 Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi( = Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi(  so the first column of our coefficient matrix is in the span of the  

vectors Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi( and Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi( .  Lets look at the other two 

 

 

> c2:=<1,-1,0>;
 

`:=`(c2, Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mtable(Typesetting:-mtr(Typesetting:-mtd(Typesetting:-mn(
 

> BackwardSubstitute(GaussianElimination(<A|c2>));
 

Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mtable(Typesetting:-mtr(Typesetting:-mtd(Typesetting:-mn(
 

So if we take 1 times the first vector and -1 times the second vector we arrive at the vector 

Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi(  

Finally we can show that the third vector is a linear combination of the vectors we have been using. 

 

The last vector was common to both sets so we do not have to solve for it.   

 

What does all this mean.  We need a new definition before we go further.   

Definition 2.13  
A set of m vectors {Typesetting:-mrow(Typesetting:-mi(,...,Typesetting:-mrow(Typesetting:-msub(Typesetting:-mi(} is called a
linearly independent set of vectors if the equation  

Typesetting:-mrow(Typesetting:-mi( + . . . + Typesetting:-mrow(Typesetting:-mi(  

implies that all Typesetting:-mrow(Typesetting:-mi(, j = 1,2, . . . , m.  In other words, the only solution (unique solution) is  

Typesetting:-mrow(Typesetting:-mi(= . . . = Typesetting:-mrow(Typesetting:-mi(.  When referencing a set of linearly independent vectors, the word " linearly" is often dropped and the vectors are call an independent set of vectors.  If the above equation holds with at least one nonzero scalar, Typesetting:-mrow(Typesetting:-msub(Typesetting:-mi(, then the set is called a linearly dependent set of vectors.  Again this is often referred to as a dependent set of vectors.  Let us return to our set of vectors from our model problem  

 

> c[1]:=<-1,1/2,1/2>;
 

`:=`(c[Typesetting:-mn(
 

> c[2]:=<1,-1,0>;
 

`:=`(c[Typesetting:-mn(
 

> c[3]:=<0,1,-1>;
 

`:=`(c[Typesetting:-mn(
 

> z:=<0,0,0>;
 

`:=`(z, Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mtable(Typesetting:-mtr(Typesetting:-mtd(Typesetting:-mn(
 

> BackwardSubstitute(GaussianElimination(<c[1]|c[2]|c[3]|z>));
 

Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mtable(Typesetting:-mtr(Typesetting:-mtd(Typesetting:-mrow(Typesetting:-mn(
 

Since there is a solution other than ther zero solution they are linearly dependent.   It also tells us that one of the vectors can be written as a linear combination of the other two since there is one parameter.  

 

Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi( = Typesetting:-mrow(Typesetting:-mi( so here we are going to select a value for the parameter and the value 

I selected was one. i.e. _Typesetting:-mrow(Typesetting:-msub(Typesetting:-mi(=1 and solve for the last vector in therms of the other two.   

 

This tell us that they are linearly dependent and that we can solve one of the vectors in terms of the other two.  We could have selected the second or the first but because of the placement of the 2 in the solution vector I decided to solve for the third vector in terms of the first and second. 

 

Consider now the vectors 

 

Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi( and Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi(.  Are they linearly independent or linearly dependent? 

 

We should be able to see this right off hand since  

Typesetting:-mrow(Typesetting:-mi( = Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi(  gives Typesetting:-mrow(Typesetting:-mi( from the first equation and Typesetting:-mrow(Typesetting:-mi( from the second equation.   We now have a little better idea of what is going on with the two spanning sets.  The first spanning set was not linearly independent while the second one was.   What would happen if we used only the first and third columns from the original set of vectors.   

Typesetting:-mrow(Typesetting:-mi( + Typesetting:-mrow(Typesetting:-mi( = Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi(  and again we have that Typesetting:-mrow(Typesetting:-mi( by looking at the third equation  

which then tells us that Typesetting:-mrow(Typesetting:-mi(  So they are linearly independent.   

We could look at the second and third and the first and third.  They would also be linearly independent.  The question is would they span the set.   Let us know look at showing that the vectors  Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi( and Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi( are in the span{Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi(,Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi(} .  You can also avoid the paramters once you know the vectors are linearly dependent by leaving off the z vector.  This makes it easier to see the linear combination.    

 

 

> <c[1]|c[3]|c[2]>;
 

Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mtable(Typesetting:-mtr(Typesetting:-mtd(Typesetting:-mrow(Typesetting:-mo(
 

> BackwardSubstitute(GaussianElimination(%));
 

Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mtable(Typesetting:-mtr(Typesetting:-mtd(Typesetting:-mrow(Typesetting:-mo(
 

> -1*c[1]+(-1/2)*c[3];
 

Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mtable(Typesetting:-mtr(Typesetting:-mtd(Typesetting:-mn( (1.1)
 

We see that the second vector is the same in both sets so they span the same set.   

 

This leads to a new definition 

Definition 2.20  A set of vectors {Typesetting:-mrow(Typesetting:-mi(, . . . , Typesetting:-mrow(Typesetting:-msub(Typesetting:-mi(} is call a basis for a space S if and only if  

S = { z | z = Typesetting:-mrow(Typesetting:-mi( + . . . + Typesetting:-mrow(Typesetting:-mi(}  

and the set of vectors {Typesetting:-mrow(Typesetting:-mi(, . . . , Typesetting:-mrow(Typesetting:-mi(| is an independent set.  Since it takes m vectors to describe  

S, the space S is said to have dimension m.  This is denotes dim(S) = m.   

 

We have learned that the dimension of the subspace of possible difference of our water tower system 

from hour k to hour k+1 was of  dimension two and we found several different basis for the subspace.  A basis for a space is not unique but the number of elements in the basis is unique.   Being of dimension 2 does not means that the subspace in in two space only that it is a subspace of three space of dimension 2.   

 

Can you give a set of basis elements for Typesetting:-mrow(Typesetting:-mi(
 

Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi( and Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi( will work.   

 

How about the vectors Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi( and Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi(.    Is the second set linearly independent? 

 

Just look at the determinant of the matrix Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi( .  Since the determinant is not zero what does this tell us about the vectors being linearly independent?    Why are they also a basis for Typesetting:-mrow(Typesetting:-mi(
What does this mean from a geometric point of view.  Graph the vectors.  Then draw a straight line through the oigion in both directions.  What appears to happen?  Think rotation.  Also look at the lenght of each vector.  Remember you will need the command norm(v,2) for the lenght of vector v.   Are the vectors perpendicular?
 

 

How about the two vectors Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi( and Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi(.  Are they a basis for Typesetting:-mrow(Typesetting:-msup(Typesetting:-mi(?  Why?   Again try graphing the vectors.  Are they unit vectors?  Can you derive a set of unit vectors from the above?  You should do this.  Are vectors perpendicular?    

 

We will do a few more examples of independent and dependent sets.  

 

span{Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi(, Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi(, Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi(}   

 

> ca[1]:=<-2,0,1>; ca[2]:=<1,-1,2>; ca[3]:=<4,-2,3>;
 

 

 

`:=`(ca[Typesetting:-mn(
`:=`(ca[Typesetting:-mn(
`:=`(ca[3], Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mtable(Typesetting:-mtr(Typesetting:-mtd(Typesetting:-mn(
 

> Ca:=<ca[1]|ca[2]|ca[3]>;
 

`:=`(Ca, Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mtable(Typesetting:-mtr(Typesetting:-mtd(Typesetting:-mrow(Typesetting:-mo( (1.2)
 

> BackwardSubstitute(GaussianElimination(<Ca|z>));
 

Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mtable(Typesetting:-mtr(Typesetting:-mtd(Typesetting:-msub(Typesetting:-mi(
 

They are thus linearly dependent and we know how to write one as a linear combination of the other two 

Can you find a basis for this subspace?   

 

 

> <ca[1]|ca[2]>;
 

Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mtable(Typesetting:-mtr(Typesetting:-mtd(Typesetting:-mrow(Typesetting:-mo(
 

> BackwardSubstitute(GaussianElimination(<%|z>));
 

Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mtable(Typesetting:-mtr(Typesetting:-mtd(Typesetting:-mn(
 

So we have a basis and the subspace is of dimension 2.  Try to find a second basis for this subspace. 

 

Can you find a third vector that will expand this to a basis for all of Typesetting:-mrow(Typesetting:-mi(. 

 

Let us try the vector Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi(
 

> <<ca[1]|ca[2]|<0,0,1>>>;
 

Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mtable(Typesetting:-mtr(Typesetting:-mtd(Typesetting:-mrow(Typesetting:-mo(
 

> Determinant(%);
 

2
 

This was very obvious from the start after we added the vector so we have now started with a set of vectors that span a subspace of Typesetting:-mrow(Typesetting:-msup(Typesetting:-mi(of dimension 2 and added a vector to the set and found that 

they are linearly independent.  These three vectors must be a basis for Typesetting:-mrow(Typesetting:-mi(why?   Think of how many vectors in a basis for Typesetting:-mrow(Typesetting:-msup(Typesetting:-mi(.  You know a standard basis.   Consider the vectors [1,0,0],[0,1,0],[0,0,1].  Do they span the space and are the linearly independent?   

 

Consider now three different vectors 

 

Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi(, Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi(, and Typesetting:-mrow(Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mi(.  Are they linearly independent or linearly dependent.  

 

 

>
 

> E:=<<1,0,-1>|<0,1,2>|<1,1,3>>;
 

`:=`(E, Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mtable(Typesetting:-mtr(Typesetting:-mtd(Typesetting:-mn(
 

> Determinant(E);
 

2
 

> BackwardSubstitute(GaussianElimination(<E|z>));
 

Typesetting:-mfenced(Typesetting:-mrow(Typesetting:-mtable(Typesetting:-mtr(Typesetting:-mtd(Typesetting:-mn(
 

Are these three vectors a basis for Typesetting:-mrow(Typesetting:-mi(?  You really only need to know if they are linearly independent since three linearly independent vectors in Typesetting:-mrow(Typesetting:-msup(Typesetting:-mi( must be a basis.   

 

 

Exercises Section 2.2 

Problems due on October 15, 2008 .     

Exercise 2.2.1, Exercise 2.2.3 (a), (b),(c), Exercise 2.2.7, Exercise 2.2.8, Exercise 2.2.9, Exercise 2.2.12 (b),(c) 

>