NetDEM v1.0
Loading...
Searching...
No Matches
membrane_wall.hpp
Go to the documentation of this file.
1#pragma once
2
3#include "membrane.hpp"
4#include "modifier.hpp"
5#include "wall.hpp"
6
7namespace netdem {
8
14class MembraneWall : public Modifier, public Membrane {
15public:
16 bool enable_deformation{false}, dump_info{true}, facing_outside{true};
17
19
24
31 MembraneWall(double radius, double height);
32
41 MembraneWall(double radius, double height, double mesh_size);
42
54 MembraneWall(double radius, double height, double mesh_size, double center_x,
55 double center_y, double center_z);
56
62 void SetRootPath(std::string const &root_path);
63
69 void SetDataType(std::string const &data_type);
70
76 void SetSaveByTime(double interval);
77
83 void SetSaveByCycles(double interval);
84
91 void SetDimensions(double r, double h);
92
98 Modifier *Clone() const override;
99
105 void Init(Simulation *sim) override;
106
112 void SetPressure(double pressure);
113
119 void Execute() override;
120
121private:
122 std::string root_path{"tmp/out/"}, data_type{"vtk"};
123 bool save_by_cycles{true};
124 int cycle_interval{0}, cycle_previous{0};
125 double time_interval{0}, time_previous{0};
126
127 VecXT<VecXT<Vec2d>> linked_facets;
128
133 void UpdateBCForceFromDEM();
134
140 std::string GetFilename();
141
147 bool CheckIfToSave();
148
149 double KernelFunc(double r);
150};
151
152} // namespace netdem
A class that simulates a membrane.
Definition membrane.hpp:15
double radius
The radius of the membrane.
Definition membrane.hpp:18
double mesh_size
The size of the elements in the mesh used to represent the membrane.
Definition membrane.hpp:24
double height
The height of the membrane.
Definition membrane.hpp:21
void Init()
Initializes the membrane.
Definition membrane.cpp:33
A class used to model a membrane wall in a DEM simulation.
Definition membrane_wall.hpp:14
VecXT< Wall * > wall_list
Definition membrane_wall.hpp:18
Modifier * Clone() const override
Clones the current MembraneWall instance.
Definition membrane_wall.cpp:62
void SetDataType(std::string const &data_type)
Sets the data type for saving membrane wall data.
Definition membrane_wall.cpp:37
void Execute() override
Executes the MembraneWall instance.
Definition membrane_wall.cpp:138
bool enable_deformation
Definition membrane_wall.hpp:16
MembraneWall()
Default constructor for MembraneWall class.
Definition membrane_wall.cpp:9
void SetDimensions(double r, double h)
Sets the radius and height of the membrane wall.
Definition membrane_wall.cpp:51
void SetSaveByCycles(double interval)
Sets the cycle interval for saving membrane wall data.
Definition membrane_wall.cpp:46
void SetSaveByTime(double interval)
Sets the time interval for saving membrane wall data.
Definition membrane_wall.cpp:41
bool dump_info
Definition membrane_wall.hpp:16
void SetPressure(double pressure)
Sets the pressure applied to the membrane wall.
Definition membrane_wall.cpp:134
bool facing_outside
Definition membrane_wall.hpp:16
void SetRootPath(std::string const &root_path)
Sets the root path for saving membrane wall data.
Definition membrane_wall.cpp:33
An interface class used to modify a DEM simulation.
Definition modifier.hpp:18
Simulation * sim
Definition modifier.hpp:23
Class for managing a DEM simulation.
Definition simulation.hpp:21
Definition bond_entry.hpp:7
std::vector< T > VecXT
Definition utils_macros.hpp:31