42 #ifdef HAVE_TRILINOS_ANASAZI 44 #ifndef EIGENSOLVER_HPP 45 #define EIGENSOLVER_HPP 48 #include <Epetra_MultiVector.h> 49 #include <Epetra_SerialDenseVector.h> 50 #include <Epetra_Operator.h> 51 #include <Epetra_CrsMatrix.h> 53 #include <Teuchos_RefCountPtrDecl.hpp> 55 #include <AnasaziBlockDavidson.hpp> 56 #include <AnasaziLOBPCG.hpp> 57 #include <AnasaziBasicOutputManager.hpp> 58 #include <AnasaziBasicSort.hpp> 59 #include <AnasaziConfigDefs.hpp> 60 #include <AnasaziBasicEigenproblem.hpp> 61 #include <AnasaziBlockKrylovSchurSolMgr.hpp> 62 #include <AnasaziLOBPCGSolMgr.hpp> 63 #include <AnasaziEpetraAdapter.hpp> 66 #include <lifev/core/LifeV.hpp> 68 #include <lifev/core/filter/GetPot.hpp> 73 class UNDEF_EIGENSOLVER_EXCEPTION;
93 typedef double data_Type;
94 typedef Epetra_Operator solver_Type;
95 typedef Epetra_MultiVector vector_Type;
97 typedef Anasazi::BasicEigenproblem<data_Type, vector_Type, solver_Type> eigenpb_Type;
98 typedef Teuchos::RCP<Anasazi::BasicEigenproblem<data_Type, vector_Type, solver_Type> > eigenpbPtr_Type;
99 typedef Anasazi::BlockKrylovSchurSolMgr <data_Type, vector_Type, solver_Type> eigensolver_Type;
100 typedef std::shared_ptr<eigensolver_Type> eigensolverPtr_Type;
106 EigenSolver (std::shared_ptr<solver_Type>
const matrix, Epetra_BlockMap
const& block_map,
long unsigned int numvec);
108 virtual ~EigenSolver()
117 void setDataFromGetPot ( GetPot
const& dataFile, std::string
const& section );
120 void setHermitian (
bool flag)
122 MyProblem->setHermitian (flag);
126 void eigenvalues (std::vector< data_Type>& realPart, std::vector< data_Type>& imgPart);
136 Teuchos::RCP<vector_Type> M_eigenVectors;
137 eigenpbPtr_Type MyProblem;
138 Teuchos::ParameterList MyPL;
139 eigensolverPtr_Type MySolver;
143 class UNDEF_EIGENSOLVER_EXCEPTION
146 UNDEF_EIGENSOLVER_EXCEPTION() {}
147 virtual ~UNDEF_EIGENSOLVER_EXCEPTION() {}