![]() |
GranOO
3.0
A robust and versatile workbench to build 3D dynamic simulations based on the Discrete Element Method
|
a property for adding electrical physics to DEM::Element More...
#include <Electrical.hpp>

Public Member Functions | |
| Electrical () | |
| constructor More... | |
| virtual | ~Electrical () |
| destructor More... | |
| virtual std::string | info () const |
| void | set_as_positive (bool activate) |
| Defines the attached discrete element as connected to the positive terminal of the voltage source. More... | |
| void | set_as_ground (bool activate) |
| Defines the attached discrete element as connected to the ground terminal of the voltage source. More... | |
| void | add_current (double current) |
| Adds the contribution of a branch to the total current crossing the node, which is represented by a discrete element. More... | |
| void | add_power (double current, double conductance) |
| Adds the contribution of a branch to the electrical power crossing the node, given a current and conductance value. More... | |
| void | clear_all_power () |
Sets all powers to 0, namely the enterring and leaving powers. More... | |
| void | clear_all_current () |
Sets all currents to 0, namely the enterring and leaving currents. More... | |
| void | compute_power () |
| Computes the total power in the node by averaging the enterring and leaving powers. More... | |
| const bool | is_boundary_condition () const |
| const bool | is_positive () const |
| const bool | is_ground () const |
Public Member Functions inherited from GranOO3::Core::Prop< Element > | |
| Prop () | |
| virtual | ~Prop () |
| Element & | item () |
| const Element & | item () const |
| void | set_item (Element &) |
| virtual void | set_color (const Core::Color &) |
| Core::Color & | get_color () |
| float & | get_line_width () |
| virtual void | add (SetOf< Prop< Element > > *) |
| virtual void | erase (SetOf< Prop< Element > > *) |
| virtual std::ostream & | write_ascii (std::ostream &out) const |
| virtual std::istream & | read_ascii (std::istream &in) |
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::ostream & | export_to_povray (std::ostream &out) const |
| 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 () |
| 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_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 |
| bool | belong_to_setof (const SetOf< Base > &set) const |
| std::list< SetOf< Base > * > & | get_setof_list () |
| unsigned long long int | get_numeric_ID () const |
Public Member Functions inherited from GranOO3::Core::Register< type > | |
| Register () | |
| virtual | ~Register () |
| void | erase_from_all_setof () |
| bool | belong_to_setof (const std::string &setOfId) const |
| bool | belong_to_setof (const SetOf< type > &set) const |
| std::list< SetOf< type > * > & | get_setof_list () |
| unsigned long long int | get_numeric_ID () const |
Public Member Functions inherited from GranOO3::Core::Register< Electrical > | |
| Register () | |
| virtual | ~Register () |
| void | erase_from_all_setof () |
| bool | belong_to_setof (const std::string &setOfId) const |
| bool | belong_to_setof (const SetOf< Electrical > &set) const |
| std::list< SetOf< Electrical > * > & | get_setof_list () |
| unsigned long long int | get_numeric_ID () const |
Private Member Functions | |
| template<class Archive > | |
| void | serialize (Archive &ar, const unsigned int) |
| complete serializing of the instance in the *.gdd format More... | |
Private Attributes | |
| double | _electrical_conductivity |
| The electrical conductivity of the material. More... | |
| double | _potential |
| The electrical potential in the node. More... | |
| double | _entering_power |
| The sum of all current powers enterring the node. More... | |
| double | _leaving_power |
| The sum of all current powers leaving the node. More... | |
| double | _total_power |
| The total power in the node computed as the average of the enterring and leaving powers. More... | |
| double | _joule_power |
| double | _entering_current |
| The sum of all currents enterring the node. More... | |
| double | _leaving_current |
| The sum of all currents leaving the node. More... | |
| bool | _boundary_condition |
| A flag that tells whether the node is part of the boundary conditions. More... | |
| bool | _is_ground |
| A flag that tells whether the node is part of the ground terminal of the current source. More... | |
| bool | _is_positive |
| A flag that tells whether the node is part of the positive terminal of the current source. More... | |
Friends | |
| class | boost::serialization::access |
Additional Inherited Members | |
Public Types inherited from GranOO3::Core::Prop< Element > | |
| typedef Element | Owner |
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 Attributes inherited from GranOO3::Core::Null | |
| static Null | null = Null() |
Protected Member Functions inherited from GranOO3::Core::Prop< Element > | |
| virtual Base & | base_item () |
| virtual const Base & | base_item () const |
| void | serialize (Archive &ar, const unsigned int) |
Protected Member Functions inherited from GranOO3::Core::Base | |
| Base () | |
Static Protected Member Functions inherited from GranOO3::Core::Base | |
| static unsigned int | affect_class_rank_ID () |
a property for adding electrical physics to DEM::Element
The aim of this DEM::Element property is to add electrical properties to DEM::Element. It enables to carry out multi-physics simulation taking into account electrical conduction. For more information, please refer to [1].
[1] Hubert, C., André, D., Dubar, L., Iordanoff, I., & Charles, J. L. (2017). Simulation of continuum electrical conduction and Joule heating using DEM domains. International Journal for Numerical Methods in Engineering, 110(9), 862-877.
| GranOO3::DEM::Electrical::Electrical | ( | ) |
constructor
Constructs a new Electrical instance. Do not call this constructor. To build a new Electrical instance, you must create a new property by invoking the Element::new_prop<Electrical>() method of the Element class.
|
virtual |
destructor
Destructs an Electrical instance. Be aware, as Electrical is a property, you must not invoke destructor by yourself, it could lead to unexpected behavior. Note that the Electrical instances are automatically destructed when their associated elements are destructed.
| void GranOO3::DEM::Electrical::add_current | ( | double | current | ) |
Adds the contribution of a branch to the total current crossing the node, which is represented by a discrete element.
| [in] | current | : The current to be added. |
| void GranOO3::DEM::Electrical::add_power | ( | double | current, |
| double | conductance | ||
| ) |
Adds the contribution of a branch to the electrical power crossing the node, given a current and conductance value.
| [in] | current | : The current in the branch. |
| [in] | conductance | : The branch conductance. |
| void GranOO3::DEM::Electrical::clear_all_current | ( | ) |
Sets all currents to 0, namely the enterring and leaving currents.
| void GranOO3::DEM::Electrical::clear_all_power | ( | ) |
Sets all powers to 0, namely the enterring and leaving powers.
| void GranOO3::DEM::Electrical::compute_power | ( | ) |
Computes the total power in the node by averaging the enterring and leaving powers.
|
virtual |
Reimplemented from GranOO3::Core::Prop< Element >.
| const bool GranOO3::DEM::Electrical::is_boundary_condition | ( | ) | const |
true or false whether the node is defined as a boundary condition. | const bool GranOO3::DEM::Electrical::is_ground | ( | ) | const |
true or false whether the node is part of the ground terminal of the current source. | const bool GranOO3::DEM::Electrical::is_positive | ( | ) | const |
true or false whether the node is part of the positive terminal of the current source.
|
private |
| void GranOO3::DEM::Electrical::set_as_ground | ( | bool | activate | ) |
Defines the attached discrete element as connected to the ground terminal of the voltage source.
| [in] | activate | : A flag that defines the attached discrete element as positive. |
| void GranOO3::DEM::Electrical::set_as_positive | ( | bool | activate | ) |
Defines the attached discrete element as connected to the positive terminal of the voltage source.
| [in] | activate | : A flag that defines the attached discrete element as positive. |
|
friend |
|
private |
A flag that tells whether the node is part of the boundary conditions.
|
private |
The electrical conductivity of the material.
|
private |
The sum of all currents enterring the node.
|
private |
The sum of all current powers enterring the node.
|
private |
A flag that tells whether the node is part of the ground terminal of the current source.
|
private |
A flag that tells whether the node is part of the positive terminal of the current source.
|
private |
|
private |
The sum of all currents leaving the node.
|
private |
The sum of all current powers leaving the node.
|
private |
The electrical potential in the node.
|
private |
The total power in the node computed as the average of the enterring and leaving powers.