Template Function ImmersX::set_overlap_material_ids(dealii::Triangulation<dim, spacedim>&, const dealii::GridTools::Cache<spacedim, spacedim>&, PointGenerator&&, const OverlapMaterialIds&, const double)¶
Defined in File overlap_classification.h
Function Documentation¶
-
template<int dim, int spacedim, typename PointGenerator>
void ImmersX::set_overlap_material_ids(dealii::Triangulation<dim, spacedim> &source, const dealii::GridTools::Cache<spacedim, spacedim> &background, PointGenerator &&points_on_cell, const OverlapMaterialIds &ids = {}, const double tolerance = 1.e-10)¶ Assign material ids from physical samples located in a background mesh.
The point generator is called once per locally owned active source cell and must return a nonempty range of Point<spacedim>. It can supply lifted wall points instead of centreline points. A cell is outside if no sample is found, inside if every sample is found, and partial otherwise. This is a sampled classification, not an exact geometric cell intersection.
This operation is collective on the background communicator. Source and background communicators must be identical or congruent. Source cells may be owned by different ranks than the background cells containing the samples; ranks without local source cells still participate. Material ids are copied from source owners to ghost cells using deal.II’s cell-data exchange. Serial sources are also supported. Parallel source meshes must support GridTools::exchange_cell_data_to_ghosts().
Cell labels do not remove exterior samples from partially covered cells. Reclassify after changing either mesh, its mapping, or the sample geometry.