Eigenvalues and Eigenvectors
Few concepts to remember from linear algebra Let ๐ฉ be an ๐ร๐ matrix and the linear transformation ๐ = ๐ฉ๐ ๐ฉ ๐ โ โ ๐ ๐ โ โ ๐ โ Rank: maximum number of linearly independent columns or rows of ๐ฉ โข Range ๐ฉ = ๐ = ๐ฉ๐ โ๐} โข Null ๐ฉ = ๐ ๐ฉ๐ = ๐} โข
Eigenvalue problem Let ๐ฉ be an ๐ร๐ matrix: ๐ โ ๐ is an eigenvector of ๐ฉ if there exists a scalar ๐ such that ๐ฉ ๐ = ๐ ๐ where ๐ is called an eigenvalue . If ๐ is an eigenvector, then ฮฑ๐ is also an eigenvector. Therefore, we will usually seek for normalized eigenvectors , so that ๐ = 1 Note: When using Python, numpy.linalg.eig will normalize using p=2 norm.
How do we find eigenvalues? Linear algebra approach: ๐ฉ ๐ = ๐ ๐ ๐ฉ โ ๐ ๐ฑ ๐ = ๐ Therefore the matrix ๐ฉ โ ๐ ๐ฑ is singular โน ๐๐๐ข ๐ฉ โ ๐ ๐ฑ = 0 ๐ ๐ = ๐๐๐ข ๐ฉ โ ๐ ๐ฑ is the characteristic polynomial of degree ๐ . In most cases, there is no analytical formula for the eigenvalues of a matrix (Abel proved in 1824 that there can be no formula for the roots of a polynomial of degree 5 or higher) โน Approximate the eigenvalues numerically !
Example ๐ฉ = 2 1 ๐๐๐ข 2 โ ๐ 1 2 โ ๐ = 0 4 2 4 Solution of characteristic polynomial gives: ๐ . = 4, ๐ / = 0 To get the eigenvectors, we solve: ๐ฉ ๐ = ๐ ๐ ๐ฆ $ ๐ = 1 2 โ (4) 1 = 0 ๐ฆ % 2 4 2 โ (4) 0 ๐ฆ $ 2 โ (0) 1 = 0 ๐ = โ1 ๐ฆ % 4 2 โ (0) 0 2 Notes: The matrix ๐ฉ is singular (det(A)=0), and rank( ๐ฉ )=1 The matrix has two distinct real eigenvalues The eigenvectors are linearly independent
Diagonalizable Matrices A ๐ร๐ matrix ๐ฉ with ๐ linearly independent eigenvectors ๐ is said to be diagonalizable . ๐ฉ ๐ ๐ = ๐ . ๐ ๐ , ๐ฉ ๐ ๐ = ๐ / ๐ ๐ , โฆ ๐ฉ ๐ ๐ = ๐ ; ๐ ๐ , In matrix form: ๐ # 0 0 ๐ฉ ๐ ๐ โฆ ๐ ๐ = ๐ # ๐ ๐ ๐ $ ๐ ๐ = ๐ ๐ โฆ ๐ ๐ โฆ 0 โฑ 0 0 0 ๐ $ This corresponds to a similarity transformation ๐ฉ๐ฝ = ๐ฝ๐ฌ โบ ๐ฉ = ๐ฝ๐ฌ๐ฝ %๐
๐๐๐ข 2 โ ๐ 1 ๐ฉ = 2 1 Example 2 โ ๐ = 0 4 4 2 Solution of characteristic polynomial gives: ๐ . = 4, ๐ / = 0 To get the eigenvectors, we solve: ๐ฉ ๐ = ๐ ๐ ๐ฆ $ ๐ = 0.447 2 โ (4) 1 = 0 ๐ = 1 or normalized ๐ฆ % 0.894 4 2 โ (4) 0 2 eigenvector ( ๐ = 2 norm) ๐ฆ $ ๐ = โ0.447 2 โ (0) 1 ๐ = โ1 = 0 ๐ฆ % 0.894 2 4 2 โ (0) 0 ๐ฝ = 0.447 โ0.447 ๐ฌ = 4 0 ๐ฉ = ๐ฝ๐ฌ๐ฝ <. 0.894 0.894 0 0 Notes: The matrix ๐ฉ is singular (det(A)=0), and rank( ๐ฉ )=1 Since ๐ฉ has two linearly independent eigenvectors, the matrix ๐ฝ is full rank, and hence, the matrix ๐ฉ is diagonalizable.
Example The eigenvalues of the matrix: ๐ฉ = 3 โ18 2 โ9 are ๐ . = ๐ / = โ3 . Select the incorrect statement: A) Matrix ๐ฉ is diagonalizable B) The matrix ๐ฉ has only one eigenvalue with multiplicity 2 C) Matrix ๐ฉ has only one linearly independent eigenvector D) Matrix ๐ฉ is not singular
Letโs look back at diagonalizationโฆ 1) If a ๐ร๐ matrix ๐ฉ has ๐ linearly independent eigenvectors ๐ then ๐ฉ is diagonalizable, i.e., ๐ฉ = ๐ฝ๐ฌ๐ฝ <๐ where the columns of ๐ฝ are the linearly independent normalized eigenvectors ๐ of ๐ฉ (which guarantees that ๐ฝ <๐ exists) and ๐ฌ is a diagonal matrix with the eigenvalues of ๐ฉ . 2) If a ๐ร๐ matrix ๐ฉ has less then ๐ linearly independent eigenvectors, the matrix is called defective (and therefore not diagonalizable). 3) If a ๐ร๐ symmetric matrix ๐ฉ has ๐ distinct eigenvalues then ๐ฉ is diagonalizable.
A ๐ร๐ symmetric matrix ๐ฉ with ๐ distinct eigenvalues is diagonalizable. Suppose ๐ , ๐ and ๐, ๐ are eigenpairs of ๐ฉ ๐ ๐ = ๐ฉ๐ ๐ ๐ = ๐ฉ๐ ๐ ๐ = ๐ฉ๐ โ ๐ 1 ๐ ๐ = ๐ 1 ๐ฉ๐ ๐ ๐ 1 ๐ = ๐ฉ ๐ผ ๐ 1 ๐ = ๐ฉ ๐ 1 ๐ = ๐ ๐ 1 ๐ โ ๐ โ ๐ ๐ 1 ๐ = 0 If all ๐ eigenvalues are distinct โ ๐ โ ๐ โ 0 Hence, ๐ 1 ๐ = 0 , i.e., the eigenvectors are orthogonal (linearly independent), and consequently the matrix ๐ฉ is diagonalizable. Note that a diagonalizable matrix ๐ฉ does not guarantee ๐ distinct eigenvalues.
Some things to remember about eigenvalues: โข Eigenvalues can have zero value โข Eigenvalues can be negative โข Eigenvalues can be real or complex numbers โข A ๐ร๐ real matrix can have complex eigenvalues โข The eigenvalues of a ๐ร๐ matrix are not necessarily unique. In fact, we can define the multiplicity of an eigenvalue. โข If a ๐ร๐ matrix has ๐ linearly independent eigenvectors, then the matrix is diagonalizable
How can we get eigenvalues numerically? Assume that ๐ฉ is diagonalizable (i.e., it has ๐ linearly independent eigenvectors ๐ ). We can propose a vector ๐ which is a linear combination of these eigenvectors: ๐ = ๐ฝ # ๐ # + ๐ฝ ' ๐ ' + โฏ + ๐ฝ $ ๐ $ Then we evaluate ๐ฉ ๐ : ๐ฉ ๐ = ๐ฝ # ๐ฉ๐ # + ๐ฝ ' ๐ฉ๐ ' + โฏ + ๐ฝ $ ๐ฉ๐ $ And since ๐ฉ๐ # = ๐ # ๐ # we can also write: ๐ฉ ๐ = ๐ฝ # ๐ # ๐ # + ๐ฝ ' ๐ ' ๐ ' + โฏ + ๐ฝ $ ๐ $ ๐ $ where ๐ ( is the eigenvalue corresponding to eigenvector ๐ ( and we assume |๐ # | > |๐ ' | โฅ |๐ ) | โฅ โฏ โฅ |๐ $ |
Power Iteration Our goal is to find an eigenvector ๐ ( of ๐ฉ. We will use an iterative process, where we start with an initial vector, where here we assume that it can be written as a linear combination of the eigenvectors of ๐ฉ . ๐ * = ๐ฝ # ๐ # + ๐ฝ ' ๐ ' + โฏ + ๐ฝ $ ๐ $ And multiply by ๐ฉ to get: ๐ # = ๐ฉ ๐ * = ๐ฝ # ๐ # ๐ # + ๐ฝ ' ๐ ' ๐ ' + โฏ + ๐ฝ $ ๐ $ ๐ $ ๐ ' = ๐ฉ ๐ # = ๐ฝ # ๐ # ' ๐ # + ๐ฝ ' ๐ ' ' ๐ ' + โฏ + ๐ฝ $ ๐ $ ' ๐ $ โฎ ๐ + = ๐ฉ ๐ +%# = ๐ฝ # ๐ # + ๐ # + ๐ฝ ' ๐ ' + ๐ ' + โฏ + ๐ฝ $ ๐ $ + ๐ $ Or rearrangingโฆ + + ๐ ' ๐ $ ๐ + = ๐ # + ๐ฝ # ๐ # + ๐ฝ ' ๐ ' + โฏ + ๐ฝ $ ๐ $ ๐ # ๐ #
Power Iteration B B ๐ / ๐ ; ๐ B = ๐ . B ๐ฝ . ๐ . + ๐ฝ / ๐ / + โฏ + ๐ฝ ; ๐ ; ๐ . ๐ . Assume that ๐ฝ . โ 0 , the term ๐ฝ . ๐ . dominates the others when ๐ is very large. B Since |๐ . > |๐ / , we have C ! โช 1 when ๐ is large C " Hence, as ๐ increases, ๐ B converges to a multiple of the first eigenvector ๐ . , i.e., C " # = ๐ฝ . ๐ . or ๐ B โ ๐ฝ . ๐ . B ๐ . ๐ # lim BโD
How can we now get the eigenvalues? If ๐ is an eigenvector of ๐ฉ such that ๐ฉ ๐ = ๐ ๐ then how can we evaluate the corresponding eigenvalue ๐ ? ๐ = ๐ ๐ผ ๐ฉ๐ Rayleigh coefficient ๐ ๐ผ ๐
Normalized Power Iteration & & ๐ % ๐ ' ๐ & = ๐ $ & ๐ฝ $ ๐ $ + ๐ฝ % ๐ % + โฏ + ๐ฝ ' ๐ ' ๐ $ ๐ $ ๐ ๐ = arbitrary nonzero vector ๐ ๐ ๐ ๐ = ๐ ๐ for ๐ = 1,2, โฆ ๐ B = ๐ฉ ๐ B<. ๐ # ๐ B = ๐ #
Normalized Power Iteration B B ๐ / ๐ ; ๐ B = ๐ . B ๐ฝ . ๐ . + ๐ฝ / ๐ / + โฏ + ๐ฝ ; ๐ ; ๐ . ๐ . What if the starting vector ๐ ๐ have no component in the dominant eigenvector ๐ $ ( ๐ฝ $ = 0 )? Demo โPower Iteration
Normalized Power Iteration B B ๐ / ๐ ; ๐ B = ๐ . B ๐ฝ . ๐ . + ๐ฝ / ๐ / + โฏ + ๐ฝ ; ๐ ; ๐ . ๐ . What if the first two largest eigenvalues (in magnitude) are the same, |๐ $ = |๐ % ? B B ๐ B = ๐ . B ๐ฝ . ๐ . + ๐ . B ๐ / ๐ ; ๐ฝ / ๐ / + ๐ . B โฆ + ๐ฝ ; ๐ ; ๐ . ๐ . Demo โPower Iteration
Potential pitfalls Starting vector ๐ ๐ may have no component in the dominant eigenvector ๐ " (๐ฝ " = 1. 0) . This is usually unlikely to happen if ๐ ๐ is chosen randomly, and in practice not a problem because rounding will usually introduce such component. 2. Risk of eventual overflow (or underflow): in practice the approximated eigenvector is normalized at each iteration (Normalized Power Iteration) First two largest eigenvalues (in magnitude) may be the same: |๐ " | = |๐ # | . In this 3. case, power iteration will give a vector that is a linear combination of the corresponding eigenvectors: โข If signs are the same, the method will converge to correct magnitude of the eigenvalue. If the signs are different, the method will not converge. โข This is a โrealโ problem that cannot be discounted in practice.
Error B B ๐ / ๐ ; ๐ B = ๐ . B ๐ฝ . ๐ . + ๐ฝ / ๐ / + โฏ + ๐ฝ ; ๐ ; ๐ . ๐ . ๐น๐ ๐ ๐๐ We can see from the above that the rate of convergence depends on the ratio C ! C " , that is: B ๐ / ๐ . <B ๐ B โ ๐ฝ . ๐ . = ๐ ๐ .
Convergence and error B ๐ B = ๐ . + ๐ฝ / ๐ / ๐ / + โฏ ๐ฝ . ๐ . ๐ & ๐ PQR ๐ P โ ? S ? R Power method has linear convergence, which is quite slow.
Iclicker question A) 0.1536 B) 0.192 C) 0.09 D) 0.027
Recommend
More recommend