# Matrices

A matrix is defined as a rectangular array of numbers, e.g.,  which is a (two by two'') matrix. A general matrix may be , where is the number of rows, and is the number of columns of the matrix. For example, the general matrix is Either square brackets or large parentheses may be used to delimit the matrix. The th elementH.1 of a matrix may be denoted by , , or . For example, in the above two examples. The rows and columns of matrices are normally numbered from instead of from 0; thus, and . When , the matrix is said to be square. The transpose of a real matrix is denoted by and is defined by While is , its transpose is . We may say that the rows and columns are interchanged'' by the transpose operation, and transposition can be visualized as flipping'' the matrix about its main diagonal. For example, A complex matrix , is simply a matrix containing complex numbers. The transpose of a complex matrix is normally defined to include conjugation. The conjugating transpose operation is called the Hermitian transpose. To avoid confusion, in this tutorial, and the word transpose'' will always denote transposition without conjugation, while conjugating transposition will be denoted by and be called the Hermitian transpose'' or the conjugate transpose.'' Thus, ## Matrix Multiplication

Let be a general matrix and let denote a general matrix. Denote the matrix product by . Then matrix multiplication is carried out by computing the inner product of every row of with every column of . Let the th row of be denoted by , , and the th column of by , . Then the matrix product is defined as This definition can be extended to complex matrices by using a definition of inner product which does not conjugate its second argument.H.2 Examples:    An matrix can be multiplied on the right by an matrix, where is any positive integer. An matrix can be multiplied on the left by a matrix, where is any positive integer. Thus, the number of columns in the matrix on the left must equal the number of rows in the matrix on the right. Matrix multiplication is non-commutative, in general. That is, normally even when both products are defined (such as when the matrices are square.) The transpose of a matrix product is the product of the transposes in reverse order: The identity matrix is denoted by and is defined as Identity matrices are always square. The identity matrix , sometimes denoted as , satisfies for every matrix . Similarly, , for every matrix . As a special case, a matrix times a vector produces a new vector which consists of the inner product of every row of with  A matrix times a vector defines a linear transformation of . In fact, every linear function of a vector can be expressed as a matrix multiply. In particular, every linear filtering operation can be expressed as a matrix multiply applied to the input signal. As a special case, every linear, time-invariant (LTI) filtering operation can be expressed as a matrix multiply in which the matrix is Toeplitz, i.e., (constant along diagonals). As a further special case, a row vector on the left may be multiplied by a column vector on the right to form a single inner product: ## Solving Linear Equations Using Matrices

Consider the linear system of equations in matrix form: This can be written in higher level form as where denotes the two-by-two matrix above, and and denote the two-by-one vectors. The solution to this equation is then The general two-by-two matrix inverse is given by and the inverse exists whenever (which is called the determinant of the matrix ) is nonzero. For larger matrices, numerical algorithms are used to invert matrices, such as used by Matlab based on LINPACK . An initial introduction to matrices and linear algebra can be found in .
Next Section:
Matlab/Octave Examples
Previous Section:
Number Systems for Digital Audio