NetDEM v1.0
|
An abstract base class for domain splitters used in discrete element method simulations. More...
#include <domain_splittor.hpp>
Public Member Functions | |
DomainSplittor () | |
Default constructor. | |
virtual void | InitFromSTL (std::string const &stl_file, int num_ele_each) |
Initializes the domain splitter from an STL file. | |
virtual void | InitFromSTL (STLModel const &stl_model, int num_ele_each)=0 |
Initializes the domain splitter from an STL model. | |
virtual void | GetPeriDigmNodes (VecXT< Vec3d > *const nodes, VecXT< double > *const node_vols)=0 |
Gets the nodes and volumes of the discretized domain. | |
virtual void | MakePorosity (double porosity)=0 |
Modifies the domain by adding porosity. | |
virtual STLModel | GetSTLModel ()=0 |
Gets the STL model corresponding to the discretized domain. | |
virtual STLModel | GetSTLModel (const VecXT< int > &indices)=0 |
Gets the STL model corresponding to a subset of the discretized domain. | |
virtual | ~DomainSplittor () |
Virtual destructor. | |
An abstract base class for domain splitters used in discrete element method simulations.
This class defines an interface for splitting a domain, represented by an STL model, into discrete elements that can be used in a DEM simulation. Classes derived from this class can implement specific algorithms for splitting domains according to different criteria.
|
inline |
Default constructor.
|
inlinevirtual |
Virtual destructor.
|
pure virtual |
Gets the nodes and volumes of the discretized domain.
This method populates the given arrays with the positions of the nodes and the volumes of the elements in the discretized domain.
nodes | A pointer to an array of Vec3d objects to fill with node positions. |
node_vols | A pointer to an array of doubles to fill with element volumes. |
Implemented in netdem::LevelSetSplittor, and netdem::TetMeshSplittor.
|
pure virtual |
Gets the STL model corresponding to the discretized domain.
This method returns an STL model representing the discretized domain.
Implemented in netdem::LevelSetSplittor, and netdem::TetMeshSplittor.
Gets the STL model corresponding to a subset of the discretized domain.
This method returns an STL model representing a subset of the discretized domain defined by the given indices.
indices | A VecXT<int> object containing the indices of the subset of elements to include in the STL model. |
Implemented in netdem::LevelSetSplittor, and netdem::TetMeshSplittor.
|
inlinevirtual |
Initializes the domain splitter from an STL file.
This method loads an STL file and initializes the domain splitter using the corresponding STL model.
stl_file | The path to the STL file to load. |
num_ele_each | The desired number of elements in each dimension of the split domain. |
|
pure virtual |
Initializes the domain splitter from an STL model.
This method initializes the domain splitter using the given STL model.
stl_model | The STL model to use as the domain. |
num_ele_each | The desired number of elements in each dimension of the split domain. |
Implemented in netdem::LevelSetSplittor, and netdem::TetMeshSplittor.
|
pure virtual |
Modifies the domain by adding porosity.
This method modifies the discretized domain by randomly removing elements from it, according to the given porosity value.
porosity | The desired porosity of the modified domain. |
Implemented in netdem::LevelSetSplittor, and netdem::TetMeshSplittor.