AXOM
Axom provides a robust, flexible software infrastructure for the development of multi-physics applications and computational tools.
axom::mint::ShapeFunction< ShapeType > Class Template Reference

The ShapeFunction class defines the shape functions, \( N(\xi)^e \), for a given reference element \( \overline{\Omega^e} \). More...

#include </home/docs/checkouts/readthedocs.org/user_builds/axom/checkouts/latest/src/axom/mint/fem/shape_functions/ShapeFunction.hpp>

Inheritance diagram for axom::mint::ShapeFunction< ShapeType >:

Static Public Member Functions

Generic ShapeFunction API
static CellType cellType ()
 Returns the underlying cell type, e.g., MINT_QUAD, etc. More...
 
static int type ()
 Returns the Finite Element basis family type. More...
 
static int numDofs ()
 Returns the number of degrees of freedom. More...
 
static int maxNewtonIters ()
 Returns the maximum number of iterations for the Newton-Raphson. More...
 
static int dimension ()
 Returns the dimension of the reference element. More...
 
static double min ()
 Returns the min coordinate of the reference element. More...
 
static double max ()
 Returns the max coordinate of the reference element. More...
 
static void center (double *center)
 Returns the center of the reference element. More...
 
static void coords (double *coords)
 Returns the coordinates of the reference element. More...
 
static void evaluate (const double *nc, double *phi)
 Evaluates the ShapeFunction at the given natural coordinates. More...
 
static void derivatives (const double *nc, double *phidot)
 Evaluates the first derivatives of the shape function at the given natural coordinates. More...
 

Detailed Description

template<typename ShapeType>
class axom::mint::ShapeFunction< ShapeType >

The ShapeFunction class defines the shape functions, \( N(\xi)^e \), for a given reference element \( \overline{\Omega^e} \).

ShapeFunction is a templated class that employs the Curiously Recurring Template Pattern (CRTP) to provide a unified API for all underlying ShapeFunction implementations.

See also
FiniteElement
FEBasisTypes.hpp

Member Function Documentation

◆ cellType()

template<typename ShapeType >
static CellType axom::mint::ShapeFunction< ShapeType >::cellType ( )
inlinestatic

Returns the underlying cell type, e.g., MINT_QUAD, etc.

Returns
cellType the cell type
See also
CellType.hpp

◆ type()

template<typename ShapeType >
static int axom::mint::ShapeFunction< ShapeType >::type ( )
inlinestatic

Returns the Finite Element basis family type.

Returns
type the basis function type, e.g., MINT_LAGRANGE_BASIS
See also
FEBasisTypes.hpp

◆ numDofs()

template<typename ShapeType >
static int axom::mint::ShapeFunction< ShapeType >::numDofs ( )
inlinestatic

Returns the number of degrees of freedom.

Returns
ndofs the number of degrees of freedom
Postcondition
ndofs >= 1

◆ maxNewtonIters()

template<typename ShapeType >
static int axom::mint::ShapeFunction< ShapeType >::maxNewtonIters ( )
inlinestatic

Returns the maximum number of iterations for the Newton-Raphson.

Returns
N the maximum number of Newton-Raphson iterations

◆ dimension()

template<typename ShapeType >
static int axom::mint::ShapeFunction< ShapeType >::dimension ( )
inlinestatic

Returns the dimension of the reference element.

Returns
ndims the dimension of the reference element
Postcondition
ndims >= 1

◆ min()

template<typename ShapeType >
static double axom::mint::ShapeFunction< ShapeType >::min ( )
inlinestatic

Returns the min coordinate of the reference element.

Returns
min the min coordinate of the reference element

◆ max()

template<typename ShapeType >
static double axom::mint::ShapeFunction< ShapeType >::max ( )
inlinestatic

Returns the max coordinate of the reference element.

Returns
max the max coordinate of the reference element

◆ center()

template<typename ShapeType >
static void axom::mint::ShapeFunction< ShapeType >::center ( double *  center)
inlinestatic

Returns the center of the reference element.

Parameters
[out]centerbuffer (ndims long) to store the centroid
Precondition
center != nullptr

◆ coords()

template<typename ShapeType >
static void axom::mint::ShapeFunction< ShapeType >::coords ( double *  coords)
inlinestatic

Returns the coordinates of the reference element.

Parameters
[out]coordsbuffer (ndims*ndofs long) to store the coordinates
Precondition
coords != nullptr
Note
THe coordinates are arranged in column-major flat array layout

◆ evaluate()

template<typename ShapeType >
static void axom::mint::ShapeFunction< ShapeType >::evaluate ( const double *  nc,
double *  phi 
)
inlinestatic

Evaluates the ShapeFunction at the given natural coordinates.

Parameters
[in]ncnatural coordinates at which to compute the shape functions
[out]phibuffer (ndofs long) to store the shape function.
Precondition
nc != nullptr
phi != nullptr

◆ derivatives()

template<typename ShapeType >
static void axom::mint::ShapeFunction< ShapeType >::derivatives ( const double *  nc,
double *  phidot 
)
inlinestatic

Evaluates the first derivatives of the shape function at the given natural coordinates.

Parameters
[in]ncnatural coordinates at which to compute the derivatives
[out]phidotbuffer (ndofs*ndims long) to store the derivatives
Precondition
nc != nullptr
phidot != nullptr

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