1 Matrices: Introductory Material

advertisement
ECON 213
Refresher Notes
2000/2001
This can also be accessed through the
web on the following address:
http://www.lancs.ac.uk/people/ecajj
1
PART I: INTRODUCTORY MATRICES AND MATRIX MANIPULATION
You should already be familiar with matrices and their manipulation (eg addition,
subtraction, multiplication and inversion of 2x2 matrices). In order to refresh your
memories, I strongly recommend that you read the attached pages and attempt the
simple exercises on page 10. If you find any part of this material difficult then
please consult one of the following texts, both of which can be found in the
library:
M. Hoy et al Mathematics for Economics, Addison Wesley
K. Holden and A.W. Pearson Introductory Mathematics for Economics and
Business, Macmillan
If you have time, or if you have particular difficulties then the following exercises
should also be attempted from Hoy et al:
Definition of matrices:
p274 section 8.1 Qs 1-5
Matrix manipulation including addition,
subtraction and multiplication:
p287 section 8.2 Qs 1-6
Further matrix manipulation including
transposes:
p291 section 8.3 Qs 1-7
Inverses:
p312 section 9.1 Qs 1-3
and the following exercises from Holden and Pearson:
Inverses
Transposes
p57 section 2.5 Qs 1 & 2
p63 section 2.7 Qs 1 & 2
p75 section 2.11 Qs 1 & 3
The solutions to the exercises on page 8 of these notes can be found at website
http://www.lancs.ac.uk/people/ecajj after September 20th. The solutions to the
exercises from the text books will be discussed in the first tutorial session of the
Michaelmas term.
2
1 Matrices: Introductory Material
1.1 Definition: A matrix is an array of numbers written in brackets (round or
square).
1.2 Examples
 1 3


 2 5
 1 3


2
1




 3 8
1.3 Definitions: The numbers in the array are called the elements of the matrix. A
matrix which has r rows and c columns is described as an r x c matrix or a matrix
of order (or dimension) r x c. When r = c then the matrix is described as a square
matrix.
A matrix is generally denoted as B = [bij]. For example if i=j=1,2 then
 b11 b12 

 b21 b22 
B = [bij] = 
1.4 Definitions: A matrix with only one column is called a column vector. A
matrix with only one row is called a row vector.
1.5 Equality: two matrices are equal if and only if (iff) (a) they have the same
dimension and (b) all elements in corresponding locations in each array are equal.
1.5.1 Examples
1.
2.
 2 1  2 1  3 5

 
 

 3 5  3 5  2 1
If
 x   2
   
 y  4
then x = 2 and y = 4
1.6 Addition and subtraction: Matrices can be added and subtracted iff they are of
the same dimension. In this case they are said to be conformable for addition or
conformable for subtraction.
3
1.6.1 Addition
 a11 a12   b11 b12   a11  b11 a12  b12 

 
 

 a21 a22   b21 b22   a21  b21 a22  b22 
1.6.2 Subtraction
 a11 a12   b11 b12   a11  b11 a12  b12 

 
 

 a21 a22   b21 b22   a21  b21 a22  b22 
1.6.3 Note: Matrix addition is commutative and associative i.e.
A+B=B+A
(commutative law)
and
(A + B) + C = A + (B + C)
(associative law)
where A, B and C are of the same dimension.
1.7 Scalar multiplication: A matrix of any order can be multiplied by a number or
scalar. The multiplication is performed by multiplying every element in the matrix
by the given number.
1.7.1 Example: Consider the scalar a, and the matrix B=[bij] where i=j=1,2
 b11 b12   ab11 ab12 
 

 b21 b22   ab21 ab22 
aB = a 
1.8 Multiplication of 2 matrices: unlike scalar multiplication which can be
performed on matrices of any order, multiplication of 2 matrices depends upon a
particular dimensional requirement being satisfied. Consider two matrices X and
Y, and the product XY. X is said to be the lead matrix in the product and Y is the
lag matrix in the expression. For multiplication to be possible, then the column
dimension of the lead matrix must equal the row dimension of the lag matrix i.e. if
X is of dimension c x d and Y is of dimension p x q, then X and Y are
conformable for multiplication iff d = p. Moreover, the resulting matrix will be of
dimension c x q.
4
1.8.1 Example: Suppose X is of dimension 2x3 and Y is of dimension 3x2.
Clearly, X and Y are conformable for multiplication and the resulting matrix XY
will be of dimension 2x2.
XY
y12 
y
x13   11

  y21 y22 
x23  

 y31 y32 
 x11 y11  x12 y21  x13 y31 x11 y12  x12 y22  x13 y32 
=

 x21 y11  x22 y21  x23 y31 x21 y12  x22 y22  x23 y32 
 x11
=
 x21
x12
x22
1.8.2 Numerical example:
Suppose
1
3

1
2



X= 
 and Y =  2
 1 0 3

4
1
3

1
2


then XY
=

 2
 1 0 3 
4
3

8

0
3

8

0
=
 (3)(1)  ( 1)(2)  (2)(4) (3)(3)  ( 1)(8)  (2)(0)


(1)(3)  (0)(8)  (3)(0) 
 (1)(1)  (0)(2)  (3)(4)
=
 9 1


 13 3
1.8.3 Notes
a) Matrix multiplication is generally non-commutative i.e. it is not generally the
case that XY = YX.
b) Matrix multiplication is associative i.e.
(AB)C = A(BC)
although the conformability condition must be satisfied by each adjacent pair of
matrices.
5
c) Matrix multiplication is distributive i.e.
A(B + C) = AB + AC
(B + C)A = BA + CA
although the conformability condition for addition and multiplication must be
satisfied.
d) Matrix multiplication allows a concise representation of systems of equations.
For example, the following equations
2x1 + 3x2 = 6
3x1 + 4x2 = 12
can be represented as
Ax = d
where
 2 3
A= 

 3 4
 x1 
x =  
 x2 
 6
d =  
 12
As will be illustrated later, this representation of systems of equations leads to the
development of a simple method of solution.
1.9 Transposition: When the rows and columns of matrix A are interchanged (i.e.
the rows become the columns and the columns become the rows) the resulting
matrix is the transpose of A and denoted by A' or AT.
1.9.1 Example:
 a11 a12
If A = 
 a21 a22
a13 

a23 
 a11

 a12

 a13
a21 

a22 

a23 
then A' =
1.9.2 Notes
a) Clearly if A is of dimension r x c then A' must be of dimension c x r.
b) When a matrix is left unaltered by transposition (i.e. A = A') then it is called a
symmetric matrix.
c) (A') = A'
d) (A + B)'= A'+ B'
e) (AB)' = B'A'
6
1.10 Identity and null matrices
1.10.1 Definition: The principal diagonal (or leading diagonal ) of a square matrix
is the diagonal of elements going from northwest to southeast.
1.10.2 Identity matrices: An identity matrix is a square matrix with 1s on the
principal diagonal and 0s in all other elements of the array. It is denoted by I or I n
where n represents the row and column dimension.
1.10.3 Examples
 1 0
I2 = 

 0 1
 1 0 0


I 3 =  0 1 0


 0 0 1
1.10.4 Notes
a) The identity matrix acts like the number 1 in the number system. For any matrix
A, IA = AI = A. As long as A is not a square matrix, then the premultiplication
and postmultiplication of A by I requires identity matrices of different
dimensions. In the case where A is a square matrix, however, I will have the same
dimension in each case and is an example of an exception to the rule that matrix
multiplication is not commutative.
b) (I)2 = I and so (I)k = I for k=1,2,... Any matrix which remains unchanged when
multiplied by itself any number of times is known as an idempotent matrix.
c) The identity matrix is a symmetric matrix i.e I' = I.
1.10.5 Null matrices: A null matrix (denoted by 0) is one where every element in
the array is zero. It may be of any dimension and operates like the number zero in
the number system.
1.10.6 Example
 0 0 0
 0 0


and
0
=
0
0
0
0= 



 0 0


 0 0 0
are null matrices of different dimensions.
1.10.7 Notes
a) A + 0 = 0 + A = A assuming the conformability condition for addition is
satisfied.
b) A - 0 = A assuming the conformability condition for subtraction is satisfied.
7
c) A0 = 0 and 0A = 0 assuming the conformability condition for multiplication is
satisfied in each case. Note also that the null matrices may each be of different
dimension even though they are each denoted by 0.
d) A square null matrix is idempotent, but a nonsquare null matrix is not. (Proof
left as exercise)
e) An interesting anomaly regarding the null matrix is that, whereas in the case of
numbers ab=0 always implies that a=0 or b=0, this is not the case with matrices.
Eg.
AB =
 4 8  4 8   0 0


 

 2 4  2 4  0 0
The anomaly arises when a matrix is singular (see below).
1.11 Inverses: The inverse of the square matrix A (denoted by A-1) is such that
AA-1 = A-1A = I
1.11.1 Notes
a) It is worth stressing that only a square matrix can have an inverse.
b) Not every square matrix has an inverse (being square is a necessary but not
sufficient condition for the inverse to exist). A matrix which does not have an
inverse is said to be singular. Conversely a matrix which can be inverted is
nonsingular.
c) If A is n x n and can be inverted then A-1 is also n x n, as is the identity matrix I
resulting from the product AA-1.
d) If an inverse exists then it is unique (proof left as exercise).
e) (A-1)-1 = A
f) (AB)-1 = B-1A-1 assuming that the inverses exist and the condition of
conformability for multiplication is satisfied. (Proof left as exercise).
g) (A')-1 = (A-1)' assuming that the inverses exist. (Proof left as exercise).
1.11.2 The inverse of a 2 x 2 matrix
a) Find the determinant of the matrix. For a 2 x 2 matrix X
det(X) =
x11
x21
x12
x22
= x11x22 - x12x21
b) Interchange the elements on the leading diagonal.
c) Change the signs on the other two elements.
d) Divide this matrix by the determinant.
8
So X-1 =
 x22  x12 
1


x11 x22  x12 x21   x21 x11 
The method for finding the inverse of a matrix of higher dimension will be the
subject of a later section.
1.11.3 Application: The inverse of a matrix is very useful for solving sets of linear
equations. Consider the following example:
2x1 + 5x2
= 39
7x1 - 3x2 = 75
a) Write the equations in matrix form as discussed in section 1.8.3. In this
example, the system of equations can be written as
Ax = b
2 5 
where A = 

 7 3
 x1 
x =  
 x2 
 39
and b =  
 75
b) The column vector of unknowns, x, can be found as follows:
Ax
=
b
-1
-1
<=>
A Ax =
A b
<=>
x
=
A-1b
Thus the solution to the system of equations involves finding the inverse of the
coefficient matrix A.
Now det(A) = (2)(-3)-(5)(7) = -41
-1
A =
1  3 5


41  7 2 
 x1  1  3 5   39  12
and so   

    
 x2  41  7 2  75  3 
So x1 = 12 and x2 = 3
9
1.12 Exercises
 2  5
1. Given A = 

6 7 
a) A + B
b) C – A
c) 3A
d) 4B + 2C
0 6 
B = 

 2  3
 7 2
C = 
 find:
 5 1
 2 2


 5 0
 1 3
2. Given A =  4 0 
B = 
C = 


2
4
2
9




6 1 


a) Is AB defined? Calculate Ab. Can you calculate BA?
b) Is BC defined? Calculate BC. Is CB defined? If so calculate CB.
c) Is it the case that BC = CB?
3. Find product matrices for the following:
 2  1 4 1  4 
 x



  3 2 5  
 y 
a)  3 0  7  2 0 
b) 
 4 0  1  
5 3



0  3 5 

 z
1 3 5 
4. Given A = 
 and B =
2
4
6


a) AI
b) IA
c) BI
 5
 
 3  caculate:
1
 
d) IB
5. Given A and B as defined in question 4 find:
a) A’
b) B’
2 4 
6. Given A = 
 and B =
5

2


a) A-1
 3 0

 find

1
5


b) B-1
10
PART 2: CONCAVITY, CONVEXITY AND THE REST:
For the second part of the course, students will be required to demonstrate
familiarity with the techniques for differentiating functions of more than one
variable. The most useful preparation for this is to revise the principles which
have been acquired at A-level.
The following examples will provide you with a basis for testing your skills. This
is not a test in the formal sense, however, since the answers are given immediately
after the questions. If your answer does not correspond to that given, go back and
try again!
1
Differentiate to following with respect to x.:
1.
2.
3.
4.
5.
y  x 3  3x
y  ( x 3  3x) 2
y  x1/ 2
y  (1 / x) 3
y  x3  2x
Answers:
1.
2.
3.
4.
5.
2
3x 2  3
6 x( x 2  1)( x 2  3)
1 /( 2 x)
 (3 / x 4 )
3x 2  2
2 x ( x 2  2)
Find the first order partial derivatives of the following expressions:
1. z  3x 2  xy  2 y
2. z  ( x 2  y 2 ) /( x 3  y 3 )
3. z  e x 3 y
3
2
11
Answers:
z
 6x  y
x
1.
z
zy 
 x2
y
zx 
2.
x( x 3  3 xy2  2 y 3 )
zx  
( x3  y 3 )2
zy 
y (2 x 3  3x 2 y  y 3 )
(x3  y3 )2
3. z x  3x 2 zLN (e); z y  6 yzLN (e)
12
Download