Sec 3.6 Determinants Sec 3.6 Determinants Recall from section 3.5 : TH2: the invers of 2x2 matrix 1 d b A det c a det ad bc a b A c d Sec 3.6 Determinants 2x2 matrix Example Evaluate the determinant of 3 5 A 1 2 3 5 (3)( 2) (5)(1) 6 5 1 det A 1 2 How to compute the Higher-order determinants 1 2 1 det B 3 5 1 4 0 2 1 0 det C 0 1 1 0 1 1 0 1 0 1 0 1 1 1 1 1 0 0 0 1 1 0 1 Sec 3.6 Determinants Def: Minors Let A =[aij] be an nxn matrix . The ijth minor of A ( or the minor of aij) is the determinant Mij of the (n-1)x(n-1) submatrix after you delete the ith row and the jth column of A. Example Find 1 0 2 A 4 3 1 3 5 1 M 23 , M 32 , M 33 , Sec 3.6 Determinants Def: Cofactors Let A =[aij] be an nxn matrix . The ijth cofactor of A ( or the cofactor of aij) is defined to be Aij (1)i j M ij Example Find 1 0 2 A 4 3 1 3 5 1 A23 , A32 , A33 , signs Sec 3.6 Determinants 3x3 matrix signs a11 a12 a21 a22 a31 a32 a13 a23 a11 A11 a12 A12 a13 A13 a33 a11M 11 a12 M 12 a13M 13 Example Find det A 1 0 2 A 4 3 1 3 5 1 Sec 3.6 Determinants The cofactor expansion of det A along the first row of A a11 a12 a21 a22 a31 a32 Note: 3x3 determinant 4x4 determinant 5x5 determinant nxn determinant a13 a23 a11 A11 a12 A12 a13 A13 a33 expressed in terms of expressed in terms of expressed in terms of expressed in terms of three 2x2 determinants four 3x3 determinants five 4x4 determinants n determinants of size (n-1)x(n-1) Sec 3.6 Determinants nxn matrix det A a11 A11 a12 A12 a1n A1n We multiply each element by its cofactor ( in the first row) Also we can choose any row or column Th1: the det of an nxn matrix can be obtained Example 0 2 0 1 A 7 4 6 2 0 3 0 0 3 5 2 4 by expansion along any row or column. i-th row det A ai1 Ai1 ai 2 Ai 2 ain Ain j-th column det A a1 j A1 j a2 j A2 j anj Anj Row and Column Properties Prop 1: interchanging two rows (or columns) Example 0 2 0 1 A 7 4 6 2 0 3 0 0 3 5 2 4 2 3 0 0 B 7 5 6 4 0 0 0 1 3 4 2 2 det A det B Example 0 2 0 1 A 7 4 6 2 0 3 0 0 3 5 2 4 det A det C 6 2 0 1 C 7 4 0 2 0 3 2 0 3 4 0 5 Row and Column Properties Prop 2: two rows (or columns) are identical 2 3 0 1 B 7 5 6 4 Example Example 0 3 0 1 3 5 2 4 6 2 0 1 C 7 4 6 2 2 4 0 0 3 5 2 4 det B 0 det C 0 Row and Column Properties Prop 3: Example (k) i-th row + j-th row 0 2 0 1 A 7 4 6 2 0 3 0 0 3 5 2 4 (k) i-th col + j-th col 0 2 0 1 B 7 4 6 2 0 3 0 2 3 13 2 8 det A det B Example 0 2 0 1 A 7 4 6 2 0 3 0 0 3 5 2 4 det A det C 2 0 0 1 C 7 4 2 2 0 3 0 0 3 5 2 8 Row and Column Properties Prop 4: Example (k) i-th row 0 2 0 1 A 7 4 6 2 0 3 0 0 3 5 2 4 (k) i-th col 0 2 0 5 B 7 20 6 10 0 3 0 0 3 5 2 4 det B (5) det A Example 0 2 0 1 A 7 4 6 2 0 3 0 0 3 5 2 4 det C (3) det A 0 2 0 1 C 7 4 18 6 0 3 0 0 3 5 6 12 Row and Column Properties Prop 5: i-th row B = i-th row A1 + i-th row A2 Example 0 2 0 1 B 7 4 18 6 0 3 0 0 3 5 6 12 0 2 0 1 A1 7 4 12 4 0 3 0 0 3 5 4 10 0 2 0 1 A2 7 4 6 2 0 3 0 0 3 5 2 2 det B det A1 det A2 Prop 5: i-th col B = i-th col A1 + i-th col A2 Row and Column Properties upper tria ngular matrix 2 2 0 1 A 0 0 0 0 lower tria ngular matrix 1 3 2 9 3 5 0 4 Zeros below main diagonal Prop 6: Example 2 0 2 1 A 1 3 9 7 0 0 0 0 3 0 4 4 triangular matrix Either upper or lower Zeros above main diagonal det( triangular ) = product of diagonal 2 2 0 1 A 0 0 0 0 1 3 2 9 3 5 0 4 Row and Column Properties Example 2 2 1 1 A 1 6 0 0 1 3 2 9 3 5 0 4 Transpose Transpose of a matrix A [aij ] Prop 6: Example AT [a ji ] 1 2 3 A 4 5 6 7 8 9 1 4 7 AT 2 5 8 3 6 9 det( matrix ) = det( transpose) 1 2 3 A 4 5 6 7 8 9 1 4 7 B 2 5 8 3 6 9 det A det B Transpose A A cAT cAT T T A B T AB T A B T B T AT T Determinant and invertibility THM 2: The nxn matrix A is invertible 1 3 2 9 0 5 0 4 Example : find A -1 2 2 0 1 A 0 0 0 0 Example : find A -1 2 3 2 3 1 1 1 9 A 2 6 2 5 6 4 6 4 detA = 0 Theorem7:(p193) A row equivalent I Every n-vector b Ax = b det( A) 0 has unique sol A Invertible A Every n-vector b is a product of elementary matrices Ax = b is consistent The system Ax = 0 has only the trivial sol A nonsingular Determinant and inevitability THM 2: det ( A B ) = det A * det B AB A B Note: A 1 1 A Proof: Example: compute 1 0 1 1 A 2 6 6 4 0 0 0 0 2 0 6 1 A 1 Cramer’s Rule (solve linear system) Solve the system a11x1 a12 x2 a13 x3 a1n xn b1 (eq 1) a 21x1 a 22 x2 a 23 x3 a 2n xn b1 (eq 2) a n1x1 a n2 x2 a n3 x3 a nn xn b1 (eq n) a1n x1 b1 a2 n x2 b2 ann xn bn b1 b1 a1n a11 a12 b2 a22 a2 n a21 b2 a2 n a21 a22 b2 an 2 ann A a b ann x2 n1 n A an1 an 2 bn A b1 x1 a11 a12 a 21 a22 an1 an 2 bn a12 a1n a11 xn Sec 3.6 Determinants Cramer’s Rule (solve linear system) Solve the system a11x a12 y b1 a11 a12 x b1 a 21 a22 y b2 a12 a12 a21 a22 a21x a22 y b2 b1 a11 a11 det A b1 b2 a22 x a11 a12 a21 b2 y a11 a12 a21 a22 a21 a22 Example Solve the system 3x 5 y 2 x 2y 1 Cramer’s Rule (solve linear system) Use cramer’s rule to solve the system x 4 y 5z 1 (eq1) 4 x 2 y 5 z 0 (eq2) - 3 x 3 y z 0 (eq3) Adjoint matrix Def: Cofactor matrix Let A =[aij] be an nxn matrix . The cofactor matrix = [Aij] Example Find the cofactor matrix 1 0 2 A 4 3 1 3 5 1 Def: Adjoint matrix of A Adj A (cofactor matrix) Adj A [Aij ]T [ Aji ] T signs Example Find the adjoint matrix 1 0 2 A 4 3 1 3 5 1 Another method to find the inverse How to find the inverse of a matrix Thm2: The inverse of A Example Find the inverse of A 1 0 2 A 4 3 1 3 5 1 A1 Adj A A Computational Efficiency The amount of labor required to compute a numerical calculation is measured by the number of arithmetical operations it involves Goal: let us count just the number of multiplications required to evaluate an nxn determinant using cofactor expansion 2x2: 2 multiplications 3x3: three 2x2 determinants 3x2= 6 multiplications 4x4: four 3x3 determinants 4x3x2= 24 multiplications 5x5: four 3x3 determinants 4x3x2= 24 multiplications ---------------------------nxn: n (n-1)x(n-1) determinants nx…x3x2= n! multiplications Computational Efficiency Goal: let us count just the number of multiplications required to evaluate an nxn determinant using cofactor expansion nxn: determinants requires n! multiplications a typical 1998 desktop computer , using MATLAB and performing only 40 million operations per second To evaluate a determinant of a 15x15 matrix using cofactor 15! expansion requires 40,000,000 seconds 9.08 Hours a supercomputer capable of a billion operations per seconds To evaluate a detrminant of a 25x25 matrix using cofactor expansion requires 1.55 x1016 1.55x10 25 1.55x10 25 25! 16 sec sec 1.55 x10 sec sec 9 9 9 365.25 x 24 x3600 10 10 10 9.64 x10 47 years