Download as pdf or txt
Download as pdf or txt
You are on page 1of 11

BASIC MATRIX ALGEBRA

(Appendix to ch 18 Stock and Watson, appendix A Verbeek)

Notation:
matrices are represented by capital letters in bold, e.g. A, vectors in lowercase bold,
e.g. a, and entries of vectors and matrices are italic (since they are numbers from a
field), e.g. A and a. Index notation is often the clearest way to express definitions, and
is used as standard in the literature. The i, j entry of matrix A is indicated by (A)ij, Aij
or aij, whereas a numerical label (not matrix entries) on a collection of matrices is
subscripted only, e.g. A1, A2, etc.

1
2
Matrix operations

3
That is, the entry cij of the product is obtained by multiplying term-by-term the entries of the ith row
f A and the jth column of B, and summing these n products. In other words, cij is the dot product of
the ith row of A and the jth column of B.

Thus the product AB is defined if and only if the number of columns in A equals the number of rows
in B, in this case n.
The product is carried out columns by rows, if we have A (nxm) and B (mxp)  C is an nxp

4
Example

The first row of the resulting product matrix is

The second row

The result is

Another example: a matrix times a vector

5
6
Determinant
The determinant det(A) or |A| of a square matrix A is a number encoding
certain properties of the matrix. A matrix is invertible if and only if its
determinant is nonzero.
The determinant of 2 x 2 matrices is given by

The determinant of a 3x3 matrix can be computed by using the rule of Sarrus
The rule of Sarrus is a mnemonic for the 3 × 3 matrix determinant: the sum
of the products of three diagonal north-west to south-east lines of matrix
elements, minus the sum of the products of three diagonal south-west to
north-east lines of elements, when the copies of the first two columns of the
matrix are written beside it as in the illustration. This scheme for calculating
the determinant of a 3 × 3 matrix does not carry over into higher dimensions.

Determinant of a generic n x n matrix


The determinant of a matrix of arbitrary size can be defined by the Leibniz
formula or the Laplace formula. (see

7
https://en.wikipedia.org/wiki/Determinant#3_%C3%97_3_matrices or any
textbook on linear algebra).
Notice that (i) the determinant is zero if a column or a row contains only
zeros; (ii) at least a column or a row can be rewritten as a linear combination
of other columns or rows.

Invertible matrix
Let A be a square n by n matrix, its inverse A-1 is such that A-1A=In

Where adj(A) is the adjugate matrix


If B is the inverse of A  AB=I and BA=I

We won’t enter the details of inversion of matrices but it is important here


to know that:
a. An inverse cannot be computed for non square matrix
b. An inverse cannot be computed for non-full rank matrices, i.e. those
having determinant =0
c. The following expressions are equivalent: (i) matrix A has full rank,
(ii) det(A) is non zero, (iii) A is nonsingular, (iv) A is invertible
d. The transpose of an inverse is the inverse of the transpose:

8
e. The inverse of a product is the product of the inverted matrices

Special cases:
The inverse of a diagonal matrix

The inverse of a two by two matrix

For further details see


https://en.wikipedia.org/wiki/Invertible_matrix#In_relation_to_its_adjugat
e
https://en.wikipedia.org/wiki/Adjugate_matrix

9
10
Differentiation
Let x be an n-dimensional column vector. If c is also an n-dimensional
column vector, c’x is a scalar. Let us consider c’x as a function of the vector
x. Then, we can consider the vector of derivatives of cx with respect to each
of the elements in x, that is

More generally, for a vectorial function Ax (where A is a matrix) we have

The element in column i, row j of this matrix is the derivative of the jth
element in the function Ax with respect to xi. Further,

for a symmetric matrix A. If A is not symmetric, we have

11

You might also like