51 void SetProperty(nlohmann::json
const &js)
override;
58 void SetProperty(std::string
const &name,
double value)
override;
77 double dt)
const override;
90 double dt)
const override;
95 void Print()
const override;
A class representing the geometries associated with a collision.
Definition collision_geometries.hpp:15
Contact model that uses linear spring elements to evaluate contact forces and moments.
Definition model_linear_spring.hpp:16
double kt
Definition model_linear_spring.hpp:19
double kn
< Parameters used to calculate contact forces.
Definition model_linear_spring.hpp:19
void SetProperty(std::string const &name, double value) override
Sets a specific contact model property.
void SetProperty(nlohmann::json const &js) override
Sets the contact model properties.
Definition model_linear_spring.cpp:52
ContactModel * Clone() const override
Creates a copy of this contact model.
Definition model_linear_spring.cpp:85
nlohmann::json PackJson() override
Packs the contact model properties into a JSON object.
Definition model_linear_spring.cpp:23
void EvaluateForces(ContactForces *const cnt_forces, CollisionGeometries &cnt_geoms, ContactPP *const cnt, double dt) const override
Evaluates the forces and moments between two particles using linear spring elements.
Definition model_linear_spring.cpp:87
LinearSpring()
Default constructor for LinearSpring.
Definition model_linear_spring.cpp:12
double mu
Definition model_linear_spring.hpp:19
double beta
Definition model_linear_spring.hpp:19
void Print() const override
Prints the contact model properties.
Definition model_linear_spring.cpp:134
void InitFromJson(nlohmann::json const &js) override
Initializes the contact model from a JSON object.
Definition model_linear_spring.cpp:34
Definition bond_entry.hpp:7