Reputation: 282
I know that the eigenvectors produced by eig(A) have 2-norm 1. But what about the vectors produced in the generalized eigenvalue problem eig(A,B)? A natural conjecture is that such a vector v should satisfy v'Bv=1. When B is the identity matrix, then v'Bv is exactly the square of the 2-norm. I ran the following test for various matrices A and B:
[p,d]=eig(A,B);
v=p(:,1);
v'*B*v
I always choose B to be diagonal. I noticed that v'Bv is not always 1. However, it is indeed 1 when A is symmetric. Does anyone know the rule for the way that Matlab normalizes the generalized eigenvectors? I can't find it in the document.
Upvotes: 3
Views: 1472
Reputation: 60504
According to the documentation (emphasis mine):
The form and normalization of V depends on the combination of input arguments:
[...]
[V,D] = eig(A,B)
and[V,D] = eig(A,B,algorithm)
returnsV
as a matrix whose columns are the generalized right eigenvectors that satisfyA*V = B*V*D
. The 2-norm of each eigenvector is not necessarily 1. In this case,D
contains the generalized eigenvalues of the pair, (A
,B
), along the main diagonal.When
eig
uses the'chol'
algorithm with symmetric (Hermitian)A
and symmetric (Hermitian) positive definiteB
, it normalizes the eigenvectors inV
so that theB
-norm of each is 1.
This means that, unless you are using the 'chol'
algorithm, V
is not normalized.
Upvotes: 1
Reputation: 478
If I get you correctly, you are looking for a way to generalize a vector then given a vector you can divide it by its norm to obtain a secondary vector whose norm is 1.
If you are looking for the mathematical background, then Eigendecomposition of a matrix contains a good introduction.
Upvotes: 0