3 #ifndef DUNE_LOCALFUNCTIONS_BREZZIDOUGLASMARINI2_SIMPLEX2D_LOCALINTERPOLATION_HH 4 #define DUNE_LOCALFUNCTIONS_BREZZIDOUGLASMARINI2_SIMPLEX2D_LOCALINTERPOLATION_HH 8 #include <dune/geometry/quadraturerules.hh> 29 sign0 = sign1 = sign2 = 1.0;
39 sign0 = sign1 = sign2 = 1.0;
63 n2[0] = 1.0/sqrt(2.0);
64 n2[1] = 1.0/sqrt(2.0);
65 c0 = 0.5*n0[0] - 1.0*n0[1];
66 c1 = -1.0*n1[0] + 0.5*n1[1];
67 c2 = 0.5*n2[0] + 0.5*n2[1];
78 template<
typename F,
typename C>
82 typedef typename LB::Traits::RangeFieldType Scalar;
83 typename F::Traits::RangeType y;
86 fill(out.begin(), out.end(), 0.0);
89 const Dune::QuadratureRule<Scalar,1>& rule = Dune::QuadratureRules<Scalar,1>::rule(Dune::GeometryType(Dune::GeometryType::simplex,1), qOrder);
91 for (
typename Dune::QuadratureRule<Scalar,1>::const_iterator it=rule.begin(); it!=rule.end(); ++it)
98 typename LB::Traits::RangeFieldType sign0, sign1, sign2;
99 typename LB::Traits::DomainType m0, m1, m2;
100 typename LB::Traits::DomainType n0, n1, n2;
101 typename LB::Traits::RangeFieldType c0, c1, c2;
104 #endif // DUNE_LOCALFUNCTIONS_BREZZIDOUGLASMARINI2_SIMPLEX2D_LOCALINTERPOLATION_HH BDM2Simplex2DLocalInterpolation(unsigned int s)
Make set number s, where 0 <= s < 8.
Definition: brezzidouglasmarini2simplex2dlocalinterpolation.hh:37
void interpolate(const F &f, std::vector< C > &out) const
Interpolate a given function with shape functions.
Definition: brezzidouglasmarini2simplex2dlocalinterpolation.hh:79
BDM2Simplex2DLocalInterpolation()
Standard constructor.
Definition: brezzidouglasmarini2simplex2dlocalinterpolation.hh:27
Definition: brezzidouglasmarini1cube2dlocalbasis.hh:14
First order Brezzi-Douglas-Marini shape functions on triangles.
Definition: brezzidouglasmarini2simplex2dlocalinterpolation.hh:22