38 #ifndef _EPETRAPRECONDITIONER_HPP_ 39 #define _EPETRAPRECONDITIONER_HPP_ 43 #include <Teuchos_ParameterList.hpp> 46 #include <lifev/core/LifeV.hpp> 48 #include <lifev/core/util/Factory.hpp> 49 #include <lifev/core/util/FactorySingleton.hpp> 50 #include <lifev/core/filter/GetPot.hpp> 51 #include <lifev/core/util/Displayer.hpp> 52 #include <lifev/core/array/MatrixEpetra.hpp> 119 const std::string& section,
120 const std::string& subSection ) = 0;
135 virtual void showMe ( std::ostream& output = std::cout )
const;
157 virtual Int Apply (
const Epetra_MultiVector& vector1, Epetra_MultiVector& vector2 )
const;
164 virtual Int ApplyInverse (
const Epetra_MultiVector& vector1, Epetra_MultiVector& vector2 )
const;
virtual Int Apply(const Epetra_MultiVector &vector1, Epetra_MultiVector &vector2) const
Apply the inverse of the preconditioner on vector1 and store the result in vector2.
virtual const Epetra_Map & OperatorRangeMap() const
Return the Range map of the operator.
const bool & preconditionerCreated()
Return true if the preconditioner has been created.
virtual void setDataFromGetPot(const GetPot &dataFile, const std::string §ion)=0
Set the data of the preconditioner using a GetPot object.
SolverAztecOO - Class to wrap linear solver.
bool M_preconditionerCreated
virtual void createParametersList(list_Type &list, const GetPot &dataFile, const std::string §ion, const std::string &subSection)=0
Create the list of parameters of the preconditioner.
void importFromHDF5(std::string const &fileName, std::string const &matrixName="matrix")
Read a matrix from a HDF5 (.h5) file.
std::shared_ptr< comm_Type > commPtr_Type
int32_type Int
Generic integer data.
virtual void showMe(std::ostream &output=std::cout) const
Show informations about the preconditioner.
virtual void setSolver(SolverAztecOO &)
Set the internal solver.
virtual Real condest()=0
Return An estimation of the condition number of the preconditioner.
void updateInverseJacobian(const UInt &iQuadPt)
const list_Type & parametersList() const
Return the parameters list.
virtual std::string preconditionerType()=0
Return the type of preconditioner.
virtual prec_raw_type * preconditioner()=0
Return a raw pointer on the preconditioner.
Epetra_Operator prec_raw_type
virtual Int SetUseTranspose(const bool useTranspose=false)
Set the matrix to be used transposed (or not)
void setParametersList(const list_Type &list)
The the internal list.
Preconditioner(const Preconditioner &preconditioner, const commPtr_Type &comm=commPtr_Type())
Copy constructor.
MatrixEpetra< Real > operator_raw_type
list_Type & parametersList()
Return the parameters list.
virtual Int ApplyInverse(const Epetra_MultiVector &vector1, Epetra_MultiVector &vector2) const
Apply the inverse of the preconditioner on vector1 and store the result in vector2.
Preconditioner(const commPtr_Type &comm=commPtr_Type())
Constructor.
double Real
Generic real data.
Teuchos::ParameterList list_Type
Preconditioner - Abstract preconditioner class.
virtual Int buildPreconditioner(operator_type &matrix)=0
Build a preconditioner based on the given matrix.
std::shared_ptr< prec_raw_type > prec_type
FactorySingleton< Factory< Preconditioner, std::string > > PRECFactory
virtual ~Preconditioner()
Destructor.
virtual const Epetra_Map & OperatorDomainMap() const
Return the Domain map of the operator.
virtual bool UseTranspose()
Return true if the preconditioner is transposed.
virtual void resetPreconditioner()=0
Reset the preconditioner.
std::shared_ptr< operator_raw_type > operator_type
Displayer - This class is used to display messages in parallel simulations.
virtual prec_type preconditionerPtr()=0
Return a shared pointer on the preconditioner.