47 #ifndef __Teko_BlockedTpetraOperator_hpp__
48 #define __Teko_BlockedTpetraOperator_hpp__
51 #include "Tpetra_Operator.hpp"
54 #include "Teuchos_RCP.hpp"
56 #include "Thyra_LinearOpBase.hpp"
59 #include "Teko_BlockedReordering.hpp"
60 #include "Teko_TpetraOperatorWrapper.hpp"
61 #include "Teko_TpetraBlockedMappingStrategy.hpp"
62 #include "Teko_ConfigDefs.hpp"
65 namespace TpetraHelpers {
82 const Teuchos::RCP<
const Tpetra::Operator<ST,LO,GO,NT> > & content,
83 const std::string & label=
"<ANYM>");
93 virtual void SetContent(
const std::vector<std::vector<GO> > & vars,
94 const Teuchos::RCP<
const Tpetra::Operator<ST,LO,GO,NT> > & content);
100 { BuildBlockedOperator(); }
102 virtual const Teuchos::RCP<const Tpetra::Operator<ST,LO,GO,NT> > GetContent()
const
103 {
return fullContent_; }
105 virtual const Teuchos::RCP<const Tpetra::Operator<ST,LO,GO,NT> > GetContent()
106 {
return fullContent_; }
108 const Teuchos::RCP<const Tpetra::Operator<ST,LO,GO,NT> > GetBlock(
int i,
int j)
const;
113 void Reorder(
const BlockReorderManager & brm);
120 virtual void WriteBlocks(
const std::string & prefix)
const;
131 virtual int SetUseTranspose(
bool )
134 virtual int ApplyInverse(
const Tpetra::MultiVector<ST,LO,GO,NT> &, Tpetra::MultiVector<ST,LO,GO,NT> &)
const
135 { TEUCHOS_ASSERT(
false);
return -1; }
137 virtual double NormInf()
const
138 { TEUCHOS_ASSERT(
false);
return 0.0; }
141 virtual bool UseTranspose()
const {
return false; }
142 virtual bool HasNormInf()
const {
return false; }
143 virtual const Teuchos::Comm<int> & Comm()
const {
return *fullContent_->getRangeMap()->getComm(); }
145 #ifndef Teko_DEBUG_OFF
152 Teuchos::RCP<const Tpetra::Operator<ST,LO,GO,NT> > fullContent_;
153 Teuchos::RCP<TpetraBlockedMappingStrategy> blockedMapping_;
154 Teuchos::RCP<Thyra::LinearOpBase<ST> > blockedOperator_;
155 Teuchos::RCP<const BlockReorderManager> reorderManager_;
159 void BuildBlockedOperator();
void Reorder(const BlockReorderManager &brm)
virtual void RebuildOps()
void RemoveReording()
Remove any reordering on this object.
Tear about a user specified Tpetra::Operator<ST,LO,GO,NT> (CrsMatrix) using a vector of vectors of GI...
virtual void WriteBlocks(const std::string &prefix) const
BlockedTpetraOperator(const std::vector< std::vector< GO > > &vars, const Teuchos::RCP< const Tpetra::Operator< ST, LO, GO, NT > > &content, const std::string &label="<ANYM>")
bool testAgainstFullOperator(int count, ST tol) const
Helps perform sanity checks.
virtual void SetContent(const std::vector< std::vector< GO > > &vars, const Teuchos::RCP< const Tpetra::Operator< ST, LO, GO, NT > > &content)
Implements the Epetra_Operator interface with a Thyra LinearOperator. This enables the use of absrtac...