1 #ifndef KRATOS_SPACE_TIME_SET_H
2 #define KRATOS_SPACE_TIME_SET_H
24 #include "../real_functions.h"
25 #include "../real_field.h"
56 std::vector<SpaceTimeRule::Pointer> union_rules;
57 union_rules.push_back(b_box_rule);
58 mUnionOfRules.push_back(union_rules);
64 std::vector<SpaceTimeRule::Pointer> union_rules;
65 union_rules.push_back(b_box_rule);
66 mUnionOfRules.push_back(union_rules);
78 for (
unsigned int i = 0;
i < mUnionOfRules.size(); ++
i){
79 mUnionOfRules[
i].push_back(p_rule);
88 std::vector<SpaceTimeRule::Pointer> p_rule_array;
89 p_rule_array.push_back(p_rule);
90 mUnionOfRules.push_back(p_rule_array);
99 for (
unsigned int i = 0;
i < mUnionOfRules.size(); ++
i){
101 for (
unsigned int j = 0;
j < p_rules.size(); ++
j){
102 mUnionOfRules[
i].push_back(p_rules[
j]);
112 mUnionOfRules.push_back(p_rules);
118 bool IsIn(
const double time,
const double coor_x,
const double coor_y,
const double coor_z)
120 bool rules_are_met =
true;
122 for (
unsigned int i = 0;
i < mUnionOfRules.size(); ++
i){
124 for (
unsigned int j = 0;
j < mUnionOfRules[
i].size(); ++
j){
125 rules_are_met = rules_are_met && mUnionOfRules[
i][
j]->CheckIfRuleIsMet(
time, coor_x, coor_y, coor_z);
151 std::vector<std::vector<SpaceTimeRule::Pointer> >
GetRules(){
return mUnionOfRules;}
160 virtual std::string
Info()
const
236 std::vector<std::vector<SpaceTimeRule::Pointer> > mUnionOfRules;
269 SpaceTimeSet::Pointer
SetUnion(SpaceTimeSet::Pointer set_1, SpaceTimeSet::Pointer set_2);
270 SpaceTimeSet::Pointer
SetIntersection(SpaceTimeSet::Pointer set_1, SpaceTimeSet::Pointer set_2);
Definition: space_time_rule.h:159
Definition: space_time_set.h:32
double GetHighTime()
Definition: space_time_set.h:144
virtual void PrintData(std::ostream &rOStream) const
Print object's data.
Definition: space_time_set.h:173
void AddOrRules(std::vector< SpaceTimeRule::Pointer > p_rules)
Definition: space_time_set.h:110
void AddAndRule(SpaceTimeRule::Pointer p_rule)
Definition: space_time_set.h:76
double GetLowZ()
Definition: space_time_set.h:149
std::vector< std::vector< SpaceTimeRule::Pointer > > GetRules()
Definition: space_time_set.h:151
virtual void PrintInfo(std::ostream &rOStream) const
Print information about this object.
Definition: space_time_set.h:167
void AddOrRule(SpaceTimeRule::Pointer p_rule)
Definition: space_time_set.h:86
double GetLowX()
Definition: space_time_set.h:145
double GetHighZ()
Definition: space_time_set.h:150
SpaceTimeSet()
Definition: space_time_set.h:61
double GetHighY()
Definition: space_time_set.h:148
virtual std::string Info() const
Turn back information as a stemplate<class T, std::size_t dim> tring.
Definition: space_time_set.h:160
double GetLowY()
Definition: space_time_set.h:147
double GetHighX()
Definition: space_time_set.h:146
double GetLowTime()
Definition: space_time_set.h:143
KRATOS_CLASS_POINTER_DEFINITION(SpaceTimeSet)
SpaceTimeSet(const double min_time, const double max_time, const double min_x, const double min_y, const double min_z, const double max_x, const double max_y, const double max_z)
Default constructor.
Definition: space_time_set.h:39
void AddAndRules(std::vector< SpaceTimeRule::Pointer > p_rules)
Definition: space_time_set.h:97
virtual ~SpaceTimeSet()
Destructor.
Definition: space_time_set.h:71
bool IsIn(const double time, const double coor_x, const double coor_y, const double coor_z)
Definition: space_time_set.h:118
REF: G. R. Cowper, GAUSSIAN QUADRATURE FORMULAS FOR TRIANGLES.
Definition: mesh_condition.cpp:21
SpaceTimeSet::Pointer SetIntersection(SpaceTimeSet::Pointer set_1, SpaceTimeSet::Pointer set_2)
Definition: space_time_set.cpp:22
SpaceTimeSet::Pointer SetUnion(SpaceTimeSet::Pointer set_1, SpaceTimeSet::Pointer set_2)
Definition: space_time_set.cpp:5
float max_time
Definition: ProjectParameters.py:8
time
Definition: face_heat.py:85
int j
Definition: quadrature.py:648
integer i
Definition: TensorModule.f:17