public class Eigen extends Object
Eigen computes the eigenvalues and eigenvectors of a real
matrix. The matrix is first balanced. Orthogonal similarity transformations
are used to reduce the balanced matrix to a real upper Hessenberg matrix.
The implicit double-shifted QR algorithm is used to compute the eigenvalues
and eigenvectors of this Hessenberg matrix. The eigenvectors are normalized
such that each has Euclidean length of value one. The largest component is
real and positive.
The balancing routine is based on the EISPACK routine
The reduction routine is based on the EISPACK routines
ORTRAN. The QR algorithm routine is based on the EISPACK routine
HQR2. See Smith et al. (1976) for the EISPACK routines. Further
details, some timing data, and credits are given in Hanson et al. (1990).
While the exact value of the performance index, ,
is highly machine dependent, the performance of
considered excellent if , good if
, and poor if
The performance index was first developed by the EISPACK project at Argonne National Laboratory; see Smith et al. (1976, pages 124-125).
|Modifier and Type||Class and Description|
The iteration did not converge
|Constructor and Description|
Constructs the eigenvalues and the eigenvectors of a real square matrix.
|Modifier and Type||Method and Description|
Returns the maximum number of iterations.
Returns the eigenvalues of a matrix of type
Returns the eigenvectors.
Returns the performance index of a real eigensystem.
Set the maximum number of iterations allowed.
Solves for the eigenvalues and (optionally) the eigenvectors of a real square matrix.
public int getMaxIterations()
intcontaining the maximum number of iterations.
public Complex getValues()
Complexarray containing the eigenvalues of this matrix in descending order
public Complex getVectors()
Complexmatrix containing the eigenvectors. The eigenvector corresponding to the j-th eigenvalue is stored in the j-th column. Each vector is normalized to have Euclidean length one.
public double performanceIndex(double a)
doublescalar value indicating how well the algorithms which have computed the eigenvalue and eigenvector pairs have performed. A performance index less than 1 is considered excellent, 1 to 100 is good, while greater than 100 is considered poor.
public void setMaxIterations(int maxIterations)
intspecifying the maximum number of iterations allowed.
maxIterationsmust be greater than 0. By default,
public void solve(double a, boolean computeVectors) throws Eigen.DidNotConvergeException
a- is the
doublesquare matrix for which the eigenvalues and (optionally) eigenvectors are to be found
computeVectors- is true if the eigenvectors are to be computed
Eigen.DidNotConvergeException- is thrown when the algorithm fails to converge on the eigenvalues of the matrix.
Copyright © 1970-2015 Rogue Wave Software
Built October 13 2015.