GranOO 3.0
A robust and versatile workbench to build 3D dynamic simulations based on the Discrete Element Method
Loading...
Searching...
No Matches
GranOO3::DEM::Beam Class Reference

a bond beam that works in tension, compression, bending and torsion More...

#include <Beam.hpp>

Inheritance diagram for GranOO3::DEM::Beam:

Public Member Functions

 Beam (Element &el1, Element &el2)
 constructor
 Beam (Element &el1, Element &el2, double young_mod, double radius, double poisson_ratio, double max_stress=0.)
 constructor
 Beam (Element &el1, Element &el2, double young_mod, double damping, double radius, double poisson_ratio, double max_stress)
 constructor
virtual ~Beam ()
virtual void compute_load ()
 compute the reaction force and torque of the beam
virtual double get_linear_stiffness () const
 compute the linear stiffness of the bond
virtual double get_angular_stiffness () const
 similar as get_linear_stiffness() for rotation
virtual double compute_critical_time_step () const
 compute the critical time of the bond
void update_coeff_value ()
virtual void draw ()
 OpenGL draw of the bond.
virtual std::string info () const
 Display some useful info in the terminal.
Public Member Functions inherited from GranOO3::DEM::Bond
 Bond (Element &el1, Element &el2, bool contact=false)
 Constructor.
virtual ~Bond ()=0
 Destructor.
Element & get_item1 ()
const Element & get_item1 () const
Element & get_item2 ()
const Element & get_item2 () const
Element & item1 ()
Element & item2 ()
double get_normal_force_intensity () const
double get_tangential_force_intensity () const
Element & bonded_element (const Element &)
 get the bonded element
const Element & get_bonded_element (const Element &) const
 same as bonded_element(const Element&) (provided for convenience)
void apply_linear_damping_factor ()
 compute and apply the linear (translation) damping factor of the bond
void apply_angular_damping_factor ()
 similar as apply_linear_damping_factor() for rotation
void apply_load ()
 apply the computed reaction force and torque to the bonded Element (_element1 and _element2)
void disable (bool manage_slave=true)
 disable the bond
void disable_fast_mode (bool manage_slave=true)
 simply disable the bond by switching the _disabled attribute to true without doing the lot of things done by the disable() method
void enable (bool manage_slave=true)
 simply enable the bond by switching the _disabled attribute to false
bool is_disabled () const
 check if the bond is enable or not
void crack (bool manage_slave=true)
void uncrack (bool manage_slave=true)
bool is_cracked () const
void init_local_frame (bool update_initial_param=false)
 initialize the bond local frame
void update_local_frame ()
 update the bond local frame
void update_current_length ()
 update the current value of the bond length (see _current_length attribute)
void build_voronoi_bond ()
 build a voronoi bond from the current bond
virtual void stiffness_matrix (Eigen::MatrixXd &kMatrix)
 assemble a stiffness matrix
virtual void update_dof ()
 update the bond dof
const std::vector< unsigned int > & get_dof () const
 get the dof vector
const Geom::Point & initial_pos (const Element &) const
 get the initial position of the el element
Geom::Vector get_disp (const Element &) const
 get the displacement of the el element
Geom::Vector get_disp1 () const
 get the displacement of the first bonded element (_element1)
Geom::Vector get_disp2 () const
 similar as get_disp1()
void swap (Element &from, Element &to)
 swap the bond from the Element from to to
void add_slave (Bond &b)
 add a slave bond (useful for periodic simulation)
virtual std::ostream & export_to_povray (std::ostream &out) const
 exporting to povray format
Public Member Functions inherited from GranOO3::Physic::BodyInteraction
 BodyInteraction (Body &b1, Body &b2, bool contact_interaction)
 constructor
virtual ~BodyInteraction ()
 destructor
void apply_torque ()
 apply the current torque value
void clear_torque ()
 set the torques to zero
Geom::Vector & torque_on (const Body &b)
 get the torque value applied on b
const Geom::Vector & torque_on (const Body &b) const
 same as BodyInteraction::torque_on
void add_label_torque (const std::string &label, const Geom::Vector &t1, const Geom::Vector &t2)
 add a label for the torque
void swap (Body &from, Body &to)
 swap one body
Public Member Functions inherited from GranOO3::Physic::NodeInteraction
 NodeInteraction (Node &de1, Node &de2, bool build_node_interaction)
virtual ~NodeInteraction ()
bool contact_interaction () const
void apply_force ()
void clear_force ()
Geom::Vector & force_on (const Node &)
const Geom::Vector & force_on (const Node &) const
void swap (Node &from, Node &to)
virtual std::ostream & write_ascii (std::ostream &out) const
void add_label_force (const std::string &label, const Geom::Vector &f1, const Geom::Vector &f2)
Public Member Functions inherited from GranOO3::Core::Base
virtual ~Base ()
size_t numID () const
size_t uID () const
void set_numID (size_t val)
void clear_numID ()
Physic::Material & get_mat () const
void set_mat (Physic::Material *)
Base & item ()
const Base & item () const
bool is_same (const Base &) const
template<class T>
T & cast_to ()
template<class T>
const T & cast_to () const
template<class T>
bool is () const
virtual bool is (size_t) const
virtual const std::string & get_ID () const
virtual Base & clone ()
template<class T>
T & clone_to ()
virtual std::istream & read_ascii (std::istream &in)
Signal< Base & > & deleted_signal ()
Public Member Functions inherited from GranOO3::Core::Null
 Null ()
virtual ~Null ()
Public Member Functions inherited from GranOO3::Core::Drawable
 Drawable ()
virtual ~Drawable ()
virtual void draw_edge ()
virtual void init_default_color ()
virtual std::ostream & get_info (std::ostream &os) const
virtual const Color & default_color () const
Color & get_color ()
const Color & get_color () const
virtual void set_color (const Color &)
virtual void set_alpha (float alpha)
void apply_color () const
void apply_edge_color () const
void apply_default_color ()
void apply_selected_color ()
void set_line_width (float)
float get_line_width () const
float & get_line_width ()
void apply_line_width () const
bool is_visible () const
void set_visible (bool)
void paint ()
void paint_edge ()
unsigned int get_item_glkey () const
Public Member Functions inherited from GranOO3::Core::Register< Base >
 Register ()
virtual ~Register ()
void erase_from_all_setof ()
bool belong_to_setof (const std::string &setOfId) const
std::list< SetOf< Base > * > & get_setof_list ()
unsigned long long int get_numeric_ID () const
Public Member Functions inherited from GranOO3::Core::Register< NodeInteraction >
 Register ()
virtual ~Register ()
void erase_from_all_setof ()
bool belong_to_setof (const std::string &setOfId) const
std::list< SetOf< NodeInteraction > * > & get_setof_list ()
unsigned long long int get_numeric_ID () const
Public Member Functions inherited from GranOO3::Core::Register< BodyInteraction >
 Register ()
virtual ~Register ()
void erase_from_all_setof ()
bool belong_to_setof (const std::string &setOfId) const
std::list< SetOf< BodyInteraction > * > & get_setof_list ()
unsigned long long int get_numeric_ID () const
Public Member Functions inherited from GranOO3::Core::PropClass< Bond >
 PropClass ()
virtual ~PropClass ()
T & new_object ()
T & get ()
bool prop_exist () const
void add_prop (Core::Prop< Bond > *)
void remove_prop (Core::Prop< Bond > *)
std::string info () const
Public Member Functions inherited from GranOO3::Core::Register< Bond >
 Register ()
virtual ~Register ()
void erase_from_all_setof ()
bool belong_to_setof (const std::string &setOfId) const
std::list< SetOf< Bond > * > & get_setof_list ()
unsigned long long int get_numeric_ID () const
Public Member Functions inherited from GranOO3::Core::Register< Beam >
 Register ()
virtual ~Register ()
void erase_from_all_setof ()
bool belong_to_setof (const std::string &setOfId) const
std::list< SetOf< Beam > * > & get_setof_list ()
unsigned long long int get_numeric_ID () const

Static Public Member Functions

static unsigned int get_broken_beam_number ()
Static Public Member Functions inherited from GranOO3::DEM::Bond
static double get_disabled_cumulative_surface ()
 get the total surface disabled surface
Static Public Member Functions inherited from GranOO3::Core::Base
static Base & get_by_numID (size_t)
static void clear_all_numID ()
static unsigned int get_sub_class_number ()
Static Public Member Functions inherited from GranOO3::Core::Drawable
static Drawable & get_drawable_item_by_glkey (int)
static void set_draw_precision (unsigned int p)
static void increase_draw_precision ()
static void decrease_draw_precision ()
static unsigned int get_draw_precision ()
Static Public Member Functions inherited from GranOO3::Physic::CriticalTimeStep
static const std::set< CriticalTimeStep * > & get_all ()

Protected Attributes

double _young_modulus
 the Young's modulus value of the beam in [Pa]
double _radius
 the radius of the beam in [m]
double _poisson_ratio
 the Poisson's ratio of the beam in [-]
double _max_stress
 the maximal tensile stress of the beam in [Pa]
double _current_stress
 the current maximal stress (including normal, bending and torsion stresses) in [Pa]
double _current_tensile_stress
 the current tensile stress into the beam
double _current_bending_stress
 the current maximal bending stress into the beam
double _current_torsion_stress
 the current maximal torsion stress into the beam
double _current_normal_stress
 the current maximal normal stress into the beam (sum of tensile and bending stresses)
double _Ig
 for storing some intermediate values to speed-up the computation (quadratic inertia)
double _factor_Tb
 for storing some intermediate values to speed-up the computation
double _Io
 for storing some intermediate values to speed-up the computation (quadratic polar inertia)
double _G
 for storing some intermediate values to speed-up the computation (Coulomb's modulus)
double _factor_Tt
 for storing some intermediate values to speed-up the computation
double _S
 for storing some intermediate values to speed-up the computation (normal surface)
double _K
 for storing some intermediate values to speed-up the computation (normal stiffness)
double _factor_Fb
 for storing some intermediate values to speed-up the computation
Protected Attributes inherited from GranOO3::DEM::Bond
Element * _element1
 the first of the two bonded Element
Element * _element2
 the second of the two bonded Element
double _linear_damping_factor
 the linear damping factor of the bond
double _angular_damping_factor
 the angular damping factor of the bond
double _relaxed_length
 the relaxed length of the bond.
double _current_length
 the current length of the bond that correspond to the norm of the vector between the center of the bonded elements
double _max_relative_elongation
 a threshold corresponding to a maximal admissible relative elongation (the longitudinal strain)
double _surface
 this attribute stores the corresponding normal surface of the bond
Core::SetOfBase< Bond > _slave
 a container that list the slave bond
std::vector< unsigned int > _dofs
 a vector that stores the dof of the bond
Protected Attributes inherited from GranOO3::Physic::BodyInteraction
Body * _body1
 a pointer the first body
Body * _body2
 a pointer the second body
Geom::Vector _torque_on1
 the current value of the applied torque on the body 1
Geom::Vector _torque_on2
 the current value of the applied torque on the body 2
Protected Attributes inherited from GranOO3::Physic::NodeInteraction
const bool _contact_interaction
Node * _node1
Node * _node2
Geom::Vector _force_on1
Geom::Vector _force_on2
Protected Attributes inherited from GranOO3::Core::PropClass< Bond >
std::vector< Core::Prop< Bond > * > _prop

Private Member Functions

 Beam ()=delete
 Beam (const Beam &frame)=delete
Beam & operator= (const Beam &)=delete
template<class Archive>
void save (Archive &, const unsigned int) const
 complete serializing of the bond in the *.gdd format
template<class Archive>
void load (Archive &, const unsigned int)
 complete serializing of the bond in the *.gdd format
 BOOST_SERIALIZATION_SPLIT_MEMBER ()

Static Private Attributes

static unsigned int _broken_beam_number = 0

Friends

class boost::serialization::access

Additional Inherited Members

Public Types inherited from GranOO3::DEM::Bond
enum  FailureMode { NONE =0 , TENSION =1 , COMPRESSION =2 , SHEAR =3 }
enum  DrawMode { SOLID , LINE , NO }
Static Public Attributes inherited from GranOO3::DEM::Bond
static double epsilon
 a very small value used as a threshold
static double draw_solid_factor
static DrawMode draw_mode = LINE
static Core::Signal< Bond & > disable_signal = Core::Signal<Bond&>()
 get the signal when a bond is disabled
Static Public Attributes inherited from GranOO3::Core::Null
static Null null = Null()
Protected Member Functions inherited from GranOO3::DEM::Bond
template<class Archive>
void save (Archive &, const unsigned int) const
template<class Archive>
void load (Archive &, const unsigned int)
 BOOST_SERIALIZATION_SPLIT_MEMBER ()
Protected Member Functions inherited from GranOO3::Core::Base
 Base ()
Protected Member Functions inherited from GranOO3::Physic::CriticalTimeStep
 CriticalTimeStep ()
 constructor
virtual ~CriticalTimeStep ()
 destructor
Static Protected Member Functions inherited from GranOO3::Core::Base
static unsigned int affect_class_rank_ID ()

Detailed Description

a bond beam that works in tension, compression, bending and torsion

The bond beam models an Euler-Bernouilli Beam between two bonds. It is mainly used for modeling continuum with DEM. You can get a complete description here [1].

[1] André, D., Iordanoff, I., Charles, J. L., & Néauport, J. (2012). Discrete element method to simulate continuous material by using the cohesive beam model. Computer Methods in Applied Mechanics and Engineering, 213, 113-125.

Constructor & Destructor Documentation

◆ Beam() [1/5]

GranOO3::DEM::Beam::Beam ( Element & el1,
Element & el2 )

constructor

Parameters
[in]el1: the first bonded element
[in]el2: the second bonded element

Build a new beam between the Element el1 and el2. Mechanical attributes are set to zero.

◆ Beam() [2/5]

GranOO3::DEM::Beam::Beam ( Element & el1,
Element & el2,
double young_mod,
double radius,
double poisson_ratio,
double max_stress = 0. )

constructor

Parameters
[in]el1: the first bonded element
[in]el2: the second bonded element
[in]young_mod: the Young's modulus of the beam in [Pa]
[in]radius: the radius of the beam in [m]
[in]poisson_ratio: the Poisson's ratio value of the beam
[in]max_stress: the maximal stress threshold of the beam in [Pa] (note that zero means infinite strength)

Build a new beam between the Element el1 and el2 with the required mechanical attributes. In case of continuum modeling, note that the max_stress is not the best way for managing fracture. You may prefer to use the stress computation (see the ApplyFracture PlugIn) which gives more accurate results.

◆ Beam() [3/5]

GranOO3::DEM::Beam::Beam ( Element & el1,
Element & el2,
double young_mod,
double damping,
double radius,
double poisson_ratio,
double max_stress )

constructor

Parameters
[in]el1: the first bonded element
[in]el2: the second bonded element
[in]young_mod: the Young's modulus of the beam in [Pa]
[in]damping: the damping factor (in the [0,1] range) which is expressed as the ratio of the critical damping
[in]radius: the radius of the beam in [m]
[in]poisson_ratio: the Poisson's ratio value of the beam
[in]max_stress: the maximal stress threshold of the beam in [Pa] (note that zero means infinite strength)

Build a new beam between the Element el1 and el2 with the required mechanical attributes. In case of continuum modeling, note that the max_stress is not the best way for managing fracture. You may prefer to use the stress computation (see the ApplyFracture PlugIn) which gives more accurate results.

◆ ~Beam()

GranOO3::DEM::Beam::~Beam ( )
virtual

◆ Beam() [4/5]

GranOO3::DEM::Beam::Beam ( )
privatedelete

◆ Beam() [5/5]

GranOO3::DEM::Beam::Beam ( const Beam & frame)
privatedelete

Member Function Documentation

◆ BOOST_SERIALIZATION_SPLIT_MEMBER()

GranOO3::DEM::Beam::BOOST_SERIALIZATION_SPLIT_MEMBER ( )
private

◆ compute_critical_time_step()

double GranOO3::DEM::Beam::compute_critical_time_step ( ) const
virtual

compute the critical time of the bond

Returns
the maximal time step

Note that this method computes on-the-fly the critical time step.

Implements GranOO3::Physic::CriticalTimeStep.

◆ compute_load()

void GranOO3::DEM::Beam::compute_load ( )
virtual

compute the reaction force and torque of the beam

Reimplemented from GranOO3::DEM::Bond.

Reimplemented in GranOO3::DEM::PlasticBeam, and GranOO3::DEM::PlasticBeamIT.

◆ draw()

void GranOO3::DEM::Beam::draw ( )
inlinevirtual

OpenGL draw of the bond.

This method is used for drawing the bond. It is used by the granoo-viewer vizualization tool

Reimplemented from GranOO3::DEM::Bond.

Reimplemented in GranOO3::DEM::PlasticBeam, and GranOO3::DEM::PlasticBeamIT.

◆ get_angular_stiffness()

double GranOO3::DEM::Beam::get_angular_stiffness ( ) const
virtual

similar as get_linear_stiffness() for rotation

Reimplemented from GranOO3::DEM::Bond.

◆ get_broken_beam_number()

unsigned int GranOO3::DEM::Beam::get_broken_beam_number ( )
static

◆ get_linear_stiffness()

double GranOO3::DEM::Beam::get_linear_stiffness ( ) const
virtual

compute the linear stiffness of the bond

Returns
the linear stiffness

Reimplemented from GranOO3::DEM::Bond.

◆ info()

std::string GranOO3::DEM::Beam::info ( ) const
virtual

Display some useful info in the terminal.

Reimplemented from GranOO3::DEM::Bond.

Reimplemented in GranOO3::DEM::PlasticBeam, and GranOO3::DEM::PlasticBeamIT.

◆ load()

template<class Archive>
void GranOO3::DEM::Beam::load ( Archive & ar,
const unsigned int v )
private

complete serializing of the bond in the *.gdd format

See also
the Domain classes to get additional info about I/O

◆ operator=()

Beam & GranOO3::DEM::Beam::operator= ( const Beam & )
privatedelete

◆ save()

template<class Archive>
void GranOO3::DEM::Beam::save ( Archive & ar,
const unsigned int v ) const
private

complete serializing of the bond in the *.gdd format

See also
the Domain classes to get additional info about I/O

◆ update_coeff_value()

void GranOO3::DEM::Beam::update_coeff_value ( )

◆ boost::serialization::access

friend class boost::serialization::access
friend

Member Data Documentation

◆ _broken_beam_number

unsigned int GranOO3::DEM::Beam::_broken_beam_number = 0
staticprivate

◆ _current_bending_stress

double GranOO3::DEM::Beam::_current_bending_stress
protected

the current maximal bending stress into the beam

◆ _current_normal_stress

double GranOO3::DEM::Beam::_current_normal_stress
protected

the current maximal normal stress into the beam (sum of tensile and bending stresses)

◆ _current_stress

double GranOO3::DEM::Beam::_current_stress
protected

the current maximal stress (including normal, bending and torsion stresses) in [Pa]

Note that the _max_stress threshold uses this value as computational reference for determining the maximal strength.

◆ _current_tensile_stress

double GranOO3::DEM::Beam::_current_tensile_stress
protected

the current tensile stress into the beam

◆ _current_torsion_stress

double GranOO3::DEM::Beam::_current_torsion_stress
protected

the current maximal torsion stress into the beam

◆ _factor_Fb

double GranOO3::DEM::Beam::_factor_Fb
protected

for storing some intermediate values to speed-up the computation

◆ _factor_Tb

double GranOO3::DEM::Beam::_factor_Tb
protected

for storing some intermediate values to speed-up the computation

◆ _factor_Tt

double GranOO3::DEM::Beam::_factor_Tt
protected

for storing some intermediate values to speed-up the computation

◆ _G

double GranOO3::DEM::Beam::_G
protected

for storing some intermediate values to speed-up the computation (Coulomb's modulus)

◆ _Ig

double GranOO3::DEM::Beam::_Ig
protected

for storing some intermediate values to speed-up the computation (quadratic inertia)

◆ _Io

double GranOO3::DEM::Beam::_Io
protected

for storing some intermediate values to speed-up the computation (quadratic polar inertia)

◆ _K

double GranOO3::DEM::Beam::_K
protected

for storing some intermediate values to speed-up the computation (normal stiffness)

◆ _max_stress

double GranOO3::DEM::Beam::_max_stress
protected

the maximal tensile stress of the beam in [Pa]

◆ _poisson_ratio

double GranOO3::DEM::Beam::_poisson_ratio
protected

the Poisson's ratio of the beam in [-]

◆ _radius

double GranOO3::DEM::Beam::_radius
protected

the radius of the beam in [m]

◆ _S

double GranOO3::DEM::Beam::_S
protected

for storing some intermediate values to speed-up the computation (normal surface)

◆ _young_modulus

double GranOO3::DEM::Beam::_young_modulus
protected

the Young's modulus value of the beam in [Pa]


The documentation for this class was generated from the following files: