Bachelor in Statistics and Business Universidad Carlos III de Madrid Mathematical Methods II María Barbero Liñán Homework sheet : MATRICES AND DETERMINANTS (with solutions Year 0-0 Let 0 7 5 A =, B =, C = ( 4 5 4 3 3 5 5 D =, E = 4 3, Compute each of the following matrix sum or product if it is defined If an expression is undefined, explain why -A (b B-A (c AC (d CD (e A+B (f 3C-E (g CB (h EB 4 0 3 5 3 Solution: A = (b B A = 8 0 4 7 6 7 (c The product AC is not possible because, for instance, C should be of size 3, not The number of columns of the first matrix must match the number of rows in the second matrix so that( the product is possible 3 6 0 (d CD = (e A + B = 7 6 6 3 4 (f The operation ( 3C E is not possible because the matrices have different size 9 3 5 (g CB = 3 6 5 (h The product EB is not possible because, for instance, E should have columns 4 Let A = Compute 3I 5 A and (3I A 3 Solution: 3I A = and (3I 5 5 A = 5 6 3 Compute the following products AB in two ways: ( by the definition, where Ab and Ab are computed separately, and ( by the row-column rule for computing AB 3 4 A = 5 0, B = (b A = 5 4, B = 3 3 3
( ( 3 Solution: ( AB = A, A (b ( AB = ( ( 3 A, A = 5 5 5 5 = 5 5 ( AB = 5 5 3 3 7 4 7 4 7 6 ( AB = 7 6 7 7 4 If a matrix A is 5 3 and the product AB is 5 7, what is the size of B? Solution: The matrix B has size 3 7, that is, B M 3 7 5 How many rows does B have if BC is a 3 4 matrix? Solution: The matrix B must have three rows 3 4 7 4 6 Let A = y B = What value(s of k, if any, will make 5 5 k AB = BA? Solution: For k = 9 7 Let A = yet B C ( 3 4 6, B = 8 4, C = 5 5 5 Verify that AB = AC and 3 7 Solution: AB = = AC, even though B C 4 6 8 Let A = Find a matrix B, whose both columns are different 3 from zero, and such that AB = 0 3c 3d Solution: B = for c, d R {0} c d 9 Let A be a m p matrix and B be a p n matrix If the first and third rows of A are equal, what can you say about the rows of AB? Why? (b If the second column of B is zero, what can you say about the second column of AB? Why? (c If the third column of B is the sum of the first two columns, what can you say about the third column of AB? Why? Solution: The first and the third rows of AB are equal because they are computed as follows: a B and a 3 B where a i denotes the i-th row of A As a = a 3, we have a B = a 3 B (bthe second column of AB is zero because it is computed as Ab = A0 = 0, where b is the second column of B (c The third column of AB is the sum of the first two columns of AB, because the third column of AB is computed as follows Ab 3 = A(b +b = Ab +Ab, where b i is the i-th column of B
0 If A = ( 5 y AB =, determine the first and second 6 9 3 columns of B ( 7 Solution: The first column of B is and the second column of B is 4 a Let u = 3 and v = b 4 c Compute u T v, v T u, uv T and vu T 8 5 (b If u, v IR n, how are u T v and v T u related? How are uv T and vu T related? a b c Solution: u T v = a + 3b 4c, v T u = a + 3b 4c, uv T = 3a 3b 3c and 4a 4b 4c a 3a 4a vu T = b 3b 4b c 3c 4c (b u T v = v T u and uv T = (vu T T Find the inverses of the matrices: ( 8 6 3, (b 5 4 7 4 8 5, (c 7 5 3 Solution: (b (c 5/ 4 7/ 3/ 7/5 8/5 4 5 3 Find the inverse of the matrix and use it to solve the system: 5 6 4x 5x = 3, 5x + 6x = 6 5 Solution: The inverse is We solve the system by using the inverse as follows 5 4 x 6 5 3 3 = = x 5 4 4 Let [ ] [ 5 3 A =, b 3 8 = ], b = [ Find A, and use it to solve the four equations ], b 3 = [ 4 Ax = b, Ax = b, Ax = b 3, Ax = b 4 ], b 4 = [ ] 3
(b The four equations in part can be solved by the same set of row operations, since the coefficient matrix is the same in each case Solve the four equations in part by row reducing the augmented matrix [A b b b 3 b 4 ] 8 3 Solution: A = Each of the columns of the following matrix correspond 3 5 with the solution of the above four equations: A ( 9 6 5 b b b 3 b 4 = 8 (b By row elementary operations we have: 5 3 4 3 8 0 9 6 5 0 8 5 Find the inverses of the matrices 4 3 5 0 A = 7 6, B = 7 6, 7 3 4 if they exist 8 3 3 Solution: A = 0 The matrix B does not have inverse because its determinant is zero or because by row elementary operations from 7 3 B I 3 we cannot recover the identity matrix in the first half of the matrix Instead we obtain a row of zeroes a b 6 Let A = c d Show that if ad bc = 0, then the equation Ax = 0 has more than one solution Why does this imply that A is not invertible? (Hint: First, ( consider a = b = 0 b Then, if a and b are not both zero, consider the vector x = a (b Find a formula for A if ad bc 0 0 0 0 Solution: If a = b = 0, the system has one free variable Hence the system c d 0 b 0 has more than one solution If a and b are non zero, note that A = Thus the system a 0 Ax = 0 has a non trivial solution Thus Ax ( = 0 has more than one solution (b If ad bc 0, then A d b = = d b ad bc c a det A c a 5 7 7 Let A = 5 6 Determine the second column of A without computing 3 4 the other columns 4
Solution: 3 8 Assume that the matrices are partitioned conformably for block multiplication Compute the products shown: I 0 A B E I C D E 0 A B (b 0 F C D 0 I W X (c I 0 Y Z I 0 A B (d X I C D A B EA EB Y Z Solution: (b (c ( EA + C EB + D F C F D W X A B (d AX + C BX + D 9 Find formulas for X, Y, Z in terms of A, B and C in the following equalities: A B I 0 0 I = C 0 X Y Z 0 Z X 0 0 (b A 0 0 I 0 = Y 0 I 0 I B I Solution: Assuming that B is invertible, Z = C, Y = B, X = B A (b Assuming that A is invertible, X = A, Y = BA, Z = 0 I 0 0 I 0 0 0 The inverse of C I 0 is Z I 0 Find X, Y and Z A B I X Y I I 0 0 I 0 0 I 0 0 Solution: From the equation C I 0 Z I 0 = 0 I 0, we have Z = C, A B I X Y I 0 0 I Y = B, X = A + BC Find an LU factorization of the matrices: 5 3 4 A = 0 8 9, B = 5 4 5 3 7 9 3 4 6 7 5 6 6, C = 4 5 7 3 5 6 4 8 8 3 9
5 3 4 0 0 Solution: For A, U = 0, L = 0 0 0 9 3 5 0 0 0 4 5 For B, U = 0 5 6, L = 3 0 0 0 0 0 0 0 6 6 0 0 0 0 0 7 5 For C, U = 0 0 0 0 0 0, L = 0 0 0 3/ 0 0 3 0 0 0 0 0 4 3 0 0 Solve the equation Ax = b by using the LU factorization given for A 3 7 7 A = 3 5, b = 5 6 4 0 0 0 3 7 A = 0 0 5 0 0 4 3 5 (b A = 4 5 7, b = 4 8 6 8 6 0 0 4 3 5 A = 0 0 0 0 0 (c A = 6 0, b = 0 8 5 4 0 0 A = 3 0 0 3 4 4 0 0 3 /4 Solution: 4 (b (c 3 6 3 3 Compute the following determinants: 0 5 4 3 0 4, (b 3 5 3 4, (c 5 0 0 3 0 6 7 5 5 0 4 4 Solution: (b 0 (c 6 6
4 Compute the following elementary matrices and identify them with a row operation when they multiply a matrix 0 0 0 0 k 0, (b 0 0 0 k 0 0 0, (c 0 0 0 0 0 0 Solution: (b k (c a b 5 Let A = a matrix and a real number α Find a formula that c d relates det [α A] with α and det A Solution: det (αa = α det A 6 Find the determinants by row reduction to echelon form: 5 3 3 3 4 3 3 3 3 7, (b 0 5 5 4 3 3 7 5 Solution: 8 (b 0 7 Combine the methods of row reduction and cofactor expansion to compute the following determinants: 3 0 3 4 3 4 3 0 5 4 6 6 (b 3 0 3 3 4 8 4 4 3 3 4 0 4 Solution: 4 (b 0 8 Find the following determinants where a + d b + e c + f d e f g h i, (b g h i a b c d e f a b c d e f g h i, = 7 (c a b c 3d 3e 3f g h i Solution: 7 (b 7 (c 9 Let A be a n n square matrix If A is invertible, then show that det A = det A (b If α is a real number, find a formula for det (α A 7
(c Let B be also a n n square matrix Show that det (A B = det (B A, even though, in general, A B B A (d If P is a n n square invertible matrix Show that det (P A P = det A (e Let U be a n n square matrix such that U T U = I Show that det U = ± (f If det A 4 = 0, is A invertible? Solution: As AA = I n, after taking determinants det (AA = det AdetA = Thus deta = det A (b det(αa = α n det A (c det(ab = detadetb = detbdeta = det(ba because real numbers commute (d det(p AP = detp detadet(p = detadetp det(p = detadet(p P = detadeti = deta (e = det(u T U = detu T detu = detudetu = (detu Then detu = ± (f 0 = det(a 4 = (deta 4 Equivalently, deta = 0 Thus A is not invertible 30 Let A and B be 3 3 matrices, with det A = 4 and det B = 3 Use properties of determinants to compute: det (A B (b det (A (c det (5 A (d det (A 3 (e det (B T Solution: (b /4 (c 500 (d 64 (e 3 3 Use Cramer s rule to compute the solutions of the following systems: { x 4x +x = 6, +x +x 3 = 4, (b x 5x +x = 7 +x 3 =, 3x +x +3x 3 = Solution: (x, x = 5 3, (b (x, x, x 3 = ( 4, 3, 3 3 Use determinants to decide if the following matrices are invertible or not Compute the adjugate of the given matrix and give the inverse of the matrix, whenever is possible: 5 0 3, 0 5 3 3 (b, 0 0 Solution: It is not invertible because the determinant is zero (b 3 7 5 3 8 0 0 5 (c 3 5 4 4 3 6 3 6 7 (c 0 3 4 8
Additional exercises: D C Lay Linear algebra and its applications, 0 Sections -5 for matrices Sections 3-33 for determinants 9