47#ifndef THYRA_MUELU_PRECONDITIONER_FACTORY_DECL_HPP
48#define THYRA_MUELU_PRECONDITIONER_FACTORY_DECL_HPP
52#if defined(HAVE_MUELU_STRATIMIKOS) && defined(HAVE_MUELU_THYRA)
55#include "Thyra_DefaultPreconditioner.hpp"
56#include "Thyra_BlockedLinearOpBase.hpp"
57#include "Thyra_DiagonalLinearOpBase.hpp"
59#ifdef HAVE_MUELU_TPETRA
60#include "Thyra_TpetraLinearOp.hpp"
61#include "Thyra_TpetraThyraWrappers.hpp"
63#ifdef HAVE_MUELU_EPETRA
64#include "Thyra_EpetraLinearOp.hpp"
67#include "Teuchos_Ptr.hpp"
68#include "Teuchos_TestForException.hpp"
69#include "Teuchos_Assert.hpp"
70#include "Teuchos_Time.hpp"
72#include <Xpetra_CrsMatrixWrap.hpp>
73#include <Xpetra_CrsMatrix.hpp>
74#include <Xpetra_Matrix.hpp>
75#include <Xpetra_ThyraUtils.hpp>
77#include <MueLu_Hierarchy.hpp>
79#include <MueLu_HierarchyUtils.hpp>
80#include <MueLu_Utilities.hpp>
81#include <MueLu_ParameterListInterpreter.hpp>
82#include <MueLu_MLParameterListInterpreter.hpp>
86#ifdef HAVE_MUELU_TPETRA
87#include <MueLu_TpetraOperator.hpp>
88#include <Xpetra_TpetraHalfPrecisionOperator.hpp>
90#ifdef HAVE_MUELU_EPETRA
94#include "Thyra_PreconditionerFactoryBase.hpp"
96#include "KokkosCompat_DefaultNode.hpp"
105 template <
class Scalar,
class LocalOrdinal,
class GlobalOrdinal,
class Node>
107 static bool replaceWithXpetra(ParameterList& paramList, std::string parameterName);
110#ifdef HAVE_MUELU_EPETRA
111 template <
class GlobalOrdinal>
112 struct Converters<double, int,
GlobalOrdinal, Kokkos::Compat::KokkosSerialWrapperNode> {
113 static bool replaceWithXpetra(ParameterList& paramList, std::string parameterName);
122 template <
class Scalar,
class LocalOrdinal,
class GlobalOrdinal,
class Node = KokkosClassic::DefaultNode::DefaultNodeType>
123 class MueLuPreconditionerFactory :
public PreconditionerFactoryBase<Scalar> {
130 MueLuPreconditionerFactory();
137 bool isCompatible(
const LinearOpSourceBase<Scalar>& fwdOp)
const;
139 Teuchos::RCP<PreconditionerBase<Scalar> > createPrec()
const;
141 void initializePrec(
const Teuchos::RCP<
const LinearOpSourceBase<Scalar> >& fwdOp,
142 PreconditionerBase<Scalar>* prec,
143 const ESupportSolveUse supportSolveUse
146 void uninitializePrec(PreconditionerBase<Scalar>* prec,
147 Teuchos::RCP<
const LinearOpSourceBase<Scalar> >* fwdOp,
148 ESupportSolveUse* supportSolveUse
157 void setParameterList(
const Teuchos::RCP<Teuchos::ParameterList>& paramList);
159 Teuchos::RCP<Teuchos::ParameterList> unsetParameterList();
161 Teuchos::RCP<Teuchos::ParameterList> getNonconstParameterList();
163 Teuchos::RCP<const Teuchos::ParameterList> getParameterList()
const;
172 std::string description()
const;
182 Teuchos::RCP<Teuchos::ParameterList> paramList_;
Various adapters that will create a MueLu preconditioner that is an Xpetra::Matrix.
MueLu::DefaultGlobalOrdinal GlobalOrdinal
void getValidParameters(Teuchos::ParameterList ¶ms)