14#include "libmesh/elem.h"
20 const std::vector<dof_id_type> & primary_elem_ids,
21 const std::vector<std::tuple<dof_id_type, unsigned short int>> & secondary_boundary_info)
48 assembly.
reinit(primary_elem);
53 for (
const auto & secondary_elem_id : secondary_elem_ids)
61 const Elem * secondary_elem =
_mesh.
elemPtr(secondary_elem_id);
63 assembly.
reinit(secondary_elem, secondary_side_id);
69 for (std::size_t i = 0; i < secondary_qps.size(); i++)
71 unsigned int patch_size = 1;
72 std::vector<std::size_t> return_index(patch_size);
73 kd_tree_qp.
neighborSearch(secondary_qps[i], patch_size, return_index);
const MooseArray< Point > & qPoints() const
void setCurrentSubdomainID(SubdomainID i)
void reinit(const Elem *elem)
const MooseArray< Point > & qPointsFace() const
void neighborSearch(const Point &query_point, unsigned int patch_size, std::vector< std::size_t > &return_index)
void buildCoupledElemQpIndexMap(Assembly &assembly)
Builds the map used for getting the coupled quadrature point index.
void initialize(const std::vector< dof_id_type > &primary_elem_ids, const std::vector< std::tuple< dof_id_type, unsigned short int > > &secondary_boundary_info)
Extracts mesh information and builds the mapping.
MeshAlignment1D3D(const MooseMesh &mesh)
Constructor.
const MooseMesh & _mesh
Mesh.
std::vector< dof_id_type > _primary_node_ids
List of primary node IDs.
std::vector< dof_id_type > _primary_elem_ids
List of primary element IDs.
std::vector< Point > _primary_elem_points
List of primary element points.
std::vector< Point > _primary_node_points
List of primary node points.
std::vector< dof_id_type > _secondary_node_ids
List of secondary node IDs.
void extractFromBoundaryInfo(const std::vector< std::tuple< dof_id_type, unsigned short int > > &boundary_info, std::vector< dof_id_type > &elem_ids, std::vector< unsigned short int > &side_ids, std::vector< Point > &side_points, std::vector< dof_id_type > &node_ids, std::vector< Point > &node_points) const
Extracts mesh information from boundary info.
void extractFrom1DElements(const std::vector< dof_id_type > &elem_ids, std::vector< Point > &elem_points, std::vector< dof_id_type > &node_ids, std::vector< Point > &node_points) const
Extracts mesh information from 1D elements.
std::vector< Point > _secondary_elem_points
List of secondary element points.
std::vector< unsigned short int > _secondary_side_ids
List of secondary side IDs (if any)
std::vector< Point > _secondary_node_points
List of secondary node points.
std::vector< dof_id_type > _secondary_elem_ids
List of secondary element IDs.
Builds mapping between a 1D/2D boundary and a 3D boundary.
void buildMapping()
Builds the mapping using the extracted mesh information.
std::map< dof_id_type, std::vector< unsigned int > > _secondary_elem_id_to_qp_indices
Map of secondary element ID to vector of coupled quadrature points.
const std::vector< dof_id_type > & getCoupledSecondaryElemIDs(const dof_id_type &primary_elem_id) const
Gets the coupled secondary element IDs for a given primary element ID.
unsigned int _n_qp_primary
Number of quadrature points for faces on the primary boundary.
unsigned int _n_qp_secondary
Number of quadrature points for faces on the secondary boundary.
std::vector< T > stdVector() const
unsigned int getMaxLeafSize() const
virtual Elem * elemPtr(const dof_id_type i)
virtual Elem * queryElemPtr(const dof_id_type i)
processor_id_type processor_id() const