1、Yang JCollege of Computer Science & TechnologyBeijing University of Posts & TelecommunicationsMatrices( 矩阵)2* College of Computer Science & Technology, BUPT 2.6 Matricesn A matrix is a rectangular array of objects (usually numbers).n An mn (“m by n”) matrix has exactly m horizontal rows, and n verti
2、cal columns.n Plural of matrix = matrices (say MAY-trih-sees)n An nn matrix is called a square matrix,whose order or rank is n.a 32 matrixNote: The singular formof “matrices” is “matrix,”not “MAY-trih-see”!3* College of Computer Science & Technology, BUPT Applications of MatricesTons of applications
3、, including:n Solving systems of linear equationsn Computer Graphics, Image Processingn Models within many areas of Computational Science & Engineeringn Quantum Mechanics, Quantum Computingn Many, many more4* College of Computer Science & Technology, BUPT Matrix Equalityn Two matrices A and B are co
4、nsidered equal iff they have the same number of rows, the same number of columns, and all their corresponding elements are equal.5* College of Computer Science & Technology, BUPT Row and Column Ordern The rows in a matrix are usually indexed 1 to m from top to bottom. The columns are usually indexed
5、 1 to n from left to right. Elements are indexed by row, then column.6* College of Computer Science & Technology, BUPT Matrices as Functionsn An mn matrix A = ai,j of members of a set S can be encoded as a partial function fA: NN S, such that for im, jn, fA(i, j) = ai,j.n By extending the domain ove
6、r which fA is defined, various types of infinite and/or multidimensional matrices can be obtained.7* College of Computer Science & Technology, BUPT Matrix Sumsn The sum A+B of two matrices A, B (which must have the same number of rows, and the same number of columns) is the matrix (also with the sam
7、e shape) given by adding corresponding elements of A and B.A+B = ai,j+bi,j8* College of Computer Science & Technology, BUPT Matrix Productsn For an mk matrix A and a kn matrix B, the product AB is the mn matrix:n I.e., the element of AB indexed (i,j) is given by the vector dot product of the ith row
8、 of A and the jth column of B (considered as vectors).n Note: Matrix multiplication is not commutative!9* College of Computer Science & Technology, BUPT Matrix Product Examplen An example matrix multiplication to practice in class:10* College of Computer Science & Technology, BUPT nnIdentity Matricesn The identity matrix of order n, In, is the rank-n square matrix with 1s along the upper-left to lower-right diagonal, and 0s everywhere else. Kronecker Delta1i,jn