mbsim 4.0.0 MBSim Kernel

Public Member Functions | Public Attributes | Protected Types | Protected Attributes | Friends | List of all members
MBSim::SingleContact Class Reference

class for contacts More...

`#include <single_contact.h>`

Inheritance diagram for MBSim::SingleContact:
[legend]

## Public Member Functions

| SingleContact (const std::string &name="")
| constructor More...
void | resetUpToDate () override
bool | isSticking () const
const double & | evalGeneralizedNormalForce ()
const fmatvec::VecV & | evalGeneralizedTangentialForce ()
double & | getGeneralizedNormalForce (bool check=true)
const double & | evallaN ()
const fmatvec::Vec & | evallaT ()
const double & | evalLaN ()
const fmatvec::Vec & | evalLaT ()
const double & | evalgdnN ()
const fmatvec::Vec & | evalgdnT ()
const double & | evalgddN ()
const fmatvec::Vec & | evalgddT ()
void | updateGeneralizedNormalForce ()
void | updateGeneralizedTangentialForce ()
void | updateGeneralizedNormalForceS ()
void | updateGeneralizedNormalForceM ()
void | updateGeneralizedNormalForceP ()
void | updateGeneralizedTangentialForceS ()
void | updateGeneralizedTangentialForceM ()
void | updateGeneralizedTangentialForce0 ()
void | updateGeneralizedForces () override
void | updateGeneralizedPositions () override
void | updateGeneralizedVelocities () override
void | updatePositions (Frame *frame) override
void | updateg () override
void | updategd () override
void | updateh (int i=0) override
void | updateW (int i=0) override
void | updateV (int i=0) override
void | updatewb () override
void | updateStopVector () override
void | updateStopVectorParameters () override
void | updatelaRef (fmatvec::Vec &ref) override
| references to contact force parameter of dynamic system parent
void | updateLaRef (fmatvec::Vec &ref) override
| references to contact force parameter of dynamic system parent
void | updategdRef (fmatvec::Vec &ref) override
| references to contact relative velocities of dynamic system parent
void | calcSize () override
void | calclaSize (int j) override
| calculates size of contact force parameters
void | calcgSize (int j) override
| calculates size of relative distances
void | calcgdSize (int j) override
| calculates size of gap velocities More...
void | calcrFactorSize (int j) override
| calculates size of rfactors
void | calcsvSize () override
| calculates size of stopvector (root function for event driven integration)
void | calcLinkStatusSize () override
| calculates size of vector LinkStatus
void | calcLinkStatusRegSize () override
| calculates size of vector LinkStatusReg
void | init (InitStage stage, const InitConfigSet &config) override
| plots time series header More...
bool | isSetValued () const override
| asks the link if it contains force laws that contribute to the lagrange multiplier and is therefore set valued More...
bool | isSingleValued () const override
| asks the link if it contains single valued force laws that contribute to the right-hand side vector h More...
void | updateLinkStatus () override
void | updateLinkStatusReg () override
bool | isActive () const override
bool | gActiveChanged () override
bool | detectImpact () override
void | solveImpactsFixpointSingle () override
void | solveConstraintsFixpointSingle () override
void | solveImpactsGaussSeidel () override
void | solveConstraintsGaussSeidel () override
void | solveImpactsRootFinding () override
void | solveConstraintsRootFinding () override
void | jacobianConstraints () override
| computes JACOBIAN and mass action matrix of nonlinear contact equations
void | jacobianImpacts () override
| computes JACOBIAN and mass action matrix of nonlinear contact equations on velocity level
void | updaterFactors () override
| update relaxation factors for contact equations
void | checkConstraintsForTermination () override
| verify underlying force laws concerning given tolerances
void | checkImpactsForTermination () override
| verify underlying force laws on velocity level concerning given tolerances
void | checkActive (int j) override
| check if set-valued contacts are active and set corresponding attributes More...
void | LinearImpactEstimation (double t, fmatvec::Vec &gInActive_, fmatvec::Vec &gdInActive_, int *IndInActive_, fmatvec::Vec &gAct_, int *IndActive_) override
| get gap distance and calculate gap velocity of unilateral links to estimate impacts within the next step More...
void | SizeLinearImpactEstimation (int *sizeInActive_, int *sizeActive_) override
| calculates the number of active and inactive unilateral constraints and increments sizeActive/sizeInActive
void | setNormalForceLaw (GeneralizedForceLaw *fcl_)
GeneralizedForceLaw * | getNormalForceLaw () const
void | setNormalImpactLaw (GeneralizedImpactLaw *fnil_)
void | setTangentialForceLaw (FrictionForceLaw *fdf_)
FrictionForceLaw * | getTangentialForceLaw () const
void | setTangentialImpactLaw (FrictionImpactLaw *ftil_)
virtual int | getFrictionDirections () const
void | calccorrSize (int j) override
void | updatecorr (int j) override
void | checkRoot () override
bool | isNormalForceLawSetValued () const
bool | isTangentialForceLawSetValued () const
bool | isNormalForceLawSetValuedAndActive () const
bool | isTangentialForceLawSetValuedAndActive () const
Public Member Functions inherited from MBSim::ContourLink
| ContourLink (const std::string &name)
| constructor More...
| ~ContourLink () override
| destructor
void | updateWRef (fmatvec::Mat &ref, int i=0) override
| references to contact force direction matrix of dynamic system parent
void | updateVRef (fmatvec::Mat &ref, int i=0) override
| references to condensed contact force direction matrix of dynamic system parent
void | updatehRef (fmatvec::Vec &hRef, int i=0) override
| references to complete and link smooth force vector of dynamic system parent
virtual void | updatedhdqRef (fmatvec::Mat &ref, int i=0)
virtual void | updatedhduRef (fmatvec::SqrMat &ref, int i=0)
virtual void | updatedhdtRef (fmatvec::Vec &ref, int i=0)
void | updaterRef (fmatvec::Vec &ref, int i=0) override
| references to nonsmooth force vector of dynamic system parent
void | connect (Contour *contour0, Contour *contour1)
Contour * | getContour (int i)
ContourFrame * | getContourFrame (int i)
void | updateForce () override
void | updateMoment () override
void | updateForceDirections () override
const fmatvec::Mat3xV & | evalGlobalForceDirection ()
const fmatvec::Mat3xV & | evalGlobalMomentDirection ()
void | initializeUsingXML (xercesc::DOMElement *element) override
Public Member Functions inherited from MBSim::MechanicalLink
| MechanicalLink (const std::string &name)
| constructor More...
virtual void | updatePositions ()
virtual void | updateVelocities ()
virtual void | updatelaF ()
virtual void | updatelaM ()
virtual void | updateR ()
const fmatvec::Vec3 & | evalForce (int i=1)
const fmatvec::Vec3 & | evalMoment (int i=1)
const fmatvec::Mat3xV & | evalRF (int i=1)
const fmatvec::Mat3xV & | evalRM (int i=1)
const fmatvec::VecV & | evallaF ()
const fmatvec::VecV & | evallaM ()
fmatvec::Vec3 & | getForce (int i=1, bool check=true)
fmatvec::Vec3 & | getMoment (int i=1, bool check=true)
Frame * | getPointOfApplication (int i)
int | getNumberOfForces ()
void | plot () override
| plots time dependent data More...
Public Member Functions inherited from MBSim::Link
| Link (const std::string &name)
| constructor More...
int | getGeneralizedRelativePositionSize ()
int | getGeneralizedRelativeVelocitySize ()
int | getGeneralizedForceSize ()
virtual void | updater (int i=0)
virtual void | updateJrla (int i=0)
virtual void | updateJacobians (int j=0)
virtual void | updateb ()
virtual void | updatedx ()
virtual void | updatexd ()
virtual void | calcxSize ()
const fmatvec::Vec & | getx () const
fmatvec::Vec & | getx ()
const fmatvec::Vec & | getxd (bool check=true) const
fmatvec::Vec & | getxd (bool check=true)
int | getxInd ()
virtual void | setxInd (int xInd_)
int | getxSize () const
virtual void | updatexRef (fmatvec::Vec &ref)
virtual void | updatexdRef (fmatvec::Vec &ref)
virtual void | updatedxRef (fmatvec::Vec &ref)
virtual void | updatebRef (fmatvec::Mat &hRef)
virtual void | initz ()
virtual void | writez (H5::GroupBase *group)
virtual void | readz0 (H5::GroupBase *group)
virtual void | setbInd (int bInd_)
virtual void | updateJrlaRef (fmatvec::Mat &ref, int i=0)
virtual void | updatewbRef (fmatvec::Vec &ref)
| references to TODO of dynamic system parent
virtual void | deletelaRef ()
| delete reference to contact force parameter of dynamic system parent
virtual void | updateInternalStateRef (fmatvec::Vec &cur, fmatvec::Vec &next)
| references to internal state of dynamic system parent
virtual void | updategRef (fmatvec::Vec &ref)
| references to contact relative distances of dynamic system parent
virtual void | updateresRef (fmatvec::Vec &ref)
| references to residuum of nonlinear contact equations of dynamic system parent
virtual void | updaterFactorRef (fmatvec::Vec &ref)
| references to rfactors of dynamic system parent
virtual void | updatesvRef (fmatvec::Vec &sv)
| references to stopvector of dynamic system parent (root function for event driven integration)
virtual void | updatejsvRef (fmatvec::VecInt &jsvParent)
| references to stopvector evaluation of dynamic system parent (root detection with corresponding bool array by event driven integrator)
virtual void | updateLinkStatusRef (fmatvec::VecInt &LinkStatusParent)
| reference to vector of link status (for set valued links with piecewise link equations)
virtual void | updateLinkStatusRegRef (fmatvec::VecInt &LinkStatusRegParent)
| reference to vector of link status (for single-valued links)
int | getisInd ()
int | getisSize ()
virtual void | calcisSize ()
virtual void | aboutToUpdateInternalState ()
virtual void | postprocessing ()
virtual void | calcbSize ()
| calculates size of rfactors
virtual void | setGeneralizedForceTolerance (double tol)
virtual void | setGeneralizedImpulseTolerance (double tol)
virtual void | setGeneralizedRelativePositionTolerance (double tol)
virtual void | setGeneralizedRelativeVelocityTolerance (double tol)
virtual void | setGeneralizedRelativeAccelerationTolerance (double tol)
virtual void | setGeneralizedRelativePositionCorrectionValue (double corr)
virtual void | setGeneralizedRelativeVelocityCorrectionValue (double corr)
virtual void | setrMax (double rMax_)
virtual void | setLinkStatusInd (int LinkStatusInd_)
virtual void | setLinkStatusRegInd (int LinkStatusRegInd_)
virtual void | setlaInd (int laInd_)
virtual void | setisInd (int isInd_)
virtual void | setgInd (int gInd_)
virtual void | setgdInd (int gdInd_)
virtual void | setrFactorInd (int rFactorInd_)
virtual void | updatecorrRef (fmatvec::Vec &ref)
virtual void | setcorrInd (int corrInd_)
void | setx (const fmatvec::Vec &x_)
virtual void | setsvInd (int svInd_)
int | getsvSize () const
int | getLinkStatusSize () const
int | getLinkStatusRegSize () const
const fmatvec::Vec & | getla (bool check=true) const
const fmatvec::Vec & | getLa (bool check=true) const
fmatvec::Vec & | getla (bool check=true)
fmatvec::Vec & | getLa (bool check=true)
fmatvec::Vec & | getwb (bool check=true)
int | getlaInd () const
int | getlaSize () const
int | getbSize () const
const fmatvec::Vec & | evalg ()
const fmatvec::Vec & | evalgd ()
const fmatvec::Vec & | evalla ()
const fmatvec::Vec & | evalLa ()
const fmatvec::Vec & | evalwb ()
const fmatvec::Vec & | evalxd ()
int | getgdInd () const
int | getgSize () const
int | getgdSize () const
int | getrFactorSize () const
const fmatvec::VecInt & | getrFactorUnsure () const
const fmatvec::VecV & | evalGeneralizedRelativePosition ()
const fmatvec::VecV & | evalGeneralizedRelativeVelocity ()
const fmatvec::VecV & | evalGeneralizedForce ()
fmatvec::VecV & | getGeneralizedRelativePosition (bool check=true)
fmatvec::VecV & | getGeneralizedRelativeVelocity (bool check=true)
fmatvec::VecV & | getGeneralizedForce (bool check=true)
void | savela ()
| saves contact forces for use as starting value in next time step
void | saveLa ()
| saves contact impulses for use as starting value in next time step
void | initla ()
| load contact forces for use as starting value
void | initLa ()
| load contact impulses for use as starting value
void | decreaserFactors ()
| decrease rfactor if mass action matrix is not diagonal dominant (cf. Foerg: Dissertation, page 80 et seq.)
int | getcorrSize () const
bool | getUpdaterrel () const
void | createPlotGroup () override
| creates the plotGroup for H5-output
Public Member Functions inherited from MBSim::Element
| Element (const std::string &name)
| constructor
| ~Element () override=default
| destructor
void | throwError (const std::string &msg) const
virtual void | setDynamicSystemSolver (DynamicSystemSolver *sys)
| sets the used dynamics system solver to the element More...
virtual void | plotAtSpecialEvent ()
| plots time dependent data at special events More...
const std::string & | getName () const
void | setName (const std::string &str)
void | setPath (const std::string &str)
DynamicSystemSolver * | getDynamicSystemSolver ()
H5::GroupBase * | getPlotGroup ()
virtual H5::GroupBase * | getFramesPlotGroup ()
virtual H5::GroupBase * | getContoursPlotGroup ()
virtual H5::GroupBase * | getGroupsPlotGroup ()
virtual H5::GroupBase * | getObjectsPlotGroup ()
virtual H5::GroupBase * | getLinksPlotGroup ()
virtual H5::GroupBase * | getConstraintsPlotGroup ()
virtual H5::GroupBase * | getObserversPlotGroup ()
bool | getPlotFeature (const PlotFeatureEnum &pf)
virtual void | setPlotFeature (const PlotFeatureEnum &pf, bool value)
| Set a plot feature. More...
void | setPlotFeatureForChildren (const PlotFeatureEnum &pf, bool value)
| Set a plot feature for the children of this object. More...
void | setPlotFeatureRecursive (const PlotFeatureEnum &pf, bool value)
| Set a plot feature for this object and the children of this object. More...
template<class T >
void | setPlotAttribute (const std::string &name, const T &value)
| Set a plot attribute: static data attached as key/value pairs to the plot datasets/groups.
void | setPlotAttribute (const std::string &name)
template<class T >
T * | getByPath (const std::string &path, bool initialCaller=true) const
| Get the object of type T represented by the path path. Do not set any argurment other than path!
std::string | getPath (const Element *relTo=nullptr, std::string sep="/") const
| Return the path of this object. If relativeTo is not NULL return a relative path to relativeTo. Do not set any argurment other than relTo and sep!
virtual Element * | getChildByContainerAndName (const std::string &container, const std::string &name) const
| Get the Element named name in the container named container.
virtual std::shared_ptr< OpenMBV::Group > | getOpenMBVGrp ()
virtual std::shared_ptr< OpenMBV::Group > | getFramesOpenMBVGrp ()
virtual std::shared_ptr< OpenMBV::Group > | getContoursOpenMBVGrp ()
virtual std::shared_ptr< OpenMBV::Group > | getGroupsOpenMBVGrp ()
virtual std::shared_ptr< OpenMBV::Group > | getObjectsOpenMBVGrp ()
virtual std::shared_ptr< OpenMBV::Group > | getLinksOpenMBVGrp ()
virtual std::shared_ptr< OpenMBV::Group > | getConstraintsOpenMBVGrp ()
virtual std::shared_ptr< OpenMBV::Group > | getObserversOpenMBVGrp ()
virtual Element * | getParent ()
virtual const Element * | getParent () const
virtual void | setParent (Element *parent_)
std::vector< Element * > | getDependencies () const
| checks dependency on other elements. More...
void | addDependency (Element *ele)
int | computeLevel ()
| computes the length of the pathes in the graph that represents the dependencies between all elements. More...
virtual void | updateVelocities (Frame *frame)
virtual void | updateAccelerations (Frame *frame)
virtual void | updateJacobians (Frame *frame, int j=0)
virtual void | updateGyroscopicAccelerations (Frame *frame)
const double & | getTime () const
double | getStepSize () const
const MBXMLUtils::DOMEvalException & | getDOMEvalError () const

## Public Attributes

void(SingleContact::* | updateGeneralizedNormalForce_ )()
void(SingleContact::* | updateGeneralizedTangentialForce_ )()

## Protected Types

enum | Direction { normal, tangential, DirectionDIM }

## Protected Attributes

GeneralizedForceLaw * | fcl {nullptr}
| force laws in normal and tangential direction on acceleration and velocity level
FrictionForceLaw * | fdf {nullptr}
| force law defining relation between tangential velocities and tangential forces
GeneralizedImpactLaw * | fnil {nullptr}
| force law defining relation between penetration velocity and resulting normal impulses
FrictionImpactLaw * | ftil {nullptr}
| force law defining relation between tangential velocities and forces impulses
fmatvec::Vec | laN
| force in normal direction More...
fmatvec::Vec | LaN
fmatvec::Vec | laT
| force in tangential direction More...
fmatvec::Vec | LaT
fmatvec::Vec | gdN
| relative velocity in normal direction More...
fmatvec::Vec | gdT
| relative velocity in tangential direction More...
unsigned int | gActive {0}
| boolean flag symbolising activity of contact on position level with possibility to save previous time step
unsigned int | gActive0 {0}
std::array< unsigned int, DirectionDIM > | gdActive
| boolean flag symbolising activity of contact on velocity level More...
std::array< unsigned int, DirectionDIM > | gddActive
| boolean flag symbolising activity of contact on acceleration level More...
fmatvec::Vec | gdnN
| new gap velocity after an impact for event driven scheme
fmatvec::Vec | gdnT
fmatvec::Vec | gddN
| gap acceleration for event driven scheme on acceleration level
fmatvec::Vec | gddT
double | lambdaN
fmatvec::VecV | lambdaT
bool | updlaN {true}
bool | updlaT {true}
fmatvec::Vec | gdTDir
int | rootID {0}
| type of detected root More...
Protected Attributes inherited from MBSim::ContourLink
fmatvec::Vec3 | WrP0P1
| difference vector of position, velocity and angular velocity
fmatvec::Vec3 | WvP0P1
fmatvec::Vec3 | WomK0K1
fmatvec::Mat3xV | DF
fmatvec::Mat3xV | DM
std::vector< Contour * > | contour
std::vector< ContourFrame * > | cFrame
bool | updDF
Protected Attributes inherited from MBSim::MechanicalLink
std::vector< Frame * > | P
std::vector< fmatvec::Mat3xV > | RF
std::vector< fmatvec::Mat3xV > | RM
fmatvec::VecV | lambdaF
fmatvec::VecV | lambdaM
std::vector< fmatvec::Vec3 > | F
std::vector< fmatvec::Vec3 > | M
fmatvec::RangeV | iF
| indices of forces and torques
fmatvec::RangeV | iM
bool | updF
bool | updM
bool | updRMV
bool | updlaF
bool | updlaM
Protected Attributes inherited from MBSim::Link
int | ng
int | ngd
int | nla
fmatvec::Vec | x
| order one parameters
fmatvec::Vec | xd
| differentiated order one parameters
fmatvec::Vec | dx
fmatvec::Vec | x0
| order one initial value
int | xSize
| size and local index of order one parameters
int | xInd
fmatvec::Vec | sv
| stop vector for event driven integration (root function)
fmatvec::VecInt | jsv
| evaluation of roots of stop vector with a boolean vector
int | svSize
| size and local index of stop vector
int | svInd
fmatvec::VecInt | LinkStatus
| status of link (default 0) describing which piece of the equation is valid (e.g. stick or slip) More...
int | LinkStatusSize
| size and local index of link status vector (set-valued)
int | LinkStatusInd
fmatvec::VecInt | LinkStatusReg
| status of link More...
int | LinkStatusRegSize
| size and local index of single-valued link status vector
int | LinkStatusRegInd
fmatvec::Vec | curis
fmatvec::Vec | nextis
fmatvec::Vec | g
| relative position, relative velocity, contact force and impact parameters
fmatvec::Vec | gd
fmatvec::Vec | la
fmatvec::Vec | La
fmatvec::Vec | laS
| contact forces of smooth contact laws
int | isSize
int | isInd
int | gSize
| size and local index of relative distances
int | gInd
int | gdSize
| size and local index of relative velocities
int | gdInd
int | laSize
| size and local index of contact force parameters
int | laInd
int | bSize
| size and local index of contact force parameters
int | bInd
fmatvec::RangeV | Ig
| local index of relative distances and contact force parameters
fmatvec::RangeV | Ila
double | gTol
| tolerance for relative position, relative velocity, relative acceleration, force and impact
double | gdTol
double | gddTol
double | laTol
double | LaTol
double | gCorr
| correction factor for relative position and relative velocity
double | gdCorr
fmatvec::Vec | la0
| attribute to save contact force parameter of previous time step
fmatvec::Vec | La0
fmatvec::Vec | rFactor
| vector of rfactors for relaxation of contact equations
fmatvec::VecInt | rFactorUnsure
| boolean vector defining if rfactor belongs to not diagonal dominant mass action matrix (cf. Foerg Dissertation, page 80 et seq.)
int | rFactorSize
| size and local index of rfactors
int | rFactorInd
double | rMax
| maximum r-factor
fmatvec::Vec | res
std::vector< fmatvec::Mat > | W [2]
| force direction matrix for nonsmooth right hand side
std::vector< fmatvec::Mat > | V [2]
| reduced force direction matrix for nonsmooth right hand side
std::vector< fmatvec::Vec > | h [2]
| smooth complete and link right hand side
std::vector< fmatvec::Mat > | dhdq
| smooth Jacobians for implicit integration
std::vector< fmatvec::Mat > | dhdu
std::vector< fmatvec::Vec > | dhdt
std::vector< fmatvec::Vec > | r [2]
| nonsmooth right hand side
std::vector< fmatvec::Mat > | Jrla [2]
| Jacobian dr/dla.
fmatvec::Vec | wb
| TODO.
fmatvec::Mat | b
| TODO.
int | corrSize
int | corrInd
fmatvec::Vec | corr
fmatvec::VecV | rrel
fmatvec::VecV | vrel
fmatvec::VecV | lambda
bool | updSize
bool | updrrel
bool | updvrel
bool | updla
Protected Attributes inherited from MBSim::Element
Element * | parent
std::string | name
| name of element
std::string | path
| The path of this object. Is set during the init stage reorganizeHierarchy. Before this the path is calculated dynamically using getPath() after this stage getPath just returns this value.
MBXMLUtils::DOMEvalException | domEvalError
| Special XML helper variable.
DynamicSystemSolver * | ds
| dynamic system
H5::VectorSerie< double > * | plotVectorSerie
| time series
std::vector< double > | plotVector
| one entry of time series
std::vector< std::string > | plotColumns
| columns of time series
H5::GroupBase * | plotGroup
| associated plot group
std::vector< Element * > | dependency
| vector containing all dependencies.
PlotFeatureMap | plotFeature
| plot feature
PlotFeatureMap | plotFeatureForChildren
std::map< std::string, std::variant< std::monostate, int, double, std::string, std::vector< int >, std::vector< double >, std::vector< std::vector< double > > > > | plotAttribute

## Friends

class | Contact
class | MaxwellContact

## Additional Inherited Members

Public Types inherited from MBSim::Element
enum | InitStage { resolveStringRef =0, preInit, plotting, unknownStage, LASTINITSTAGE }
| The stages of the initialization. More...
Protected Member Functions inherited from MBSim::Element
void | updatePlotFeatures ()
void | addToPlot (const std::string &name)
void | addToPlot (const std::string &name, int size)
void | addToPlot (const std::string &name, const std::vector< std::string > &iname)
template<class AT >
void | plot (const AT &x)
template<class Type , class AT >
void | plot (const fmatvec::Vector< Type, AT > &x)

## Detailed Description

class for contacts

Author
  Martin Foerg

Date
  2009-04-02 some comments (Thorsten Schindler)
  2009-07-16 splitted link / object right hand side (Thorsten Schindler)
  2009-08-03 contacts can now visualize their ContactPointFrames (Markus Schneider)
  2010-07-06 added LinkStatus and LinearImpactEstimation for timestepper ssc (Robert Huber)
  2012-05-08 added LinkStatusReg for AutoTimeSteppingSSCIntegrator (Jan Clauberg)
  2014-09-16 contact forces are calculated on acceleration level (Thorsten Schindler)

basic class for contacts between contours, mainly implementing geometrical informations of contact-pairings

Remarks:

- constitutive laws on acceleration and velocity level have to be set pairwise

## Constructor & Destructor Documentation

## ◆ SingleContact()

MBSim::SingleContact::SingleContact | ( | const std::string & | name = `""` | ) |

inline

constructor

Parameters

  name | of contact

## Member Function Documentation

## ◆ calcgdSize()

void MBSim::SingleContact::calcgdSize | ( | int | j | ) |

override virtual

calculates size of gap velocities

Parameters

  flag | to decide which contacts are included in the calculation

see SingleContact for the implementation and DynamicSystem for explanation

Reimplemented from MBSim::Link.

## ◆ checkActive()

void MBSim::SingleContact::checkActive | ( | int | j | ) |

override virtual

check if set-valued contacts are active and set corresponding attributes

Parameters

  flag | to decide which criteria are used to define 'activity'

see SingleContact for the implementation and DynamicSystem for explanation

Reimplemented from MBSim::Link.

## ◆ detectImpact()

bool MBSim::SingleContact::detectImpact | ( |  | ) |

override virtual

Returns
  has an impact occured?

Reimplemented from MBSim::Link.

## ◆ gActiveChanged()

bool MBSim::SingleContact::gActiveChanged | ( |  | ) |

override virtual

Returns
  has the relative distance vector changed?

Implements MBSim::Link.

## ◆ getFrictionDirections()

int MBSim::SingleContact::getFrictionDirections | ( |  | ) | const

virtual

Returns
  number of considered friction directions

## ◆ init()

void MBSim::SingleContact::init | ( | InitStage | stage,
|  | const InitConfigSet & | config
| ) |  |

override virtual

plots time series header

Parameters

  invocing | parent class

Reimplemented from MBSim::ContourLink.

## ◆ isActive()

bool MBSim::SingleContact::isActive | ( |  | ) | const

override virtual

Returns
  are link equations active?

Implements MBSim::Link.

## ◆ isSetValued()

bool MBSim::SingleContact::isSetValued | ( |  | ) | const

override virtual

asks the link if it contains force laws that contribute to the lagrange multiplier and is therefore set valued

Returns
  set valued force laws used within the link?

Reimplemented from MBSim::Link.

## ◆ isSingleValued()

bool MBSim::SingleContact::isSingleValued | ( |  | ) | const

override virtual

asks the link if it contains single valued force laws that contribute to the right-hand side vector h

Returns
  single valued force laws used within link?

Reimplemented from MBSim::Link.

## ◆ LinearImpactEstimation()

void MBSim::SingleContact::LinearImpactEstimation | ( | double | t,
|  | fmatvec::Vec & | gInActive_,
|  | fmatvec::Vec & | gdInActive_,
|  | int * | IndInActive_,
|  | fmatvec::Vec & | gAct_,
|  | int * | IndActive_
| ) |  |

override virtual

get gap distance and calculate gap velocity of unilateral links to estimate impacts within the next step

Parameters

  gInActive | gap distance of inactive links (return)
  gdInActive | gap velocities of inactive links (return)
  IndInActive | index for gInActive/gdInActive; incremented with size after storage (return and input)
  gAct | gap distance of active links (return)
  IndActive | index for gActive; incremented with size after storage (return and input)

Reimplemented from MBSim::Link.

## ◆ solveConstraintsFixpointSingle()

void MBSim::SingleContact::solveConstraintsFixpointSingle | ( |  | ) |

override virtual

solve contact equations of motion with single step fixed point scheme

Reimplemented from MBSim::Link.

## ◆ solveConstraintsGaussSeidel()

void MBSim::SingleContact::solveConstraintsGaussSeidel | ( |  | ) |

override virtual

solve contact equations of motion with Gauss-Seidel scheme

Reimplemented from MBSim::Link.

## ◆ solveConstraintsRootFinding()

void MBSim::SingleContact::solveConstraintsRootFinding | ( |  | ) |

override virtual

solve contact equations of motion with Newton scheme

Reimplemented from MBSim::Link.

## ◆ solveImpactsFixpointSingle()

void MBSim::SingleContact::solveImpactsFixpointSingle | ( |  | ) |

override virtual

solve impact equations of motion with single step fixed point scheme on velocity level

Parameters

  time | step-size

Reimplemented from MBSim::Link.

## ◆ solveImpactsGaussSeidel()

void MBSim::SingleContact::solveImpactsGaussSeidel | ( |  | ) |

override virtual

solve impact equations of motion with Gauss-Seidel scheme on velocity level

Parameters

  time | step-size

Reimplemented from MBSim::Link.

## ◆ solveImpactsRootFinding()

void MBSim::SingleContact::solveImpactsRootFinding | ( |  | ) |

override virtual

solve impact equations of motion with Newton scheme on velocity level

Parameters

  time | step-size

Reimplemented from MBSim::Link.

## Member Data Documentation

## ◆ gdActive

std::array<unsigned int, DirectionDIM> MBSim::SingleContact::gdActive

protected

boolean flag symbolising activity of contact on velocity level

gdActive[normal] = normal direction; gdActive[tangential] = tangential direction

## ◆ gddActive

std::array<unsigned int, DirectionDIM> MBSim::SingleContact::gddActive

protected

boolean flag symbolising activity of contact on acceleration level

gddActive[normal] = normal direction; gddActive[tangential] = tangential direction

## ◆ gdN

fmatvec::Vec MBSim::SingleContact::gdN

protected

relative velocity in normal direction

## ◆ gdT

fmatvec::Vec MBSim::SingleContact::gdT

protected

relative velocity in tangential direction

Todo:
  : use fixed size?

## ◆ laN

fmatvec::Vec MBSim::SingleContact::laN

protected

force in normal direction

Todo:
  : only double needed here

## ◆ laT

fmatvec::Vec MBSim::SingleContact::laT

protected

force in tangential direction

Todo:
  : use fixed size?

## ◆ rootID

int MBSim::SingleContact::rootID {0}

protected

type of detected root

1 = close-open transition / stick-slip transition 2 = slip-stick transition 3 = open-close transition, i.e., impact

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

- /mbsim-env/mbsim/kernel/mbsim/links/single_contact.h
- /mbsim-env/mbsim/kernel/mbsim/links/single_contact.cc