OGS
ProcessLib::Assembly::SubmeshAssemblyData Struct Reference

Detailed Description

Data necessary for global equation system assembly on submeshes of the bulk mesh.

Definition at line 78 of file AssemblyData.h.

#include <AssemblyData.h>

Inheritance diagram for ProcessLib::Assembly::SubmeshAssemblyData:
[legend]
Collaboration diagram for ProcessLib::Assembly::SubmeshAssemblyData:
[legend]

Public Member Functions

 SubmeshAssemblyData (MeshLib::Mesh const &submesh, std::vector< std::vector< std::reference_wrapper< MeshLib::PropertyVector< double > > > > &&residuum_vectors)
void setAllElementsActive ()
 Assembly should proceed on all elements of this submesh.
void setElementSelectionActive (std::vector< std::size_t > const &sorted_active_element_ids_whole_mesh)
Public Member Functions inherited from ProcessLib::Assembly::CommonAssemblyData
 CommonAssemblyData (std::vector< std::vector< std::reference_wrapper< MeshLib::PropertyVector< double > > > > &&residuum_vectors)
std::shared_ptr< std::vector< std::size_t > const > activeElementIDsSorted (std::vector< std::size_t > const *const sorted_element_subset) const
virtual ~CommonAssemblyData ()=default

Public Attributes

MeshLib::PropertyVector< std::size_t > const & bulk_node_ids
Public Attributes inherited from ProcessLib::Assembly::CommonAssemblyData
std::vector< std::vector< std::reference_wrapper< MeshLib::PropertyVector< double > > > > residuum_vectors
 Residuum vectors for each process ID.

Private Attributes

MeshLib::PropertyVector< std::size_t > const & bulk_element_ids

Additional Inherited Members

Protected Member Functions inherited from ProcessLib::Assembly::CommonAssemblyData
bool areAllElementsActive () const
Protected Attributes inherited from ProcessLib::Assembly::CommonAssemblyData
std::shared_ptr< std::vector< std::size_t > const > sorted_active_element_ids_

Constructor & Destructor Documentation

◆ SubmeshAssemblyData()

ProcessLib::Assembly::SubmeshAssemblyData::SubmeshAssemblyData ( MeshLib::Mesh const & submesh,
std::vector< std::vector< std::reference_wrapper< MeshLib::PropertyVector< double > > > > && residuum_vectors )
explicit

Creates a new instance.

Parameters
submeshThe submesh to which the instance belongs.
residuum_vectorsResiduum vectors for each process ID.

Definition at line 60 of file AssemblyData.cpp.

68{
69}
PropertyVector< std::size_t > const * bulkElementIDs(Mesh const &mesh)
Definition Mesh.cpp:290
PropertyVector< std::size_t > const * bulkNodeIDs(Mesh const &mesh)
Definition Mesh.cpp:282
CommonAssemblyData(std::vector< std::vector< std::reference_wrapper< MeshLib::PropertyVector< double > > > > &&residuum_vectors)
std::vector< std::vector< std::reference_wrapper< MeshLib::PropertyVector< double > > > > residuum_vectors
Residuum vectors for each process ID.
MeshLib::PropertyVector< std::size_t > const & bulk_element_ids
MeshLib::PropertyVector< std::size_t > const & bulk_node_ids

References ProcessLib::Assembly::CommonAssemblyData::CommonAssemblyData(), bulk_element_ids, bulk_node_ids, and ProcessLib::Assembly::CommonAssemblyData::residuum_vectors.

Member Function Documentation

◆ setAllElementsActive()

void ProcessLib::Assembly::SubmeshAssemblyData::setAllElementsActive ( )

Assembly should proceed on all elements of this submesh.

Definition at line 71 of file AssemblyData.cpp.

72{
73 std::vector<std::size_t> aeis;
74 aeis.insert(aeis.end(), bulk_element_ids.begin(), bulk_element_ids.end());
75 ranges::sort(aeis);
77 std::make_shared<std::vector<std::size_t> const>(std::move(aeis));
78}
std::shared_ptr< std::vector< std::size_t > const > sorted_active_element_ids_

References bulk_element_ids, and ProcessLib::Assembly::CommonAssemblyData::sorted_active_element_ids_.

◆ setElementSelectionActive()

void ProcessLib::Assembly::SubmeshAssemblyData::setElementSelectionActive ( std::vector< std::size_t > const & sorted_active_element_ids_whole_mesh)

Assembly should proceed on the passed element IDs only (intersected with the elements of this submesh).

Definition at line 80 of file AssemblyData.cpp.

82{
83 assert(ranges::is_sorted(sorted_active_element_ids_whole_mesh));
84
85 std::vector<std::size_t> aeis;
86
87 ranges::set_intersection(bulk_element_ids,
88 sorted_active_element_ids_whole_mesh,
89 std::back_inserter(aeis));
90
92 std::make_shared<std::vector<std::size_t> const>(std::move(aeis));
93}

References bulk_element_ids, and ProcessLib::Assembly::CommonAssemblyData::sorted_active_element_ids_.

Member Data Documentation

◆ bulk_element_ids

MeshLib::PropertyVector<std::size_t> const& ProcessLib::Assembly::SubmeshAssemblyData::bulk_element_ids
private

◆ bulk_node_ids

MeshLib::PropertyVector<std::size_t> const& ProcessLib::Assembly::SubmeshAssemblyData::bulk_node_ids

The documentation for this struct was generated from the following files: