Professional Documents
Culture Documents
Basic Matrix Algebra
Basic Matrix Algebra
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 result is
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.
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
8
e. The inverse of a product is the product of the inverted matrices
Special cases:
The inverse of a diagonal 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
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,
11