MeshFields
GPU accelerated mesh-based fields
Public Member Functions | Static Public Attributes | List of all members
MeshField::QuadraticTetrahedronShape Struct Reference

Quadratic (P2) shape functions for 3D tetrahedral elements. More...

#include <MeshField_Shape.hpp>

Public Member Functions

KOKKOS_INLINE_FUNCTION Kokkos::Array< Real, numNodes *meshEntDimgetNodeParametricCoords () const
 Get parametric coordinates of element nodes. More...
 
KOKKOS_INLINE_FUNCTION Kokkos::Array< Real, numNodesgetValues (Vector3 const &xi) const
 Evaluate quadratic shape functions at parametric coordinate. More...
 
KOKKOS_INLINE_FUNCTION Kokkos::Array< Real, meshEntDim *numNodesgetLocalGradients (Vector3 const &xi) const
 Get gradients of quadratic shape functions in parametric coordinates. More...
 

Static Public Attributes

static const size_t numNodes = 10
 Number of nodes (10 for quadratic tetrahedron)
 
static const size_t meshEntDim = 3
 Mesh entity dimension (3D)
 
constexpr static Mesh_Topology DofHolders [2] = {Vertex, Edge}
 DOFs at vertices and edges.
 
constexpr static size_t NumDofHolders [2] = {4, 6}
 4 vertices, 6 edges
 
constexpr static size_t DofsPerHolder [2] = {1, 1}
 1 DOF per vertex/edge
 
constexpr static size_t Order = 2
 Polynomial order (quadratic)
 

Detailed Description

Quadratic (P2) shape functions for 3D tetrahedral elements.

Defines quadratic basis functions for a tetrahedral element with 10 nodes. Nodes are located at vertices and edge midpoints. Parametric coordinate range: xi0, xi1, xi2 $\in$ [0, 1]

Node ordering:

Shape functions and ordering from: Zienkiewicz, Taylor, and Zhu 'The Finite Element Method: Its Basis and Fundamentals', 2013

Definition at line 461 of file MeshField_Shape.hpp.

Member Function Documentation

◆ getLocalGradients()

KOKKOS_INLINE_FUNCTION Kokkos::Array<Real, meshEntDim * numNodes> MeshField::QuadraticTetrahedronShape::getLocalGradients ( Vector3 const &  xi) const
inline

Get gradients of quadratic shape functions in parametric coordinates.

Parameters
xiParametric coordinates (xi0, xi1, xi2) where xi_i $\in$ [0,1]
Returns
Array of gradient vectors [dN0/dxi0, dN0/dxi1, dN0/dxi2, ..., dN9/dxi0, dN9/dxi1, dN9/dxi2]

Definition at line 532 of file MeshField_Shape.hpp.

◆ getNodeParametricCoords()

KOKKOS_INLINE_FUNCTION Kokkos::Array<Real, numNodes * meshEntDim> MeshField::QuadraticTetrahedronShape::getNodeParametricCoords ( ) const
inline

Get parametric coordinates of element nodes.

Returns
Array of node coordinates for 10 nodes (4 at vertices, 6 at edge midpoints)

Definition at line 474 of file MeshField_Shape.hpp.

◆ getValues()

KOKKOS_INLINE_FUNCTION Kokkos::Array<Real, numNodes> MeshField::QuadraticTetrahedronShape::getValues ( Vector3 const &  xi) const
inline

Evaluate quadratic shape functions at parametric coordinate.

Parameters
xiParametric coordinates (xi0, xi1, xi2) where xi_i $\in$ [0,1]
Returns
Array of 10 shape function values for quadratic tetrahedron N_i = L_i(2L_i - 1) for vertices (i=0,1,2,3) N_i = 4*L_j*L_k for edge midpoints (i=4-9) where L0=1-xi0-xi1-xi2, L1=xi0, L2=xi1, L3=xi2 are barycentric coordinates

Definition at line 502 of file MeshField_Shape.hpp.


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