MueLu Version of the Day
Loading...
Searching...
No Matches
Thyra_MueLuRefMaxwellPreconditionerFactory_decl.hpp
Go to the documentation of this file.
1// @HEADER
2// *****************************************************************************
3// MueLu: A package for multigrid based preconditioning
4//
5// Copyright 2012 NTESS and the MueLu contributors.
6// SPDX-License-Identifier: BSD-3-Clause
7// *****************************************************************************
8// @HEADER
9
10#ifndef THYRA_MUELU_REFMAXWELL_PRECONDITIONER_FACTORY_DECL_HPP
11#define THYRA_MUELU_REFMAXWELL_PRECONDITIONER_FACTORY_DECL_HPP
12
13#include <MueLu_ConfigDefs.hpp>
14
15#if defined(HAVE_MUELU_STRATIMIKOS) && defined(HAVE_MUELU_THYRA)
16
17// Stratimikos needs Thyra, so we don't need special guards for Thyra here
18#include "Thyra_DefaultPreconditioner.hpp"
19#include "Thyra_BlockedLinearOpBase.hpp"
20#include "Thyra_DiagonalLinearOpBase.hpp"
23#include "Thyra_TpetraLinearOp.hpp"
24#include "Thyra_TpetraThyraWrappers.hpp"
25#ifdef HAVE_MUELU_EPETRA
26#include "Thyra_EpetraLinearOp.hpp"
27#include "Thyra_EpetraThyraWrappers.hpp"
28#endif
29
30#include "Teuchos_Ptr.hpp"
31#include "Teuchos_TestForException.hpp"
32#include "Teuchos_Assert.hpp"
33#include "Teuchos_Time.hpp"
34
35#include <Xpetra_CrsMatrixWrap.hpp>
36#include <Xpetra_CrsMatrix.hpp>
37#include <Xpetra_Matrix.hpp>
38#include <Xpetra_ThyraUtils.hpp>
39
40#include <MueLu_XpetraOperator_decl.hpp> // todo fix me
41#include <MueLu_RefMaxwell.hpp>
42#include <MueLu_TpetraOperator.hpp>
43#include <Xpetra_TpetraOperator.hpp>
44#include <Xpetra_TpetraHalfPrecisionOperator.hpp>
45#ifdef HAVE_MUELU_EPETRA
47#include <Xpetra_EpetraOperator.hpp>
48#endif
49
50#include "Thyra_PreconditionerFactoryBase.hpp"
51
52#include <Tpetra_KokkosCompat_DefaultNode.hpp>
53
54#include <list>
55
56namespace Thyra {
57
66template <class Scalar, class LocalOrdinal, class GlobalOrdinal, class Node = Tpetra::KokkosClassic::DefaultNode::DefaultNodeType>
67class MueLuRefMaxwellPreconditionerFactory : public PreconditionerFactoryBase<Scalar> {
68 public:
71
73 MueLuRefMaxwellPreconditionerFactory();
75
78
80 bool isCompatible(const LinearOpSourceBase<Scalar>& fwdOp) const;
82 Teuchos::RCP<PreconditionerBase<Scalar> > createPrec() const;
84 void initializePrec(const Teuchos::RCP<const LinearOpSourceBase<Scalar> >& fwdOp,
85 PreconditionerBase<Scalar>* prec,
86 const ESupportSolveUse supportSolveUse) const;
88 void uninitializePrec(PreconditionerBase<Scalar>* prec,
89 Teuchos::RCP<const LinearOpSourceBase<Scalar> >* fwdOp,
90 ESupportSolveUse* supportSolveUse) const;
91
93
96
98 void setParameterList(const Teuchos::RCP<Teuchos::ParameterList>& paramList);
100 Teuchos::RCP<Teuchos::ParameterList> unsetParameterList();
102 Teuchos::RCP<Teuchos::ParameterList> getNonconstParameterList();
104 Teuchos::RCP<const Teuchos::ParameterList> getParameterList() const;
106 Teuchos::RCP<const Teuchos::ParameterList> getValidParameters() const;
108
111
113 std::string description() const;
114
115 // ToDo: Add an override of describe(...) to give more detail!
116
118
119 private:
120 Teuchos::RCP<Teuchos::ParameterList> paramList_;
121};
122
123} // namespace Thyra
124
125#endif // #ifdef HAVE_MUELU_STRATIMIKOS
126
127#endif // THYRA_MUELU_REFMAXWELL_PRECONDITIONER_FACTORY_DECL_HPP
void getValidParameters(Teuchos::ParameterList &params)