Sie sind auf Seite 1von 22

Matrices

By Neil Bajoria Fazal Shah Harris Islam Chao Chen

What is a Matrix?
An element/entry Column

Row

Adding
To add two matrices, just add the numbers in the matching positions

(The two matrices must be the same size)

Negatives
The negative of a matrix is also simple

-(2)=-2 -(7)=-7

-(-4)=+4 -(10)=-10

Subtracting

Actually defined as the addition of a negative matrix: A + (-B)

Multiplying By A Constant
To multiply a matrix by a single number is easy:

We call the number ("2" in this case) a scalar, so this is called "scalar multiplication".

Multiplying A Matrix By Another Matrix


To multiply a matrix by another matrix you need to do the "dot product" of rows and columns To work out the answer for the 1st row and 1st column:

The "Dot Product" is where you multiply matching entries, then sum up: (1, 2, 3) (7, 9, 11) = 17 + 29 + 311 = 58 We match the 1st members (1 and 7), multiply them, likewise for the 2nd members (2 and 9) and the 3rd members (3 and 11), and finally sum them up.

Multiplying A Matrix By Another Matrix Cont.


We then do the same thing and multiply every row by every column. Here it is for the 1st row and 2nd column:

Then the same thing for the 2nd row and 1st column: (4, 5, 6) (7, 9, 11) = 47 + 59 + 611 = (1, 2, 3) (8, 10, 12) = 18 + 210 + 312 = 139 64 And finally for the 2nd row and 2nd column (4, 5, 6) (8, 10, 12) = 48 + 510 + 612 = 154 YOUR TURN

So we get:

When Do We Multiply A Matrix By Another


When we do multiplication: The number of columns of the 1st matrix must equal the number of rows of the 2nd matrix. And the result will have the same number of rows as the 1st matrix, and the same number of columns as the 2nd matrix.

Order of multiplication
In arithmetic we are used to: 35=53 But this is not generally true for matrices: AB BA When you change the order of multiplication, the answer is (usually) different. Example: See how changing the order affects this multiplication:

Dividing
You dont actually divide matrices You instead multiply by the inverse... So first, lets look at how to find the inverse of a matrix...

11

Inverse of a Matrix!
The inverse is the same idea as a reciprocal number
eg. 8 1/8, 7 1/7, 6 ?

HOWEVER, we dont write 1/A, because we dont divide by matrices -1 In fact, 1/8 can instead, we write A

ie. A

A-1

also be written as 8-1 !

12

Inverse of a Matrix! (cont.)


When you multiply a number by its reciprocal, you get 1
eg. 6 x (1/6) = 1

When you multiply a matrix by its inverse you get I


eg. A x A-1 = I

BUT WHAT IS I ??
13

What is I ??

I=

1 0 0 0 1 0 0 0 1
A 3x3 Identity Matrix (I = Identity)
14

What is I ?? (cont.)
I stands for Identity Matrix I is a square (ie. it has the same number of rows and columns) It has 1s on the diagonal ( ) and 0s everywhere else It can be different sizes (eg. 2x2, 3x3, etc.) BUT How do you calculate the inverse in order to get I ??
15

How do you calculate the inverse?


Well, for a 2x2 matrix...

[ ]
a
c

-1

1 ad - bc

[ ]
d -b
a -c
16

the determinant!

Basically, you... - swap the positions of a and d ( ) - put negatives in front of b and c - find the determinant (X) and do a multiplication

How do you calculate the inverse? (cont.)


a c b

eg.

[ ]
4 2 7 6

-1

1 4x6 - 2x7 1 ?

[ ] [ ] [ ]
d 6 -7 4 -2 6 -7 4 -2

-1

[ ]
?
?

17

How do you calculate the inverse? (cont.)


answer...

[ ]
4 2 7 6

-1

[ ] [ ] [ ]
1 6 -7 4 4x6 - 2x7 1 -2

-7
4

10

-2

0.6 -0.7 -0.2 0.4

18

Dividing
So, to divide, because you cant divide matrices, you multiply by the inverse!
Just like with numbers --> 3/6 = 3 x (1/6) = 3 x 6-1

With matrices --> A/B = A x B -1

19

eg.
2 4

[ ] [ ][ ] [ ][ ]
a c b d 3 1 4 2 7 6 2 4 3 1 4 2 7 6

Dividing (cont.)

-1

-1

??
1
ad - bc

[ ]
d -b a -c
20

Dividing (cont.)

[ ][ ] [ [ [ [
2 3 4 7

2 4 2 4

3 1 3 1

2 4

3 1

][ ] ] [ ] ] ][ ]
4 7

-1

-7 4

4x6 - 7x2 1

-2

10

0.6

-0.7

-0.2

0.4

21

Dividing (cont.)
answer (cont.)

[ ][ ][ ]
2 4 3 1

0.6

-0.7
0.4

0.6 2.2

-0.2 -2.4

-0.2

answer

22

Das könnte Ihnen auch gefallen