Matlab flips the eigenvalue and eigenvector of matrix when passing through singularity
Show older comments
Problem: I have a matrix(H(3x3)) in which I vary a parameter(B) and compute the eigenvalues and eigenvectors with varying parameter. I am using the eig() function of matlab. At a particular value of B, the matrix H becomes singular and after that I see in result that the eigenvalues and eigenvectors are flipped automatically. The first and second eigenvectors and eigenvalues changes there place after passing through singularity although they are being calculated correctly. I am sure of it because I have solved the problem analytically.
Mathematical Description: H = [D-B 0 0; 0 0 0; 0 0 D+B]; D=1.5; B=0:0.1:3
eigenvector [0 1 0] corresponds to eigenvalue 0
eigenvector [1 0 0] corresponds to eigenvalue D-B
eigenvector [0 0 1] corresponds to eigenvalue D+B
First eigenvalue should not change through out the variation of parameter B, but one can check that second eigenvalue takes the place of first eigenvalue after passing through the singularity B=D.


Is there any solution for such problems, because in future I will be using higher dimension matrices where it's not analytically possible to calculate eigenvalues.
Accepted Answer
More Answers (0)
Categories
Find more on Linear Algebra in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!