Why does "polyeig" returns eigenvectors that have smaller size than number of eigenvalues?

3 ビュー (過去 30 日間)
I tried to solve an eigenvalue problem with " polyeig ". It correctly evaluated eigenvalues, however eigenvectors are not same as correct answer, which are obtained using " eig ". Do you know why " polyeig " returns smaller size eigenvectors?
This matter is clearly noted in the explanation of " polyeig ": [X,e] = polyeig(A0,A1,...,Ap) also returns matrix X, of size n-by-n*p, whose columns are the eigenvectors.
  2 件のコメント
Steven Lord
Steven Lord 2018 年 8 月 2 日
Please show us a small sample of code that illustrates the difference.
Masoud
Masoud 2018 年 8 月 2 日
In this code, eigenvectors of matrix A is calculated using both "eig" and "polyeig" and size of answer matrices are not same (I mean number of rows of X1 and X2).

サインインしてコメントする。

採用された回答

David Goodmanson
David Goodmanson 2018 年 8 月 2 日
編集済み: David Goodmanson 2018 年 8 月 2 日
Hi Masoud,
Your matrix A is 402x402. Denote Gamma by G and Omega by W, both 201x201. Let each eigenvector of A be the concatenation [u; v] where u and v are each 201x1. The system of equations is
Wu + Gv = bu (1)
-G'u - Wv = bv (2)
with eigenvalue b.
Working out polyeig for u gives the formulas you got. Both polyeig(A0,A21,A2) and eig(A) have 402 eigenvalues, and each polyeig eigenvector u is 201x1 as you noted. To obtain the second half of the eigenvector of A, you can invert (1) and use
v = G\(bu-Wu)
  3 件のコメント
David Goodmanson
David Goodmanson 2018 年 8 月 2 日
編集済み: David Goodmanson 2018 年 8 月 2 日
Hi Masoud,
I'm taking the point of view that it doesn't really matter what Gamma and Omega are as long as they are complex square matrices of the same size. The code below is basically a copy of yours once the matrices have been created. All the eigenvalues come out the same between the two methods. So it appears to work. But your case appears to come out differently ?!
If in your case Gamma has a large condition number, there could of course be some problems.
n = 201;
Gamma = 2*rand(n,n)-1 +i*(2*rand(n,n)-1);
Omega = 2*rand(n,n)-1 +i*(2*rand(n,n)-1);
A=[Omega Gamma;-Gamma' -Omega];
A0=Gamma'-((Omega/Gamma)*Omega);
A1=(Omega/Gamma)-(Gamma\Omega);
A2=inv(Gamma);
[X1 e1] = polyeig(A0,A1,A2); % e1 is a vector
[X2 e2] = eig(A); % e2 is a diagonal matrix
e2vec = diag(e2);
figure(1)
plot(e1)
hold on
plot(e2vec,'o')
hold off
Masoud
Masoud 2018 年 8 月 3 日
編集済み: Masoud 2018 年 8 月 3 日
Why do you plotted eigenvalues in your code? My problem is eigenvectors, and even in your example, your proposed formula is not working.

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeLinear Algebra についてさらに検索

タグ

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by