Docsity

Linear Algebra Homework: Row Reduced Echelon Form, Column Space, and Null Space, Assignments of Linear Algebra

Toggle sidebar
bg1
Homework Solutions Section 3.6
>with(linalg):
Warning, the protected names norm and trace have been redefined and
unprotected
1 Problem 1
1.1 Problem 1a)
>A := array(1..3,1..3,[[1,3,2],[2,1,4],[4,7,8]]);
A:=
132
214
478
1.1.1 Row Space
Find row reduced echelon form of A:
>gaussjord(A);
102
010
000
>rowspace(A);
{[1,0,2],[0,1,0]}
1.1.2 Column Space
>gaussjord(transpose(A));
102
011
000
>colspace(A);
{[0,1,1],[1,0,2]}
1.1.3 Null Space
>zero := array(1..3,1..1,[[0],[0],[0]]);
zero :=
0
0
0
>linsolve(A,zero);
−2t11
0
t11
>nullspace(A);
{[−2,0,1]}
pf3
pf4
pf5

Partial preview of the text

Download Linear Algebra Homework: Row Reduced Echelon Form, Column Space, and Null Space and more Assignments Linear Algebra in PDF only on Docsity!

Homework Solutions Section 3.

(^) with(linalg):

Warning, the protected names norm and trace have been redefined and unprotected

1 Problem 1

1.1 Problem 1a)

(^) A := array(1..3,1..3,[[1,3,2],[2,1,4],[4,7,8]]);

A :=

1.1.1 Row Space

Find row reduced echelon form of A:

(^) gaussjord(A);  

(^) rowspace(A); {[1, 0 , 2], [0, 1 , 0]}

1.1.2 Column Space

(^) gaussjord(transpose(A));  

(^) colspace(A); {[0, 1 , 1], [1, 0 , 2]} 1.1.3 Null Space (^) zero := array(1..3,1..1,[[0],[0],[0]]);

zero :=

(^) linsolve(A,zero);  

− 2 t 11 0 t 11

(^) nullspace(A); {[− 2 , 0 , 1]}

1.2 Problem 1b)

(^) A := array(1..3,1..4,[[-3,1,3,4],[1,2,-1,-2],[-3,8,4,2]]);

A :=

1.2.1 Row Space

(^) gaussjord(A);       1 0 0

(^) rowspace(A);

{[0, 0 , 1 , 0],

[

]

[

]

1.2.2 Column Space

(^) gaussjord(transpose(A));    

(^) colspace(A); {[0, 0 , 1], [1, 0 , 0], [0, 1 , 0]} 1.2.3 Null Space (^) linsolve(A,zero);         10 7 t 11

2 7

t 11

0 t 11

(^) nullspace(A);

{

[

]

1.3 Problem 1c

(^) A := array(1..3,1..4,[[1,3,-2,1],[2,1,3,2],[3,4,5,6]]);

A :=

1.3.1 Row Space

(^) gaussjord(A);

Free variables are the {2,4,5}, Lead variables are {1,3,6}

(^) A1 := submatrix(A,1..3,[1,3,6]);

A1 :=

(^) linsolve(A1,submatrix(A,1..3,2..2));  

column 2 = 2*column 1

(^) linsolve(A1,submatrix(A,1..3,4..4));  

column 4 = 5*column 1 - column 3

(^) linsolve(A1,submatrix(A,1..3,5..5));  

column 5 = -3column 1 + 2column 3

2.2 Problem 3b

Lead variables are columns {1,3,6} Solution to this part is same as in a)

3 Problem 4

3.1 Problem 4a)

(^) A := array(1..2,1..2,[[1,2],[2,4]]); (^) b := array(1..2,1..1,[[4],[8]]);

A :=

[

]

b :=

[

]

(^) gaussjord(augment(A,b)); [ 1 2 4 0 0 0

]

infinitely many solutions, so equation is consistent b = 4column 1 = 2column 2

3.2 Problem 4b)

(^) A := array(1..2,1..2,[[3,6],[1,2]]); (^) b := array(1..2,1..1,[[1],[1]]);

A :=

[

]

b :=

[

]

(^) gaussjord(augment(A,b)); [ 1 2 0 0 0 1

]

No solution, hence equations are inconsistent

3.3 Problem 4c)

(^) A := array(1..2,1..2,[[2,1],[3,4]]); (^) b := array(1..2,1..1,[[4],[6]]);

A :=

[

]

b :=

[

]

(^) gaussjord(augment(A,b)); [ 1 0 2 0 1 0

]

unique solution, hence consistent

3.4 Problem 4d)

(^) A := array(1..3,1..3,[[1,1,2],[1,1,2],[1,1,2]]); (^) b := array(1..3,1..1,[[1],[2],[3]]);

A :=

b :=

(^) gaussjord(augment(A,b));

 

no solution, hence inconsistent (note second row!)

6 Problem 7

6.1 Problem 7a)

If A is an mxn matrix with m>n, and N(A)={ 0 } (which means the nullspace has dimension zero), then the rank = n-0 = n Since the dimension of the column space and the rowspace are the same, the dimension of the column space = n = # of columns. This means they are linearly independent. The column vectors can not span Rmsince m > n. Fewer than m vectors cannot span Rm

6.2 Problem 7b)

If b is not in the column space of A, then Ax=b can not have any solution! If b is in the column space, the solution must be unique, since N(A)={ 0 }. If there were two solutions, the difference would be in the nullspace of A...

7 Problem 15

7.1 Problem 15a)

If Ax=Bx for all x in Rn then (A-B)x=0 for all x in Rn This means that the null space is all of Rn which means that N(A-B)= Rn

7.2 Problem 15b)

Consequenlty, since rank(A-B)=0, A-B must be the zero matrix (since it is the only matrix with rank 0! Therefore A=B