Note: this is documentation for an old release. View the latest documentation at docs.fenicsproject.org/dolfinx/v0.9.0/cpp/doxygen/df/dfe/namespacedolfinx_1_1refinement_1_1plaza.html
DOLFINx  0.5.1
DOLFINx C++ interface
Enumerations | Functions
dolfinx::refinement::plaza Namespace Reference

Function in this namespace implement the refinement method described in Plaza and Carey "Local refinement of simplicial grids based on the skeleton" (Applied Numerical Mathematics 32 (2000) 195-218). More...

Enumerations

enum class  RefinementOptions : int { none = 0 , parent_cell = 1 , parent_facet = 2 , parent_cell_and_facet = 3 }
 Selection of options when refining a Mesh. parent_cell will output a list containing the local parent cell index for each new cell, parent_facet will output a list of the cell-local facet indices in the parent cell of each facet in each new cell (or -1 if no match). parent_cell_and_facet will output both datasets.
 

Functions

std::tuple< mesh::Mesh, std::vector< std::int32_t >, std::vector< std::int8_t > > refine (const mesh::Mesh &mesh, bool redistribute, RefinementOptions options)
 Uniform refine, optionally redistributing and optionally calculating the parent-child relationships, selected by RefinementOptions. More...
 
std::tuple< mesh::Mesh, std::vector< std::int32_t >, std::vector< std::int8_t > > refine (const mesh::Mesh &mesh, const std::span< const std::int32_t > &edges, bool redistribute, RefinementOptions options)
 Refine with markers, optionally redistributing, and optionally calculating the parent-child relationships, selected by RefinementOptions. More...
 
std::tuple< graph::AdjacencyList< std::int64_t >, std::vector< double >, std::array< std::size_t, 2 >, std::vector< std::int32_t >, std::vector< std::int8_t > > compute_refinement_data (const mesh::Mesh &mesh, RefinementOptions options)
 Refine mesh returning new mesh data. More...
 
std::tuple< graph::AdjacencyList< std::int64_t >, std::vector< double >, std::array< std::size_t, 2 >, std::vector< std::int32_t >, std::vector< std::int8_t > > compute_refinement_data (const mesh::Mesh &mesh, const std::span< const std::int32_t > &edges, RefinementOptions options)
 Refine with markers returning new mesh data. More...
 

Detailed Description

Function in this namespace implement the refinement method described in Plaza and Carey "Local refinement of simplicial grids based on the skeleton" (Applied Numerical Mathematics 32 (2000) 195-218).

Function Documentation

◆ compute_refinement_data() [1/2]

std::tuple< graph::AdjacencyList< std::int64_t >, std::vector< double >, std::array< std::size_t, 2 >, std::vector< std::int32_t >, std::vector< std::int8_t > > compute_refinement_data ( const mesh::Mesh mesh,
const std::span< const std::int32_t > &  edges,
RefinementOptions  options 
)

Refine with markers returning new mesh data.

Parameters
[in]meshInput mesh to be refined
[in]edgesIndices of the edges that should be split by this refinement
[in]optionsRefinementOptions enum to choose the computation of parent facets, parent cells. If an option is unselected, an empty list is returned.
Returns
New mesh data: cell topology, vertex coordinates and parent cell index, and stored parent facet indices (if requested).

◆ compute_refinement_data() [2/2]

std::tuple< graph::AdjacencyList< std::int64_t >, std::vector< double >, std::array< std::size_t, 2 >, std::vector< std::int32_t >, std::vector< std::int8_t > > compute_refinement_data ( const mesh::Mesh mesh,
RefinementOptions  options 
)

Refine mesh returning new mesh data.

Parameters
[in]meshInput mesh to be refined
[in]optionsRefinementOptions enum to choose the computation of parent facets, parent cells. If an option is unselected, an empty list is returned.
Returns
New mesh data: cell topology, vertex coordinates, vertex coordinates shape, and optional parent cell index, and parent facet indices.

◆ refine() [1/2]

std::tuple< mesh::Mesh, std::vector< std::int32_t >, std::vector< std::int8_t > > refine ( const mesh::Mesh mesh,
bool  redistribute,
RefinementOptions  options 
)

Uniform refine, optionally redistributing and optionally calculating the parent-child relationships, selected by RefinementOptions.

Parameters
[in]meshInput mesh to be refined
[in]redistributeFlag to call the mesh partitioner to redistribute after refinement
[in]optionsRefinementOptions enum to choose the computation of parent facets, parent cells. If an option is unselected, an empty list is returned.
Returns
New Mesh and optional parent cell index, parent facet indices

◆ refine() [2/2]

std::tuple< mesh::Mesh, std::vector< std::int32_t >, std::vector< std::int8_t > > refine ( const mesh::Mesh mesh,
const std::span< const std::int32_t > &  edges,
bool  redistribute,
RefinementOptions  options 
)

Refine with markers, optionally redistributing, and optionally calculating the parent-child relationships, selected by RefinementOptions.

Parameters
[in]meshInput mesh to be refined
[in]edgesIndices of the edges that should be split by this refinement
[in]redistributeFlag to call the Mesh Partitioner to redistribute after refinement
[in]optionsRefinementOptions enum to choose the computation of parent facets, parent cells. If an option is unselected, an empty list is returned.
Returns
New Mesh and optional parent cell index, parent facet indices