29 #ifndef BASE_BODY_RELATION_H 30 #define BASE_BODY_RELATION_H 43 size_t operator()(
size_t particle_index)
const {
return particle_index; };
51 : body_part_particles_(body_part_particles){};
52 size_t operator()(
size_t particle_entry)
const {
return body_part_particles_[particle_entry]; };
58 int operator()(
size_t particle_index)
const {
return 1; };
70 Real inv_grid_spacing_ = 1.0 / target_cell_linked_list->GridSpacing();
72 search_depth_ = 1 + (int)floor(kernel_->CutOffRadius() * inv_grid_spacing_);
74 int operator()(
size_t particle_index)
const {
return search_depth_; };
82 Real inv_grid_spacing_;
86 : inv_grid_spacing_(1.0 / target_cell_linked_list->GridSpacing()),
89 int operator()(
size_t particle_index)
const 91 return 1 + (int)floor(kernel_->CutOffRadius(h_ratio_[particle_index]) * inv_grid_spacing_);
108 void subscribeToBody() { sph_body_->
body_relations_.push_back(
this); };
109 virtual void updateConfigurationMemories() = 0;
110 virtual void updateConfiguration() = 0;
120 virtual void resetNeighborhoodCurrentSize();
129 virtual void updateConfigurationMemories()
override;
144 StdVec<SearchDepthMultiResolution *> get_search_depths_;
145 StdVec<NeighborRelationContact *> get_contact_neighbors_;
147 virtual void resetNeighborhoodCurrentSize();
150 RealBodyVector contact_bodies_;
157 virtual void updateConfigurationMemories()
override;
160 #endif //BASE_BODY_RELATION_H
a small functor for obtaining search depth for variable smoothing length
Definition: base_body_relation.h:80
StdVec< SPHBodyRelation * > body_relations_
Definition: base_body.h:89
Particles with essential (geometric and kinematic) data. There are three types of particles, all par...
Definition: base_particles.h:81
The base relation between a SPH body and its contact SPH bodies.
Definition: base_body_relation.h:136
Defining a mesh cell linked list for a body. The meshes for all bodies share the same global coordina...
Definition: cell_linked_list.h:113
StdVec< size_t > IndexVector
Definition: sph_data_containers.h:37
Here gives the classes for managing cell linked lists. This is the basic class for building the parti...
There are the classes for neighboring particles. It saves the information for carring out pair intera...
Definition: base_body_relation.h:41
ContactParticleConfiguration contact_configuration_
Definition: base_body_relation.h:151
Abstract base class of a general SPH kernel function which is a smoothed Dirac delta function...
Definition: base_kernel.h:63
StdLargeVec< Neighborhood > ParticleConfiguration
Definition: neighbor_relation.h:66
StdLargeVec< VariableType > * getVariableByName(const std::string &variable_name)
Definition: base_particles.hpp:74
Definition: base_body_relation.h:56
a small functor for obtaining search depth across resolution
Definition: base_body_relation.h:64
Shape is the base class for all geometries.
A wrapper to provide an ownership for a vector of base class pointers which point to derived objects...
Definition: ownership.h:127
StdVec< ParticleConfiguration > ContactParticleConfiguration
Definition: neighbor_relation.h:68
This is the base class of SPH particles. The basic data of the particles is saved in separated large ...
A complex body is characterized with a secondary structure, which can be imported externally or creat...
BaseParticles * base_particles_
Definition: base_body.h:88
SPHBody is a base body with basic data and functions. Its derived class can be a real fluid body...
Definition: base_body.h:61
ParticleConfiguration inner_configuration_
Definition: base_body_relation.h:124
The abstract class for all relations within a SPH body or with its contact SPH bodies.
Definition: base_body_relation.h:99
The abstract relation within a SPH body.
Definition: base_body_relation.h:117
SPHAdaptation * sph_adaptation_
Definition: base_body.h:86
Derived body with inner particle configuration or inner interactions. After construction, the particle and material must be specified.
Definition: base_body.h:182
Definition: solid_body_supplementary.cpp:9
Definition: base_body_relation.h:47