|
AGX Dynamics
2.37.3.2
|
The CableDamage class is used to estimate damage caused to a cable during a simulation. More...
#include <CableDamage.h>
Inheritance diagram for agxCable::CableDamage:Public Member Functions | |
| CableDamage () | |
| Create a new CableDamage instance. More... | |
| const agxCable::SegmentDamage & | getAccumulatedDamageAt (size_t index) const |
| Provides access to the accumulated damage estimation for a particular cable segment. More... | |
| agxCable::SegmentDamagePtrVector | getAccumulatedDamagePtrs () const |
| const agxCable::SegmentDamageVector & | getAccumulatedDamages () const |
| Provides access to the per-segment damage estimates that has been accumulated over the simulation so far. More... | |
| agx::Real | getBendDeformationWeight () const |
| agx::Real | getBendRateWeight () |
| agx::Real | getBendTensionWeight () |
| agx::Real | getBendThreshold () |
| agxCable::Cable * | getCable () |
| Get the cable that this CableDamage is estimating damage for. More... | |
| const agxCable::Cable * | getCable () const |
| Get the cable that this CableDamage is estimating damage for. More... | |
| const char * | getClassName () const override |
| const agxCable::SegmentDamage & | getCurrentDamageAt (size_t index) const |
| Provides access to the last time step's damage contribution for a particular cable segment. More... | |
| agxCable::SegmentDamagePtrVector | getCurrentDamagePtrs () const |
| const agxCable::SegmentDamageVector & | getCurrentDamages () const |
| Provides access to the per-segment damage estimate contributions that the last time step produced. More... | |
| agx::Real | getFrictionForceWeight () |
| agx::Real | getNormalForceWeight () |
| size_t | getNumDamages () const |
| May return zero until the cable for which damage is estimated has been fully initialized. More... | |
| agxStream::StorageAgent * | getStorageAgent () const override |
| agx::Real | getStretchDeformationWeight () const |
| agx::Real | getStretchRateWeight () |
| agx::Real | getStretchTensionWeight () |
| agx::Real | getStretchThreshold () |
| agx::Real | getThreshold (agxCable::Direction direction) const |
| agx::Real | getTwistDeformationWeight () const |
| agx::Real | getTwistRateWeight () |
| agx::Real | getTwistTensionWeight () |
| agx::Real | getTwistThreshold () |
| agx::Real | getWeight (agxCable::DamageTypes::DamageType type) const |
| Get the weight, or scaling, used for the given damage source when summing it with all the other damage sources to form a total damage estimate. More... | |
| virtual void | restore (agxStream::InputArchive &in) override |
| void | setBendDeformationWeight (agx::Real weight) |
| Set the weight to use for damage caused by bend deformation. More... | |
| void | setBendRateWeight (agx::Real weight) |
| Set the weight to use for damage caused by bend rate. More... | |
| void | setBendTensionWeight (agx::Real weight) |
| Set the weight to use for damage caused by bend tension. More... | |
| void | setBendThreshold (agx::Real threshold) |
| Set the bend deformation threshold that must be surpassed before the bend deformation begin to contribute to the damage estimation. More... | |
| void | setFrictionForceWeight (agx::Real weight) |
| Set the weight to use for damage caused by friction forces from contacts. More... | |
| void | setNormalForceWeight (agx::Real weight) |
| Set the weight to use for damage caused by normal forces from contacts. More... | |
| void | setStretchDeformationWeight (agx::Real weight) |
| Set the weight to use for damage caused by stretch deformation. More... | |
| void | setStretchRateWeight (agx::Real weight) |
| Set the weight to use for damage caused by stretch rate. More... | |
| void | setStretchTensionWeight (agx::Real weight) |
| Set the weight to use for damage caused by stretch tension. More... | |
| void | setStretchThreshold (agx::Real threshold) |
| Set the stretch deformation threshold that must be surpassed before the stretch deformation begin to contribute to the damage estimation. More... | |
| void | setThreshold (agxCable::Direction direction, agx::Real threshold) |
| Set the deformation threshold for the given direction that must be surpassed before the deformation begin to contribute to the damage estimation. More... | |
| void | setTwistDeformationWeight (agx::Real weight) |
| Set the weight to use for damage caused by twist deformation. More... | |
| void | setTwistRateWeight (agx::Real weight) |
| Set the weight to use for damage caused by twist rate. More... | |
| void | setTwistTensionWeight (agx::Real weight) |
| Set the weight to use for damage caused by twist tension. More... | |
| void | setTwistThreshold (agx::Real threshold) |
| Set the twist deformation threshold that must be surpassed before the twist deformation begin to contribute to the damage estimation. More... | |
| void | setWeight (agxCable::DamageTypes::DamageType type, agx::Real weight) |
| Set the weight, or scaling, to use for the given damage source when summing it with all the other damage sources to form a total damage estimate. More... | |
| virtual void | store (agxStream::OutputArchive &out) const override |
Public Member Functions inherited from agxSDK::LinkedStructureComponent | |
| const char * | getClassName () const override |
| agxSDK::LinkedStructure * | getLinkedStructure () const |
| const agx::Name & | getName () const |
| agxSDK::Simulation * | getSimulation () const |
| agxStream::StorageAgent * | getStorageAgent () const override |
| void | setName (const agx::Name &name) |
| Assign new name to this component. More... | |
Public Member Functions inherited from agx::Referenced | |
| Referenced () | |
| Default constructor. More... | |
| Referenced (const Referenced &) | |
| template<typename T > | |
| T * | as () |
| Subclass casting. More... | |
| template<typename T > | |
| const T * | as () const |
| template<typename T > | |
| T * | asSafe () |
| Safe subclass casting, return nullptr if template type does not match. More... | |
| template<typename T > | |
| const T * | asSafe () const |
| int | getReferenceCount () const |
| template<typename T > | |
| bool | is () const |
| Subclass test. More... | |
| Referenced & | operator= (const Referenced &) |
| Assignment operator. Will increment the number of references to the referenced object. More... | |
| void | reference (void *ptr=nullptr) const |
| Explicitly increment the reference count by one, indicating that this object has another pointer which is referencing it. More... | |
| void | unreference (void *ptr=nullptr) const |
| Decrement the reference count by one, indicating that a pointer to this object is referencing it. More... | |
| void | unreference_nodelete () const |
| Decrement the reference count by one, indicating that a pointer to this object is referencing it. More... | |
Public Member Functions inherited from agxStream::Serializable | |
| virtual | ~Serializable () |
| Destructor for normal C++ use but hidden from SWIG bindings. More... | |
| bool | getEnableSerialization () const |
| bool | getEnableUuidGeneration () |
| agx::UInt32 | getIndex () const |
| This index is given at creation of this object. More... | |
| agx::Uuid | getUuid () const |
| bool | isFinished () const |
| void | setEnableSerialization (bool flag) |
| Set to false to disable serialization of this object. More... | |
| void | setFinished () |
| Tells this class that it is restored correctly and should not be deleted during destruction of an Archive. More... | |
| void | setUuid (const agx::Uuid &uuid) |
| Explicitly set a Uuid on a serializable object. More... | |
Static Public Member Functions | |
| static agxStream::Serializable * | create () |
| static agxStream::Serializable * | create (agxStream::InputArchive &) |
| static agxCable::CableDamage * | getCableDamage (agxCable::Cable *cable) |
| Find the CableDamage instances that estimate damage for the given cable. More... | |
| static const char * | getConstructClassId () |
Static Public Member Functions inherited from agxSDK::LinkedStructureComponent | |
| static agxStream::Serializable * | create () |
| static agxStream::Serializable * | create (agxStream::InputArchive &) |
| static const char * | getConstructClassId () |
Static Public Member Functions inherited from agx::Referenced | |
| template<typename T > | |
| static bool | ValidateCast (const Referenced *object) |
Static Public Member Functions inherited from agxStream::Serializable | |
| static void | setEnableUuidGeneration (bool flag) |
| Specify if there should be UUID:s generated for each new Serializable object. By default it is enabled. More... | |
Protected Member Functions | |
| virtual | ~CableDamage () |
| virtual void | onAddNotification (agxSDK::LinkedStructure *linkedStructure) override |
| Called when this component is added to a linked structure. More... | |
| virtual void | onAddNotification (agxSDK::Simulation *simulation) override |
| Called when addNotification is executed when this linked structure is added to the simulation. More... | |
| virtual void | onPostStep () override |
| Called on simulation post step event - after user postStep. More... | |
| virtual void | onPreStep () override |
| Called on simulation pre step event - after user preStep. More... | |
Protected Member Functions inherited from agxSDK::LinkedStructureComponent | |
| LinkedStructureComponent (const agx::Name &name="") | |
| Default, protected constructor. More... | |
| virtual | ~LinkedStructureComponent () |
| Reference counted object - protected destructor. More... | |
| virtual void | onLastStep () |
| Called on simulation last step event - after user lastStep. More... | |
| virtual void | onPreCollideStep () |
| Called on simulation pre-collide step event - after user preCollide. More... | |
| virtual void | onRemoveNotification (agxSDK::Simulation *simulation) |
| Called when removeNotification is executed when this linked structure is removed from the simulation. More... | |
| virtual void | onRemoveNotification (agxSDK::LinkedStructure *linkedStructure) |
| Called when this component is removed from a linked structure. More... | |
Protected Member Functions inherited from agx::Referenced | |
| virtual | ~Referenced () |
| Destructor. More... | |
| void | allocateObserverVector () const |
| void | deleteUsingDeleteHandler () const |
Protected Member Functions inherited from agxStream::Serializable | |
| Serializable () | |
| Default constructor. More... | |
| Serializable (const Serializable &other) | |
| Copy constructor. More... | |
| void | generateUuid () |
Additional Inherited Members | |
Static Protected Member Functions inherited from agx::Referenced | |
| static DeleteHandler * | getDeleteHandler () |
| static void | setDeleteHandler (DeleteHandler *handler) |
| Internal: Set a DeleteHandler to which deletion of all referenced counted objects will be delegated to. More... | |
Protected Attributes inherited from agx::Referenced | |
| Mutex | m_mutex |
| ObserverContainer | m_observers |
| AtomicValue | m_refCount |
The CableDamage class is used to estimate damage caused to a cable during a simulation.
Damage is estimated from a number of damage sources and weighted together to form a total.
The damage sources are categorized in two ways: dimension and cause. The dimension is one of the regular cable dimensions: bend, twist, or stretch. The cause is the state of the cable that is producing the damage and is either tension, deformation or deformation rate. There is also contacts, which are treated separately.
Given three dimensions; bend, twist, and stretch, and three sources; tension, deformation and deformation rate, we get a total of nine damage types, plus two contact types normal force and friction force. They are enumerated in agxCable::DamageTypes.
The damage model incorporates the notion of "safe deformations". These are deformation thresholds below which no damage is being produced due to deformation or deformation rate. Tension and contact damage still apply.
Damage is estimated per cable segment.
Definition at line 57 of file CableDamage.h.
| agxCable::CableDamage::CableDamage | ( | ) |
Create a new CableDamage instance.
The CableDamage is activated when added to a Cable.
|
protectedvirtual |
|
inlinestatic |
Definition at line 393 of file CableDamage.h.
|
inlinestatic |
Definition at line 393 of file CableDamage.h.
| const agxCable::SegmentDamage& agxCable::CableDamage::getAccumulatedDamageAt | ( | size_t | index | ) | const |
Provides access to the accumulated damage estimation for a particular cable segment.
index must be less than the value returned by getNumDamages.
| index | - The index of the SegmentDamage instance to access. |
| agxCable::SegmentDamagePtrVector agxCable::CableDamage::getAccumulatedDamagePtrs | ( | ) | const |
| const agxCable::SegmentDamageVector& agxCable::CableDamage::getAccumulatedDamages | ( | ) | const |
Provides access to the per-segment damage estimates that has been accumulated over the simulation so far.
| agx::Real agxCable::CableDamage::getBendDeformationWeight | ( | ) | const |
| agx::Real agxCable::CableDamage::getBendRateWeight | ( | ) |
| agx::Real agxCable::CableDamage::getBendTensionWeight | ( | ) |
| agx::Real agxCable::CableDamage::getBendThreshold | ( | ) |
| agxCable::Cable* agxCable::CableDamage::getCable | ( | ) |
Get the cable that this CableDamage is estimating damage for.
Will return nullptr if this CableDamage hasn't been added to a cable yet.
| const agxCable::Cable* agxCable::CableDamage::getCable | ( | ) | const |
Get the cable that this CableDamage is estimating damage for.
Will return nullptr if this CableDamage hasn't been added to a cable yet.
|
static |
Find the CableDamage instances that estimate damage for the given cable.
| cable | - The cable for which a CableDamage instance should be found. |
|
inlineoverridevirtual |
Reimplemented from agxStream::Serializable.
Definition at line 393 of file CableDamage.h.
|
inlinestatic |
Definition at line 393 of file CableDamage.h.
| const agxCable::SegmentDamage& agxCable::CableDamage::getCurrentDamageAt | ( | size_t | index | ) | const |
Provides access to the last time step's damage contribution for a particular cable segment.
index must be less than the value returned by getNumDamages.
| index | - The index of the SegmentDamage instance to access. |
| agxCable::SegmentDamagePtrVector agxCable::CableDamage::getCurrentDamagePtrs | ( | ) | const |
| const agxCable::SegmentDamageVector& agxCable::CableDamage::getCurrentDamages | ( | ) | const |
Provides access to the per-segment damage estimate contributions that the last time step produced.
| agx::Real agxCable::CableDamage::getFrictionForceWeight | ( | ) |
| agx::Real agxCable::CableDamage::getNormalForceWeight | ( | ) |
| size_t agxCable::CableDamage::getNumDamages | ( | ) | const |
May return zero until the cable for which damage is estimated has been fully initialized.
|
inlineoverridevirtual |
Implements agxStream::Serializable.
Definition at line 393 of file CableDamage.h.
| agx::Real agxCable::CableDamage::getStretchDeformationWeight | ( | ) | const |
| agx::Real agxCable::CableDamage::getStretchRateWeight | ( | ) |
| agx::Real agxCable::CableDamage::getStretchTensionWeight | ( | ) |
| agx::Real agxCable::CableDamage::getStretchThreshold | ( | ) |
| agx::Real agxCable::CableDamage::getThreshold | ( | agxCable::Direction | direction | ) | const |
| direction | - Direction to get deformation threshold for. |
| agx::Real agxCable::CableDamage::getTwistDeformationWeight | ( | ) | const |
| agx::Real agxCable::CableDamage::getTwistRateWeight | ( | ) |
| agx::Real agxCable::CableDamage::getTwistTensionWeight | ( | ) |
| agx::Real agxCable::CableDamage::getTwistThreshold | ( | ) |
| agx::Real agxCable::CableDamage::getWeight | ( | agxCable::DamageTypes::DamageType | type | ) | const |
Get the weight, or scaling, used for the given damage source when summing it with all the other damage sources to form a total damage estimate.
| type | - The damage type to get the weight for. |
|
overrideprotectedvirtual |
Called when this component is added to a linked structure.
Reimplemented from agxSDK::LinkedStructureComponent.
|
overrideprotectedvirtual |
Called when addNotification is executed when this linked structure is added to the simulation.
Reimplemented from agxSDK::LinkedStructureComponent.
|
overrideprotectedvirtual |
Called on simulation post step event - after user postStep.
Reimplemented from agxSDK::LinkedStructureComponent.
|
overrideprotectedvirtual |
Called on simulation pre step event - after user preStep.
Reimplemented from agxSDK::LinkedStructureComponent.
|
overridevirtual |
Reimplemented from agxSDK::LinkedStructureComponent.
| void agxCable::CableDamage::setBendDeformationWeight | ( | agx::Real | weight | ) |
Set the weight to use for damage caused by bend deformation.
| weight | - The new weight for bend deformation damage estimation. |
| void agxCable::CableDamage::setBendRateWeight | ( | agx::Real | weight | ) |
Set the weight to use for damage caused by bend rate.
Bend rate is a measure of how fast the cable is being bent, measured as the change in curvature per unit time.
| weight | - The new weight for bend rate damage estimation. |
| void agxCable::CableDamage::setBendTensionWeight | ( | agx::Real | weight | ) |
Set the weight to use for damage caused by bend tension.
| weight | - The new weight for bend tension damage estimation. |
| void agxCable::CableDamage::setBendThreshold | ( | agx::Real | threshold | ) |
Set the bend deformation threshold that must be surpassed before the bend deformation begin to contribute to the damage estimation.
The threshold is measured in radians per unit length.
| threshold | - The minimum bend deformation for bend damage to be applied. |
| void agxCable::CableDamage::setFrictionForceWeight | ( | agx::Real | weight | ) |
Set the weight to use for damage caused by friction forces from contacts.
| weight | - The new weight for friction force damage estimation. |
| void agxCable::CableDamage::setNormalForceWeight | ( | agx::Real | weight | ) |
Set the weight to use for damage caused by normal forces from contacts.
| weight | - The new weight for normal force damage estimation. |
| void agxCable::CableDamage::setStretchDeformationWeight | ( | agx::Real | weight | ) |
Set the weight to use for damage caused by stretch deformation.
| weight | - The new weight for stretch deformation damage estimation. |
| void agxCable::CableDamage::setStretchRateWeight | ( | agx::Real | weight | ) |
Set the weight to use for damage caused by stretch rate.
Stretch rate is a measure of how fast the cable is being stretched, measured in lengths per unit length per unit time.
| weight | - The new weight for stretch rate damage estimation. |
| void agxCable::CableDamage::setStretchTensionWeight | ( | agx::Real | weight | ) |
Set the weight to use for damage caused by stretch tension.
| weight | - The new weight for stretch tension damage estimation. |
| void agxCable::CableDamage::setStretchThreshold | ( | agx::Real | threshold | ) |
Set the stretch deformation threshold that must be surpassed before the stretch deformation begin to contribute to the damage estimation.
The threshold is given in length per unit length.
| threshold | - The minimum stretch deformation for stretch damage to be applied. |
| void agxCable::CableDamage::setThreshold | ( | agxCable::Direction | direction, |
| agx::Real | threshold | ||
| ) |
Set the deformation threshold for the given direction that must be surpassed before the deformation begin to contribute to the damage estimation.
The unit of the threshold depends on the direction. See setStretchThreshold, setBendThreshold, and setTwistThreshold.
| direction | - The direction to set deformation threshold for. |
| threshold | - The new deformation threshold. |
| void agxCable::CableDamage::setTwistDeformationWeight | ( | agx::Real | weight | ) |
Set the weight to use for damage caused by twist deformation.
| weight | - The new weight for twist deformation damage estimation. |
| void agxCable::CableDamage::setTwistRateWeight | ( | agx::Real | weight | ) |
Set the weight to use for damage caused by twist rate.
Twist rate is a measure of how fast the cable is being twisted, measured in radians per unit length per unit time.
| weight | - The new weight for twist rate damage estimation. |
| void agxCable::CableDamage::setTwistTensionWeight | ( | agx::Real | weight | ) |
Set the weight to use for damage caused by twist tension.
| weight | - The new weight for twist tension damage estimation. |
| void agxCable::CableDamage::setTwistThreshold | ( | agx::Real | threshold | ) |
Set the twist deformation threshold that must be surpassed before the twist deformation begin to contribute to the damage estimation.
The twist threshold is measured in radians per unit length.
| threshold | - The minimum twist deformation for twist damage to be applied. |
| void agxCable::CableDamage::setWeight | ( | agxCable::DamageTypes::DamageType | type, |
| agx::Real | weight | ||
| ) |
Set the weight, or scaling, to use for the given damage source when summing it with all the other damage sources to form a total damage estimate.
| type | - The damage type to set the weight for. |
| weight | - The new weight. |
|
overridevirtual |
Reimplemented from agxSDK::LinkedStructureComponent.