DOLFINx
0.1.0
DOLFINx C++ interface
|
10 #include <dolfinx/common/MPI.h>
11 #include <dolfinx/graph/AdjacencyList.h>
15 #include <xtl/xspan.hpp>
29 class ElementDofLayout;
54 graph::AdjacencyList<std::int32_t>
56 std::int32_t num_cells);
81 typename = std::enable_if_t<std::is_same<
83 DofMap(std::shared_ptr<const ElementDofLayout> element,
87 _index_map_bs(
index_map_bs), _dofmap(std::forward<U>(dofmap)), _bs(
bs)
113 return _dofmap.links(cell);
117 int bs() const noexcept;
129 std::pair<std::unique_ptr<
DofMap>, std::vector<std::int32_t>>
130 collapse(MPI_Comm comm, const mesh::Topology& topology) const;
134 const graph::AdjacencyList<std::int32_t>&
list() const;
147 int _index_map_bs = -1;
150 graph::AdjacencyList<std::int32_t> _dofmap;
Mesh data structures and algorithms on meshes.
Definition: DirichletBC.h:22
DofMap extract_sub_dofmap(const std::vector< int > &component) const
Extract subdofmap component.
Definition: DofMap.cpp:194
std::pair< std::unique_ptr< DofMap >, std::vector< std::int32_t > > collapse(MPI_Comm comm, const mesh::Topology &topology) const
Create a "collapsed" dofmap (collapses a sub-dofmap)
Definition: DofMap.cpp:232
std::shared_ptr< const ElementDofLayout > element_dof_layout
Layout of dofs on an element.
Definition: DofMap.h:137
This class provides a static adjacency list data structure. It is commonly used to store directed gra...
Definition: AdjacencyList.h:46
const graph::AdjacencyList< std::int32_t > & list() const
Get dofmap data.
Definition: DofMap.cpp:293
Degree-of-freedom map.
Definition: DofMap.h:65
graph::AdjacencyList< std::int32_t > transpose_dofmap(const graph::AdjacencyList< std::int32_t > &dofmap, std::int32_t num_cells)
Create an adjacency list that maps a global index (process-wise) to the 'unassembled' cell-wise contr...
Definition: DofMap.cpp:150
Miscellaneous classes, functions and types.
int bs() const noexcept
Return the block size for the dofmap.
Definition: DofMap.cpp:192
virtual ~DofMap()=default
Destructor.
The class represents the degree-of-freedom (dofs) for an element. Dofs are associated with a mesh ent...
Definition: ElementDofLayout.h:35
DofMap(std::shared_ptr< const ElementDofLayout > element, std::shared_ptr< const common::IndexMap > index_map, int index_map_bs, U &&dofmap, int bs)
Create a DofMap from the layout of dofs on a reference element, an IndexMap defining the distribution...
Definition: DofMap.h:83
std::shared_ptr< const common::IndexMap > index_map
Index map that describes the parallel distribution of the dofmap.
Definition: DofMap.h:140
Finite element method functionality.
Definition: assemble_matrix_impl.h:22
int index_map_bs() const
Block size associated with the index_map.
Definition: DofMap.cpp:298
xtl::span< const std::int32_t > cell_dofs(int cell) const
Local-to-global mapping of dofs on a cell.
Definition: DofMap.h:111