4.3 matrix multiplication 1.multiplying a matrix by a scalar 2.multiplying matrices

51
4.3 Matrix Multiplication 1. Multiplying a Matrix by a Scalar 2. Multiplying Matrices

Upload: avis-tucker

Post on 04-Jan-2016

235 views

Category:

Documents


3 download

TRANSCRIPT

Page 1: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

4.3 Matrix Multiplication

1. Multiplying a Matrix by a Scalar

2. Multiplying Matrices

Page 2: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

1) Multiplying a Matrix by a Scalar

The number or factor you multiply a matrix by is called a scalar.

When multiplying by a scalar, every element in the matrix gets multiplied.

Page 3: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

1) Multiplying a Matrix by a Scalar

Example 1:

Find 3-2 -3 4

0 9 3.4

3 is a scalar

Page 4: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

1) Multiplying a Matrix by a Scalar

Example 1:

Find 3

=

-2 -3 4

0 9 3.4

-6 -9 12

0 27 10.2

Page 5: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

1) Multiplying a Matrix by a Scalar

Example 2: Find X.

6 9

-12 15

27 -18

30 6=-3X + 2

Page 6: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

1) Multiplying a Matrix by a Scalar

Example 2: Find X.

6 9

-12 15

27 -18

30 6=-3X + 2

12 18

-24 30

27 -18

30 6=-3X +

Page 7: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

1) Multiplying a Matrix by a Scalar

Example 2: Find X.

6 9

-12 15

27 -18

30 6=-3X + 2

12 18

-24 30

27 -18

30 6=-3X +

12 18

-24 30

27 -18

30 6

=-3X -

Page 8: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

1) Multiplying a Matrix by a Scalar

Example 2: Find X.

6 9

-12 15

27 -18

30 6=-3X + 2

12 18

-24 30

27 -18

30 6=-3X +

15 -36

54 -24

=-3X

Page 9: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

1) Multiplying a Matrix by a Scalar

Example 2: Find X.

6 9

-12 15

27 -18

30 6=-3X + 2

12 18

-24 30

27 -18

30 6=-3X +

-5 12

-18 8

=X

Page 10: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Multiply the rows of the first matrix by the columns of the second matrix and add.

Stay organized or it will get messy…fast.

Page 11: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 1:

Find the product of and-3 3

5 0

-1 0

3 -4

Page 12: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 1:

Find the product of and

Answer: Some matrix with dimensions 2x2

-3 3

5 0

-1 0

3 -4

? ?

? ?

Page 13: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 1:

Find the product of and-3 3

5 0

-1 0

3 -4

Multiply row 1 and column 1

Page 14: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 1:

Find the product of and

= (-3)(-1) + 3(3)

= 12

-3 3

5 0

-1 0

3 -4

Multiply row 1 and column 1

Page 15: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 1:

Find the product of and

= (-3)(-1) + 3(3)

= 12

-3 3

5 0

-1 0

3 -4

Multiply row 1 and column 1

12 ?

? ?

Page 16: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 1:

Find the product of and

= (-3)(0) + 3(-4)

= -12

-3 3

5 0

-1 0

3 -4

Multiply row 1 and column 2

12 ?

? ?

Page 17: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 1:

Find the product of and

= (-3)(0) + 3(-4)

= -12

-3 3

5 0

-1 0

3 -4

Multiply row 1 and column 2

12 -12

? ?

Page 18: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 1:

Find the product of and

= (5)(-1) + 0(3)

= -5

-3 3

5 0

-1 0

3 -4

Multiply row 2 and column 1

12 -12

? ?

Page 19: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 1:

Find the product of and

= (5)(-1) + 0(3)

= -5

-3 3

5 0

-1 0

3 -4

Multiply row 2 and column 1

12 -12

-5 ?

Page 20: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 1:

Find the product of and

= (5)(0) + 0(-4)

= 0

-3 3

5 0

-1 0

3 -4

Multiply row 2 and column 2

12 -12

-5 ?

Page 21: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 1:

Find the product of and

= (5)(0) + 0(-4)

= 0

-3 3

5 0

-1 0

3 -4

Multiply row 2 and column 2

12 -12

-5 0

Page 22: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 2:

Find the product of and-3 3

5 0

-1 0

3 -4

Page 23: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 2:

Find the product of and-3 3

5 0

-1 0

3 -4

? ?

? ?

Page 24: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 2:

Find the product of and-3 3

5 0

-1 0

3 -4

? ?

? ?

Page 25: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 2:

Find the product of and

= (-1)(-3) + (0)(5)

= 3

-3 3

5 0

-1 0

3 -4

? ?

? ?

Page 26: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 2:

Find the product of and

= (-1)(-3) + (0)(5)

= 3

-3 3

5 0

-1 0

3 -4

3 ?

? ?

Page 27: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 2:

Find the product of and

= (-1)(3) + (0)(5)

= -3

-3 3

5 0

-1 0

3 -4

3 ?

? ?

Page 28: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 2:

Find the product of and

= (-1)(3) + (0)(5)

= -3

-3 3

5 0

-1 0

3 -4

3 -3

? ?

Page 29: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 2:

Find the product of and

= (3)(-3) + (-4)(5)

= -29

-3 3

5 0

-1 0

3 -4

3 -3

? ?

Page 30: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 2:

Find the product of and

= (3)(-3) + (-4)(5)

= -29

-3 3

5 0

-1 0

3 -4

3 -3

-29 ?

Page 31: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 2:

Find the product of and

= (3)(3) + (-4)(0)

= 9

-3 3

5 0

-1 0

3 -4

3 -3

-29 ?

Page 32: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 2:

Find the product of and

= (3)(3) + (-4)(0)

= 9

-3 3

5 0

-1 0

3 -4

3 -3

-29 9

Page 33: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

4.2 Quiz Prep

p.180 #35-38

Page 34: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

4.2 Quiz Prep Answers

p.180 #35-38

35) B

36) G

37) x = 4, y = -2, w = 0, z = 6

38) x = 5, y = 1

Page 35: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 3:

Find the product of A = and B =-2 5 2

5 0.5 1

-3 7

4 2

Page 36: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 3:

Find the product of A = and B =

**The matrices are different dimensions

-2 5 2

5 0.5 1

-3 7

4 2

Page 37: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 3:

Find the product of A = and B =

**The matrices are different dimensions

**How do you know if a matrix product exists?

-2 5 2

5 0.5 1

-3 7

4 2

Page 38: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 3:

Find the product of A = and B = -2 5 2

5 0.5 1

-3 7

4 2

AB BA

(2 x 2)(2 x 3) (2 x 3)(2 x 2)

Page 39: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 3:

Find the product of A = and B = -2 5 2

5 0.5 1

-3 7

4 2

AB BA

(2 x 2)(2 x 3) (2 x 3)(2 x 2)

Page 40: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 3:

Find the product of A = and B = -2 5 2

5 0.5 1

-3 7

4 2

AB BA

(2 x 2)(2 x 3) (2 x 3)(2 x 2)

Page 41: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 3:

Find the product of A = and B = -2 5 2

5 0.5 1

-3 7

4 2

AB BA

(2 x 2)(2 x 3) (2 x 3)(2 x 2)

Columns of A match rows of B

Columns of B do not match rows of A

Page 42: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 3:

Find the product of A = and B = -2 5 2

5 0.5 1

-3 7

4 2

AB BA

(2 x 2)(2 x 3) (2 x 3)(2 x 2)

Columns of A match rows of B

Columns of B do not match rows of A

Product AB is defined

Product BA is undefined

Page 43: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 3:

Find the product of A = and B =

Dimensions of the product matrix

= (2 x 2)(2 x 3)

-2 5 2

5 0.5 1

-3 7

4 2

Page 44: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 3:

Find the product of A = and B =

Dimensions of the product matrix

= (2 x 2)(2 x 3)

-2 5 2

5 0.5 1

-3 7

4 2

Page 45: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 3:

Find the product of A = and B =

Dimensions of the product matrix

= (2 x 2)(2 x 3)

= (2 x 3)

-2 5 2

5 0.5 1

-3 7

4 2

Page 46: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 3:

Find the product of A = and B =

-3(-2) + 7(5) -3(5) + 7(0.5) -3(2) + 7(1)

=

4(-2) + 2(5) 4(5) + 2(0.5) 4(2) + 2(1)

-2 5 2

5 0.5 1

-3 7

4 2

Page 47: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 3:

Find the product of A = and B =

41 -11.5 1

=

2 21 10

-2 5 2

5 0.5 1

-3 7

4 2

Page 48: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 4:

Find the product of B = and A =-2 5 2

5 0.5 1

-3 7

4 2

Page 49: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

2) Multiplying Matrices

Example 4:

Find the product of B = and A =

= (2 x 3)(2 x 2)

= undefined

-2 5 2

5 0.5 1

-3 7

4 2

Page 50: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

Homework

p.186 #5, 7, 10, 13-15, 19, 20-24, 40, 51

Tomorrow

In-class assignment

Friday

Quiz – section 4.3

Page 51: 4.3 Matrix Multiplication 1.Multiplying a Matrix by a Scalar 2.Multiplying Matrices

Select Homework Solutions

p.186 #5, 7, 10, 13-15, 19, 20-24, 40, 51

14) [34] 23) Undefined15) [34 0] 24) Defined20) Defined 51) x = -3, y = -921) Defined22) Defined