You are on page 1of 33

Page 1

Matrices
A matrix consisting of m horizontal rows and n
vertical columns is called an mn matrix or a
matrix of size mn.
a12

.
.

.
.

a11
a
21
.

a12
.

...

a1n

...
...

.
.

... a2n
...
.

## For the entry aij, we call i the row subscript and j

the column subscript.
Page 2

Matrices

## a. The matrix 1 2 0 has size 1

.3
1 6
b. The matrix 5 1 has size 3 . 2

9 4

## c. The matrix 7 has size 1

. 1

7 2 4
1 3
d. The matrix 9 11 5 6 8 has size 3 5.

6 2 1 1 1

Page 3

Equality of Matrices
Matrices A = [aij ] and B = [bij] are equal if
they have the same size and aij = bij for
each i and j.

Transpose of a Matrix

## A transpose matrix is denoted by AT.

If A 1 2 3, find AT .
4 5 6

Solution:

1 4
AT 2 5
3 6

Observe that

T T

A
Page 4

## Matrix Addition and Scalar Multiplication

Sum A + B is the m n matrix obtained by adding
corresponding entries of A and B.

a.
b.

1 2 7 2 1 7 2 2 8 0
3 4 6 4 3 6 4 4 3 8

5 6 3
0 5 3 6 0 8 6

1 2 2
3 4 1 is impossible as matrices are not of the same

size.

Page 5

## Example 2 Matrix Subtraction

a. 2

6 6 2
2 6 6 2
4 8
4 1 4 1 4 4 1 1 8 0
3 0 2 3
3 1
3 2 0 3

Page 6

D1 3 2 5

D2 0 17 1

DC 0 1 4

DE 20 0 8

D3 4 6 12
DS 30 5 0

## What is the total demand for consumers and the

industries?
Solution:

D1 D2 D3 3 2 5 0 17 1 4 6 12 7 25 18

Total:

DC DE DS 0 1 4 20 0 8 30 5 0 50 6 12

25 18 50 6 12 57 31 30
Page 7

Scalar Multiplication
Properties of Scalar Multiplication:

Subtraction of Matrices
Property of subtraction is A 1 A

Page 8

## To multiply matrices A and B

look at their dimensions

m n

n p

MUST BE SAME
SIZE OF PRODUCT

## If the number of columns of A does not

equal the number of rows of B then the
product AB is undefined.
Page 9

Multiplication of Matrices

## The multiplication of matrices is easier shown than put

into words. You multiply the rows of the first matrix
with the columns of the second adding products

Find AB

3 2 1
A

0 4 1

11 1 3 5
3 3 2 2 2 2

2 4

B 1 3
3 1

## First we multiply across the first row and down the

Page 10
the first row, first column of the answer.

Find AB

3 2 1
A

0 4 1
55
AB
AB
1

2 4

B 1 3
3 1

77 7

4
442
311
00300

324424
4
33123 31111
7 1
11

Notice the sizes of A and B and the size of the product AB.
Now we multiply across the first
second
rowrow
andand
down
down
the the
second
first
We multiplied across first row and down first column
column column
second
and welland
putwell
put the in
the second
first
in the
row,row,
second
second
firstrow,
so we put the answer in the first row, first column.
Page 11
column.column.
second

## Now lets look at the product BA.

2 4
3 2 1
A

B 1 3
0 4 1
3 1 3132121213123223114134034141004410
9
4614
2312
ly
ip
ult
across
acrossthird
second
second
third
row
row
row
row
across
first
second
row
row
as
as
aswe
we
godown
down
we
as
we
go go
go
down
down
first
third
third
first
second
second
third
column:
column:
column:
column:
column:
second
column:
first
column:
column:

32

can m

23

12
12
12
12 2
66 666 12
2 22
wer
size of a n s

BA
BA
BA
BA
BA

3
3
3
14
14
14

4
4
4

99 10
4
10

Commuter's Beware!
Completely different than AB!

AB BA
Page 12

## Chapter 3: Matrix Algebra

Matrix Multiplication

a.
b.
c.

4
1 2 3 5 32
6
1
1 6
2 1 6 2 12

3
3 18

1 3
2 2

0
1

0
1
2 1

0 4 2

2 5 3 11
3 4 1 0
2 7 4 10

b22
a
b

a
b
a
b

a
b
22 21
21 12
22 22
21 11

a
b
a
22
21
21

Page 13

## Given the price and the quantities, calculate the total

cost.
7 units of A
P 2 3 4

Solution:
The cost vector is

Q 5 units of B
11 units of C

7
PQ 2 3 4 5 73
11

Page 14

## Given the prices (in dollars per unit) for three

textbooks are represented by the price vector. A
university bookstore orders these books in the
quantities given by the column vector Q. find the total
cost (in dollars) of the purchase.
P 26.25 34.75 28.50

250
Q 325
175

22,843.75
Page 15

## Chapter 3: Matrix Algebra

Matrix Multiplication

If

1 2

3 4

3 0 1

1 1 2

Solution 1:

1 2
A BC

3 4

1 0
C 0 2
1 1

Solution
2:
1 0

3 0 1

1 1 2 0 2

1 1

1 2 2 1 4 9

3 4 3 4 18 13

1
1 2 3 0 1
0
AB C

3 4 1 1 2 1

1 0
1 2 5

0
2

13

1 1

0
2

1
4 9
18 13

Page 16

## Chapter 3: Matrix Algebra

Matrix Multiplication

If

3 2
A

1 4

51

2
5

1
10

3
10

1 0
I

0 1

0 0

0 0

Solution:
1 0 3 2
2 2
a. I A

0
1
1
4

3 2
3 2 2 0 3 6
1 0

b. 3 A 2I 3

1
4
0
1
1
4
0
2
3
6

3 2 0 0
O

1 4 0 0

c. AO

3 2 52
d. AB
1
1 4 10

51
3
10

1 0
I

0 1

Page 17

## Chapter 3: Matrix Algebra

Matrix Multiplication

2 x1 5 x 2 4
Write the system
8 x1 3 x 2 7

Solution:
If
2 5
A

8
3

x1
X
x2

4
B
7

AX B
2 5 x1 4
8 3 x 7

2
Page 18

## A contractor accepted orders for five

ranch-style houses, seven Cape Cod style
houses, and nine colonial style houses.
This order represented by:
The raw materials that go into each type of
houses are steel, wood, glass, paint, and
labor shown in the matrix R.

Page 19

## Suppose that the contractor want to know

how many amount of each raw material
needed to fulfill the orders. The we should
compute the matrix QR.
QR 128 451 236 143 349

## The contractor also interested in the costs

for the materials for each, shown in matrix
C

Page 20

## Then, the cost of each type of house is given by

2500
matrix:

5 20 16 7 17 1200
75850
RC 7 18 12 9 21 800 81550

6 25 8 5 13 150
71650
1500

## Consequently, the total costs of materials for

ranch style \$75,850; cape Cod style \$ 81,550;
and colonial style \$71,650
The total cost of raw materials for all the houses
is:
75850
QRC Q RC 5 7 9 81550 1,594,950
71650

Page 21

## Inverses 2x2 Matric

When matrix AB = I, A is an inverse of B
and A is invertible.
Example 1 Inverse of a Matrix
3 5
B

1
2

2 5
A

1 3

Page 22

Inverses
Find matrix :

determinant A

Page 23

## Chapter 3: Matrix Algebra

Inverses
Find matrix :

2 5
A

1
3

Page 24

Exercises
Find its inverse

Page 25

Inverses 3x3
Find the minor of Matric A:
Eliminate the first row and
first coloumn, get IM11I

Page 26

Page 27

## Now do the adjoint, that is the transpose

of matrix cofactor M
Then, do the determinant

Page 28

A=

1 0 0
0 3 0

0 0 4
K=

12 0 0
0

4
0

0
0 3

Page 29

12 0 0
0

4
0

0
0 3

Page 30

A -1

0
0
1
0 1/ 3 0

0
0
1 / 4

Page 31

## Find its inverse

7 0 2
0 1 0

3 0 1

Page 32

Quiz no.1
Jababeka property accepted orders for five ranch-style
houses, two Cape Cod style houses, and four colonial
style houses. This order represented by:
Q 5 2 4

## The raw materials that go into each type of houses are

steel, wood, glass, paint, and labor shown in the matrix
R.
5 20 16 7 15
R 7 15 10 8 20
6 25 8 5 12

## The contractor also interested in the costs for the

materials for each, shown in matrix C

2000
1200

C 800

200

1500

## Using matrix multiplication, compute the total cost of raw

materials. (in dollar0
Page 33