n n matrices The system of m linear equations in n variables x 1, x 2,..., x n can be written as a matrix equation by Ax = b, or in full

Similar documents
Matrices Gaussian elimination Determinants. Graphics 2009/2010, period 1. Lecture 4: matrices

Elementary maths for GMT

Phys 201. Matrices and Determinants

Matrices. Chapter Definitions and Notations

Math Linear Algebra Final Exam Review Sheet

Matrix Arithmetic. j=1

MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS. + + x 1 x 2. x n 8 (4) 3 4 2

MATH2210 Notebook 2 Spring 2018

CS 246 Review of Linear Algebra 01/17/19

We could express the left side as a sum of vectors and obtain the Vector Form of a Linear System: a 12 a x n. a m2

[ Here 21 is the dot product of (3, 1, 2, 5) with (2, 3, 1, 2), and 31 is the dot product of

Elementary Row Operations on Matrices

Chapter 2 Notes, Linear Algebra 5e Lay

Materials engineering Collage \\ Ceramic & construction materials department Numerical Analysis \\Third stage by \\ Dalya Hekmat

MATH.2720 Introduction to Programming with MATLAB Vector and Matrix Algebra

Chapter 4 - MATRIX ALGEBRA. ... a 2j... a 2n. a i1 a i2... a ij... a in

Graduate Mathematical Economics Lecture 1

Undergraduate Mathematical Economics Lecture 1

Things we can already do with matrices. Unit II - Matrix arithmetic. Defining the matrix product. Things that fail in matrix arithmetic

CHAPTER 8: Matrices and Determinants

Determinants Chapter 3 of Lay

Chapter 7. Linear Algebra: Matrices, Vectors,

Matrix Algebra. Matrix Algebra. Chapter 8 - S&B

Linear Equations in Linear Algebra

Linear Algebra and Matrix Inversion

ICS 6N Computational Linear Algebra Matrix Algebra

Fundamentals of Engineering Analysis (650163)

POLI270 - Linear Algebra

Matrix Multiplication

Matrix Operations. Linear Combination Vector Algebra Angle Between Vectors Projections and Reflections Equality of matrices, Augmented Matrix

Matrix operations Linear Algebra with Computer Science Application

Section 9.2: Matrices.. a m1 a m2 a mn

INSTITIÚID TEICNEOLAÍOCHTA CHEATHARLACH INSTITUTE OF TECHNOLOGY CARLOW MATRICES

MATRICES The numbers or letters in any given matrix are called its entries or elements

Matrix representation of a linear map

Matrices and Linear Algebra

A Review of Matrix Analysis

Matrix Operations: Determinant

Fall Inverse of a matrix. Institute: UC San Diego. Authors: Alexander Knop

Math Camp II. Basic Linear Algebra. Yiqing Xu. Aug 26, 2014 MIT

Topics. Vectors (column matrices): Vector addition and scalar multiplication The matrix of a linear function y Ax The elements of a matrix A : A ij

Linear Systems and Matrices

Finite Math - J-term Section Systems of Linear Equations in Two Variables Example 1. Solve the system

CS100: DISCRETE STRUCTURES. Lecture 3 Matrices Ch 3 Pages:

Linear Algebra review Powers of a diagonalizable matrix Spectral decomposition

Linear Algebra review Powers of a diagonalizable matrix Spectral decomposition

Vectors and matrices: matrices (Version 2) This is a very brief summary of my lecture notes.

Matrix representation of a linear map

A FIRST COURSE IN LINEAR ALGEBRA. An Open Text by Ken Kuttler. Matrix Arithmetic

Matrix Algebra Determinant, Inverse matrix. Matrices. A. Fabretti. Mathematics 2 A.Y. 2015/2016. A. Fabretti Matrices

Linear Algebra. Matrices Operations. Consider, for example, a system of equations such as x + 2y z + 4w = 0, 3x 4y + 2z 6w = 0, x 3y 2z + w = 0.

MTH5112 Linear Algebra I MTH5212 Applied Linear Algebra (2017/2018)

Math 3108: Linear Algebra

Matrix & Linear Algebra

1 Multiply Eq. E i by λ 0: (λe i ) (E i ) 2 Multiply Eq. E j by λ and add to Eq. E i : (E i + λe j ) (E i )

MATH 213 Linear Algebra and ODEs Spring 2015 Study Sheet for Midterm Exam. Topics

MATRICES AND MATRIX OPERATIONS

1 Last time: determinants

a11 a A = : a 21 a 22

Section 9.2: Matrices. Definition: A matrix A consists of a rectangular array of numbers, or elements, arranged in m rows and n columns.

Kevin James. MTHSC 3110 Section 2.1 Matrix Operations

MAC Module 3 Determinants. Learning Objectives. Upon completing this module, you should be able to:

Components and change of basis

Lecture 3: Matrix and Matrix Operations

MATH Topics in Applied Mathematics Lecture 12: Evaluation of determinants. Cross product.

Matrices. 1 a a2 1 b b 2 1 c c π

Matrix Algebra 2.1 MATRIX OPERATIONS Pearson Education, Inc.

System of Linear Equations

Math Bootcamp An p-dimensional vector is p numbers put together. Written as. x 1 x =. x p

Linear Algebra M1 - FIB. Contents: 5. Matrices, systems of linear equations and determinants 6. Vector space 7. Linear maps 8.

ECON 186 Class Notes: Linear Algebra

Inverses and Determinants

10. Linear Systems of ODEs, Matrix multiplication, superposition principle (parts of sections )

Introduction to Matrices

Matrices: 2.1 Operations with Matrices

Equality: Two matrices A and B are equal, i.e., A = B if A and B have the same order and the entries of A and B are the same.

Lectures on Linear Algebra for IT

x + 2y + 3z = 8 x + 3y = 7 x + 2z = 3

CLASS 12 ALGEBRA OF MATRICES

Numerical Analysis Lecture Notes

MATRICES. a m,1 a m,n A =

Multiplying matrices by diagonal matrices is faster than usual matrix multiplication.

1300 Linear Algebra and Vector Geometry

22m:033 Notes: 3.1 Introduction to Determinants

Introduction. Vectors and Matrices. Vectors [1] Vectors [2]

M. Matrices and Linear Algebra

Lecture Notes in Linear Algebra

Matrices and Determinants

Linear Algebra March 16, 2019

1 Matrices and Systems of Linear Equations. a 1n a 2n

Finite Mathematics Chapter 2. where a, b, c, d, h, and k are real numbers and neither a and b nor c and d are both zero.

What is the Matrix? Linear control of finite-dimensional spaces. November 28, 2010

Linear Algebra V = T = ( 4 3 ).

NOTES FOR LINEAR ALGEBRA 133

CHAPTER 6. Direct Methods for Solving Linear Systems

Linear Equations and Matrix

is a 3 4 matrix. It has 3 rows and 4 columns. The first row is the horizontal row [ ]

1 Determinants. 1.1 Determinant

Lemma 8: Suppose the N by N matrix A has the following block upper triangular form:

Math 240 Calculus III

Transcription:

n n matrices Matrices Definitions Diagonal, Identity, and zero matrices Addition Multiplication Transpose and inverse The system of m linear equations in n variables x 1, x 2,..., x n a 11 x 1 + a 12 x 2 + + a 1n x n = b 1 a 21 x 1 + a 22 x 2 + + a 2n x n = b 2. a m1 x 1 + a m2 x 2 + + a mn x n = b m can be written as a matrix equation by Ax = b, or in full a 11 a 12 a 1n x 1 b 1 a 21 a 22 a 2n x 2....... = b 2. a m1 a m2 a mn x n b m

n n matrices Matrices Definitions Diagonal, Identity, and zero matrices Addition Multiplication Transpose and inverse The matrix a 11 a 12 a 1n a 21 a 22 a 2n A =...... a m1 a m2 a mn has m rows and n columns, and is called an m n matrix.

Definitions Diagonal, Identity, and zero matrices Addition Multiplication Transpose and inverse A square matrix (for which m = n) is called a diagonal matrix if all elements a ij for which i j are zero. If all elements a ii are one, then the matrix is called an identity matrix, denoted with I m (depending on the context, the subscript m may be left out). 1 0 0 0 1 0 I =...... 0 0 1 If all matrix entries are zero, then the matrix is called a zero matrix, denoted with 0.

Matrix addition Matrices Definitions Diagonal, Identity, and zero matrices Addition Multiplication Transpose and inverse For two matrices A and B, we have A + B = C, with c ij = a ij + b ij : 1 4 7 10 8 14 2 5 + 8 11 = 10 16 3 6 9 12 12 18 Q: what are the conditions for the dimensions of the matrices A and B?

Matrix multiplication Matrices Definitions Diagonal, Identity, and zero matrices Addition Multiplication Transpose and inverse Multiplying a matrix with a scalar is defined as follows: ca = B, with b ij = ca ij. For example, 1 2 3 2 4 6 2 4 5 6 = 8 10 12 7 8 9 14 16 18

Matrix multiplication Matrices Definitions Diagonal, Identity, and zero matrices Addition Multiplication Transpose and inverse Multiplying two matrices is a bit more involved. We have AB = C with c ij = n k=1 a ikb kj. For example, ( 6 5 1 3 2 1 8 4 ) 1 0 0 ( ) 1 1 0 6 2 2 5 0 2 = 37 5 16 0 1 0 Q: what are the conditions for the dimensions of the matrices A and B? What are the dimensions of C?

Properties of matrix multiplication Definitions Diagonal, Identity, and zero matrices Addition Multiplication Transpose and inverse Matrix multiplication is associative and distributive over addition: (AB)C = A(BC) A(B + C) = AB + AC (A + B)C = AC + BC However, matrix multiplication is not commutative: in general, AB BA. Also: if AB = AC, it doesn t necessarily follow that B = C (even if A is not the null matrix).

Transposed matrices Matrices Definitions Diagonal, Identity, and zero matrices Addition Multiplication Transpose and inverse The transpose A T of an m n matrix A is an n m matrix that is obtained by interchanging the rows and columns of A: a 11 a 12 a 1n a 21 a 22 a 2n A =...... a m1 a m2 a mn a 11 a 21 a m1 A T a 12 a 22 a m2 =...... a 1n a 2n a mn

Transposed matrices Matrices Definitions Diagonal, Identity, and zero matrices Addition Multiplication Transpose and inverse for example: A = ( 1 2 ) 3 4 5 6 1 4 A T = 2 5 3 6 For the transpose of the product of two matrices we have (AB) T = B T A T

The dot product revisited Definitions Diagonal, Identity, and zero matrices Addition Multiplication Transpose and inverse If we regard (column) vectors as matrices, we see that the inproduct of two vectors can be written as u v = u T v: 1 4 2 5 = ( 1 2 3 ) 4 5 = 32 3 6 6 (A 1 1 matrix is simply a number, and the brackets are omitted.)

Inverse matrices Matrices Definitions Diagonal, Identity, and zero matrices Addition Multiplication Transpose and inverse The inverse of a matrix A is a matrix A 1 such that AA 1 = I. Only square matrices possibly have an inverse. Note that the inverse of A 1 is A, so we have AA 1 = A 1 A = I

Solving systems of linear equations Inverting matrices Matrices are a convenient way of representing systems of linear equations: a 11 x 1 + a 12 x 2 + + a 1n x n = b 1 a 21 x 1 + a 22 x 2 + + a 2n x n = b 2 a m1 x 1 + a m2 x 2 + + a mn x n = b m If such a system has a unique solution, it can be solved with..

Solving systems of linear equations Inverting matrices Permitted operations in are interchanging two rows. multiplying a row with a (non-zero) constant. adding a multiple of another row to a row.

Solving systems of linear equations Inverting matrices Matrices are not necessary for, but very convenient, especially augmented matrices. The augmented matrix corresponding to the system of equations on the previous slides is a 11 a 12 a 1n b 1 a 21 a 22 a 2n b 2....... a m1 a m2 a mn b m

Solving systems of linear equations Inverting matrices : example Suppose we want to solve the following system: x + y + 2z = 17 2x + y + z = 15 x + 2y + 3z = 26 Q: what is the geometric interpretation of this system? And what is the interpretation of its solution?

Solving systems of linear equations Inverting matrices : example Applying the rules in a clever order, we get 1 1 2 17 1 1 2 17 2 1 1 15 0 1 3 19 1 2 3 26 0 1 1 9 1 1 2 17 0 1 3 19 0 1 1 9 1 0 1 2 0 1 3 19 0 0 1 5 1 0 1 2 0 1 3 19 0 0 2 10 1 0 0 3 0 1 0 4 0 0 1 5

Solving systems of linear equations Inverting matrices : example The interpretation of the last augmented matrix 1 0 0 3 0 1 0 4 0 0 1 5 is the very convenient system of linear equations x = 3 y = 4 z = 5 In other words, the point (3, 4, 5) satisfies all three equations.

Solving systems of linear equations Inverting matrices Note: In the literature you also find a slightly different procedure 1st step: Put 0 s in the lower triangle... 2nd step:.. then work your way back up 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 Q: what if a system can not be reduced to a triangular form? Q: does this always mean that their is no valid solution?

Solving systems of linear equations Inverting matrices : inverting matrices The same procedure can also be used to invert matrices: 1 1 2 1 0 0 1 3 4 0 1 0 0 2 5 0 0 1 1 1 2 1 0 0 0 2 2 1 1 0 0 2 5 0 0 1 1 1 2 1 0 0 1 0 1 1 1 0 1 1 1 2 1 2 0 1 2 2 0 0 1 1 1 1 2 2 0 0 2 5 0 0 1 0 0 3 1 1 1 1 0 1 1 1 2 1 7 2 0 1 0 0 0 1 1 1 6 1 6 2 6 1 2 2 0 0 1 0 5 5 1 0 0 1 3 1 6 6 2 6 1 2 3 3 0 0 1 6 2 2 6 6

Solving systems of linear equations Inverting matrices : inverting matrices The last augmented matrix tells us that the inverse of 1 1 2 1 3 4 0 2 5 equals 7 1 2 1 5 5 2 6 2 2 2

Matrices Volume Computing determinants: cofactors Solving systems of linear equations II Inverting matrices II Computing determinants II The determinant of a matrix is the signed volume spanned by the column vectors. The determinant det A of a matrix A is also written as A. For example, ( ) a11 a A = 12 a 21 a 22 det A = A = a 11 a 12 a 21 a 22 (a 12, a 22 ) (a 11, a 21 )

Computing determinants Volume Computing determinants: cofactors Solving systems of linear equations II Inverting matrices II Computing determinants II can be computed as follows: The determinant of a matrix is the sum of the products of the elements of any row or column of the matrix with their cofactors If only we knew what cofactors are...

Cofactors Matrices Volume Computing determinants: cofactors Solving systems of linear equations II Inverting matrices II Computing determinants II Take a deep breath... The cofactor of an entry a ij in an n n matrix a is the determinant of the (n 1) (n 1) matrix A that is obtained from A by removing the i-th row and the j-th column, multiplied by 1 i+j. Right: long live recursion! Q: what is the bottom of this recursion?

Cofactors Matrices Volume Computing determinants: cofactors Solving systems of linear equations II Inverting matrices II Computing determinants II Example: for a 4 4 matrix A, the cofactor of the entry a 13 is a c 13 = a 21 a 22 a 24 a 31 a 32 a 34 a 41 a 42 a 44 and A = a 12 a c 12 + a 22a c 22 + a 32a c 32 + a 42a c 42

and cofactors Volume Computing determinants: cofactors Solving systems of linear equations II Inverting matrices II Computing determinants II Example 0 1 2 3 4 5 6 7 8 = 0 4 5 7 8 1 3 5 6 8 + 2 3 4 6 7 = 0(32 35) 1(24 30) + 2(21 24) = 0.

Volume Computing determinants: cofactors Solving systems of linear equations II Inverting matrices II Computing determinants II Systems of linear equations and determinants Consider our system of linear equations again: x + y + 2z = 17 2x + y + z = 15 x + 2y + 3z = 26 Such a system of n equations in n unknowns can be solved by using determinants. In general, if we have Ax = b, then x i = Ai A. where A i is obtained from A by replacing the i-th column with b.

Volume Computing determinants: cofactors Solving systems of linear equations II Inverting matrices II Computing determinants II and systems of linear equations So for our system x + y + 2z = 17 2x + y + z = 15 x + 2y + 3z = 26 we have x = 17 1 2 15 1 1 26 2 3 1 1 2 2 1 1 1 2 3 y = 1 17 2 2 15 1 1 26 3 1 1 2 2 1 1 1 2 3 z = 1 1 17 2 1 15 1 2 26 1 1 2 2 1 1 1 2 3

and inverse matrices Volume Computing determinants: cofactors Solving systems of linear equations II Inverting matrices II Computing determinants II can also be used to compute the inverse A 1 of an invertible matrix A: A 1 = 1 A à where à is the adjoint of A, which is the transpose of the cofactor matrix of A. The cofactor matrix of A is obtained from A by replacing every entry a ij by its cofactor a c ij.

Computing determinants differently Volume Computing determinants: cofactors Solving systems of linear equations II Inverting matrices II Computing determinants II 2x2 matrices: a b c d = ad bc 3x3 matrices: a b c d e f g h i = a e f h i... = (aei + bfg + cdg) (hfa + idb + gec) Note: This does not generalize to higher dimensions!

Computing determinants differently Volume Computing determinants: cofactors Solving systems of linear equations II Inverting matrices II Computing determinants II can also be computed by a method that resembles : if A is obtained from A by exchanging two rows, then A = A. if A is obtained from A by multiplying a row with a scalar c, then A = c A. if A is obtained from A by adding a multiple of one row of A to another, then A = A. I = 1 if A contains any row or column with only zeros, then A = 0

Computing determinants differently Volume Computing determinants: cofactors Solving systems of linear equations II Inverting matrices II Computing determinants II Example 0 1 2 3 4 5 6 7 8 = 1 2 0 1 2 6 8 10 6 7 8 = 1 2 0 1 2 6 7 8 6 7 8 = 1 2 0 1 2 0 0 0 6 7 8 = 1 2 0 = 0.