Advanced Multi-Physics (AMP)
On-Line Documentation
subsetCommSelfDOFManager.h
Go to the documentation of this file.
1#ifndef included_AMP_subsetCommSelfDOFManager
2#define included_AMP_subsetCommSelfDOFManager
3
4#include "AMP/discretization/DOF_Manager.h"
5#include "AMP/mesh/MeshElement.h"
6#include <memory>
7
8
9namespace AMP::Discretization {
10
11
19{
20public:
22
25
30 subsetCommSelfDOFManager( std::shared_ptr<const DOFManager> parentDOFManager );
31
32
38 AMP::Mesh::MeshElementID getElementID( size_t dof ) const override;
39
40
46 std::unique_ptr<AMP::Mesh::MeshElement> getElement( size_t dof ) const override;
47
48
50 virtual ~subsetCommSelfDOFManager() = default;
51
52
56 std::shared_ptr<const AMP::Mesh::Mesh> getMesh() const override;
57
58
64
65
67 std::vector<size_t> getRemoteDOFs() const override;
68
69
71 virtual std::vector<size_t> getLocalParentDOFs() const;
72
73
75 virtual std::vector<size_t> getParentDOF( const std::vector<size_t> & ) const;
76
77
83 virtual std::vector<size_t> getSubsetDOF( const std::vector<size_t> & ) const;
84
85
87 virtual std::shared_ptr<const DOFManager> getDOFManager() const;
88
89
91 std::vector<size_t> getLocalSizes() const override { return { d_end - d_begin }; }
92
98 int getDOFsPerPoint() const override;
99
100
101public: // Advanced interfaces
104 size_t *dofs,
105 size_t N_alloc,
106 bool sort = true ) const override;
108
109 // Append DOFs to the list
111 size_t *dofs,
112 size_t index,
113 size_t capacity ) const override;
114
115
116protected:
117 // Convert dof indicies
118 size_t getSubsetDOF( size_t N, size_t *dofs ) const;
119
120private:
122 std::shared_ptr<const DOFManager> d_parentDOFManager;
123
126};
127} // namespace AMP::Discretization
128
129#endif
size_t d_begin
The begining DOF, ending DOF and number of local DOFs for this processor.
std::vector< size_t > getRowDOFs(const AMP::Mesh::MeshElementID &id) const
Get the row DOFs given a mesh element.
virtual std::shared_ptr< DOFManager > subset(const AMP_MPI &comm)
Subset the DOF Manager for a AMP_MPI communicator.
A derived class to subset a DOFManagers.
std::unique_ptr< AMP::Mesh::MeshElement > getElement(size_t dof) const override
Get the mesh element for a DOF.
virtual std::shared_ptr< const DOFManager > getDOFManager() const
Get the parent DOFManager.
virtual ~subsetCommSelfDOFManager()=default
Deconstructor.
AMP::Mesh::MeshIterator getIterator() const override
Get an entry over the mesh elements associated with the DOFs.
int getDOFsPerPoint() const override
Get the number of DOFs per element.
size_t getSubsetDOF(size_t N, size_t *dofs) const
AMP::Mesh::MeshElementID getElementID(size_t dof) const override
Get the mesh element ID for a DOF.
size_t d_parentBegin
The parent begin, end, and global DOFs.
subsetCommSelfDOFManager(std::shared_ptr< const DOFManager > parentDOFManager)
Default constructor.
virtual std::vector< size_t > getParentDOF(const std::vector< size_t > &) const
Function to convert DOFs from a subset DOFManager DOF to the parent DOF.
size_t getRowDOFs(const AMP::Mesh::MeshElementID &id, size_t *dofs, size_t N_alloc, bool sort=true) const override
Get the row DOFs given a mesh element.
virtual std::vector< size_t > getSubsetDOF(const std::vector< size_t > &) const
std::shared_ptr< const AMP::Mesh::Mesh > getMesh() const override
Get the underlying mesh.
std::shared_ptr< const DOFManager > d_parentDOFManager
The parent DOF Manager.
std::vector< size_t > getLocalSizes() const override
Get the local sizes on each rank.
std::vector< size_t > getRemoteDOFs() const override
Get the remote DOFs for a vector.
virtual std::vector< size_t > getLocalParentDOFs() const
Function to return the local DOFs on the parent DOF manager.
size_t appendDOFs(const AMP::Mesh::MeshElementID &id, size_t *dofs, size_t index, size_t capacity) const override
A class used to iterate over elements in a Mesh.
A structure used to identify the mesh element.
Definition MeshID.h:156



Advanced Multi-Physics (AMP)
Oak Ridge National Laboratory
Idaho National Laboratory
Los Alamos National Laboratory
This page automatically produced from the
source code by doxygen
Last updated: Tue Mar 10 2026 13:06:40.
Comments on this page