AGXDynamics  2.31.1.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
agx::WireContactBendConstraint Class Reference

#include <WireContactSolver.h>

+ Inheritance diagram for agx::WireContactBendConstraint:

Public Member Functions

 WireContactBendConstraint (WireParticle *bwp, WireParticle *mwp, WireParticle *ewp, Real radius, Real youngsModulus, size_t beginIndex)
 
bool addWireParticle (WireParticle *wp, size_t contactIndex)
 
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
 
void calculateD (Real timestep)
 
void calculateEpsilon (Real timestep)
 
void calculateInitialLambda (Real timestep)
 
virtual void calculateJacobian () override
 
virtual void calculateRHS (Real invTimestep, Real violation)
 
virtual void calculateViolation () override
 
Real getD () const
 
Real getEpsilon () const
 
size_t getFirstParticleGlobalIndex () const
 
Real getForceOnParticle (size_t globalIndex, Real timestep)
 
bool getHasBounds ()
 
Real getInvMass (size_t particleIndex)
 
bool getJacobian (size_t particleIndex, Real &G)
 
Real getLambda () const
 
Real getLowerBounds () const
 
Real getMass (size_t particleIndex)
 
WireParticleRefVector & getParticles ()
 
bool getReachedBounds ()
 
int getReferenceCount () const
 
Real getRHS () const
 
Real getUpperBounds () const
 
Real getViolation () const
 
template<typename T >
bool is () const
 Subclass test. More...
 
virtual void postCallback (Real)
 
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 setBounds (RangeReal bounds)
 
void setCompliance (Real compliance)
 
void setLambda (Real lambda)
 
void setReachedBounds (bool reached)
 
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...
 

Static Public Member Functions

template<typename T >
static bool ValidateCast (const Referenced *object)
 

Protected Member Functions

virtual ~WireContactBendConstraint ()
 
void allocateObserverVector () const
 
void deleteUsingDeleteHandler () const
 

Static Protected Member Functions

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

Real m_compliance
 
Real m_damping
 
size_t m_firstParticleGlobalIndex
 
bool m_hasBounds
 
RealVector m_jacobianVector
 
Mutex m_mutex
 
RealVector m_normalForces
 
ObserverContainer m_observers
 
WireParticleRefVector m_particles
 
AtomicValue m_refCount
 
Real m_rhs
 
Real m_violation
 

Detailed Description

Definition at line 349 of file WireContactSolver.h.

Constructor & Destructor Documentation

agx::WireContactBendConstraint::WireContactBendConstraint ( WireParticle *  bwp,
WireParticle *  mwp,
WireParticle *  ewp,
Real  radius,
Real  youngsModulus,
size_t  beginIndex 
)
inline
virtual agx::WireContactBendConstraint::~WireContactBendConstraint ( )
inlineprotectedvirtual

Definition at line 376 of file WireContactSolver.h.

Member Function Documentation

void agx::Referenced::allocateObserverVector ( ) const
protectedinherited
template<typename T >
T* agx::Referenced::as ( )
inherited

Subclass casting.

Template type must match actual type, dynamic_cast assertion will fail otherwise.

Referenced by agx::InternalData::get(), agxVehicle::Track::getNode(), and agx::InternalData::getOrCreate().

template<typename T >
const T* agx::Referenced::as ( ) const
inherited
template<typename T >
T* agx::Referenced::asSafe ( )
inherited

Safe subclass casting, return nullptr if template type does not match.

Referenced by agxUtil::CollectBodiesAndWiresVisitor::visit().

template<typename T >
const T* agx::Referenced::asSafe ( ) const
inherited
void agx::WireContactConstraint::calculateEpsilon ( Real  timestep)
inlineinherited
void agx::WireContactConstraint::calculateInitialLambda ( Real  timestep)
inlineinherited
virtual void agx::WireContactBendConstraint::calculateJacobian ( )
overridevirtual
virtual void agx::WireContactConstraint::calculateRHS ( Real  invTimestep,
Real  violation 
)
inlinevirtualinherited
virtual void agx::WireContactBendConstraint::calculateViolation ( )
overridevirtual
void agx::Referenced::deleteUsingDeleteHandler ( ) const
protectedinherited
Real agx::WireContactConstraint::getD ( ) const
inlineinherited

Definition at line 222 of file WireContactSolver.h.

static DeleteHandler* agx::Referenced::getDeleteHandler ( )
staticprotectedinherited
Returns
a DeleteHandler.
Real agx::WireContactConstraint::getEpsilon ( ) const
inlineinherited

Definition at line 221 of file WireContactSolver.h.

Referenced by agx::WireContactConstraint::calculateD().

size_t agx::WireContactConstraint::getFirstParticleGlobalIndex ( ) const
inlineinherited
Real agx::WireContactConstraint::getForceOnParticle ( size_t  globalIndex,
Real  timestep 
)
inlineinherited
bool agx::WireContactConstraint::getHasBounds ( )
inlineinherited

Definition at line 266 of file WireContactSolver.h.

References agx::WireContactConstraint::m_hasBounds.

Real agx::WireContactConstraint::getInvMass ( size_t  particleIndex)
inlineinherited
bool agx::WireContactConstraint::getJacobian ( size_t  particleIndex,
Real &  G 
)
inlineinherited
Real agx::WireContactConstraint::getLambda ( ) const
inlineinherited

Definition at line 219 of file WireContactSolver.h.

Real agx::WireContactConstraint::getLowerBounds ( ) const
inlineinherited

Definition at line 273 of file WireContactSolver.h.

Real agx::WireContactConstraint::getMass ( size_t  particleIndex)
inlineinherited
WireParticleRefVector& agx::WireContactConstraint::getParticles ( )
inlineinherited

Definition at line 252 of file WireContactSolver.h.

References agx::WireContactConstraint::m_particles.

bool agx::WireContactConstraint::getReachedBounds ( )
inlineinherited

Definition at line 226 of file WireContactSolver.h.

int agx::Referenced::getReferenceCount ( ) const
inherited
Returns
the number pointers currently referencing this object.
Real agx::WireContactConstraint::getRHS ( ) const
inlineinherited

Definition at line 205 of file WireContactSolver.h.

References agx::WireContactConstraint::m_rhs.

Real agx::WireContactConstraint::getUpperBounds ( ) const
inlineinherited

Definition at line 274 of file WireContactSolver.h.

Real agx::WireContactConstraint::getViolation ( ) const
inlineinherited

Definition at line 223 of file WireContactSolver.h.

References agx::WireContactConstraint::m_violation.

template<typename T >
bool agx::Referenced::is ( ) const
inherited
virtual void agx::WireContactConstraint::postCallback ( Real  )
inlinevirtualinherited

Reimplemented in agx::WireContactDistanceConstraint.

Definition at line 147 of file WireContactSolver.h.

void agx::Referenced::reference ( void *  ptr = nullptr) const
inherited

Explicitly increment the reference count by one, indicating that this object has another pointer which is referencing it.

This method should be used with care, always balanced with the same number of calls to unreference.

Referenced by agxData::Val< UInt >::Val().

void agx::WireContactConstraint::setBounds ( RangeReal  bounds)
inlineinherited
void agx::WireContactConstraint::setCompliance ( Real  compliance)
inlineinherited

Definition at line 276 of file WireContactSolver.h.

References agx::WireContactConstraint::m_compliance.

static void agx::Referenced::setDeleteHandler ( DeleteHandler *  handler)
staticprotectedinherited

Internal: Set a DeleteHandler to which deletion of all referenced counted objects will be delegated to.

void agx::WireContactConstraint::setLambda ( Real  lambda)
inlineinherited

Definition at line 220 of file WireContactSolver.h.

void agx::WireContactConstraint::setReachedBounds ( bool  reached)
inlineinherited

Definition at line 225 of file WireContactSolver.h.

void agx::Referenced::unreference ( void *  ptr = nullptr) const
inherited

Decrement the reference count by one, indicating that a pointer to this object is referencing it.

If the reference count goes to zero, it is assumed that this object is no longer referenced and is automatically deleted.

This method should be used with care, always balanced with the same number of calls to reference.

void agx::Referenced::unreference_nodelete ( ) const
inherited

Decrement the reference count by one, indicating that a pointer to this object is referencing it.

However, do not delete it, even if ref count goes to 0. Warning, unref_nodelete() should only be called if the user knows exactly who will be responsible for, one should prefer unref() over unref_nodelete() as the later can lead to memory leaks.

template<typename T >
static bool agx::Referenced::ValidateCast ( const Referenced *  object)
staticinherited

Member Data Documentation

Real agx::WireContactConstraint::m_damping
protectedinherited
bool agx::WireContactConstraint::m_hasBounds
protectedinherited
Mutex agx::Referenced::m_mutex
mutableprotectedinherited

Definition at line 240 of file Referenced.h.

RealVector agx::WireContactConstraint::m_normalForces
protectedinherited

Definition at line 284 of file WireContactSolver.h.

ObserverContainer agx::Referenced::m_observers
mutableprotectedinherited

Definition at line 239 of file Referenced.h.

AtomicValue agx::Referenced::m_refCount
mutableprotectedinherited

Definition at line 241 of file Referenced.h.

Real agx::WireContactConstraint::m_rhs
protectedinherited

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