MueLu  Version of the Day
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
MueLu_RepartitionFactory_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_REPARTITIONFACTORY_DECL_HPP
11 #define MUELU_REPARTITIONFACTORY_DECL_HPP
12 
13 #include "MueLu_ConfigDefs.hpp"
14 #ifdef HAVE_MPI
15 
16 // Some classes are only used in the definition (_def.hpp) of this class
17 // but forward declarations are needed here to enable the UseShortNames mechanism.
18 #include <Xpetra_Map_fwd.hpp>
20 #include <Xpetra_Import_fwd.hpp>
22 #include <Xpetra_Export_fwd.hpp>
24 #include <Xpetra_Vector_fwd.hpp>
25 #include <Xpetra_Matrix_fwd.hpp>
26 
30 #include "MueLu_Utilities_fwd.hpp"
31 #include "MueLu_PerfUtils_fwd.hpp"
32 
33 namespace MueLu {
34 
75 template <class Scalar = DefaultScalar,
78  class Node = DefaultNode>
80 #undef MUELU_REPARTITIONFACTORY_SHORT
81 #include "MueLu_UseShortNames.hpp"
82 
83  public:
85 
86 
89 
91  virtual ~RepartitionFactory();
92 
94 
96 
98 
99 
105  void DeclareInput(Level& currentLevel) const;
106 
108 
110 
111 
113  void Build(Level& currentLevel) const;
114 
116 
118 
119 
128  void DeterminePartitionPlacement(const Matrix& A, GOVector& decomposition, GO numPartitions, bool willAcceptPartition = true, bool allSubdomainsAcceptPartitions = true) const;
129 
130 }; // class RepartitionFactory
131 
132 } // namespace MueLu
133 
134 #define MUELU_REPARTITIONFACTORY_SHORT
135 
136 #endif // ifdef HAVE_MPI
137 #endif // MUELU_REPARTITIONFACTORY_DECL_HPP
void Build(Level &currentLevel) const
Build an object with this factory.
MueLu::DefaultLocalOrdinal LocalOrdinal
Tpetra::KokkosClassic::DefaultNode::DefaultNodeType DefaultNode
void DeterminePartitionPlacement(const Matrix &A, GOVector &decomposition, GO numPartitions, bool willAcceptPartition=true, bool allSubdomainsAcceptPartitions=true) const
Determine which process should own each partition.
GlobalOrdinal GO
Factory for building permutation matrix that can be be used to shuffle data (matrices, vectors) among processes.
MueLu::DefaultNode Node
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 DeclareInput(Level &currentLevel) const
Determines the data that RepartitionFactory needs, and the factories that generate that data...
RepartitionFactory()
Constructor.
virtual ~RepartitionFactory()
Destructor.
RCP< const ParameterList > GetValidParameterList() const
Return a const parameter list of valid parameters that setParameterList() will accept.
Base class for factories that use one level (currentLevel).