Professional Documents
Culture Documents
Introduction To Financial Econometrics Appendix Matrix Algebra Review
Introduction To Financial Econometrics Appendix Matrix Algebra Review
A = ..
..
..
.
(nm)
. ... .
an1 an2 . . . anm
where aij denotes the ith row and j th column element of A.
A vector is simply a matrix with 1 column. For example,
x1
x2
x = ..
(n1)
.
xn
1 4
1 2 3
, A0 = 2 5
A =
4
5
6
(32)
(23)
3 6
1
x
(31)
1
= 2 ,
3
x0 =
(13)
1 2 3 .
1 2
A=
.
2 1
Clearly,
0
A =A=
1.1
1.1.1
1 2
2 1
Matrix addition and subtraction are element by element operations and only apply
to matrices of the same dimension. For example, let
4 9
2 0
A=
, B=
.
2 1
0 7
Then
A+B =
AB =
1.1.2
4 9
2 1
4 9
2 1
2 0
0 7
2 0
0 7
=
=
4+2 9+0
2+0 1+7
42 90
20 17
6 9
2 8
2 9
2 6
Scalar Multiplication
3 1
A=
.
0 5
Then
cA=
2 3 2 (1)
2 (0)
25
6 2
0 10
1.1.3
Matrix Multiplication
1 2
1 2 1
and B =
.
A =
3 4
3 4 2
(22)
(23)
Then
A B
(22)
(23)
1 2
3 4
1 2 1
3 4 2
7 10 5
=
= C
15 22 11
(23)
1 2
2
A = 3 4 and B = 6 .
(22)
(21)
Then
A B
(22)
(21)
5
=
15+26
=
35+46
17
=
.
39
1 2
3 4
Then
1
4
x = 2 , y = 5 .
3
6
x0 y = 1 2 3 5 = 1 4 + 2 5 + 3 6 = 32
6
3
1.2
The identity matrix plays a similar role as the number 1. Multiplying any number by
1 gives back that number. In matrix algebra, pre or post multiplying a matrix A by
a conformable identity matrix gives back the matrix A. To illustrate, let
1 0
I=
0 1
denote the 2 dimensional identity matrix and let
a11 a12
A=
a21 a22
denote an arbitrary 2 2 matrix. Then
1 0
a11 a12
IA =
a21 a22
0 1
a11 a12
=
=A
a21 a22
and
AI =
=
1.3
a11 a12
a21 a22
a11 a12
a21 a22
1 0
0 1
= A.
Inverse Matrix
To be completed.
1.4
xk = x1 + + xk.
.
0
.
x 1 = x1 . . . xn . = x1 + + xk =
xk
k=1
1
4
and
x1
n
X
.
0
1 x = 1 . . . 1 .. = x1 + + xn =
xk .
k=1
xn
.1
0
x x = x1 . . . xn ..
xn
as
x2k .
= x21 + + x2n =
k=1
xk yk = x1 y1 + xn yn .
y1
n
X
.
0
.
x y = x1 . . . xn . = x1 y1 + xn yn =
xk yk .
k=1
yn
Note that x0 y = y0 x.
1.5
(1)
(2)
which is illustrated in Figure xxx. Equations (1) and (2) represent two straight lines
which intersect at the point x = 23 and y = 13 . This point of intersection is determined
by solving for the values of x and y such that x + y = 2x y 1 .
1
Soving for x gives x = 2y. Substituting this value into the equation x + y = 1 gives 2y + y = 1
and solving for y gives y = 1/3. Solving for x then gives x = 2/3.
1 1
x
1
=
2 1
y
1
or
Az=b
where
A=
1 1
2 1
, z=
x
y
and b =
1
1
or
x
y
b11 b12
b21 b22
= Bb
= I z = B b
= z = B b
1
1
b11 1 + b12 1
b21 1 + b22 1
If such a matrix B exists it is called the inverse of A and is denoted A1 . Intuitively, the inverse matrix A1 plays a similar role as the inverse of a number.
Suppose a is a number; e.g., a = 2. Then we know that a1 a = a1 a = 1. Similarly,
in matrix algebra A1 A = I where I is the identity matrix. Next, consider solving
the equation ax = 1. By simple division we have that x = a1 x = a1 x. Similarly, in
matrix algebra if we want to solve the system of equation Ax = b we multiply by
A1 and get x = A1 b.
Using B = A1 , we may express the solution for z as
z = A1 b.
As long as we can determine the elements in A1 then we can solve for the values of
x and y in the vector z. Since the system of linear equations has a solution as long as
the two lines intersect, we can determine the elements in A1 provided the two lines
are not parallel.
There are general numerical algorithms for &nding the elements of A1 and typical
spreadsheet programs like Excel have these algorithms available. However, if A is a
(2 2) matrix then there is a simple formula for A1 . Let A be a (2 2) matrix such
that
a11 a12
.
A=
a21 a22
6
Then
A
1
=
a11 a22 a21 a12
a22 a12
a21 a11
1
a22 a12
a11 a12
1
A A =
a21 a22
a11 a22 a21 a12 a21 a11
1
a22 a11 a12 a21
a22 a12 a12 a22
=
a11 a22 a21 a12 a21 a11 + a11 a21 a21 a12 + a11 a22
1
a22 a11 a12 a21
0
=
0
a21 a12 + a11 a22
a11 a22 a21 a12
1 0
=
.
0 1
Let s apply the above rule to &nd the inverse of A in our example:
1 1
1
1 1
1
3
A =
= 23 1
.
1 2 2 1
3
3
Notice that
1
A A=
Our solution for z is then
1
3
2
3
1
3
1
3
1 1
2 1
1 0
0 1
z =
A1 b
1
1
1
3
3
=
2
1
1
32 3
x
3
=
=
1
y
3
so that x = 23 and y = 13 .
In general, if we have n linear equations in n unknown variables we may write the
system of equations as
a11 x1 + a12 x2 + + a1n xn = b1
a21 x1 + a22 x2 + + a2n xn = b2
..
.
. = ..
an1 x1 + an2 x2 + + ann xn = bn
7
a11
a21
..
.
an1
or
in matrix form as
a12 a1n
a22 a2n
..
.
an2 ann
x1
x2
..
.
xn
b1
b2
..
.
bn
A x = b.
(nn)
(n1)
(n1)
Further Reading
Excellent treatments of portfolio theory using matrix algebra are given in Ingersol
(1987), Huang and Litzenberger (1988) and Campbell, Lo and MacKinlay (1996).
Problems
To be completed
References
[1] Campbell, J.Y., Lo, A.W., and MacKinlay, A.C. (1997). The Econometrics of
Financial Markets. Priceton, New Jersey: Princeton University Press.
[2] Huang, C.-F., and Litzenbeger, R.H. (1988). Foundations for Financial Economics. New York: North-Holland.
[3] Ingersoll, J.E. (1987). Theory of Financial Decision Making. Totowa, New Jersey:
Rowman & Little&eld.