aij: the element of matrix A in row i and column j. For a square nn matrix A, the main diagonal is: Definition Two matrices are equal if they are of the same size and if their corresponding elements are equal. Definition Two matrices are equal if they are of the same size and if their corresponding elements are equal.
Linear Algebra Chapter Matrices 2.1 Addition, Scalar Multiplication, and Multiplication of Matrices • aij: the element of matrix A in row i and column j • For a square n×n matrix A, the main diagonal is: a11 a12 a a22 21 A= an1 an a1n a2 n ann Definition Two matrices are equal if they are of the same size and if their corresponding elements are equal Thus A = B if aij = bij ∀ i, j (∀ for every, for all) Ch2_2 Addition of Matrices Definition Let A and B be matrices of the same size Their sum A + B is the matrix obtained by adding together the corresponding elements of A and B The matrix A + B will be of the same size as A and B If A and B are not of the same size, they cannot be added, and we say that the sum does not exist Thus if C = A + B, then cij = aij + bij ∀i,j Ch2_3 Example , B = − 6, and C = − 4 Let A = 8 0 − 3 − Determine A + B and A + C, if the sum exist Solution + − 6 (1) A + B = 8 0 − 3 − + − 6 = 1 + 0 − − + + 8 = 1 − − 11 (2) Because A is × matrix and C is a × matrix, there are not of the same size, A + C does not exist Ch2_4 Scalar Multiplication of matrices Definition Let A be a matrix and c be a scalar The scalar multiple of A by c, denoted cA, is the matrix obtained by multiplying every element of A by c The matrix cA will be the same size as A Thus if B = cA, then bij = caij ∀i, j Example Let A = − 4 7 − 0 × × (−2) × 4 − 12 3A = = 3 × × (−3) × 0 21 − 0 Observe that A and 3A are both × matrices Ch2_5 Negation and Subtraction Definition We now define subtraction of matrices in such a way that makes it compatible with addition, scalar multiplication, and negative Let A – B = A + (–1)B Example Suppose A = 5 − 2 and B = 2 − 1 3 − 5 0 6 − − − − (−1) 3 − − 1 A− B = = − 11 3 − − − − 6 3 Ch2_6 Multiplication of Matrices Definition Let the number of columns in a matrix A be the same as the number of rows in a matrix B The product AB then exists Let A: m×n matrix, B: n×k matrix, The product matrix C=AB has elements cij = [ ai1 b1 j b 2j ain ] = ai1b1 j + 2b2 j + + ain bnj bnj C is a m×k matrix If the number of columns in A does not equal the number of row B, we say that the product does not exist Ch2_7 Example 1 3 5 Let A = ,B= , and C = [ − 5] 2 0 3 − Determine AB, BA, and AC , if the products exist Solution AB = 2 5 [1 3] 3 = 5 [ ] 3 3 5 0 3 −2 0 [1 3] − 2 [ 0] − 2 1 6 1 [1 3] 6 [ 0] 6 (1× 5) + (3 × 3) (1× 0) + (3 × (−2)) (1×1) + (3 × 6) = (2 × 5) + (0 × 3) (2 × 0) + (0 × (−2)) (2 ×1) + (0 × 6) 14 − 19 = 10 BA and AC not exist Note In general, AB≠BA Ch2_8 Example 1 Let A = 0 and B = − 0 Determine AB 5 − − 2 [ [ 1] − 1 1] 0 3 5 1 − − [ 0] 5 AB = 0 = [ 0] − − 2 − [ − − 2] [ − − 2] 3 5 5 − + + 5 = − + 0 + 0 = − 0 − − 10 − − 10 Example −7 Let C = AB, A = − 4 and B = 1 Determine c23 2 = (−3 × 2) + (4 × 1) = −2 [ ] − c23 = 1 Ch2_9 Size of a Product Matrix If A is an m × r matrix and B is an r × n matrix, then AB will be an m × n matrix A m×r B r×n = AB m×n Example If A is a × matrix and B is an × matrix Because A has six columns and B has six rows Thus AB exits And AB will be a × matrix Ch2_10 Example 18 Let A be a symmetric matrix Prove that A2 is symmetric Proof ( A2 ) t = ( AA) t =( At At ) = AA = A2 Ch2_30 Exercises 1, 2, 6, 7, 14, p.93 to p.94 2.4 The Inverse of a Matrix Definition Let A be an n × n matrix If a matrix B can be found such that AB = BA = In, then A is said to be invertible and B is called the inverse of A If such a matrix B does not exist, then A has no inverse (denote B = A−1, and A−k=(A−1)k ) Example 19 − Prove that the matrix A = 2 has inverse B = − 3 4 2 Proof 1 − AB = 2 − = 0 = I 3 4 0 1 2 1 2 0 − BA = − = = I2 2 Thus AB = BA = I2, proving that the matrix A has inverse B Ch2_32 Theorem 2.5 The inverse of an invertible matrix is unique Proof Let B and C be inverses of A Thus AB = BA = In, and AC = CA = In Multiply both sides of the equation AB = In by C C(AB) = CIn (CA)B = C I nB = C Thm2.2 B=C Thus an invertible matrix has only one inverse Ch2_33 Gauss-Jordan Elimination for finding the Inverse of a Matrix Let A be an n × n matrix Adjoin the identity n × n matrix In to A to form the matrix [A : In] Compute the reduced echelon form of [A : In] If the reduced echelon form is of the type [In : B], then B is the inverse of A If the reduced echelon form is not of the type [In : B], in that the first n × n submatrix is not In, then A has no inverse An n × n matrix A is invertible if and only if its reduced echelon form is In Ch2_34 Example 20 − − 2 Determine the inverse of the matrix A = − − 5 5 − Solution −1 − [ A : I3 ] = − − 5 0 − ≈ −1 − (−1)R2 0 1 −1 0 0 ≈ 0 −1 − 0 R2 + (−2) R10 − − − 0 1 R3 + R1 0 1 0 ≈ − 0 −1 0 R1 + R2 0 1 − 0 1 R3 + (−2)R2 0 − 1 ≈ 1 1 0 R1 + R3 0 − − 1 R2 + (−1)R3 0 − 1 1 Thus, A−1 = − − 1 − 1 Ch2_35 Example 21 Determine the inverse of the following matrix, if it exist 1 5 A = 7 2 − 4 Solution ≈ 0 1 0 1 [ A : I ] = 0 R2 + (−1)R1 0 − 1 0 2 − 0 1 R3 + (−2)R1 0 − − − 1 ≈ − 0 1 R1 + (−1)R2 0 − 1 0 R3 + 3R2 0 0 − 1 There is no need to proceed further The reduced echelon form cannot have a one in the (3, 3) location The reduced echelon form cannot be of the form [In : B] Thus A–1 does not exist Ch2_36 Properties of Matrix Inverse Let A and B be invertible matrices and c a nonzero scalar, Then ( A−1 ) −1 = A −1 −1 (cA) = A c −1 −1 −1 ( AB) = B A ( An ) −1 = ( A−1 ) n ( At ) −1 = ( A−1 )t Proof By definition, AA−1=A−1A=I (cA)( 1c A−1 ) = I = ( 1c A−1 )(cA) ( AB)( B −1 A−1 ) = A( BB −1 ) A−1 = AA−1 = I = ( B −1 A−1 )( AB) A n ( A −1 ) n = A A ⋅ A −1 A−1 = I = ( A −1 ) n A n n times n times AA−1 = I , ( AA−1 ) t = ( A−1 ) t At = I , A−1 A = I , ( A−1 A) t = At ( A−1 ) t = I , Ch2_37 Example 22 If A = 4 1, then it can be shown that A−1 = − 1 Use this 1 − 4 informatio n to compute ( At ) −1 Solution t −1 −3 (A ) = (A ) = = −3 4 −1 4 t −1 −1 t Ch2_38 Theorem 2.6 Let AX = B be a system of n linear equations in n variables If A–1 exists, the solution is unique and is given by X = A–1B Proof (X = A–1B is a solution.) Substitute X = A–1B into the matrix equation AX = A(A–1B) = (AA–1)B = In B = B (The solution is unique.) Let Y be any solution, thus AY = B Multiplying both sides of this equation by A–1 gives A–1A Y= A–1B In Y= A–1B Y = A–1B Then Y=X Ch2_39 Example 22 x1 − x2 − x3 = Solve the system of equations x1 − x2 − x3 = − x1 + x2 + x3 = −2 Solution This system can be written in the following matrix form: − − 2 x1 1 − − 5 x2 = 3 5 x3 − 2 − If the matrix of coefficients is invertible, the unique solution is −1 x1 − − 2 1 x2 = − − 5 3 x − 5 − 2 3 This inverse has already been found in Example 20 We get x1 1 1 1 x2 = − − 1 3 = − 2 x − 1 − 2 1 3 The unique solution is x1 = 1, x2 = −2, x3 = Ch2_40 Elementary Matrices Definition An elementary matrix is one that can be obtained from the identity matrix In through a single elementary row operation Example 23 1 0 I = 0 0 0 1 R2 ↔ R3 5R2 R2+ 2R1 1 0 E1 = 0 1 0 0 1 0 E2 = 0 0 0 1 1 0 E3 = 2 0 0 1 Ch2_41 Elementary Matrices 。 Elementary row operation 。 Elementary matrix a g R2 ↔ R3 d a A = d g b e h c f i 5R2 a 5d g c 1 0 i = 0 1 ⋅ A = E1 A f 0 0 b h e c 1 0 5e f = 0 0 ⋅ A = E2 A h i 0 1 b b a d + 2a e + 2b R2+ 2R1 g h c 1 0 f + 2c = 2 0 ⋅ A = E3 A i 0 1 Ch2_42 Notes for elementary matrices Each elementary matrix is invertible Example 24 I ≈ E1 ⇒ E1 ≈ I , i.e., E2 E1 = I R1+ R 1 0 I = 0 0 0 1 R1− R 1 E1 = 0 0 0 1 1 − 0 E2 = 0 0 0 1 If A and B are row equivalent matrices and A is invertible, then B is invertible Proof If A ≈ … ≈ B, then B=En … E2 E1 A for some elementary matrices En, … , E2 and E1 So B−1 = (En … E2 E1A)−1 =A−1E1−1 E2−1 … En−1 Ch2_43 Homework Exercises 6, 9, 14, 15, 16, 19, 21, 32 from p.105 to 107 Exercise d − b a b −1 If A = , show that A = (ad − bc) − c a c d Ch2_44 [...]... can’t add the two matrices Ch2_21 Systems of Linear Equations A system of m linear equations in n variables as follows a11 x1 + + a1n xn = b1 am1 x1 + + amn xn = bm Let a11 a1n x1 b1 A = , X = , and B = am1 amn xn bm We can write the system of equations in the matrix form AX = B Ch2_22 Idempotent and Nilpotent Matrices (Exercises... 3×2+2×2 =6+4=10 ∴ A(BC) is better Ch2_18 Caution In algebra we know that the following cancellation laws apply If ab = ac and a ≠ 0 then b = c If pq = 0 then p = 0 or q = 0 However the corresponding results are not true for matrices AB = AC does not imply that B = C PQ = O does not imply that P = O or Q = O Example 11 1 2 − 1 2 − 3 8 (1) Consider the matrices A = , B = 2 1 , and C = 3 − 2... b1i b1i b b ( AB) 3i = [a31 a32 a3n ] 2i = [0 0 0] 2i = 0, ∀i bni bni Ch2_13 2.2 Algebraic Properties of Matrix Operations Theorem 2.2 -1 Let A, B, and C be matrices and a, b, and c be scalars Assume that the size of the matrices are such that the operations can be performed Properties of Matrix Addition and scalar Multiplication 1 A + B = B + A Commutative... matrix) 4 c(A + B) = cA + cB Distributive property of addition 5 (a + b)C = aC + bC Distributive property of addition 6 (ab)C = a(bC) Ch2_14 Theorem 2.2 -2 Let A, B, and C be matrices and a, b, and c be scalars Assume that the size of the matrices are such that the operations can be performed Properties of Matrix Multiplication 1 A(BC) = (AB)C Associative property of multiplication 2 A(B + C) = AB + AC Distributive... matrices A = , B = 2 1 , and C = 3 − 2 2 4 3 4 Observe that AB = AC = , but B ≠ C 6 8 1 − 2 2 − 6 (2) Consider the matrices P = , and Q = 4 − 2 1 − 3 Observe that PQ = O, but P ≠ O and Q ≠ O Ch2_19 Powers of Matrices Definition If A is a square matrix, then Ak = AA A k times Theorem 2.3 If A is an n × n square matrix and r and s are nonnegative... Distributive property of multiplication 4 AIn = InA = A (where In is the appropriate zero matrix) 5 c(AB) = (cA)B = A(cB) Note: AB≠ BA in general Multiplication of matrices is not commutative Ch2_15 Proof of Thm 2.2 (A+B=B+A) Consider the (i,j)th elements of matrices A+B and B+A: ( A + B ) ij = aij + bij = bij + aij = ( B + A) ij ∴ A+B=B+A Example 9 Let A = 1 3, B = 3 − 7 , and C = 0 − 2 1 − 4 5... Symmetric Matrices Definition The transpose of a matrix A, denoted At, is the matrix whose columns are the rows of the given matrix A i.e., A : m × n ⇒ At : n × m, ( At ) ij = A ji ∀i, j Example 15 A = 2 7, B = 1 2 − 7 , and C = [ − 1 3 4] 6 − 8 0 4 5 − 1 1 4 t t C = 3 At = 2 − 8 B = 2 5 0 7 4 − 7 6 Ch2_25 Theorem 2.4: Properties of Transpose Let A and B be matrices. ..Special Matrices Definition A zero matrix is a matrix in which all the elements are zeros A diagonal matrix is a square matrix in which all the elements not on the main diagonal are zeros An identity matrix is... − 4 + 8 + 5 5 + 1 − 1 9 Ch2_16 Arithmetic Operations If A is an m × r matrix and B is r × n matrix, the number of scalar multiplications involved in computing the product AB is mrn Consider three matrices A, B and C such that the product ABC exists Compare the number of multiplications involved in the two ways (AB)C and A(BC) of computing the product ABC Ch2_17 Example 10 4 3, and C = − 1 ... 0 0 1 identity matrix diaginal matrix A Ch2_11 Theorem 2.1 Let A be m × n matrix and Omn be the zero m × n matrix Let B be an n × n square matrix On and In be the zero and identity n × n matrices Then A + Omn = Omn + A = A BOn = OnB = On BIn = InB = B Example 8 Let A = 2 1 − 3 and B = 2 1 8 4 5 − 3 4 1 − 3 0 0 + 5 8 0 0 2 1 0 0 0 BO2 = = − 3 3 0 0