MueLu  Version of the Day
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
MueLu_LocalPermutationStrategy_decl.hpp
Go to the documentation of this file.
1 /*
2  * MueLu_LocalPermutationStrategy_decl.hpp
3  *
4  * Created on: Feb 19, 2013
5  * Author: tobias
6  */
7 
8 #ifndef MUELU_LOCALPERMUTATIONSTRATEGY_DECL_HPP_
9 #define MUELU_LOCALPERMUTATIONSTRATEGY_DECL_HPP_
10 
11 #include <Xpetra_Matrix_fwd.hpp>
12 #include <Xpetra_Vector_fwd.hpp>
15 
16 #include "MueLu_ConfigDefs.hpp"
17 #include "MueLu_Level.hpp"
18 #include "MueLu_BaseClass.hpp"
19 
20 namespace MueLu {
21 
23 
28 template <class Scalar = DefaultScalar,
31  class Node = DefaultNode>
32 class LocalPermutationStrategy : public BaseClass {
33 #undef MUELU_LOCALPERMUTATIONSTRATEGY_SHORT
34 #include "MueLu_UseShortNames.hpp"
35  public:
41 
55  void BuildPermutation(const Teuchos::RCP<Matrix>& A, const Teuchos::RCP<const Map> permRowMap, Level& currentLevel, const FactoryBase* genFactory) const;
56 
57  private:
58  void BuildPermutations(size_t nDofsPerNode) const;
59 
60  mutable std::vector<std::vector<int> > result_permvecs_;
61  mutable size_t permWidth_;
62 
63  GlobalOrdinal getGlobalDofId(const Teuchos::RCP<Matrix>& A, LocalOrdinal localNodeId, LocalOrdinal localDof) const;
65 };
66 
67 } // namespace MueLu
68 
69 #define MUELU_LOCALPERMUTATIONSTRATEGY_SHORT
70 
71 #endif /* MUELU_LOCALPERMUTATIONSTRATEGY_DECL_HPP_ */
MueLu::DefaultLocalOrdinal LocalOrdinal
Class which defines local permutations of matrix columns which correspond to DOFs of the same node...
Tpetra::KokkosClassic::DefaultNode::DefaultNodeType DefaultNode
void BuildPermutation(const Teuchos::RCP< Matrix > &A, const Teuchos::RCP< const Map > permRowMap, Level &currentLevel, const FactoryBase *genFactory) const
build permutation operators
MueLu::DefaultNode Node
std::vector< std::vector< int > > result_permvecs_
GlobalOrdinal getGlobalDofId(const Teuchos::RCP< Matrix > &A, LocalOrdinal localNodeId, LocalOrdinal localDof) const
MueLu::DefaultScalar Scalar
Tpetra::Details::DefaultTypes::scalar_type DefaultScalar
MueLu::DefaultGlobalOrdinal GlobalOrdinal
void BuildPermutations(size_t nDofsPerNode) const
GlobalOrdinal globalDofId2globalNodeId(const Teuchos::RCP< Matrix > &A, GlobalOrdinal grid) const