dune-functions 2.9.0
Public Types | Public Member Functions | Static Public Attributes | Protected Member Functions | Static Protected Member Functions | Protected Attributes | List of all members
Dune::Functions::TaylorHoodPreBasis< GV, HI > Class Template Reference

Pre-basis for lowest order Taylor-Hood basis. More...

#include <dune/functions/functionspacebases/taylorhoodbasis.hh>

Public Types

using GridView = GV
 The grid view that the FE basis is defined on. More...
 
using size_type = std::size_t
 Type used for indices and size information. More...
 
using Node = TaylorHoodBasisTree< GV >
 Template mapping root tree path to type of created tree node. More...
 

Public Member Functions

 TaylorHoodPreBasis (const GridView &gv)
 Constructor for a given grid view object. More...
 
void initializeIndices ()
 Initialize the global indices. More...
 
const GridViewgridView () const
 Obtain the grid view that the basis is defined on. More...
 
void update (const GridView &gv)
 Update the stored grid view, to be called if the grid has changed. More...
 
Node makeNode () const
 Create tree node. More...
 
size_type size () const
 Same as size(prefix) with empty prefix. More...
 
template<class SizePrefix >
size_type size (const SizePrefix &prefix) const
 Return number of possible values for next position in multi index. More...
 
size_type dimension () const
 Get the total dimension of the space spanned by this basis. More...
 
size_type maxNodeSize () const
 Get the maximal number of DOFs associated to node for any element. More...
 
template<typename It >
It indices (const Node &node, It it) const
 

Static Public Attributes

static constexpr size_type maxMultiIndexSize = useHybridIndices ? 3 : 2
 
static constexpr size_type minMultiIndexSize = 2
 
static constexpr size_type multiIndexBufferSize = maxMultiIndexSize
 

Protected Member Functions

template<bool hi, class It , typename std::enable_if< not hi, int >::type = 0>
It indicesImp (const Node &node, It multiIndices) const
 
template<bool hi, class It , typename std::enable_if< hi, int >::type = 0>
It indicesImp (const Node &node, It multiIndices) const
 

Static Protected Member Functions

template<class MultiIndex >
static const void multiIndexPushFront (MultiIndex &M, size_type M0)
 

Protected Attributes

GridView gridView_
 
PQ1PreBasis pq1PreBasis_
 
PQ2PreBasis pq2PreBasis_
 

Detailed Description

template<typename GV, bool HI = false>
class Dune::Functions::TaylorHoodPreBasis< GV, HI >

Pre-basis for lowest order Taylor-Hood basis.

Template Parameters
GVThe grid view that the FE basis is defined on
HIFlag to select hybrid indices
Note
This mainly serves as an example, since you can construct a pre-basis with the same functionality manually using
static const int k = 1;
using VelocityPreBasis = PowerPreBasis<IMS,LagrangePreBasis<GV,k+1>,dim>;
using PressurePreBasis = LagrangePreBasis<GV,k>;
A pre-basis for composite bases.
Definition: compositebasis.hh:53
A pre-basis for a PQ-lagrange bases with given order.
Definition: lagrangebasis.hh:55
A pre-basis for power bases.
Definition: powerbasis.hh:45
Where IMS is BlockedInterleaved if HI is set and FlatInterleaved otherwise.

Member Typedef Documentation

◆ GridView

template<typename GV , bool HI = false>
using Dune::Functions::TaylorHoodPreBasis< GV, HI >::GridView = GV

The grid view that the FE basis is defined on.

◆ Node

template<typename GV , bool HI = false>
using Dune::Functions::TaylorHoodPreBasis< GV, HI >::Node = TaylorHoodBasisTree<GV>

Template mapping root tree path to type of created tree node.

◆ size_type

template<typename GV , bool HI = false>
using Dune::Functions::TaylorHoodPreBasis< GV, HI >::size_type = std::size_t

Type used for indices and size information.

Constructor & Destructor Documentation

◆ TaylorHoodPreBasis()

template<typename GV , bool HI = false>
Dune::Functions::TaylorHoodPreBasis< GV, HI >::TaylorHoodPreBasis ( const GridView gv)
inline

Constructor for a given grid view object.

Member Function Documentation

◆ dimension()

template<typename GV , bool HI = false>
size_type Dune::Functions::TaylorHoodPreBasis< GV, HI >::dimension ( ) const
inline

Get the total dimension of the space spanned by this basis.

◆ gridView()

template<typename GV , bool HI = false>
const GridView & Dune::Functions::TaylorHoodPreBasis< GV, HI >::gridView ( ) const
inline

Obtain the grid view that the basis is defined on.

◆ indices()

template<typename GV , bool HI = false>
template<typename It >
It Dune::Functions::TaylorHoodPreBasis< GV, HI >::indices ( const Node node,
It  it 
) const
inline

◆ indicesImp() [1/2]

template<typename GV , bool HI = false>
template<bool hi, class It , typename std::enable_if< not hi, int >::type = 0>
It Dune::Functions::TaylorHoodPreBasis< GV, HI >::indicesImp ( const Node node,
It  multiIndices 
) const
inlineprotected

◆ indicesImp() [2/2]

template<typename GV , bool HI = false>
template<bool hi, class It , typename std::enable_if< hi, int >::type = 0>
It Dune::Functions::TaylorHoodPreBasis< GV, HI >::indicesImp ( const Node node,
It  multiIndices 
) const
inlineprotected

◆ initializeIndices()

template<typename GV , bool HI = false>
void Dune::Functions::TaylorHoodPreBasis< GV, HI >::initializeIndices ( )
inline

Initialize the global indices.

◆ makeNode()

template<typename GV , bool HI = false>
Node Dune::Functions::TaylorHoodPreBasis< GV, HI >::makeNode ( ) const
inline

Create tree node.

◆ maxNodeSize()

template<typename GV , bool HI = false>
size_type Dune::Functions::TaylorHoodPreBasis< GV, HI >::maxNodeSize ( ) const
inline

Get the maximal number of DOFs associated to node for any element.

◆ multiIndexPushFront()

template<typename GV , bool HI = false>
template<class MultiIndex >
static const void Dune::Functions::TaylorHoodPreBasis< GV, HI >::multiIndexPushFront ( MultiIndex &  M,
size_type  M0 
)
inlinestaticprotected

◆ size() [1/2]

template<typename GV , bool HI = false>
size_type Dune::Functions::TaylorHoodPreBasis< GV, HI >::size ( ) const
inline

Same as size(prefix) with empty prefix.

◆ size() [2/2]

template<typename GV , bool HI = false>
template<class SizePrefix >
size_type Dune::Functions::TaylorHoodPreBasis< GV, HI >::size ( const SizePrefix &  prefix) const
inline

Return number of possible values for next position in multi index.

◆ update()

template<typename GV , bool HI = false>
void Dune::Functions::TaylorHoodPreBasis< GV, HI >::update ( const GridView gv)
inline

Update the stored grid view, to be called if the grid has changed.

Member Data Documentation

◆ gridView_

template<typename GV , bool HI = false>
GridView Dune::Functions::TaylorHoodPreBasis< GV, HI >::gridView_
protected

◆ maxMultiIndexSize

template<typename GV , bool HI = false>
constexpr size_type Dune::Functions::TaylorHoodPreBasis< GV, HI >::maxMultiIndexSize = useHybridIndices ? 3 : 2
staticconstexpr

◆ minMultiIndexSize

template<typename GV , bool HI = false>
constexpr size_type Dune::Functions::TaylorHoodPreBasis< GV, HI >::minMultiIndexSize = 2
staticconstexpr

◆ multiIndexBufferSize

template<typename GV , bool HI = false>
constexpr size_type Dune::Functions::TaylorHoodPreBasis< GV, HI >::multiIndexBufferSize = maxMultiIndexSize
staticconstexpr

◆ pq1PreBasis_

template<typename GV , bool HI = false>
PQ1PreBasis Dune::Functions::TaylorHoodPreBasis< GV, HI >::pq1PreBasis_
protected

◆ pq2PreBasis_

template<typename GV , bool HI = false>
PQ2PreBasis Dune::Functions::TaylorHoodPreBasis< GV, HI >::pq2PreBasis_
protected

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