Class to find the smallest eigenvalues and corresponding eigenvectors in a generalized eigenproblem using the Bathe subspace iteration method. More...
Public Member Functions | |
Eigen () | |
Default constructor. Sets default parameters. | |
Eigen (SkSMatrix< double > &K, SkSMatrix< double > &M) | |
Constructor for Symmetric Skyline Matrices. More... | |
Eigen (SkSMatrix< double > &K, Vect< double > &M) | |
Constructor for Symmetric Skyline Matrices. More... | |
Eigen (DSMatrix< double > &K) | |
Constructor for a dense matrix. More... | |
~Eigen () | |
Destructor. | |
void | setMatrix (SkSMatrix< double > &K, SkSMatrix< double > &M) |
Set matrix instances (Symmetric matrices). More... | |
void | setMatrix (SkSMatrix< double > &K, Vect< double > &M) |
Set matrix instances (Symmetric matrices). More... | |
void | setMatrix (DSMatrix< double > &K) |
Set matrix instance (Symmetric matrix). More... | |
int | runSubSpace (int nb_eigv, int ss_dim=0) |
Run the subspace iteration solver. More... | |
void | setSubspaceDimension (int dim) |
Define the subspace dimension. More... | |
void | setMaxIter (int max_it) |
set maximal number of iterations. | |
int | getNbIter () const |
Return actual number of performed iterations. | |
void | setTolerance (double eps) |
set tolerance value More... | |
int | checkSturm (int &nb_found, int &nb_lost) |
Check how many eigenvalues have been found using Sturm sequence method. More... | |
double | getEigenValue (int n) const |
Return the n-th eigenvalue. | |
void | getEigenVector (int n, Vect< double > &v) const |
Return the n-th eigenvector. More... | |
Detailed Description
Class to find the smallest eigenvalues and corresponding eigenvectors in a generalized eigenproblem using the Bathe subspace iteration method.
Constructor & Destructor Documentation
Constructor for Symmetric Skyline Matrices.
- Parameters
-
[in] K Stiffness matrix [in] M "Mass" matrix
- Note
- The generalized eigenvalue problem is defined by
Kx = aMx
, whereK
andM
are referred to as stiffness and mass matrix. The mass matrix can be diagonal (lumped) or not (consistent). In the first case, it is better to choose a constructor where this matrix is stored in a vector.
Constructor for Symmetric Skyline Matrices.
- Parameters
-
[in] K "Stiffness" matrix [in] M Diagonal "Mass" matrix stored as a Vect instance
- Note
- The generalized eigenvalue problem is defined by
Kx = aMx
, whereK
andM
are referred to as stiffness and mass matrix.
Constructor for a dense matrix.
- Parameters
-
[in] K Matrix for which eigenmodes are sought.
Member Function Documentation
Set matrix instances (Symmetric matrices).
This function is to be used when the default constructor is applied. Case where the mass matrix is consistent.
- Parameters
-
[in] K Stiffness matrix instance [in] M Mass matrix instance
Set matrix instances (Symmetric matrices).
This function is to be used when the default constructor is applied. Case where the mass matrix is (lumped) diagonal and stored in a vector.
- Parameters
-
[in] K Stiffness matrix instance [in] M Mass matrix instance where diagonal terms are stored as a vector.
void setMatrix | ( | DSMatrix< double > & | K | ) |
Set matrix instance (Symmetric matrix).
This function is to be used when the default constructor is applied. Case of a standard (not generalized) eigen problem is to be solved
- Parameters
-
[in] K Stiffness matrix instance
int runSubSpace | ( | int | nb_eigv, |
int | ss_dim = 0 |
||
) |
Run the subspace iteration solver.
- Parameters
-
[in] nb_eigv Number of eigenvalues to be extracted [in] ss_dim Subspace dimension. Must be at least equal to the number eigenvalues to seek. [Default: nb_eigv
- Returns
- 1: Normal execution. Convergence has been achieved. 2: Convergence for eigenvalues has not been attained.
void setSubspaceDimension | ( | int | dim | ) |
Define the subspace dimension.
- Parameters
-
[in] dim Subspace dimension. Must be larger or equal to the number of wanted eigenvalues. By default this value will be set to the number of wanted eigenvalues
void setTolerance | ( | double | eps | ) |
set tolerance value
- Parameters
-
[in] eps Convergence tolerance for eigenvalues [Default: 1.e-8]
int checkSturm | ( | int & | nb_found, |
int & | nb_lost | ||
) |
Check how many eigenvalues have been found using Sturm sequence method.
- Parameters
-
[out] nb_found number of eigenvalues actually found [out] nb_lost number of eigenvalues missing
- Returns
- - 0, Successful completion of subroutine.
- 1, No convergent eigenvalues found.