MueLu  Version of the Day
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
MueLu_TentativePFactory_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 MUELU_TENTATIVEPFACTORY_DECL_HPP
11 #define MUELU_TENTATIVEPFACTORY_DECL_HPP
12 
13 #include <Teuchos_ScalarTraits.hpp>
16 
18 #include <Xpetra_CrsMatrix_fwd.hpp>
19 #include <Xpetra_Matrix_fwd.hpp>
22 #include <Xpetra_Map_fwd.hpp>
24 #include <Xpetra_Import_fwd.hpp>
27 
28 #include "MueLu_ConfigDefs.hpp"
30 
31 #include "MueLu_Aggregates_fwd.hpp"
35 #include "MueLu_Level_fwd.hpp"
36 #include "MueLu_PerfUtils_fwd.hpp"
37 #include "MueLu_PFactory.hpp"
38 #include "MueLu_Utilities_fwd.hpp"
39 
40 namespace MueLu {
41 
81 template <class Scalar = DefaultScalar,
84  class Node = DefaultNode>
85 class TentativePFactory : public PFactory {
86 #undef MUELU_TENTATIVEPFACTORY_SHORT
87 #include "MueLu_UseShortNames.hpp"
88 
89  public:
91 
92 
95 
97  virtual ~TentativePFactory() {}
99 
101 
103 
104 
105  void DeclareInput(Level& fineLevel, Level& coarseLevel) const;
106 
108 
110 
111 
112  void Build(Level& fineLevel, Level& coarseLevel) const;
113  void BuildP(Level& fineLevel, Level& coarseLevel) const;
114 
116 
117  private:
118  void BuildPuncoupled(RCP<Matrix> A, RCP<Aggregates> aggregates, RCP<AmalgamationInfo> amalgInfo, RCP<MultiVector> fineNullspace,
119  RCP<const Map> coarseMap, RCP<Matrix>& Ptentative, RCP<MultiVector>& coarseNullspace, const int levelID) const;
120  void BuildPcoupled(RCP<Matrix> A, RCP<Aggregates> aggregates, RCP<AmalgamationInfo> amalgInfo, RCP<MultiVector> fineNullspace,
121  RCP<const Map> coarseMap, RCP<Matrix>& Ptentative, RCP<MultiVector>& coarseNullspace) const;
123  RCP<const Map> coarseMap, RCP<Matrix>& Ptentative, RCP<MultiVector>& coarseNullspace, const int levelID) const;
124 
125  mutable bool bTransferCoordinates_ = false;
126 
127 }; // class TentativePFactory
128 
129 } // namespace MueLu
130 
131 // TODO: noQR_
132 
133 #define MUELU_TENTATIVEPFACTORY_SHORT
134 #endif // MUELU_TENTATIVEPFACTORY_DECL_HPP
void BuildPuncoupled(RCP< Matrix > A, RCP< Aggregates > aggregates, RCP< AmalgamationInfo > amalgInfo, RCP< MultiVector > fineNullspace, RCP< const Map > coarseMap, RCP< Matrix > &Ptentative, RCP< MultiVector > &coarseNullspace, const int levelID) const
void Build(Level &fineLevel, Level &coarseLevel) const
Build an object with this factory.
MueLu::DefaultLocalOrdinal LocalOrdinal
void BuildPcoupled(RCP< Matrix > A, RCP< Aggregates > aggregates, RCP< AmalgamationInfo > amalgInfo, RCP< MultiVector > fineNullspace, RCP< const Map > coarseMap, RCP< Matrix > &Ptentative, RCP< MultiVector > &coarseNullspace) const
RCP< const ParameterList > GetValidParameterList() const
Return a const parameter list of valid parameters that setParameterList() will accept.
Tpetra::KokkosClassic::DefaultNode::DefaultNodeType DefaultNode
void DeclareInput(Level &fineLevel, Level &coarseLevel) const
Input.
MueLu::DefaultNode Node
Factory for building tentative prolongator.
MueLu::DefaultScalar Scalar
Tpetra::Details::DefaultTypes::scalar_type DefaultScalar
MueLu::DefaultGlobalOrdinal GlobalOrdinal
Class that holds all level-specific information.
Definition: MueLu_Level.hpp:63
void BuildPuncoupledBlockCrs(RCP< Matrix > A, RCP< Aggregates > aggregates, RCP< AmalgamationInfo > amalgInfo, RCP< MultiVector > fineNullspace, RCP< const Map > coarseMap, RCP< Matrix > &Ptentative, RCP< MultiVector > &coarseNullspace, const int levelID) const
Factory that provides an interface for a concrete implementation of a prolongation operator...
void BuildP(Level &fineLevel, Level &coarseLevel) const
Abstract Build method.