Registered Member
|
Hello everyone !
I computed with Matlab :
And with Eigen :
I have the same eigenvalues in the two cases (except the lowest in the range of 10^-15) but the eigenvectors are really very different. The matrix A is complex. I noticed more the dimensions of A are important, better is the precision. The errors are much more significant at the level of the imaginary part of the eigenvectors than at the level of the real part. Do you see where this problem comes from ? |
Moderator
|
First of all make such that A is self-adjoint, that is (A-A.adjoint()).norm() / A.norm() is below 1e-16. Then, recall that the eigenvectors are not unique. If v is an eigenvector, then -v is also a valid eigenvector. Moreover, the multiplicity of eigenvalue is greater to 1, then the respective eigenvectors can be arbitrarily chosen within the sub-space they define. Finally, you can check the accuracy yourself with:
(A * eigenVec - eigenVec * eigenVal.asDiagonal()).norm() / A.norm() If you see a large error, then please provide an example. |
Registered Member
|
Hi, ggael I also noticed this porb. It seems like a "-" is miss, as listed in: viewtopic.php?f=74&t=133853&p=359766&hilit=SelfAdjointEigenSolver%3CMatrixXcd%3E#p359766 |
Registered users: Bing [Bot], blue_bullet, Google [Bot], rockscient, Yahoo [Bot]