This preview has intentionally blurred sections. Sign up to view the full version.
View Full Document
Unformatted text preview: Basic Linear Algebra Linear algebra deals with matrixes: twodimensional arrays of values. Here’s a matrix: 1 5 7 9 3 11 Often matrices are used to describe in a simpler way a series of linear equations. In the example above the matrix might be thought of as the following two linear expressions: 1 x + 5 y + 7 z 9 x + 3 y + 11 z A 1 × n matrix is called a column vector : 4 9 7 Matrices can be added if they have exactly the same dimensions. In this case, you just add the respective values in each position: 1 5 7 9 3 11 + 100 200 300 400 500 600 = 101 205 307 409 503 611 Matrices can also be multiplied , but this means something different than you’d expect. When you multiply the matrices A × B = C , an element at position h x , y i in C is equal to multiplying each element in row x of A times the corresponding element in column y of B, then adding up the sum. This means that the number of columns of A must be equal to the number of rows in B, and C’s rows are the number of rows in A, and its columns are the number of columns in B. a b c d e f m p n q o r = am + bn + co ap + bq + cr dm + en + f o d p + eq + f r Matrix multiplication is associative. That is, ( AB ) C = A ( BC ) . It’s also distributive over addi tion: A ( B + C ) = AB + AC . But unlike normal multiplication, matrix multiplication is not commu tative . The following is not true : AB = BA . However, addition is commutative: A + B = B + A . What can you use matrix multiplication for? Consider the following multiplication: 1 5 7 9 3 11 4 9 7 = 1 × 4 + 5 × 9 + 7 × 7 9 × 4 + 3 × 9 + 11 × 7 = 98 140 If you look carefully, basically the two items in the final column vector are the results of f 1 ( x , y , z ) = 1 x + 5 y + 7 z and f 2 ( x , y , z ) = 9 x + 3 y + 11 z if you pass 4, 9, and 7 in as x, y, and z respectively. When you multiply a matrix against a column vector, think of the matrix’s rows as 1 linear functions and the column vector as the values of the variables you’ll assign to the linear functions. The result is the output of the functions. Since multiple matrices can be multiplied, consider two matrices M and N and a column vector Z. If you write NZ this produces the results of using Z’s variables in the functions in the rows of N. You can then pass the results as variables for M’s functions: M ( NZ ) . But since matrix multiplication is associative, this is the same thing as ( MN ) Z . Let MN equal the matrix O , so now we have OZ . What is O? We have composed the various functions in M against the various functions in N to produce the new functions in O . OZ is the equivalent of multiplying Z by N and then taking that and multiplying it against M....
View
Full
Document
This note was uploaded on 04/07/2010 for the course CS 685 taught by Professor Luke,s during the Fall '08 term at George Mason.
 Fall '08
 Luke,S

Click to edit the document details