DOLFINx 0.7.3
DOLFINx C++ interface
|
This class provides an eigenvalue solver for PETSc matrices. It is a wrapper for the SLEPc eigenvalue solver. More...
#include <slepc.h>
Public Member Functions | |
SLEPcEigenSolver (MPI_Comm comm) | |
Create eigenvalue solver. | |
SLEPcEigenSolver (EPS eps, bool inc_ref_count) | |
Create eigenvalue solver from EPS object. | |
SLEPcEigenSolver (const SLEPcEigenSolver &)=delete | |
SLEPcEigenSolver (SLEPcEigenSolver &&solver) | |
Move constructor. | |
~SLEPcEigenSolver () | |
Destructor. | |
SLEPcEigenSolver & | operator= (const SLEPcEigenSolver &)=delete |
SLEPcEigenSolver & | operator= (SLEPcEigenSolver &&solver) |
Move assignment. | |
void | set_operators (const Mat A, const Mat B) |
Set operators (B may be nullptr for regular eigenvalues problems) | |
void | solve () |
Compute all eigenpairs of the matrix A (solve \(A x = \lambda x\)) | |
void | solve (std::int64_t n) |
Compute the n first eigenpairs of the matrix A (solve \(A x = \lambda x\)) | |
std::complex< PetscReal > | get_eigenvalue (int i) const |
Get ith eigenvalue. | |
void | get_eigenpair (PetscScalar &lr, PetscScalar &lc, Vec r, Vec c, int i) const |
Get ith eigenpair. | |
int | get_iteration_number () const |
Get the number of iterations used by the solver. | |
std::int64_t | get_number_converged () const |
Get the number of converged eigenvalues. | |
void | set_options_prefix (std::string options_prefix) |
Sets the prefix used by PETSc when searching the PETSc options database. | |
std::string | get_options_prefix () const |
Returns the prefix used by PETSc when searching the PETSc options database. | |
void | set_from_options () const |
Set options from PETSc options database. | |
EPS | eps () const |
Return SLEPc EPS pointer. | |
MPI_Comm | comm () const |
Return MPI communicator. | |
This class provides an eigenvalue solver for PETSc matrices. It is a wrapper for the SLEPc eigenvalue solver.