dune-localfunctions  2.2.1
Public Types | Public Member Functions | List of all members
Dune::ScalarLocalToGlobalBasisAdaptor< LocalBasis, Geometry > Class Template Reference

Convert a simple scalar local basis into a global basis. More...

#include <dune/localfunctions/common/localtoglobaladaptors.hh>

Inheritance diagram for Dune::ScalarLocalToGlobalBasisAdaptor< LocalBasis, Geometry >:
Dune::BasisInterface

Public Types

typedef
LocalToGlobalBasisAdaptorTraits
< typename LocalBasis::Traits,
Geometry::coorddimension > 
Traits
 

Public Member Functions

 ScalarLocalToGlobalBasisAdaptor (const LocalBasis &localBasis_, const Geometry &geometry_)
 construct a ScalarLocalToGlobalBasisAdaptor More...
 
std::size_t size () const
 
std::size_t order () const
 return maximum polynomial order of the base function More...
 
void evaluateFunction (const typename Traits::DomainLocal &in, std::vector< typename Traits::Range > &out) const
 
void evaluateJacobian (const typename Traits::DomainLocal &in, std::vector< typename Traits::Jacobian > &out) const
 
void evaluateFunction (const Traits::DomainLocal &in, std::vector< Traits::Range > &out) const
 Evaluate all shape functions at given position. More...
 
void evaluateJacobian (const Traits::DomainLocal &in, std::vector< Traits::Jacobian > &out) const
 Evaluate Jacobian of all shape functions at given position. More...
 
void evaluate (const array< std::size_t, Traits::dimDomainGlobal > &directions, const Traits::DomainLocal &in, std::vector< Traits::Range > &out) const
 Evaluate derivatives of all shape functions at given position. More...
 

Detailed Description

template<class LocalBasis, class Geometry>
class Dune::ScalarLocalToGlobalBasisAdaptor< LocalBasis, Geometry >

Convert a simple scalar local basis into a global basis.

The local basis must be scalar, i.e. LocalBasis::Traits::dimRange must be

  1. It's values are not transformed.

For scalar function $f$, the gradient is equivalent to the transposed Jacobian $\nabla f|_x = J_f^T(x)$. The Jacobian is thus transformed using

\[ \nabla f|_{\mu(\hat x)} = \hat J_\mu^{-T}(\hat x) \cdot \hat\nabla\hat f|_{\hat x} \]

Here the hat $\hat{\phantom x}$ denotes local quantities and $\mu$ denotes the local-to-global map of the geometry.

Template Parameters
LocalBasisType of the local basis to adapt.
GeometryType of the local-to-global transformation.

Member Typedef Documentation

template<class LocalBasis, class Geometry>
typedef LocalToGlobalBasisAdaptorTraits<typename LocalBasis::Traits, Geometry::coorddimension> Dune::ScalarLocalToGlobalBasisAdaptor< LocalBasis, Geometry >::Traits

Constructor & Destructor Documentation

template<class LocalBasis, class Geometry>
Dune::ScalarLocalToGlobalBasisAdaptor< LocalBasis, Geometry >::ScalarLocalToGlobalBasisAdaptor ( const LocalBasis &  localBasis_,
const Geometry &  geometry_ 
)
inline

construct a ScalarLocalToGlobalBasisAdaptor

Parameters
localBasis_The local basis object to adapt.
geometry_The geometry object to use for adaption.
Note
This class stores the references passed here. Any use of this class after these references have become invalid results in undefined behaviour. The exception is that the destructor of this class may still be called.

Member Function Documentation

void Dune::BasisInterface::evaluate ( const array< std::size_t, Traits::dimDomainGlobal > &  directions,
const Traits::DomainLocal in,
std::vector< Traits::Range > &  out 
) const
inherited

Evaluate derivatives of all shape functions at given position.

Note
Only required for Traits::diffOrder >= 2
template<class LocalBasis, class Geometry>
void Dune::ScalarLocalToGlobalBasisAdaptor< LocalBasis, Geometry >::evaluateFunction ( const typename Traits::DomainLocal in,
std::vector< typename Traits::Range > &  out 
) const
inline
void Dune::BasisInterface::evaluateFunction ( const Traits::DomainLocal in,
std::vector< Traits::Range > &  out 
) const
inherited

Evaluate all shape functions at given position.

template<class LocalBasis, class Geometry>
void Dune::ScalarLocalToGlobalBasisAdaptor< LocalBasis, Geometry >::evaluateJacobian ( const typename Traits::DomainLocal in,
std::vector< typename Traits::Jacobian > &  out 
) const
inline
void Dune::BasisInterface::evaluateJacobian ( const Traits::DomainLocal in,
std::vector< Traits::Jacobian > &  out 
) const
inherited

Evaluate Jacobian of all shape functions at given position.

Note: Only required for Traits::diffOrder >= 1

template<class LocalBasis, class Geometry>
std::size_t Dune::ScalarLocalToGlobalBasisAdaptor< LocalBasis, Geometry >::order ( ) const
inline

return maximum polynomial order of the base function

This is to determine the required quadrature order. For an affine geometry this is the same order as for the local basis. For other geometries this returns the order of the local basis plus the global dimension minus 1. The assumtion for non-affine geometries is that they are still multi-linear.

template<class LocalBasis, class Geometry>
std::size_t Dune::ScalarLocalToGlobalBasisAdaptor< LocalBasis, Geometry >::size ( ) const
inline

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