KASKADE 7 development version
Public Types | Public Member Functions | Static Public Attributes | Protected Attributes | List of all members
Kaskade::HierarchicSimplexShapeFunctionSet< ctype, dimension, Scalar > Class Template Referenceabstract

A container of hierarchic shape functions (see HierarchicSimplexShapeFunction) up to a given nominal order on the unit simplex of grid dimension. More...

#include <hierarchicshapefunctions.hh>

Detailed Description

template<class ctype, int dimension, class Scalar>
class Kaskade::HierarchicSimplexShapeFunctionSet< ctype, dimension, Scalar >

A container of hierarchic shape functions (see HierarchicSimplexShapeFunction) up to a given nominal order on the unit simplex of grid dimension.

For Ord<0, this set is empty.

Definition at line 398 of file hierarchicshapefunctions.hh.

Inheritance diagram for Kaskade::HierarchicSimplexShapeFunctionSet< ctype, dimension, Scalar >:
Kaskade::ShapeFunctionSet< ctype, dimension, Scalar >

Public Types

typedef HierarchicSimplexShapeFunction< ctype, dimension, Scalarvalue_type
 
typedef ShapeFunctionSet< ctype, dimension, Scalar >::Matrix Matrix
 
typedef Scalar Scalar
 Scalar field type. More...
 
typedef std::vector< Dune::FieldVector< ctype, dimension > > InterpolationNodes
 A container type for holding interpolation points in the reference elements. More...
 
typedef DynamicMatrix< Dune::FieldMatrix< Scalar, 1, 1 > > SfValueArray
 

Public Member Functions

 HierarchicSimplexShapeFunctionSet (int ord)
 Constructs a hierarchic shape function set. More...
 
 HierarchicSimplexShapeFunctionSet (HierarchicSimplexShapeFunctionSet const &other)=default
 Copy constructor. More...
 
 HierarchicSimplexShapeFunctionSet (HierarchicSimplexShapeFunctionSet &&other)=default
 Move constructor. More...
 
virtual ~HierarchicSimplexShapeFunctionSet ()
 
virtual value_type const & operator[] (int i) const
 Random access to a shape function. More...
 
virtual Dune::GeometryType type () const
 
virtual void interpolate (typename ShapeFunctionSet< ctype, dimension, Scalar >::SfValueArray const &A, Matrix &IA) const
 
void removeShapeFunction (size_t index)
 
virtual int size () const
 Number of shape functions in the set. More...
 
int order () const
 Maximal polynomial order of shape functions. More...
 
auto referenceElement () const
 
void initHierarchicalProjection (ShapeFunctionSet< ctype, dimension, Scalar, 1 > const *sfl)
 Initialize the hierarchical projection matrix based on the given lower order shape function set. More...
 
InterpolationNodes const & interpolationNodes () const
 Interpolation points. More...
 
virtual void interpolate (SfValueArray const &A, Matrix &IA) const=0
 Left-multiplies the provided matrix with the interpolation matrix of the shape function set. More...
 
void evaluate (InterpolationNodes const &iNodes, SfValueArray &phi) const
 Evaluate shape function set at a set of points. In notation of the LocalToGlobalMapperConcept, this gives the matrix \( \Phi \): the entry Phi[i][j] is the value of shape function j evaluated at iNodes[i]. More...
 
Matrix const & hierarchicProjection () const
 Returns a square matrix that projects shape function coefficients to a subspace spanned by shape functions of lower order. This is intended to be used to implement embedded error estimators. The actual definition of this subspace depends on the shape function set specified in the call to initHierarchicalProjection(). More...
 

Static Public Attributes

static int const comps
 Number of components of the shape function values. More...
 

Protected Attributes

std::vector< value_typesf
 
DynamicMatrix< Dune::FieldMatrix< Scalar, 1, 1 > > pinv
 
InterpolationNodes iNodes
 
Matrix projection
 
int order_
 
int size_
 

Member Typedef Documentation

◆ InterpolationNodes

typedef std::vector<Dune::FieldVector<ctype,dimension> > Kaskade::ShapeFunctionSet< ctype, dimension, Scalar , 1 >::InterpolationNodes
inherited

A container type for holding interpolation points in the reference elements.

Definition at line 164 of file pshapefunctions.hh.

◆ Matrix

template<class ctype , int dimension, class Scalar >
typedef ShapeFunctionSet<ctype,dimension,Scalar>::Matrix Kaskade::HierarchicSimplexShapeFunctionSet< ctype, dimension, Scalar >::Matrix

Definition at line 402 of file hierarchicshapefunctions.hh.

◆ Scalar

typedef Scalar Kaskade::ShapeFunctionSet< ctype, dimension, Scalar , 1 >::Scalar
inherited

Scalar field type.

Definition at line 112 of file pshapefunctions.hh.

◆ SfValueArray

typedef DynamicMatrix<Dune::FieldMatrix<Scalar ,1 ,1> > Kaskade::ShapeFunctionSet< ctype, dimension, Scalar , 1 >::SfValueArray
inherited

A twodimensional array type for holding shape function values evaluated at a set of nodes.

Definition at line 168 of file pshapefunctions.hh.

◆ value_type

template<class ctype , int dimension, class Scalar >
typedef HierarchicSimplexShapeFunction<ctype,dimension,Scalar> Kaskade::HierarchicSimplexShapeFunctionSet< ctype, dimension, Scalar >::value_type

Definition at line 401 of file hierarchicshapefunctions.hh.

Constructor & Destructor Documentation

◆ HierarchicSimplexShapeFunctionSet() [1/3]

template<class ctype , int dimension, class Scalar >
Kaskade::HierarchicSimplexShapeFunctionSet< ctype, dimension, Scalar >::HierarchicSimplexShapeFunctionSet ( int  ord)
inline

Constructs a hierarchic shape function set.

The shape functions span the set \( \bigcup_{p=0}^{\mathrm{ord}} \Phi_p^d \) (see * HierarchicSimplexShapeFunction).

Definition at line 410 of file hierarchicshapefunctions.hh.

◆ HierarchicSimplexShapeFunctionSet() [2/3]

template<class ctype , int dimension, class Scalar >
Kaskade::HierarchicSimplexShapeFunctionSet< ctype, dimension, Scalar >::HierarchicSimplexShapeFunctionSet ( HierarchicSimplexShapeFunctionSet< ctype, dimension, Scalar > const &  other)
default

Copy constructor.

◆ HierarchicSimplexShapeFunctionSet() [3/3]

template<class ctype , int dimension, class Scalar >
Kaskade::HierarchicSimplexShapeFunctionSet< ctype, dimension, Scalar >::HierarchicSimplexShapeFunctionSet ( HierarchicSimplexShapeFunctionSet< ctype, dimension, Scalar > &&  other)
default

Move constructor.

◆ ~HierarchicSimplexShapeFunctionSet()

template<class ctype , int dimension, class Scalar >
virtual Kaskade::HierarchicSimplexShapeFunctionSet< ctype, dimension, Scalar >::~HierarchicSimplexShapeFunctionSet ( )
inlinevirtual

Definition at line 467 of file hierarchicshapefunctions.hh.

Member Function Documentation

◆ evaluate()

void Kaskade::ShapeFunctionSet< ctype, dimension, Scalar , 1 >::evaluate ( InterpolationNodes const &  iNodes,
SfValueArray phi 
) const
inlineinherited

Evaluate shape function set at a set of points. In notation of the LocalToGlobalMapperConcept, this gives the matrix \( \Phi \): the entry Phi[i][j] is the value of shape function j evaluated at iNodes[i].

Parameters
iNodesthe points at which the shape functions are to be evaluated.
phithe array that is filled with shape function values. The array will be resized if needed.

Definition at line 253 of file pshapefunctions.hh.

◆ hierarchicProjection()

Matrix const & Kaskade::ShapeFunctionSet< ctype, dimension, Scalar , 1 >::hierarchicProjection ( ) const
inlineinherited

Returns a square matrix that projects shape function coefficients to a subspace spanned by shape functions of lower order. This is intended to be used to implement embedded error estimators. The actual definition of this subspace depends on the shape function set specified in the call to initHierarchicalProjection().

Definition at line 276 of file pshapefunctions.hh.

◆ initHierarchicalProjection()

void Kaskade::ShapeFunctionSet< ctype, dimension, Scalar , 1 >::initHierarchicalProjection ( ShapeFunctionSet< ctype, dimension, Scalar , 1 > const *  sfl)
inlineinherited

Initialize the hierarchical projection matrix based on the given lower order shape function set.

Definition at line 174 of file pshapefunctions.hh.

◆ interpolate() [1/2]

virtual void Kaskade::ShapeFunctionSet< ctype, dimension, Scalar , 1 >::interpolate ( SfValueArray const &  A,
Matrix IA 
) const
pure virtualinherited

Left-multiplies the provided matrix with the interpolation matrix of the shape function set.

Each column of A is interpreted as values of some function evaluated at this shape function set's interpolation points (see below). The columns of the output array IA then contain the shape function coefficients such that the corresponding linearcombination of shape functions "interpolates" that function in the interpolation points. What "interpolation" means is up to the actual implementation.

IA is automatically resized if needed.

Storage order: A[i][j] contains the value of function j at interpolation node i.

◆ interpolate() [2/2]

template<class ctype , int dimension, class Scalar >
virtual void Kaskade::HierarchicSimplexShapeFunctionSet< ctype, dimension, Scalar >::interpolate ( typename ShapeFunctionSet< ctype, dimension, Scalar >::SfValueArray const &  A,
Matrix IA 
) const
inlinevirtual

Definition at line 473 of file hierarchicshapefunctions.hh.

◆ interpolationNodes()

InterpolationNodes const & Kaskade::ShapeFunctionSet< ctype, dimension, Scalar , 1 >::interpolationNodes ( ) const
inlineinherited

Interpolation points.

Provides interpolation points such that the shape function coefficients can be computed from function values at interpolation nodes by multiplication by this matrix. The interpolation points are guaranteed to be inside the reference element associated to this shape function set.

Definition at line 218 of file pshapefunctions.hh.

◆ operator[]()

template<class ctype , int dimension, class Scalar >
virtual value_type const & Kaskade::HierarchicSimplexShapeFunctionSet< ctype, dimension, Scalar >::operator[] ( int  i) const
inlinevirtual

Random access to a shape function.

Implements Kaskade::ShapeFunctionSet< ctype, dimension, Scalar >.

Definition at line 469 of file hierarchicshapefunctions.hh.

◆ order()

int Kaskade::ShapeFunctionSet< ctype, dimension, Scalar , 1 >::order ( ) const
inlineinherited

Maximal polynomial order of shape functions.

Definition at line 149 of file pshapefunctions.hh.

◆ referenceElement()

auto Kaskade::ShapeFunctionSet< ctype, dimension, Scalar , 1 >::referenceElement ( ) const
inlineinherited

Returns a reference to the reference element on which this shape function set is defined.

Definition at line 158 of file pshapefunctions.hh.

◆ removeShapeFunction()

template<class ctype , int dimension, class Scalar >
void Kaskade::HierarchicSimplexShapeFunctionSet< ctype, dimension, Scalar >::removeShapeFunction ( size_t  index)
inlinevirtual

◆ size()

virtual int Kaskade::ShapeFunctionSet< ctype, dimension, Scalar , 1 >::size ( ) const
inlinevirtualinherited

Number of shape functions in the set.

Definition at line 144 of file pshapefunctions.hh.

◆ type()

template<class ctype , int dimension, class Scalar >
virtual Dune::GeometryType Kaskade::HierarchicSimplexShapeFunctionSet< ctype, dimension, Scalar >::type ( ) const
inlinevirtual

Definition at line 471 of file hierarchicshapefunctions.hh.

Member Data Documentation

◆ comps

int const Kaskade::ShapeFunctionSet< ctype, dimension, Scalar , 1 >::comps
staticinherited

Number of components of the shape function values.

Definition at line 132 of file pshapefunctions.hh.

◆ iNodes

InterpolationNodes Kaskade::ShapeFunctionSet< ctype, dimension, Scalar , 1 >::iNodes
protectedinherited

Definition at line 287 of file pshapefunctions.hh.

◆ order_

int Kaskade::ShapeFunctionSet< ctype, dimension, Scalar , 1 >::order_
protectedinherited

Definition at line 289 of file pshapefunctions.hh.

◆ pinv

template<class ctype , int dimension, class Scalar >
DynamicMatrix<Dune::FieldMatrix<Scalar,1,1> > Kaskade::HierarchicSimplexShapeFunctionSet< ctype, dimension, Scalar >::pinv
protected

◆ projection

Matrix Kaskade::ShapeFunctionSet< ctype, dimension, Scalar , 1 >::projection
protectedinherited

Definition at line 288 of file pshapefunctions.hh.

◆ sf

template<class ctype , int dimension, class Scalar >
std::vector<value_type> Kaskade::HierarchicSimplexShapeFunctionSet< ctype, dimension, Scalar >::sf
protected

◆ size_

int Kaskade::ShapeFunctionSet< ctype, dimension, Scalar , 1 >::size_
protectedinherited

Definition at line 290 of file pshapefunctions.hh.


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