Problem Set 1

Question 1

Given Matrix A:

A = matrix(c(1,2,3,4,-1,0,1,3,0,1,-2,1,5,4,-2,-3), nrow=4, byrow=TRUE)
A
##      [,1] [,2] [,3] [,4]
## [1,]    1    2    3    4
## [2,]   -1    0    1    3
## [3,]    0    1   -2    1
## [4,]    5    4   -2   -3

What is the rank of matrix A?

According to Theorum NME8: Nonsingular Matrix Equivalences, the rank of a square matrix of size n is n. So in this case, the rank of A is 4.

dim(A)
## [1] 4 4

Question 2

"Given an MxN matrix, where M > N, what can be the maximum rank and minimum rank? (Assuming that the matrix is non-zero).

For a matrix with more rows than columns (M > N), the maximum rank of the matrix is N.

Because we know that the matrix is non-zero, we know that the minimum rank is 1.

Question 3

Given matrix B:

B = matrix(c(1,2,1,3,6,3,2,4,2), nrow=3, byrow=TRUE)
B
##      [,1] [,2] [,3]
## [1,]    1    2    1
## [2,]    3    6    3
## [3,]    2    4    2

What is the rank of B?

When converting to row echelon form, this matrix has only 1 pivot column. It’s rank is 1.

Problem Set 2

Compute the eigenvalues and eigenvectors of the matrix A.

A = matrix(c(1,2,3,0,4,5,0,0,6), nrow=3, byrow=TRUE)
A
##      [,1] [,2] [,3]
## [1,]    1    2    3
## [2,]    0    4    5
## [3,]    0    0    6

Step One: Solve for characteristic polynomial

A_minus_xI = matrix(c("1-x",2,3,0,"4-x",5,0,0,"6-x"), nrow=3, byrow=TRUE)
A_minus_xI
##      [,1]  [,2]  [,3] 
## [1,] "1-x" "2"   "3"  
## [2,] "0"   "4-x" "5"  
## [3,] "0"   "0"   "6-x"

To solve for the characteristic polynomial, we first need to find the determinant of A-xIn

Because of the placement of zeros in our matrix, solving for the determinant is very simple. We only have to focus on the first column determinant. Therefore, our characteristic polynomial expression is:

(1-x)(4-x)(6-x)

Step Two: Solve for the eigenvalues

The next step is to solve for the eigenvalues, which is also very straightforward. The eigenvalues are the values that cause the characteristic polynomial expression to compute to zero. In other words, the eigenvalues are the roots of the characteristic polynomial. In this case, the eigenvalues are:

x=1, x=4, x=6

Step Three: Solve for eigenvectors

Finally, we need to compute the eigenvectors for each of the eigenvalues. To do this, we substitute our eigenvalue in for x, when creating our A-xIn matrix as we did before. Then we need to reduce A-xIn to its RREF form and solve the system of equations.

Eigenvalue with x=1

A_minus_1In = matrix(c(0,2,3,0,3,5,0,0,5), nrow=3, byrow=TRUE)
A_minus_1In
##      [,1] [,2] [,3]
## [1,]    0    2    3
## [2,]    0    3    5
## [3,]    0    0    5

RREF on A_minus_1In results in the following:

RREF_1 = matrix(c(0,1,0,0,0,1,0,0,0), nrow=3, byrow=TRUE)
RREF_1
##      [,1] [,2] [,3]
## [1,]    0    1    0
## [2,]    0    0    1
## [3,]    0    0    0

From the above we can interpret that x2 must be zero, x3 must be zero, and that x1 can take any value. Thus, our eigenvector can be represented as:

                  [1]
eigenvector_1 = x1[0]
                  [0]

Eigenvalue with x=4

A_minus_4In = matrix(c(-3,2,3,0,0,5,0,0,2), nrow=3, byrow=TRUE)
A_minus_4In
##      [,1] [,2] [,3]
## [1,]   -3    2    3
## [2,]    0    0    5
## [3,]    0    0    2

RREF on A_minus_4In results in the following:

RREF_4 = matrix(c(1,-2/3,0,0,0,1,0,0,0), nrow=3, byrow=TRUE)
RREF_4
##      [,1]       [,2] [,3]
## [1,]    1 -0.6666667    0
## [2,]    0  0.0000000    1
## [3,]    0  0.0000000    0

From the above we can interpret that x1 is equal to two-thirds x2. We can also see that x3 = 0. Thus, our eigenvector can be represented as:

                  [2/3]
eigenvector_4 = x2[1/1]
                  [0/1]

Eigenvalue with x=6

A_minus_6In = matrix(c(-5,2,3,0,-2,5,0,0,0), nrow=3, byrow=TRUE)
A_minus_6In
##      [,1] [,2] [,3]
## [1,]   -5    2    3
## [2,]    0   -2    5
## [3,]    0    0    0

RREF on A_minus_6In results in the following:

RREF_6 = matrix(c(1,0,-8/5,0,1,-5/2,0,0,0), nrow=3, byrow=TRUE)
RREF_6
##      [,1] [,2] [,3]
## [1,]    1    0 -1.6
## [2,]    0    1 -2.5
## [3,]    0    0  0.0

From the above we can interpret that x1 is -1.6 times x3. We can also see that x2 is -2.5 times x3. X3 can take any value. Thus, our eigenvector can be represented as

                  [1.6]
eigenvector_6 = x3[2.5]
                  [1.0]

8/5