47 #ifndef __Teko_BlockInvDiagonalStrategy_hpp__
48 #define __Teko_BlockInvDiagonalStrategy_hpp__
53 #include "Teuchos_RCP.hpp"
56 #include "Thyra_LinearOpBase.hpp"
60 #include "Teko_InverseFactory.hpp"
61 #include "Teko_BlockPreconditionerFactory.hpp"
85 std::vector<LinearOp> & invDiag)
const = 0;
98 const LinearOp & invD1)
99 { invDiag_.push_back(invD0); invDiag_.push_back(invD1); }
111 std::vector<LinearOp> & invDiag)
const
112 { invDiag.clear(); invDiag = invDiag_; }
116 std::vector<Teuchos::RCP<const Thyra::LinearOpBase<double> > > invDiag_;
140 const Teuchos::RCP<InverseFactory> & defaultFact=Teuchos::null);
152 std::vector<LinearOp> & invDiag)
const;
155 const std::vector<Teuchos::RCP<InverseFactory> > &
getFactories()
const
156 {
return invDiagFact_; }
160 std::vector<Teuchos::RCP<InverseFactory> > invDiagFact_;
161 Teuchos::RCP<InverseFactory> defaultInvFact_;
166 const std::string & opPrefix,
int i)
const;
Abstract class for building an inverse operator.
virtual void getInvD(const BlockedLinearOp &A, BlockPreconditionerState &state, std::vector< LinearOp > &invDiag) const
LinearOp buildInverse(const InverseFactory &invFact, const LinearOp &matrix, BlockPreconditionerState &state, const std::string &opPrefix, int i) const
Conveinence function for building inverse operators.
virtual void getInvD(const BlockedLinearOp &, BlockPreconditionerState &, std::vector< LinearOp > &invDiag) const
An implementation of a state object for block preconditioners.
const std::vector< Teuchos::RCP< InverseFactory > > & getFactories() const
Get factories for testing purposes.
virtual void getInvD(const BlockedLinearOp &A, BlockPreconditionerState &state, std::vector< LinearOp > &invDiag) const =0
returns an (approximate) inverse of the diagonal blocks of A