1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18 #ifndef GRID_EVOLUTION_H
19 #define GRID_EVOLUTION_H
20
21 #include "parameter.h"
22 #include <dune/grid/geometrygrid/coordfunction.hh>
23 #include <dune/fem/solver/timeprovider.hh>
24
25
26 namespace Grid_evolution{
27 class DeformationCoordFunction
28 : public Dune::AnalyticalCoordFunction<double, 3, 3, DeformationCoordFunction>
29 {
30 public:
31 using Base = Dune::AnalyticalCoordFunction<double, 3, 3, DeformationCoordFunction>;
32 using Domain = Base::DomainVector;
33 using Range = Base::RangeVector;
34
35 DeformationCoordFunction() = default;
36 explicit DeformationCoordFunction(const Parameter::PDE_data&);
37 DeformationCoordFunction(const DeformationCoordFunction&) = delete;
38 DeformationCoordFunction(DeformationCoordFunction&&) = delete;
39 DeformationCoordFunction& operator=(const DeformationCoordFunction&) = delete;
40 DeformationCoordFunction& operator=(DeformationCoordFunction&&) = delete;
41 ~DeformationCoordFunction() = default;
42
43 void set_timeProvider(Dune::Fem::TimeProviderBase&);
44 void evaluate(const Domain&, Range& y) const;
45 private:
46 class Grid_values;
47 Grid_values* gv_ptr {nullptr};
48 Dune::Fem::TimeProviderBase* tp_ptr {nullptr};
49 };
50
51
52 DeformationCoordFunction& deformation(const Parameter::PDE_data&);
53 }
54
55 #endif
56
57
58