dune-fem 2.12-git
Loading...
Searching...
No Matches
dunequadratures.hh
Go to the documentation of this file.
1#ifndef DUNE_FEM_DUNEQUADRATURES_HH
2#define DUNE_FEM_DUNEQUADRATURES_HH
3
4//- Dune includes
7
10
11namespace Dune
12{
13
14 namespace Fem
15 {
16
17
18
27 template< typename FieldImp, int dim >
29 : public QuadratureImp< FieldImp, dim >
30 {
31 public:
32 typedef FieldImp FieldType;
33
34 enum { dimension = dim };
35
36 private:
39
40 protected:
41 using BaseType :: addQuadraturePoint;
42
43 public:
44 typedef typename BaseType :: CoordinateType CoordinateType;
45
46 protected:
48
49 //enum { highest_order_cube = CubeQuadratureRule<ct,dim>::highest_order };
50 //enum { highest_order_simplex = SimplexQuadratureRule<ct,dim>::highest_order };
51
52 enum { highest_order = 44 };
53 //(highest_order_cube < highest_order_simplex) ?
54 // highest_order_cube : highest_order_simplex };
55
56 protected:
58 int order_;
59
60 public:
68 const int order,
69 const size_t id )
70 : BaseType( id ),
71 elementGeometry_( geometry )
72 {
73 // get gauss quadrature
74 const DuneQuadratureRuleType &rule
76 //:: rule( geometry, order, QuadratureType :: GaussLegendre );
77 :: rule( geometry, order, QuadratureType :: GaussLobatto );
78
79 order_ = rule.order();
80 assert( order <= order_ );
81
82 typedef typename DuneQuadratureRuleType :: iterator IteratorType;
83 const IteratorType endit = rule.end();
84 for( IteratorType it = rule.begin(); it != endit; ++it )
85 addQuadraturePoint( (*it).position(), (*it).weight() );
86 }
87
90 int order () const
91 {
92 return order_;
93 }
94
98 {
99 return elementGeometry_;
100 }
101
104 static unsigned int maxOrder ()
105 {
106 return highest_order;
107 }
108 };
109
110
111
112 template< class FieldType, int dim >
123
124 template< class FieldType >
133
134 template< class FieldType >
143
144 template< class FieldType >
159
160 } // namespace Fem
161
162} // namespace Dune
163
164#endif // #ifndef DUNE_FEM_DUNEQUADRATURES_HH
size_type dim() const
virtual int order() const
quadrature implementation based on the standard DUNE quadratures
Definition dunequadratures.hh:30
int order() const
obtain order of the integration point list
Definition dunequadratures.hh:90
GeometryType geometryType() const
Definition dunequadratures.hh:97
FieldImp FieldType
Definition dunequadratures.hh:32
int order_
Definition dunequadratures.hh:58
QuadratureRulesFactory(const GeometryType &geometry, const int order, const size_t id)
constructor filling the list of points and weights
Definition dunequadratures.hh:67
BaseType::CoordinateType CoordinateType
Definition dunequadratures.hh:44
@ dimension
Definition dunequadratures.hh:34
@ highest_order
Definition dunequadratures.hh:52
const GeometryType elementGeometry_
Definition dunequadratures.hh:57
QuadratureRule< FieldType, dimension > DuneQuadratureRuleType
Definition dunequadratures.hh:47
static unsigned int maxOrder()
maximal order of available quadratures
Definition dunequadratures.hh:104
Definition dunequadratures.hh:114
QuadratureImp< FieldType, dim > IntegrationPointListType
Definition dunequadratures.hh:119
PolyhedronQuadrature< FieldType, dim > PolyhedronQuadratureType
Definition dunequadratures.hh:117
int QuadratureKeyType
Definition dunequadratures.hh:121
QuadratureRulesFactory< FieldType, dim > SimplexQuadratureType
Definition dunequadratures.hh:115
QuadratureRulesFactory< FieldType, dim > CubeQuadratureType
Definition dunequadratures.hh:116
int QuadratureKeyType
Definition dunequadratures.hh:131
QuadratureImp< FieldType, 0 > IntegrationPointListType
Definition dunequadratures.hh:129
QuadratureRulesFactory< FieldType, 0 > PointQuadratureType
Definition dunequadratures.hh:127
QuadratureImp< FieldType, 1 > IntegrationPointListType
Definition dunequadratures.hh:139
int QuadratureKeyType
Definition dunequadratures.hh:141
QuadratureRulesFactory< FieldType, 1 > LineQuadratureType
Definition dunequadratures.hh:137
QuadratureRulesFactory< FieldType, 3 > CubeQuadratureType
Definition dunequadratures.hh:148
QuadratureRulesFactory< FieldType, 3 > PrismQuadratureType
Definition dunequadratures.hh:150
PolyhedronQuadrature< FieldType, 3 > PolyhedronQuadratureType
Definition dunequadratures.hh:153
QuadratureRulesFactory< FieldType, 3 > SimplexQuadratureType
Definition dunequadratures.hh:147
QuadratureRulesFactory< FieldType, 3 > PyramidQuadratureType
Definition dunequadratures.hh:151
int QuadratureKeyType
Definition dunequadratures.hh:157
QuadratureImp< FieldType, 3 > IntegrationPointListType
Definition dunequadratures.hh:155
Definition femquadratures.hh:367
size_t id() const
obtain the identifier of the integration point list
Definition quadratureimp.hh:122
Generic implementation of a Dune quadrature.
Definition quadratureimp.hh:196
void addQuadraturePoint(const CoordinateType &point, const FieldType weight)
Adds a point-weight pair to the quadrature.
Definition quadratureimp.hh:270