Lecture 8 Applications of Vectors and Matrces
Total Page:16
File Type:pdf, Size:1020Kb
Lecture 8: Vectors and Matrices III – Applications of Vectors and Matrices (See Sections 3.2, 3.3 and 3.8 to 3.12 in Boas) As noted in the previous lecture the notation of vectors and matrices is useful not only for the study of linear transformations but also for (the related) problem of solving systems of simultaneous linear equations. Consider N simultaneous linear equations for N unknowns, xk , k 1, , N , A111 x A 122 x A 111NNNN x A 1 x X 1 . (8.1) AN1 x 1 A N 2 x 2 A NN 1 x N 1 A NN x N X N Clearly we are encouraged to think in terms of a NxN matrix representation for the coefficients, Akl , a N-D vector of unknowns, xk , and a N-D vector of known inputs, X l . Then, using the notation we have developed (to simplify our lives), we can write Ax X. (8.2) As long as the matrix A is nonsingular, detA 0 , we can find its inverse and solve the simultaneous equations in matrix form ( CA is the cofactor matrix for A) as defined in Eq. 7.29 in the previous lecture, T NNNCA 11 klXC l lk x A X xk A kl X l X l l1 l 1det AA l 1 det det A (8.3) x k . k det A In the last expression the matrix A is the matrix A with the kth column replaced by k the column vector X , AAXAA11 1k 1 1 1 k 1 1 N A . k (8.4) AAXAAN1 Nk 1 N Nk 1 NN Physics 227 Lecture 8 1 Autumn 2008 We recognize that Eqs. (8.3) and (8.4) define Cramer’s rule (see Section 3.3 in Boas). Next let us consider the more general problem where Eq. (8.2) corresponds to M equations for N unknowns. The vector now has M components, the vector x has N components, and the matrix A is MxN (M rows and N columns). The question to ask first is - when does this system of equations have a solution? This corresponds to determining how many linearly independent equations are present in this revised version of Eq. (8.2). To answer this question we perform the process known as row reduction (i.e., add/subtract rows times constants to/from other rows and interchange rows, See Boas 3.2) to find a new version of the matrix A with as many zero elements as possible in the lower left hand corner (“below the pivot”). This version of A is called the row echelon form. Having performed this process (to the maximum extent possible) we count the number of rows in the reduced matrix (still a MxN matrix) with nonzero elements. Call this number M and label it the rank of the matrix A, where clearly MM . The rank counts the number of linearly independent rows in A and thus the number of linearly independent equations in the original system of equations. ASIDE: We can apply this same idea of linear independence to a general set of functions (not just linear functions). Consider the determinant of the matrix defined in terms of N functions, fk x, k 1, , N , and their derivatives (with respect to x) f12 x f x fN x f x f x f x Wx 12 N . (8.5) NNN1 1 1 f12 f fN This determinant is called the Wronskian of the functions. At values of x where Wx 0, the functions are linearly independent in the sense that (recall our discussion of linearly independent vectors) X N ck f k x 0 c k 0, k 1, , N . (8.6) k1 No linear combination of the functions vanishes except the trivial one (all zero coefficients) in the range of x where . Physics 227 Lecture 8 2 Autumn 2008 Returning to the problem of simultaneous equations we define a new Mx(N+1) matrix, the augmented version of A, which has the column vector as its N 1th column, AAX11 1N 1 A . Aug (8.7) AAXM1 MN M Next we row reduce this matrix to determine its rank. Call this last quantity M Aug and note that cannot be smaller than M , MMMAug , since every row that can be reduced to zeros in AAug can certainly be reduced to zeros in A. Now we can list the various possibilities. 1) If MM Aug (the rank of A is smaller than the rank of ), the equations are inconsistent with each other and there are no solutions to the set of simultaneous equations. 2) If MMNMAug , we can eliminate MM non-independent equations (rows) from the system of equations and arrive at the NxN problem we discussed at the beginning of the lecture. The resulting NxN matrix of coefficients we label ARed , the “reduced” matrix. Since we have eliminated all the rows that have only zero elements, we are guaranteed that the determinant -1 of the reduced matrix, , is nonzero and that an inverse matrix, ARed , exists. Hence we can use this inverse, i.e., Cramer’s rule, to find a unique solution to the system of equations, i.e., a unique value for the N-D column vector -1 x ARed X . 3) If MMNAug , the reduced problem has fewer equations than there are unknowns, i.e., there are not enough independent equations to determine all of the unknowns. Rather the solution to this system corresponds to solving for X M of the unknowns in terms of the other NM unknowns (and the original coefficients and the known vector X ). As an example consider the equations Physics 227 Lecture 8 3 Autumn 2008 x y 2 z 7 7 1 1 2 2x y 4 z 2 M 4 2 2 1 4 ,,.XA 5410x y z 1 N 3 1 5410 (8.8) 3x y 6 z 5 5 3 1 6 Proceeding to row reduce we have 1 1 2 1 1 2 0 3 0 0 3 0 A . RRRR2 2 10 9 0 3 3 2 0 0 0 (8.9) RRRR3 5 1 4 4 3 2 RR4 3 1 0 4 0 0 0 0 Hence we see that the rank of A is M 2 . Proceeding with the augmented matrix we have 1 1 2 7 1 1 2 7 2 1 4 2 0 3 0 12 A Aug 5 4 10 1 RR2 2 1 0 9 0 36 RR3 5 1 3 1 6 5 RR4 3 1 0 4 0 16 1 1 2 7 (8.10) 0 3 0 12 . RR3 3 2 0 0 0 0 RR4 4 3 2 0 0 0 0 Thus we have MMNAug 23 and the problem is under-constrained. We can solve for 2 unknowns in terms of the third. From the revised equations we have x y 2 z 7 x 7 y 2 z 3 2 z . (8.11) 3yy 12 4 The unknown z remains a free variable. The choice of z instead of x to play this role is, of course, arbitrary. Physics 227 Lecture 8 4 Autumn 2008 Now return to Eq. (8.2) and think about it in a slightly different way. What if the right-side-side ( X ) is proportional to the unknown vector x , i.e., can we find a vector such that after we perform the linear transform represented by the matrix A we end up back at times a constant? As we will see, the problem of finding vectors that are invariant (except for a overall constant) under a given transformation is extremely important/useful in physics (here we move to Section 3.11 in Boas, or Chapter 10 in the previous edition of Boas). We want to consider the following new version of Eq. (8.2), Ax x A 1 x 0. (8.12) Note that this version is a homogenous equation. If the matrix A 1 is 1 nonsingular and A 1 exists, we know that the above equation, Eq. (8.12), has only the trivial solution 1 xA 1 0 0. (8.13) Thus, to obtain interesting solutions (and we want to do that), we require that the inverse not exist or that detA1 0. (8.14) This condition, the eigenvalue condition (also called the characteristic equation for A), is an Nth order equation for the parameter generally having N distinct solutions, which may be complex. Note that the eigenvalues are a property of the transformation represented by A, and not of the vectors being transformed. On the other hand, for each specific eigenvalue there is a corresponding vector, the k eigenvectorvk , which satisfies Avk k v k . (8.15) Since this is a homogenous equation, the length of v is not specified (if is a k solution so is cvk , where c is a constant) and typically we choose to make it a unit T vector (to simplify the analysis – the lazy but smart argument), vk v k v k v k 1. (Another way to see this point is to note from Eq. (8.14) that only N-1 of the N Physics 227 Lecture 8 5 Autumn 2008 equations in (8.15) are linearly independent. You should see this explicitly as you solve (8.15).) For complex vectors the normalization choice is typically T † vk v k v k v k v k v k 1, which leaves an overall phase undetermined (i.e., i this constraint is invariant under vkk e v ). We can derive a few important properties of eigenvalues and vectors by considering a pair of distinct eigenvalues, kl, , and the corresponding eigenvectors, vvkl, for a general complex matrix A.