Itasca C++ Interface
Loading...
Searching...
No Matches
Public Member Functions | Static Public Member Functions | List of all members
cmodelsxd::ContactModelMechanical Class Referenceabstract

Mechanical contact model implementation. More...

#include <contactmodelmechanical.h>

Inheritance diagram for cmodelsxd::ContactModelMechanical:
cmodelsxd::ContactModel

Public Member Functions

 ContactModelMechanical ()
 Constructor.
 
 ~ContactModelMechanical () override
 Destructor.
 
bool isOKToDelete () const override
 Generic implementation - by default it is always OK to delete a contact.
 
ContactModelgetContactModel () override
 Return the IContactModel pointer.
 
const ContactModelgetContactModel () const override
 Return the const IContactModel pointer.
 
virtual bool checkActivity (const double &)
 Default implementation - the contact is not active.
 
bool isSliding () const override
 Default implementation - the contact model is not sliding.
 
bool isBonded () const override
 Default implementation - the contact model is not bonded.
 
void unbond () override
 Default implementation - the contact model is not bonded.
 
bool hasNormal () const override
 Default implementation - the contact model has no normal.
 
DVect3 getNormal () const override
 Default implementation - the contact model normal is the 0 vector.
 
void setPorePressure (const double &) override
 Default implementation - throws an exception if contact model doesn't support it.
 
void propagateStateInformation (IContactModelMechanical *, const CAxes &n=CAxes(), const CAxes &l=CAxes()) override
 Default implementation - state information is not propagated.
 
virtual bool endPropertyUpdated (const QString &name, const IContactMechanical *c)=0
 
virtual bool validate (ContactModelMechanicalState *state, const double &timestep)=0
 Returns true if contact is valid. Must be implemented.
 
virtual bool forceDisplacementLaw (ContactModelMechanicalState *state, const double &timestep)=0
 
virtual bool thermalCoupling (ContactModelMechanicalState *, ContactModelThermalState *, IContactThermal *, const double &)
 Used for explicit mechanical/thermal coupling. Returns true if anything changed.
 
virtual DVect2 getTimestepLimits (ContactModelMechanicalState *, const double &) const
 
virtual DVect2 getEffectiveTranslationalStiffness () const
 Return the effective translational stiffness - used for timestep calculation.
 
virtual DAVect getEffectiveRotationalStiffness () const
 Return the effective rotational stiffness - used for timestep calculation.
 
void getSphereList (const IContact *, std::vector< DVect > *, std::vector< double > *, std::vector< double > *) override
 Default implementation so that no sphere list must be defined.
 
void getCylinderList (const IContact *, std::vector< DVect > *, std::vector< DVect > *, std::vector< double > *, std::vector< double > *, std::vector< double > *) override
 Default implementation so that no cylinder list must be defined.
 
virtual DVect getForce (const IContactMechanical *) const
 Return the total force that the contact model holds.
 
virtual DAVect getMomentOn1 (const IContactMechanical *) const
 Return the total moment on 1 that the contact model holds.
 
virtual DAVect getMomentOn2 (const IContactMechanical *c) const
 Return the total moment on 2 that the contact model holds.
 
ContactModelMechanicalclone () const override
 Make a clone of this contact model. Must be implemeted.
 
- Public Member Functions inherited from cmodelsxd::ContactModel
 ContactModel ()
 Constructor.
 
virtual ~ContactModel ()
 Destructor.
 
virtual void archive (ArchiveStream &)
 Used for save/restore. Important to implement.
 
virtual void copy (const ContactModel *cm)
 Copy the contact model from cm. Must be overridden in derived classes.
 
IContactModel * getContactModel () override
 Return the IContactModel pointer.
 
const IContactModel * getContactModel () const override
 Return the const IContactModel pointer.
 
QString getName () const override=0
 
virtual QString getPluginName () const
 By default, the plugin name is the contact model name. Must be implemented in derived class.
 
QString getProperties () const override=0
 Returns a comma delimited string that lists the contact model properies. Must be implemented in derived classes.
 
QVariant getProperty (uint i, const IContact *con=0) const override=0
 
bool getPropertyGlobal (uint) const override
 
int isProperty (const QString &c, Qt::CaseSensitivity cs=Qt::CaseInsensitive) const override
 
bool setProperty (uint i, const QVariant &v, IContact *con=0) override=0
 
bool getPropertyReadOnly (uint) const override
 
bool supportsInheritance (uint) const override
 
bool getInheritance (uint) const override
 
void setInheritance (uint, bool) override
 
QString getMethods () const override
 
int isMethod (const QString &c, Qt::CaseSensitivity cs=Qt::CaseInsensitive) const override
 Processing of a methods based on the method list returned by getMehtods.
 
QString getMethodArguments (uint) const override
 Default implementation so that no methods must be defined.
 
bool setMethod (uint, const QVector< QVariant > &, IContact *c=0) override
 By default, no methods must be defined.
 
QString getEnergies () const override
 Default implementation so that no energies must be defined.
 
int isEnergy (const QString &c, Qt::CaseSensitivity cs=Qt::CaseInsensitive) const override
 Default implementation so that no energies must be defined.
 
double getEnergy (uint) const override
 Default implementation so that no energies must be defined.
 
bool getEnergyAccumulate (uint) const override
 Default implementation so that no energies must be defined.
 
void setEnergy (uint, const double &) override
 Default implementation so that no energies must be defined.
 
void activateEnergy () override
 Default implementation so that no energies must be defined.
 
virtual bool getEnergyActivated () const
 Default implementation so that no energies must be defined.
 
uint getMinorVersion () const override=0
 
void destroy () override
 
virtual QString getFishCallEvents () const
 Return a comma delimited liest of FISH callback events.
 
void setEventVal (int i, int j)
 Set the order of the contact model events as stored in the ContactModelList.
 
void setFromParent (const ContactModel *cm)
 For executing events within the contact model.
 
void setNonForcePropsFrom (IContactModel *) override
 
uint getPropertyIndex (const QString &name, Qt::CaseSensitivity cs=Qt::CaseInsensitive) const
 
QString getPropertyName (uint index) const
 Utility function that returns the property name given it's index.
 
void * operator new (size_t size)
 
void * operator new (size_t size, const char *file, unsigned line)
 
void operator delete (void *v)
 
void operator delete (void *v, const char *file, unsigned line)
 

Static Public Member Functions

static const char * getPluginPrefix ()
 Prefix for this type of plugin.
 
static const char * getPluginDirectory ()
 Directory for this type of plugin.
 
- Static Public Member Functions inherited from cmodelsxd::ContactModel
static uint32 getMajorVersion ()
 
static AllocFunctions setAllocFunctions (AllocFunctions afunc)
 
static AllocFunctions getDefaultAllocFunctions ()
 
static AllocFunctions getAllocFunctions ()
 

Additional Inherited Members

- Public Types inherited from cmodelsxd::ContactModel
typedef void *(* NewFunction) (size_t, const char *, unsigned)
 
typedef void(* DeleteFunction) (void *, const char *, unsigned)
 
typedef std::pair< NewFunction, DeleteFunction > AllocFunctions
 
- Protected Attributes inherited from cmodelsxd::ContactModel
FArray< int, 5 > cmEvents_
 Set of events as defined in a specified order. The int refers to the location of the event in the ContactModelMechanicalList.
 
- Static Protected Attributes inherited from cmodelsxd::ContactModel
static NewFunction newFunc_ = defaultNewFunction
 
static DeleteFunction deleteFunc_ = defaultDeleteFunction
 

Detailed Description

Mechanical contact model implementation.

Member Function Documentation

◆ clone()

ContactModelMechanical * cmodelsxd::ContactModelMechanical::clone ( ) const
inlineoverridevirtual

Make a clone of this contact model. Must be implemeted.

Implements cmodelsxd::ContactModel.

◆ endPropertyUpdated()

virtual bool cmodelsxd::ContactModelMechanical::endPropertyUpdated ( const QString & name,
const IContactMechanical * c )
pure virtual

Returns true if the property was actually updated in the contact model. Used for inheritance of properties from piece. Must be implemented.

◆ forceDisplacementLaw()

virtual bool cmodelsxd::ContactModelMechanical::forceDisplacementLaw ( ContactModelMechanicalState * state,
const double & timestep )
pure virtual

Updates force acting on end2 and moments acting on end1 and end2. Returns true if contact is active. Must be implemented.

◆ getCylinderList()

void cmodelsxd::ContactModelMechanical::getCylinderList ( const IContact * ,
std::vector< DVect > * ,
std::vector< DVect > * ,
std::vector< double > * ,
std::vector< double > * ,
std::vector< double > *  )
inlineoverridevirtual

Default implementation so that no cylinder list must be defined.

Implements cmodelsxd::ContactModel.

◆ getSphereList()

void cmodelsxd::ContactModelMechanical::getSphereList ( const IContact * ,
std::vector< DVect > * ,
std::vector< double > * ,
std::vector< double > *  )
inlineoverridevirtual

Default implementation so that no sphere list must be defined.

Implements cmodelsxd::ContactModel.

◆ getTimestepLimits()

virtual DVect2 cmodelsxd::ContactModelMechanical::getTimestepLimits ( ContactModelMechanicalState * ,
const double &  ) const
inlinevirtual

Returns timestep limits (defaults to (0.0,infinity)). These are further timestep restrictions that the contact model can place on the simulation, over and above those implied by stiffness.

◆ isOKToDelete()

bool cmodelsxd::ContactModelMechanical::isOKToDelete ( ) const
inlineoverridevirtual

Generic implementation - by default it is always OK to delete a contact.

Reimplemented from cmodelsxd::ContactModel.


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