43 #ifndef IFPACK2_BLOCKRELAXATION_DEF_HPP
44 #define IFPACK2_BLOCKRELAXATION_DEF_HPP
46 #include "Ifpack2_BlockRelaxation_decl.hpp"
47 #include "Ifpack2_LinearPartitioner_decl.hpp"
52 template<
class MatrixType,
class ContainerType>
55 Time_( Teuchos::
rcp( new Teuchos::Time(
"Ifpack2::BlockRelaxation") ) ),
57 PartitionerType_(
"linear"),
59 PrecType_(Ifpack2::JACOBI),
60 MinDiagonalValue_(0.0),
63 ZeroStartingSolution_(true),
66 IsInitialized_(false),
81 Teuchos::typeName(*
this) <<
"::BlockRelaxation(): input matrix reference was null.");
85 template<
class MatrixType,
class ContainerType>
90 template<
class MatrixType,
class ContainerType>
98 if (PrecType_ == Ifpack2::JACOBI)
100 else if (PrecType_ == Ifpack2::GS)
102 else if (PrecType_ == Ifpack2::SGS)
103 PT =
"Symmetric Gauss-Seidel";
108 PrecType_ = Ifpack2::JACOBI;
109 else if (PT ==
"Gauss-Seidel")
110 PrecType_ = Ifpack2::GS;
111 else if (PT ==
"Symmetric Gauss-Seidel")
112 PrecType_ = Ifpack2::SGS;
114 std::ostringstream osstr;
115 osstr <<
"Ifpack2::BlockRelaxation::setParameters: unsupported parameter-value for 'relaxation: type' (" << PT <<
")";
116 std::string str = osstr.str();
117 throw std::runtime_error(str);
130 if (PrecType_ != Ifpack2::JACOBI)
132 if (NumLocalBlocks_ < 0)
133 NumLocalBlocks_ = A_->getNodeNumRows() / (-NumLocalBlocks_);
139 "Ifpack2::BlockRelaxation:setParameters ERROR: 'relaxation: backward mode' == true is not supported yet.");
148 template<
class MatrixType,
class ContainerType>
151 return A_->getComm();
155 template<
class MatrixType,
class ContainerType>
156 Teuchos::RCP<
const Tpetra::RowMatrix<
typename MatrixType::scalar_type,
157 typename MatrixType::local_ordinal_type,
158 typename MatrixType::global_ordinal_type,
159 typename MatrixType::node_type> >
165 template<
class MatrixType,
class ContainerType>
166 const Teuchos::RCP<
const Tpetra::Map<
typename MatrixType::local_ordinal_type,
167 typename MatrixType::global_ordinal_type,
168 typename MatrixType::node_type> >&
170 return A_->getDomainMap();
174 template<
class MatrixType,
class ContainerType>
175 const Teuchos::RCP<
const Tpetra::Map<
typename MatrixType::local_ordinal_type,
176 typename MatrixType::global_ordinal_type,
177 typename MatrixType::node_type> >&
179 return A_->getRangeMap();
183 template<
class MatrixType,
class ContainerType>
189 template<
class MatrixType,
class ContainerType>
191 return(NumInitialize_);
195 template<
class MatrixType,
class ContainerType>
201 template<
class MatrixType,
class ContainerType>
207 template<
class MatrixType,
class ContainerType>
209 return(InitializeTime_);
213 template<
class MatrixType,
class ContainerType>
215 return(ComputeTime_);
219 template<
class MatrixType,
class ContainerType>
225 template<
class MatrixType,
class ContainerType>
227 return(ComputeFlops_);
231 template<
class MatrixType,
class ContainerType>
237 template<
class MatrixType,
class ContainerType>
245 template<
class MatrixType,
class ContainerType>
249 typename MatrixType::local_ordinal_type MaxIters,
251 const Teuchos::Ptr<
const Tpetra::RowMatrix<
typename MatrixType::scalar_type,
252 typename MatrixType::local_ordinal_type,
253 typename MatrixType::global_ordinal_type,
254 typename MatrixType::node_type> > &matrix)
261 Condest_ = Ifpack2::Condest(*
this, CT, MaxIters, Tol, matrix);
267 template<
class MatrixType,
class ContainerType>
269 const Tpetra::MultiVector<
typename MatrixType::scalar_type,
270 typename MatrixType::local_ordinal_type,
271 typename MatrixType::global_ordinal_type,
272 typename MatrixType::node_type>& X,
273 Tpetra::MultiVector<
typename MatrixType::scalar_type,
274 typename MatrixType::local_ordinal_type,
275 typename MatrixType::global_ordinal_type,
276 typename MatrixType::node_type>& Y,
282 "Ifpack2::BlockRelaxation::apply ERROR: isComputed() must be true prior to calling apply.");
285 "Ifpack2::BlockRelaxation::apply ERROR: X.getNumVectors() != Y.getNumVectors().");
288 "Ifpack2::BlockRelaxation::apply ERORR: transpose modes not supported.");
295 if (X.getLocalMV().getValues() == Y.getLocalMV().getValues())
296 Xcopy =
Teuchos::rcp(
new Tpetra::MultiVector<Scalar,LocalOrdinal,GlobalOrdinal,Node>(X) );
300 if (ZeroStartingSolution_)
305 case Ifpack2::JACOBI:
306 ApplyInverseJacobi(*Xcopy,Y);
309 ApplyInverseGS(*Xcopy,Y);
312 ApplyInverseSGS(*Xcopy,Y);
315 throw std::runtime_error(
"Ifpack2::BlockRelaxation::apply internal logic error.");
320 ApplyTime_ += Time_->totalElapsedTime();
324 template<
class MatrixType,
class ContainerType>
326 const Tpetra::MultiVector<
typename MatrixType::scalar_type,
327 typename MatrixType::local_ordinal_type,
328 typename MatrixType::global_ordinal_type,
329 typename MatrixType::node_type>& X,
330 Tpetra::MultiVector<
typename MatrixType::scalar_type,
331 typename MatrixType::local_ordinal_type,
332 typename MatrixType::global_ordinal_type,
333 typename MatrixType::node_type>& Y,
337 "Ifpack2::BlockRelaxation::applyMat() ERROR: isComputed() must be true prior to calling applyMat().");
339 "Ifpack2::BlockRelaxation::applyMat() ERROR: X.getNumVectors() != Y.getNumVectors().");
340 A_->apply(X, Y, mode);
344 template<
class MatrixType,
class ContainerType>
346 IsInitialized_ =
false;
349 "Ifpack2::BlockRelaxation::Initialize ERROR, Matrix is NULL");
353 NumMyRows_ = A_->getNodeNumRows();
354 NumGlobalRows_ = A_->getGlobalNumRows();
355 NumGlobalNonzeros_ = A_->getGlobalNumEntries();
360 if (PartitionerType_ ==
"linear")
366 Partitioner_->setParameters(List_);
367 Partitioner_->compute();
370 NumLocalBlocks_ = Partitioner_->numLocalParts();
375 if (A_->getComm()->getSize() != 1)
382 InitializeTime_ += Time_->totalElapsedTime();
383 IsInitialized_ =
true;
387 template<
class MatrixType,
class ContainerType>
390 if (!isInitialized()) {
401 "Ifpack2::BlockRelaxation::compute, NumSweeps_ must be >= 0");
404 ExtractSubmatrices();
407 if (PrecType_ == Ifpack2::JACOBI && OverlapLevel_ > 0) {
409 W_ =
Teuchos::rcp(
new Tpetra::Vector<Scalar,LocalOrdinal,GlobalOrdinal,Node>(A_->getRowMap()) );
413 for (LocalOrdinal i = 0 ; i < NumLocalBlocks_ ; ++i) {
414 for (
size_t j = 0 ; j < Partitioner_->numRowsInPart(i) ; ++j) {
415 int LID = (*Partitioner_)(i,j);
428 if (IsParallel_ && ((PrecType_ == Ifpack2::GS) || (PrecType_ == Ifpack2::SGS))) {
429 Importer_=A_->getGraph()->getImporter();
430 if(Importer_==Teuchos::null)
431 Importer_ =
Teuchos::rcp(
new Tpetra::Import<LocalOrdinal,GlobalOrdinal,Node>(A_->getDomainMap(),
435 "Ifpack2::BlockRelaxation::compute ERROR failed to create Importer_");
440 ComputeTime_ += Time_->totalElapsedTime();
445 template<
class MatrixType,
class ContainerType>
449 "Ifpack2::BlockRelaxation::ExtractSubmatrices, partitioner is null.");
451 NumLocalBlocks_ = Partitioner_->numLocalParts();
453 Containers_.resize(NumLocalBlocks_);
455 for (LocalOrdinal i = 0 ; i < NumLocalBlocks_ ; ++i) {
456 size_t rows = Partitioner_->numRowsInPart(i);
457 Containers_[i] =
Teuchos::rcp(
new ContainerType(rows) );
459 "Ifpack2::BlockRelaxation::ExtractSubmatrices, container consturctor failed.");
461 Containers_[i]->setParameters(List_);
462 Containers_[i]->initialize();
466 for (
size_t j = 0 ; j < rows ; ++j) {
467 Containers_[i]->ID(j) = (*Partitioner_)(i,j);
470 Containers_[i]->compute(A_);
478 template<
class MatrixType,
class ContainerType>
479 void BlockRelaxation<MatrixType,ContainerType>::ApplyInverseJacobi(
480 const Tpetra::MultiVector<Scalar,LocalOrdinal,GlobalOrdinal,Node>& X,
481 Tpetra::MultiVector<Scalar,LocalOrdinal,GlobalOrdinal,Node>& Y)
const
483 size_t NumVectors = X.getNumVectors();
484 Tpetra::MultiVector<Scalar,LocalOrdinal,GlobalOrdinal,Node> AY( Y.getMap(),NumVectors );
487 int starting_iteration=0;
488 if(ZeroStartingSolution_) {
490 starting_iteration=1;
493 for (
int j = starting_iteration; j < NumSweeps_ ; j++) {
495 AY.update(1.0,X,-1.0);
499 ApplyFlops_ += NumVectors * (2 * NumGlobalNonzeros_ + 2 * NumGlobalRows_);
506 template<
class MatrixType,
class ContainerType>
507 void BlockRelaxation<MatrixType,ContainerType>::DoJacobi(
const Tpetra::MultiVector<Scalar,LocalOrdinal,GlobalOrdinal,Node>& X, Tpetra::MultiVector<Scalar,LocalOrdinal,GlobalOrdinal,Node>& Y)
const
509 size_t NumVectors = X.getNumVectors();
513 if (OverlapLevel_ == 0) {
515 for (LocalOrdinal i = 0 ; i < NumLocalBlocks_ ; i++) {
517 if (Containers_[i]->getNumRows() == 0)
continue;
519 ApplyFlops_ += NumVectors * 2 * NumGlobalRows_;
524 for (LocalOrdinal i = 0 ; i < NumLocalBlocks_ ; i++) {
526 if (Containers_[i]->getNumRows() == 0)
continue;
529 ApplyFlops_ += NumVectors * 4 * NumGlobalRows_;
535 template<
class MatrixType,
class ContainerType>
536 void BlockRelaxation<MatrixType,ContainerType>::ApplyInverseGS(
const Tpetra::MultiVector<Scalar,LocalOrdinal,GlobalOrdinal,Node>& X,
537 Tpetra::MultiVector<Scalar,LocalOrdinal,GlobalOrdinal,Node>& Y)
const
540 Tpetra::MultiVector<Scalar,LocalOrdinal,GlobalOrdinal,Node> Xcopy(X);
541 for (
int j = 0; j < NumSweeps_ ; j++) {
542 DoGaussSeidel(Xcopy,Y);
543 if(j != NumSweeps_-1)
550 template<
class MatrixType,
class ContainerType>
551 void BlockRelaxation<MatrixType,ContainerType>::DoGaussSeidel(Tpetra::MultiVector<Scalar,LocalOrdinal,GlobalOrdinal,Node>& X,
552 Tpetra::MultiVector<Scalar,LocalOrdinal,GlobalOrdinal,Node>& Y)
const
558 int Length = A_->getNodeMaxNumRowEntries();
559 int NumVectors = X.getNumVectors();
570 Y2 =
Teuchos::rcp(
new Tpetra::MultiVector<Scalar,LocalOrdinal,GlobalOrdinal,Node>(Importer_->getTargetMap(), NumVectors) );
580 if (IsParallel_) Y2->doImport(Y,*Importer_,Tpetra::INSERT);
582 for (LocalOrdinal i = 0 ; i < NumLocalBlocks_ ; i++) {
584 if (Containers_[i]->getNumRows() == 0)
continue;
588 for (
size_t j = 0 ; j < Containers_[i]->getNumRows(); j++) {
589 LID = Containers_[i]->ID(j);
591 A_->getLocalRowCopy(LID,Indices(),Values(),NumEntries);
593 for (
size_t k = 0 ; k < NumEntries ; k++) {
594 LocalOrdinal col = Indices[k];
595 for (
int kk = 0 ; kk < NumVectors ; kk++)
596 x_ptr[kk][LID] -= Values[k] * y2_ptr[kk][col];
605 ApplyFlops_ += NumVectors * (2 * NumGlobalNonzeros_ + 2 * NumGlobalRows_);
611 for (
int m = 0 ; m < NumVectors ; ++m)
612 for (
size_t i = 0 ; i < NumMyRows_ ; ++i)
613 y_ptr[m][i] = y2_ptr[m][i];
618 template<
class MatrixType,
class ContainerType>
619 void BlockRelaxation<MatrixType,ContainerType>::ApplyInverseSGS(
const Tpetra::MultiVector<Scalar,LocalOrdinal,GlobalOrdinal,Node>& X,
620 Tpetra::MultiVector<Scalar,LocalOrdinal,GlobalOrdinal,Node>& Y)
const
623 Tpetra::MultiVector<Scalar,LocalOrdinal,GlobalOrdinal,Node> Xcopy(X);
624 for (
int j = 0; j < NumSweeps_ ; j++) {
626 if(j != NumSweeps_-1)
632 template<
class MatrixType,
class ContainerType>
633 void BlockRelaxation<MatrixType,ContainerType>::DoSGS(
const Tpetra::MultiVector<Scalar,LocalOrdinal,GlobalOrdinal,Node>& X,
634 Tpetra::MultiVector<Scalar,LocalOrdinal,GlobalOrdinal,Node>& Xcopy,
635 Tpetra::MultiVector<Scalar,LocalOrdinal,GlobalOrdinal,Node>& Y)
const
638 int Length = A_->getNodeMaxNumRowEntries();
639 int NumVectors = X.getNumVectors();
650 Y2 =
Teuchos::rcp(
new Tpetra::MultiVector<Scalar,LocalOrdinal,GlobalOrdinal,Node>(Importer_->getTargetMap(), NumVectors) );
660 if (IsParallel_) Y2->doImport(Y,*Importer_,Tpetra::INSERT);
663 for(LocalOrdinal i = 0 ; i < NumLocalBlocks_ ; i++) {
665 if (Containers_[i]->getNumRows() == 0)
continue;
669 for(
size_t j = 0 ; j < Containers_[i]->getNumRows(); j++) {
670 LID = Containers_[i]->ID(j);
672 A_->getLocalRowCopy(LID,Indices(),Values(),NumEntries);
674 for (
size_t k = 0 ; k < NumEntries ; k++) {
675 LocalOrdinal col = Indices[k];
676 for (
int kk = 0 ; kk < NumVectors ; kk++)
677 xcopy_ptr[kk][LID] -= Values[k] * y2_ptr[kk][col];
686 ApplyFlops_ += NumVectors * (2 * NumGlobalNonzeros_ + 2 * NumGlobalRows_);
691 for(LocalOrdinal i = NumLocalBlocks_-1; i >=0 ; i--) {
693 if (Containers_[i]->getNumRows() == 0)
continue;
697 for(
size_t j = 0 ; j < Containers_[i]->getNumRows(); j++) {
698 LID = Containers_[i]->ID(j);
700 A_->getLocalRowCopy(LID,Indices(),Values(),NumEntries);
702 for (
size_t k = 0 ; k < NumEntries ; k++) {
703 LocalOrdinal col = Indices[k];
704 for (
int kk = 0 ; kk < NumVectors ; kk++)
705 xcopy_ptr[kk][LID] -= Values[k] * y2_ptr[kk][col];
715 ApplyFlops_ += NumVectors * (2 * NumGlobalNonzeros_ + 2 * NumGlobalRows_);
722 for (
int m = 0 ; m < NumVectors ; ++m)
723 for (
size_t i = 0 ; i < NumMyRows_ ; ++i)
724 y_ptr[m][i] = y2_ptr[m][i];
728 template<
class MatrixType,
class ContainerType>
730 std::ostringstream oss;
732 if (isInitialized()) {
734 oss <<
"{status = initialized, computed";
737 oss <<
"{status = initialized, not computed";
741 oss <<
"{status = not initialized, not computed";
744 if (PrecType_ == Ifpack2::JACOBI) oss <<
"Type = Block Jacobi, " << std::endl;
745 else if (PrecType_ == Ifpack2::GS) oss <<
"Type = Block Gauss-Seidel, " << std::endl;
746 else if (PrecType_ == Ifpack2::SGS) oss <<
"Type = Block Sym. Gauss-Seidel, " << std::endl;
748 oss <<
", global rows = " << A_->getGlobalNumRows()
749 <<
", global cols = " << A_->getGlobalNumCols();
756 template<
class MatrixType,
class ContainerType>
768 const int myImageID = A_->getComm()->getRank();
777 out << this->description() << endl;
779 out <<
"===============================================================================" << endl;
780 out <<
"Sweeps = " << NumSweeps_ << endl;
781 out <<
"damping factor = " << DampingFactor_ << endl;
782 if (PrecType_ == Ifpack2::GS && DoBackwardGS_) {
783 out <<
"Using backward mode (BGS only)" << endl;
785 if (ZeroStartingSolution_) { out <<
"Using zero starting solution" << endl; }
786 else { out <<
"Using input starting solution" << endl; }
787 if (Condest_ == -1.0) { out <<
"Condition number estimate = N/A" << endl; }
788 else { out <<
"Condition number estimate = " << Condest_ << endl; }
790 out <<
"Phase # calls Total Time (s) Total MFlops MFlops/s " << endl;
791 out <<
"------------ ------- --------------- --------------- ---------------" << endl;
792 out << setw(12) <<
"initialize()" << setw(5) << getNumInitialize() <<
" " << setw(15) << getInitializeTime() << endl;
793 out << setw(12) <<
"compute()" << setw(5) << getNumCompute() <<
" " << setw(15) << getComputeTime() <<
" "
794 << setw(15) << getComputeFlops() <<
" "
795 << setw(15) << (getComputeTime() != 0.0 ? getComputeFlops() / getComputeTime() * 1.0e-6 : 0.0) << endl;
796 out << setw(12) <<
"apply()" << setw(5) << getNumApply() <<
" " << setw(15) << getApplyTime() <<
" "
797 << setw(15) << getApplyFlops() <<
" "
798 << setw(15) << (getApplyTime() != 0.0 ? getApplyFlops() / getApplyTime() * 1.0e-6 : 0.0) << endl;
799 out <<
"===============================================================================" << endl;
806 #endif // IFPACK2_BLOCKRELAXATION_DEF_HPP
magnitudeType computeCondEst(CondestType CT=Cheap, LocalOrdinal MaxIters=1550, magnitudeType Tol=1e-9, const Teuchos::Ptr< const Tpetra::RowMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node > > &matrix=Teuchos::null)
Computes the estimated condition number and returns the value.
Definition: Ifpack2_BlockRelaxation_def.hpp:247
double getApplyFlops() const
Returns the number of flops for the application of the preconditioner.
Definition: Ifpack2_BlockRelaxation_def.hpp:232
CondestType
Ifpack2::CondestType: enum to define the type of condition number estimate.
Definition: Ifpack2_CondestType.hpp:50
const Teuchos::RCP< const Teuchos::Comm< int > > & getComm() const
Returns the Tpetra::BlockMap object associated with the range of this matrix operator.
Definition: Ifpack2_BlockRelaxation_def.hpp:150
BlockRelaxation(const Teuchos::RCP< const Tpetra::RowMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node > > &Matrix)
BlockRelaxation constructor with given Tpetra::RowMatrix input.
Definition: Ifpack2_BlockRelaxation_def.hpp:53
std::string description() const
Return a simple one-line description of this object.
Definition: Ifpack2_BlockRelaxation_def.hpp:729
double getApplyTime() const
Returns the time spent in apply().
Definition: Ifpack2_BlockRelaxation_def.hpp:220
#define TEUCHOS_TEST_FOR_EXCEPTION(throw_exception_test, Exception, msg)
int getNumApply() const
Returns the number of calls to apply().
Definition: Ifpack2_BlockRelaxation_def.hpp:202
void getParameter(const Teuchos::ParameterList ¶ms, const std::string &name, T &value)
Set a value from a ParameterList if a parameter with the specified name exists.
Definition: Ifpack2_Parameters.hpp:59
int getNumCompute() const
Returns the number of calls to compute().
Definition: Ifpack2_BlockRelaxation_def.hpp:196
void setParameters(const Teuchos::ParameterList ¶ms)
Sets all the parameters for the preconditioner.
Definition: Ifpack2_BlockRelaxation_def.hpp:91
void compute()
compute the preconditioner for the specified matrix, diagonal perturbation thresholds and relaxation ...
Definition: Ifpack2_BlockRelaxation_def.hpp:388
Ifpack2::BlockRelaxation: defines relaxation preconditioners for Tpetra::RowMatrix objects...
Definition: Ifpack2_BlockRelaxation_decl.hpp:137
double getInitializeTime() const
Returns the time spent in initialize().
Definition: Ifpack2_BlockRelaxation_def.hpp:208
void apply(const Tpetra::MultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node > &X, Tpetra::MultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node > &Y, Teuchos::ETransp mode=Teuchos::NO_TRANS, Scalar alpha=Teuchos::ScalarTraits< Scalar >::one(), Scalar beta=Teuchos::ScalarTraits< Scalar >::zero()) const
Applies the preconditioner to X, returns the result in Y.
Definition: Ifpack2_BlockRelaxation_def.hpp:268
TEUCHOS_DEPRECATED RCP< T > rcp(T *p, Dealloc_T dealloc, bool owns_mem)
double getComputeFlops() const
Returns the number of flops in the computation phase.
Definition: Ifpack2_BlockRelaxation_def.hpp:226
double getComputeTime() const
Returns the time spent in compute().
Definition: Ifpack2_BlockRelaxation_def.hpp:214
virtual std::string description() const
virtual ~BlockRelaxation()
BlockRelaxation Destructor.
Definition: Ifpack2_BlockRelaxation_def.hpp:86
void resize(size_type new_size, const value_type &x=value_type())
int getNumInitialize() const
Returns the number of calls to initialize().
Definition: Ifpack2_BlockRelaxation_def.hpp:190
void initialize()
Initialize.
Definition: Ifpack2_BlockRelaxation_def.hpp:345
void validateParameters(ParameterList const &validParamList, int const depth=1000, EValidateUsed const validateUsed=VALIDATE_USED_ENABLED, EValidateDefaults const validateDefaults=VALIDATE_DEFAULTS_ENABLED) const
void describe(Teuchos::FancyOStream &out, const Teuchos::EVerbosityLevel verbLevel=Teuchos::Describable::verbLevel_default) const
Print the object with some verbosity level to an FancyOStream object.
Definition: Ifpack2_BlockRelaxation_def.hpp:757
const Teuchos::RCP< const Tpetra::Map< LocalOrdinal, GlobalOrdinal, Node > > & getRangeMap() const
Returns the Tpetra::Map object associated with the range of this operator.
Definition: Ifpack2_BlockRelaxation_def.hpp:178
const Teuchos::RCP< const Tpetra::Map< LocalOrdinal, GlobalOrdinal, Node > > & getDomainMap() const
Returns the Tpetra::Map object associated with the domain of this operator.
Definition: Ifpack2_BlockRelaxation_def.hpp:169
magnitudeType getCondEst() const
Returns the computed estimated condition number, or -1.0 if no computed.
Definition: Ifpack2_BlockRelaxation_def.hpp:239
void applyMat(const Tpetra::MultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node > &X, Tpetra::MultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node > &Y, Teuchos::ETransp mode=Teuchos::NO_TRANS) const
Applies the matrix to a Tpetra::MultiVector.
Definition: Ifpack2_BlockRelaxation_def.hpp:325
Teuchos::RCP< const Tpetra::RowMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node > > getMatrix() const
Returns a reference to the matrix to be preconditioned.
Definition: Ifpack2_BlockRelaxation_def.hpp:160
void getValidParameters(Teuchos::ParameterList ¶ms)
Fills a list which contains all the parameters possibly used by Ifpack2.
Definition: Ifpack2_Parameters.cpp:47
Ifpack2::LinearPartitioner: A class to define linear partitions.
Definition: Ifpack2_LinearPartitioner_decl.hpp:54
std::string typeName(const T &t)