dune-localfunctions
2.7.0
|
Go to the documentation of this file.
3 #ifndef DUNE_GENERIC_LOCALFINITEELEMENT_HH
4 #define DUNE_GENERIC_LOCALFINITEELEMENT_HH
6 #include <dune/geometry/type.hh>
20 template<
class BasisF,
class CoeffF,
class InterpolF>
25 typename CoeffF::Object,
28 typedef typename BasisF::Key
Key;
29 static const unsigned int dimDomain = BasisF::dimension;
36 "incompatible keys between BasisCreator and CoefficientsCreator");
38 "incompatible keys between BasisCreator and InterpolationCreator" );
42 : topologyId_( gt.id() ),
46 Impl::IfTopology< FiniteElement::template Maker, dimDomain >::apply( topologyId_, key_, finiteElement_ );
51 : topologyId_( other.topologyId_ ),
55 Impl::IfTopology< FiniteElement::template Maker, dimDomain >::apply( topologyId_, key_, finiteElement_ );
60 finiteElement_.release();
67 return *(finiteElement_.basis_);
74 return *(finiteElement_.coeff_);
81 return *(finiteElement_.interpol_);
87 return finiteElement_.basis_->size();
94 return GeometryType(topologyId_,
dimDomain);
101 unsigned
int topologyId ()
const
108 FiniteElement() : basis_(0), coeff_(0), interpol_(0) {}
109 template <
class Topology>
110 void create(
const Key &key )
113 basis_ = BasisF::template create<Topology>(key);
114 coeff_ = CoeffF::template create<Topology>(key);
115 interpol_ = InterpolF::template create<Topology>(key);
120 BasisF::release(basis_);
122 CoeffF::release(coeff_);
124 InterpolF::release(interpol_);
129 template<
class Topology >
132 static void apply (
const Key &key, FiniteElement &finiteElement )
134 finiteElement.template create<Topology>(key);
141 unsigned int topologyId_;
143 FiniteElement finiteElement_;
155 DGLocalCoefficientsFactory< typename FE::BasisFactory >,
156 typename FE::InterpolationFactory>
160 typename FE::InterpolationFactory>
Base;
180 DGLocalCoefficientsFactory< typename FE::BasisFactory >,
181 LocalL2InterpolationFactory< typename FE::BasisFactory, false > >
A factory class for the local l2 interpolations taking a basis factory.
Definition: l2interpolation.hh:196
BasisF BasisFactory
Definition: localfiniteelement.hh:31
GenericLocalFiniteElement< typename FE::BasisFactory, DGLocalCoefficientsFactory< typename FE::BasisFactory >, typename FE::InterpolationFactory > Base
Definition: localfiniteelement.hh:160
BasisF::Key Key
Definition: localfiniteelement.hh:28
L2LocalFiniteElement(const GeometryType >, const typename Base::Key &key)
Definition: localfiniteelement.hh:191
Definition: bdfmcube.hh:15
DGLocalFiniteElement(const GeometryType >, const typename Base::Key &key)
Definition: localfiniteelement.hh:166
unsigned int size() const
Number of shape functions in this finite element.
Definition: localfiniteelement.hh:85
const Traits::LocalCoefficientsType & localCoefficients() const
Definition: localfiniteelement.hh:72
~GenericLocalFiniteElement()
Definition: localfiniteelement.hh:58
const Traits::LocalInterpolationType & localInterpolation() const
Definition: localfiniteelement.hh:79
@ value
Definition: tensor.hh:166
GenericLocalFiniteElement(const GenericLocalFiniteElement &other)
Definition: localfiniteelement.hh:50
LocalFiniteElementTraits< typename BasisF::Object, typename CoeffF::Object, typename InterpolF::Object > Traits
Definition: localfiniteelement.hh:26
GenericLocalFiniteElement< typename FE::BasisFactory, DGLocalCoefficientsFactory< typename FE::BasisFactory >, LocalL2InterpolationFactory< typename FE::BasisFactory, false > > Base
Definition: localfiniteelement.hh:185
static void apply(const Key &key, FiniteElement &finiteElement)
Definition: localfiniteelement.hh:132
GeometryType type() const
Definition: localfiniteelement.hh:92
traits helper struct
Definition: localfiniteelementtraits.hh:10
GenericLocalFiniteElement< BasisF, CoeffF, InterpolF > This
Definition: localfiniteelement.hh:23
LI LocalInterpolationType
Definition: localfiniteelementtraits.hh:22
Base::Traits Traits
Definition: localfiniteelement.hh:162
CoeffF CoefficientFactory
Definition: localfiniteelement.hh:32
A LocalFiniteElement implementation based on three TopologyFactories providing the LocalBasis,...
Definition: localfiniteelement.hh:21
GenericLocalFiniteElement(const GeometryType >, const Key &key)
Definition: localfiniteelement.hh:41
LC LocalCoefficientsType
Definition: localfiniteelementtraits.hh:18
static const unsigned int dimDomain
Definition: localfiniteelement.hh:29
DUNE_DEPRECATED_MSG("Use type().id() instead!") unsigned int topologyId() const
Definition: localfiniteelement.hh:100
A factory class for the dg local coefficients.
Definition: dglocalcoefficients.hh:56
Takes the basis factory from a given LocalFiniteElement (derived from GenericLocalFiniteElement) and ...
Definition: localfiniteelement.hh:178
Base::Traits Traits
Definition: localfiniteelement.hh:187
Definition: localfiniteelement.hh:130
Takes the basis and interpolation factory from a given LocalFiniteElement (derived from GenericLocalF...
Definition: localfiniteelement.hh:153
InterpolF InterpolationFactory
Definition: localfiniteelement.hh:33
const Traits::LocalBasisType & localBasis() const
Definition: localfiniteelement.hh:65
LB LocalBasisType
Definition: localfiniteelementtraits.hh:14