FEAT 3
Finite Element Analysis Toolbox
Loading...
Searching...
No Matches
evaluator.hpp
1// FEAT3: Finite Element Analysis Toolbox, Version 3
2// Copyright (C) 2010 by Stefan Turek & the FEAT group
3// FEAT3 is released under the GNU General Public License version 3,
4// see the file 'copyright.txt' in the top level directory for details.
5
6#pragma once
7
8// includes, FEAT
9#include <kernel/space/parametric_evaluator.hpp>
10#include <kernel/space/dof_mapping_common.hpp>
11#include <kernel/space/lagrange2/details.hpp>
12
13namespace FEAT
14{
15 namespace Space
16 {
17 namespace Lagrange2
18 {
25
31 template<
32 typename Space_,
33 typename TrafoEvaluator_,
34 typename SpaceEvalTraits_,
35 typename Shape_ = typename Space_::ShapeType>
36 class Evaluator :
38 Evaluator<
39 Space_,
40 TrafoEvaluator_,
41 SpaceEvalTraits_,
42 Shape_ >,
43 TrafoEvaluator_,
44 SpaceEvalTraits_,
45 ref_caps>
46 {
47 public:
50
52 typedef Space_ SpaceType;
53
55 typedef Shape_ ShapeType;
56
58 typedef SpaceEvalTraits_ SpaceEvalTraits;
59
61 typedef typename SpaceEvalTraits::EvalPolicy EvalPolicy;
62
64 typedef typename EvalPolicy::DomainPointType DomainPointType;
65
67 typedef typename SpaceEvalTraits::DataType DataType;
68
71
72 public:
79 explicit Evaluator(const SpaceType& DOXY(space))
80 {
81 }
82
90 {
91 return EvalHp::get_num_local_dofs();
92 }
93
103 template<typename EvalData_>
105 EvalData_& data,
106 const DomainPointType& point) const
107 {
108 EvalHp::template eval_ref_values<EvalData_>(data, point);
109 }
110
120 template<typename EvalData_>
122 EvalData_& data,
123 const DomainPointType& point) const
124 {
125 EvalHp::template eval_ref_gradients<EvalData_>(data, point);
126 }
127
128
138 template<typename EvalData_>
140 EvalData_& data,
141 const DomainPointType& point) const
142 {
143 EvalHp::template eval_ref_hessians<EvalData_>(data, point);
144 }
145 };
146 } // namespace Lagrange2
147 } // namespace Space
148} // namespace FEAT
Lagrange-2 Element Evaluator class template declaration.
Definition: evaluator.hpp:46
EvalPolicy::DomainPointType DomainPointType
domain point type
Definition: evaluator.hpp:64
Evaluator(const SpaceType &space)
Constructor.
Definition: evaluator.hpp:79
void eval_ref_gradients(EvalData_ &data, const DomainPointType &point) const
Evaluates the basis function gradients on the reference cell.
Definition: evaluator.hpp:121
ParametricEvaluator< Evaluator, TrafoEvaluator_, SpaceEvalTraits_, ref_caps > BaseClass
base-class typedef
Definition: evaluator.hpp:49
SpaceEvalTraits_ SpaceEvalTraits
space evaluation traits
Definition: evaluator.hpp:58
EvalHelper< DomainPointType, DataType, ShapeType > EvalHp
evaluation helper, see details.hpp
Definition: evaluator.hpp:70
void eval_ref_hessians(EvalData_ &data, const DomainPointType &point) const
Evaluates the basis function hessians on the reference cell.
Definition: evaluator.hpp:139
void eval_ref_values(EvalData_ &data, const DomainPointType &point) const
Evaluates the basis function values on the reference cell.
Definition: evaluator.hpp:104
SpaceEvalTraits::DataType DataType
data type
Definition: evaluator.hpp:67
int get_num_local_dofs() const
Returns the number of local DOFs.
Definition: evaluator.hpp:89
SpaceEvalTraits::EvalPolicy EvalPolicy
evaluation policy
Definition: evaluator.hpp:61
Finite-Element Parametric Evaluator CRTP base-class template.
static constexpr SpaceTags ref_caps
Lagrange-2 Element Evaluator reference capabilities.
Definition: evaluator.hpp:24
FEAT namespace.
Definition: adjactor.hpp:12
SpaceTags
Space configuration tags enum.
Definition: eval_tags.hpp:97
@ ref_value
specifies whether the space should supply reference basis function values
@ ref_hess
specifies whether the space should supply reference basis function hessians
@ ref_grad
specifies whether the space should supply reference basis function gradients