AGX Dynamics 2.42.3.0
Loading...
Searching...
No Matches
agxPowerLine::ElementaryPhysicalDimensionConstraint Class Referenceabstract

Pure virtual function. More...

#include <PowerLineConstraints.h>

+ Inheritance diagram for agxPowerLine::ElementaryPhysicalDimensionConstraint:

Public Member Functions

 ElementaryPhysicalDimensionConstraint ()
 Constructor for pure virtual function.
 
 AGXSTREAM_DECLARE_ABSTRACT_SERIALIZABLE (agxPowerLine::ElementaryPhysicalDimensionConstraint)
 
Connector * getConnector ()
 
const Connector * getConnector () const
 
virtual size_t getJacobian (agx::Jacobian6DOFElement *, const RigidBodyPtrIntHashVector &, const agx::ConstraintRigidBodyContainer &, const PhysicalDimensionPtrIntTable &, const agx::Real)=0
 getJacobian must be implemented for all classes that inherits from this.
 
virtual void getJacobian (const agxPowerLine::PhysicalDimension *dimension, agx::Jacobian6DOFElement &G) const =0
 
virtual agx::UInt getViolation (agx::Real *, agx::UInt) override
 
virtual bool isValid () const
 Check if the dimensions of the constraint are legit.
 
virtual void restore (agxStream::InputArchive &in) override
 Restore this object from stream.
 
void setConnector (Connector *connector)
 Set a pointer to the connector that will define this constraint.
 
virtual void store (agxStream::OutputArchive &out) const override
 Store this object to stream.
 
- Public Member Functions inherited from agx::ElementaryConstraintN< 1 >
 ElementaryConstraintN (agx::Bool enable)
 Construct given enable flag.
 
- Public Member Functions inherited from agx::ElementaryConstraint
 AGXSTREAM_DECLARE_ABSTRACT_SERIALIZABLE (agx::ElementaryConstraint)
 
void copyRowFrom (const ElementaryConstraint *source, agx::UInt sourceRow, agx::UInt destRow)
 Copy configuration row from the given ElementaryConstraint into this.
 
virtual agx::UInt getBounds (agx::RangeReal *bounds, agx::UInt row, agx::Real h) const
 Returns the bounds of the Lagrange Multipliers (default (-inf, +inf)).
 
agx::Real getCompliance (agx::UInt row=0) const
 
virtual agx::Real getCurrentForce (const agx::UInt row=0) const
 Returns the force applied last time step by this elementary constraint.
 
const agx::Real * getCurrentForces () const
 
agx::Real getDamping (agx::UInt row=0) const
 
agx::Real getElasticity (agx::UInt row=0) const
 
virtual agx::Bool getEnable () const
 
agx::RangeReal & getForceRange (const agx::UInt row=0)
 
const agx::RangeReal & getForceRange (const agx::UInt row=0) const
 
virtual agx::UInt getJacobian (agx::Jacobian6DOFElement *G, agx::UInt numBlocks, agx::UInt row, agx::GWriteState::Enum writeState)
 Returns the Jacobian of this elementary constraint.
 
const agx::ElementaryConstraint::NameType & getName () const
 
virtual agx::ConstraintNlmcpCallback * getNlCallback () const
 
agx::UInt getNumRows () const
 
agx::RegularizationParameters * getRegularizationParameters (const agx::UInt row=0)
 
const agx::RegularizationParameters * getRegularizationParameters (const agx::UInt row=0) const
 
virtual agx::UInt getVelocity (agx::Real *v, agx::UInt row) const
 Returns the velocity of this elementary constraint (extra, driving term on the right hand side).
 
virtual agx::UInt getViolation (agx::Real *g, agx::UInt row)
 Returns the violation of this elementary constraint.
 
virtual agx::Bool isActive () const
 An elementary constraint is defined to be active if enabled.
 
virtual agx::Bool isImpacting () const
 
virtual void linearizeCompliance (const agx::Real *violations, agx::Real *epsilons, agx::Real minPerturbation) const
 Modify epsilon so that this ElementaryConstraint appear to be linear in the "normal" deformantion space instead any other space that the ElementaryConstraint may be using.
 
virtual agx::UInt postSolveCallback (const agx::Real *solution, agx::UInt row, agx::Real h)
 Callback after solve, with the solution.
 
virtual void prepare ()
 Prepare call.
 
void reset ()
 Reset call.
 
virtual void restore (agxStream::InputArchive &in) override
 Restore this object from stream.
 
virtual void restoreLightData (agxStream::StorageStream &str) override
 Restore structural independent data from stream.
 
virtual void setAttachmentPair (const agx::AttachmentPair *ap)
 Call for elementary constraints dependent on attachment pairs.
 
void setCompliance (agx::Real compliance)
 
void setCompliance (agx::Real compliance, int row)
 Assign compliance for a given row, or all rows if row = -1 (default).
 
void setDamping (agx::Real damping)
 
void setDamping (agx::Real damping, int row)
 Assign damping for a given row, or all rows if row = -1 (default).
 
void setElasticity (agx::Real elasticity)
 
void setElasticity (agx::Real elasticity, int row)
 Assign elasticity for a given row, or all rows if row = -1 (default).
 
virtual void setEnable (agx::Bool enable)
 Enable/disable this elementary constraint.
 
void setForceRange (agx::RangeReal forceRange, const agx::UInt row=0)
 Assign force range to a given row.
 
void setForceRange (agx::Real lower, agx::Real upper, const agx::UInt row=0)
 Assign force range to a given row.
 
void setName (const agx::ElementaryConstraint::NameType &name)
 Name this elementary constraint.
 
virtual void store (agxStream::OutputArchive &out) const override
 Store this object to stream.
 
virtual void storeLightData (agxStream::StorageStream &str) const override
 Store structural independent data to stream.
 
- Public Member Functions inherited from agx::Referenced
 Referenced ()
 Default constructor.
 
 Referenced (const Referenced &)
 
template<typename T >
T * as ()
 Subclass casting.
 
template<typename T >
const T * as () const
 
template<typename T >
T * asSafe ()
 Safe subclass casting, return nullptr if template type does not match.
 
template<typename T >
const T * asSafe () const
 
int getReferenceCount () const
 
template<typename T >
bool is () const
 Subclass test.
 
Referenced & operator= (const Referenced &)
 Assignment operator. Will increment the number of references to the referenced object.
 
void reference (void *ptr=nullptr) const
 Explicitly increment the reference count by one, indicating that this object has another pointer which is referencing it.
 
void unreference (void *ptr=nullptr) const
 Decrement the reference count by one, indicating that a pointer to this object is referencing it.
 
void unreference_nodelete () const
 Decrement the reference count by one, indicating that a pointer to this object is referencing it.
 
- Public Member Functions inherited from agxStream::Serializable
virtual ~Serializable ()
 Destructor for normal C++ use but hidden from SWIG bindings.
 
virtual const char * getClassName () const
 
bool getEnableSerialization () const
 
bool getEnableUuidGeneration ()
 
agx::UInt32 getIndex () const
 This index is given at creation of this object.
 
virtual StorageAgent * getStorageAgent () const =0
 
agx::Uuid getUuid () const
 
bool isFinished () const
 
void setEnableSerialization (bool flag)
 Set to false to disable serialization of this object.
 
void setFinished ()
 Tells this class that it is restored correctly and should not be deleted during destruction of an Archive.
 
void setUuid (const agx::Uuid &uuid)
 Explicitly set a Uuid on a serializable object.
 

Protected Member Functions

virtual ~ElementaryPhysicalDimensionConstraint ()
 destructor.
 
virtual agx::UInt getJacobian (agx::Jacobian6DOFElement *, agx::UInt, agx::UInt, agx::GWriteState::Enum) override
 Forced inheritance from agx::ElementaryConstraint.
 
- Protected Member Functions inherited from agx::ElementaryConstraintN< 1 >
 ElementaryConstraintN ()
 Used during serialization restore.
 
- Protected Member Functions inherited from agx::ElementaryConstraint
 ElementaryConstraint (agx::Bool enable, agx::UInt numRows, agx::RegularizationParameters *regParamsBuffer, agx::Real *lastForcesBuffer, agx::RangeReal *userBoundsBuffer)
 Construct given data.
 
virtual ~ElementaryConstraint ()
 Reference counted object, protected destructor.
 
- Protected Member Functions inherited from agx::Referenced
virtual ~Referenced ()
 Destructor.
 
void allocateObserverVector () const
 
void deleteUsingDeleteHandler () const
 
- Protected Member Functions inherited from agxStream::Serializable
 Serializable ()
 Default constructor.
 
 Serializable (const Serializable &other)
 Copy constructor.
 
void generateUuid ()
 

Protected Attributes

Connector * m_connector
 
- Protected Attributes inherited from agx::ElementaryConstraintN< 1 >
agx::RangeReal m_bounds [N]
 Bounds buffer.
 
agx::Real m_forces [N]
 Forces buffer.
 
agx::RegularizationParameters m_regParams [N]
 Regularization parameters buffer.
 
- Protected Attributes inherited from agx::ElementaryConstraint
agx::Bool m_enable
 enabled
 
agx::ref_ptr< agx::Referenced > m_internalData
 custom, internal data
 
agx::Real * m_lfs
 last forces
 
agx::ElementaryConstraint::NameType m_name
 name
 
agx::UInt m_numRows
 number of rows
 
agx::RegularizationParameters * m_rps
 regularization parameters
 
agx::RangeReal * m_ubs
 user bounds

 
- Protected Attributes inherited from agx::Referenced
Mutex m_mutex
 
ObserverContainer m_observers
 
AtomicValue m_refCount
 

Additional Inherited Members

- Public Types inherited from agx::ElementaryConstraint
typedef agx::Name NameType
 
typedef agx::VectorPOD< agx::ElementaryConstraint * > PtrContainer
 
typedef agx::Vector< agx::ref_ptr< agx::ElementaryConstraint > > RefContainer
 
- 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.
 
- 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.
 

Detailed Description

Pure virtual function.

Elementary constraint for constraining two physical dimensions Inherit from this to make a constraint between two physical dimensions.

Definition at line 37 of file PowerLineConstraints.h.

Constructor & Destructor Documentation

◆ ElementaryPhysicalDimensionConstraint()

agxPowerLine::ElementaryPhysicalDimensionConstraint::ElementaryPhysicalDimensionConstraint ( )

Constructor for pure virtual function.

◆ ~ElementaryPhysicalDimensionConstraint()

virtual agxPowerLine::ElementaryPhysicalDimensionConstraint::~ElementaryPhysicalDimensionConstraint ( )
protectedvirtual

destructor.

Member Function Documentation

◆ AGXSTREAM_DECLARE_ABSTRACT_SERIALIZABLE()

agxPowerLine::ElementaryPhysicalDimensionConstraint::AGXSTREAM_DECLARE_ABSTRACT_SERIALIZABLE ( agxPowerLine::ElementaryPhysicalDimensionConstraint  )

◆ getConnector() [1/2]

Connector * agxPowerLine::ElementaryPhysicalDimensionConstraint::getConnector ( )

◆ getConnector() [2/2]

const Connector * agxPowerLine::ElementaryPhysicalDimensionConstraint::getConnector ( ) const

◆ getJacobian() [1/3]

virtual agx::UInt agxPowerLine::ElementaryPhysicalDimensionConstraint::getJacobian ( agx::Jacobian6DOFElement *  ,
agx::UInt  ,
agx::UInt  ,
agx::GWriteState::Enum   
)
overrideprotectedvirtual

Forced inheritance from agx::ElementaryConstraint.

Reimplemented from agx::ElementaryConstraint.

◆ getJacobian() [2/3]

virtual size_t agxPowerLine::ElementaryPhysicalDimensionConstraint::getJacobian ( agx::Jacobian6DOFElement *  ,
const RigidBodyPtrIntHashVector &  ,
const agx::ConstraintRigidBodyContainer &  ,
const PhysicalDimensionPtrIntTable &  ,
const agx::Real   
)
pure virtual

getJacobian must be implemented for all classes that inherits from this.

Implemented in agxHydraulics::detail::ElementaryGraphJoiningConstraint, and agxPowerLine::ElementaryPhysicalDimensionMultiBodyConstraint.

◆ getJacobian() [3/3]

virtual void agxPowerLine::ElementaryPhysicalDimensionConstraint::getJacobian ( const agxPowerLine::PhysicalDimension *  dimension,
agx::Jacobian6DOFElement &  G 
) const
pure virtual

◆ getViolation()

virtual agx::UInt agxPowerLine::ElementaryPhysicalDimensionConstraint::getViolation ( agx::Real *  ,
agx::UInt   
)
overridevirtual
Returns
the constraint violation. (Default zero. Also zero for non-holonomic constraints.)

Reimplemented from agx::ElementaryConstraint.

◆ isValid()

virtual bool agxPowerLine::ElementaryPhysicalDimensionConstraint::isValid ( ) const
virtual

Check if the dimensions of the constraint are legit.

Reimplemented in agxPowerLine::ElementaryHolonomicGearConstraint.

◆ restore()

virtual void agxPowerLine::ElementaryPhysicalDimensionConstraint::restore ( agxStream::InputArchive &  in)
overridevirtual

Restore this object from stream.

Reimplemented from agx::ElementaryConstraint.

◆ setConnector()

void agxPowerLine::ElementaryPhysicalDimensionConstraint::setConnector ( Connector *  connector)

Set a pointer to the connector that will define this constraint.

◆ store()

virtual void agxPowerLine::ElementaryPhysicalDimensionConstraint::store ( agxStream::OutputArchive &  out) const
overridevirtual

Store this object to stream.

Reimplemented from agx::ElementaryConstraint.

Member Data Documentation

◆ m_connector

Connector* agxPowerLine::ElementaryPhysicalDimensionConstraint::m_connector
protected

Definition at line 96 of file PowerLineConstraints.h.


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