Chi-Tech
chi_ffinterpolation.h
Go to the documentation of this file.
1#ifndef CHI_FFINTERPOLATION_H
2#define CHI_FFINTERPOLATION_H
3
4#include <memory>
5#include <vector>
6
7namespace chi_physics
8{
9 class FieldFunctionGridBased;
10 typedef std::shared_ptr<FieldFunctionGridBased> FieldFunctionGridBasedPtr;
11}
12
14{
15 enum class Type : int
16 {
17 SLICE = 1,
18 LINE = 2,
19 VOLUME = 3,
20 POINT = 4
21 };
22
23 enum class Operation : int
24 {
25 OP_SUM = 10,
26 OP_AVG = 11,
27 OP_MAX = 12,
28 OP_SUM_LUA = 13,
29 OP_AVG_LUA = 14,
30 OP_MAX_LUA = 15,
31 };
32
33 enum class Property : int
34 {
35 PROBEPOINT = 0,
36 SLICEPOINT = 1,
37 SLICENORMAL = 2,
38 SLICETANGENT = 3,
39 SLICEBINORM = 4,
40 OPERATION = 5,
42
45
46 FIRSTPOINT = 11,
47 SECONDPOINT = 12,
48 NUMBEROFPOINTS = 13,
49 CUSTOM_ARRAY = 14,
50 };
51}
52
53namespace chi_mesh
54{
55
56//###################################################################
57/** Base class for field-function interpolation objects.*/
59{
60protected:
62 unsigned int ref_component_ = 0;
63 std::vector<chi_physics::FieldFunctionGridBasedPtr> field_functions_;
64
65public:
66 explicit
68 type_(type) {}
69
70 std::vector<chi_physics::FieldFunctionGridBasedPtr>& GetFieldFunctions()
71 {return field_functions_;}
72
74
75 virtual void Initialize(){};
76 virtual void Execute(){};
77
78 virtual std::string GetDefaultFileBaseName() const = 0;
79 virtual void ExportPython(std::string base_name) = 0;
80};
81
82}//namespace chi_mesh
83
84
85
86
87#endif
std::vector< chi_physics::FieldFunctionGridBasedPtr > & GetFieldFunctions()
std::vector< chi_physics::FieldFunctionGridBasedPtr > field_functions_
virtual std::string GetDefaultFileBaseName() const =0
ff_interpolation::Type Type() const
virtual void ExportPython(std::string base_name)=0
FieldFunctionInterpolation(ff_interpolation::Type type)
std::shared_ptr< FieldFunctionGridBased > FieldFunctionGridBasedPtr