Intrepid2
Public Types | Public Member Functions | Static Public Member Functions | Private Types | Static Private Member Functions | Static Private Attributes | List of all members
Intrepid2::RefSubcellParametrization< DeviceType > Class Template Reference

This class defines the parametrizations of edges and faces of supported reference cells. The parametrization mappings are stored in static Kokkos views. The class is templated on the Kokkos::Device Type which is used to determine layout and memory space of the views. More...

#include <Intrepid2_CellData.hpp>

Public Types

using ConstViewType = Kokkos::DynRankView< const double, DeviceType >
 

Public Member Functions

 RefSubcellParametrization ()=default
 Default constructor.
 
 ~RefSubcellParametrization ()=default
 Destructor.
 

Static Public Member Functions

static bool isSupported (const unsigned cellTopoKey)
 Checks if a cell topology has a reference parametrization. More...
 
static ConstViewType get (const ordinal_type subcellDim, const unsigned parentCellKey)
 Returns a Kokkos view with the coefficients of the parametrization maps for the edges or faces of a reference cell topology. More...
 

Private Types

using ViewType = Kokkos::DynRankView< double, DeviceType >
 static views containing the parametrization maps, allocated on DeviceType::memory_space
 

Static Private Member Functions

static void set ()
 Computes and stores static views containing the parametrizations maps of edges and faces of all reference cells.
 
template<typename HostViewType >
static void set (HostViewType subcellParam, const ordinal_type subcellDim, const shards::CellTopology parentCell)
 Sets parametrizations of reference edges and faces of cell topologies with reference cells. Used to populate Host views from array data. More...
 

Static Private Attributes

static ViewType lineEdgesParam
 
static ViewType triEdgesParam
 
static ViewType quadEdgesParam
 
static ViewType shellTriEdgesParam
 
static ViewType shellQuadEdgesParam
 
static ViewType tetEdgesParam
 
static ViewType hexEdgesParam
 
static ViewType pyrEdgesParam
 
static ViewType wedgeEdgesParam
 
static ViewType shellTriFacesParam
 
static ViewType shellQuadFacesParam
 
static ViewType tetFacesParam
 
static ViewType hexFacesParam
 
static ViewType pyrFacesParam
 
static ViewType wedgeFacesParam
 
static bool isSubcellParametrizationSet_ = false
 whether the parametrizations have been already computed using the method set()
 

Detailed Description

template<typename DeviceType>
class Intrepid2::RefSubcellParametrization< DeviceType >

This class defines the parametrizations of edges and faces of supported reference cells. The parametrization mappings are stored in static Kokkos views. The class is templated on the Kokkos::Device Type which is used to determine layout and memory space of the views.

Given an edge {V0, V1} of some reference cell, its parametrization is a mapping from [-1,1] onto the edge. Parametrization of a triangular face {V0,V1,V2} is mapping from the standard 2-simplex {(0,0,0), (1,0,0), (0,1,0)}, embedded in 3D onto that face. Parametrization of a quadrilateral face {V0,V1,V2,V3} is mapping from the standard 2-cube {(-1,-1,0),(1,-1,0),(1,1,0),(-1,1,0)}, embedded in 3D, onto that face.

All mappings are affine and orientation-preserving, i.e., they preserve the tangent and normal directions implied by the vertex order of the edge or the face relative to the reference cell:

Because faces of all reference cells supported in Intrepid2 are affine images of either the standard 2-simplex or the standard 2-cube, the coordinate functions of the respective parmetrization maps are linear polynomials in the parameter variables (u,v), i.e., they are of the form F_i(u,v)=C_0(i)+C_1(i)u+C_2(i)v; 0<=i<3 (face parametrizations are supported only for 3D cells, thus parametrization maps have 3 coordinate functions). As a result, application of these maps is independent of the face type which is convenient for cells such as Wedge or Pyramid that have both types of faces. Also, coefficients of coordinate functions for all faces can be stored together in the same array.

Definition at line 77 of file Intrepid2_CellData.hpp.

Member Function Documentation

template<typename DeviceType >
RefSubcellParametrization< DeviceType >::ConstViewType Intrepid2::RefSubcellParametrization< DeviceType >::get ( const ordinal_type  subcellDim,
const unsigned  parentCellKey 
)
inlinestatic

Returns a Kokkos view with the coefficients of the parametrization maps for the edges or faces of a reference cell topology.

See Intrepid2::RefSubcellParametrization class description for details about parametrization maps.

Parameters
subcellDim[in] - dimension of subcells whose parametrization map is returned
parentCellKey[in] - topology key of the reference cell owning the subcells
Returns
a rank-3 Kokkos::View containing coefficients of the parameterization map for all subcells of the specified dimension. Returned view has dimensions (# subcells, parentCellDim, subcellDim+1)

Definition at line 69 of file Intrepid2_CellDataDef.hpp.

Referenced by Intrepid2::ProjectionStruct< DeviceType, ValueType >::createHCurlProjectionStruct(), Intrepid2::ProjectionStruct< DeviceType, ValueType >::createHDivProjectionStruct(), Intrepid2::ProjectionStruct< DeviceType, ValueType >::createHGradProjectionStruct(), Intrepid2::ProjectionStruct< DeviceType, ValueType >::createL2ProjectionStruct(), Intrepid2::Impl::OrientationTools::getCoeffMatrix_HDIV(), Intrepid2::Impl::OrientationTools::getCoeffMatrix_HGRAD(), Intrepid2::ProjectionTools< DeviceType >::getHCurlBasisCoeffs(), Intrepid2::ProjectionTools< DeviceType >::getHGradBasisCoeffs(), Intrepid2::LagrangianTools< DeviceType >::getOrientedDofCoords(), Intrepid2::CellTools< DeviceType >::getPhysicalEdgeTangents(), Intrepid2::CellTools< DeviceType >::getPhysicalFaceTangents(), Intrepid2::CellTools< DeviceType >::getReferenceEdgeTangent(), and Intrepid2::CellTools< DeviceType >::getReferenceFaceTangents().

template<typename DeviceType >
bool Intrepid2::RefSubcellParametrization< DeviceType >::isSupported ( const unsigned  cellTopoKey)
inlinestatic

Checks if a cell topology has a reference parametrization.

Parameters
cellTopoKey[in] - key of the cell topology
Returns
true if the cell topology has a cell parametrization, false otherwise

Definition at line 27 of file Intrepid2_CellDataDef.hpp.

Referenced by Intrepid2::CellTools< DeviceType >::hasReferenceCell().

template<typename DeviceType >
template<typename HostViewType >
void Intrepid2::RefSubcellParametrization< DeviceType >::set ( HostViewType  subcellParam,
const ordinal_type  subcellDim,
const shards::CellTopology  parentCell 
)
staticprivate

Sets parametrizations of reference edges and faces of cell topologies with reference cells. Used to populate Host views from array data.

See Intrepid2::RefSubcellParametrization::set() for more info about parametrization maps.

Parameters
subcellParam[out] - host view with the coefficients of the parametrization map
subcellDim[in] - dimension of the subcells being parametrized (1 or 2)
parentCell[in] - topology of the parent cell owning the subcells.

Definition at line 244 of file Intrepid2_CellDataDef.hpp.

References Intrepid2::RefCellNodes< DeviceType >::get().


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