MueLu Version of the Day
Loading...
Searching...
No Matches
MueLu_LocalPermutationStrategy_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/*
11 * MueLu_LocalPermutationStrategy_decl.hpp
12 *
13 * Created on: Feb 19, 2013
14 * Author: tobias
15 */
16
17#ifndef MUELU_LOCALPERMUTATIONSTRATEGY_DECL_HPP_
18#define MUELU_LOCALPERMUTATIONSTRATEGY_DECL_HPP_
19
20#include <Xpetra_Matrix_fwd.hpp>
21#include <Xpetra_Vector_fwd.hpp>
22#include <Xpetra_VectorFactory_fwd.hpp>
23#include <Xpetra_CrsMatrixWrap_fwd.hpp>
24
25#include "MueLu_ConfigDefs.hpp"
26#include "MueLu_Level.hpp"
27#include "MueLu_BaseClass.hpp"
28
29namespace MueLu {
30
32
37template <class Scalar = DefaultScalar,
40 class Node = DefaultNode>
42#undef MUELU_LOCALPERMUTATIONSTRATEGY_SHORT
44 public:
51
64 void BuildPermutation(const Teuchos::RCP<Matrix>& A, const Teuchos::RCP<const Map> permRowMap, Level& currentLevel, const FactoryBase* genFactory) const;
65
66 private:
67 void BuildPermutations(size_t nDofsPerNode) const;
68
69 mutable std::vector<std::vector<int> > result_permvecs_;
70 mutable size_t permWidth_;
71
72 GlobalOrdinal getGlobalDofId(const Teuchos::RCP<Matrix>& A, LocalOrdinal localNodeId, LocalOrdinal localDof) const;
73 GlobalOrdinal globalDofId2globalNodeId(const Teuchos::RCP<Matrix>& A, GlobalOrdinal grid) const;
74};
75
76} // namespace MueLu
77
78#define MUELU_LOCALPERMUTATIONSTRATEGY_SHORT
79
80#endif /* MUELU_LOCALPERMUTATIONSTRATEGY_DECL_HPP_ */
MueLu::DefaultLocalOrdinal LocalOrdinal
MueLu::DefaultScalar Scalar
MueLu::DefaultGlobalOrdinal GlobalOrdinal
MueLu::DefaultNode Node
Base class for MueLu classes.
Base class for factories (e.g., R, P, and A_coarse).
Class that holds all level-specific information.
GlobalOrdinal globalDofId2globalNodeId(const Teuchos::RCP< Matrix > &A, GlobalOrdinal grid) const
std::vector< std::vector< int > > result_permvecs_
void BuildPermutation(const Teuchos::RCP< Matrix > &A, const Teuchos::RCP< const Map > permRowMap, Level &currentLevel, const FactoryBase *genFactory) const
build permutation operators
GlobalOrdinal getGlobalDofId(const Teuchos::RCP< Matrix > &A, LocalOrdinal localNodeId, LocalOrdinal localDof) const
Namespace for MueLu classes and methods.
Tpetra::KokkosClassic::DefaultNode::DefaultNodeType DefaultNode
Tpetra::Details::DefaultTypes::scalar_type DefaultScalar