mbsim 4.0.0 MBSim Kernel

Public Member Functions | Protected Attributes | Private Member Functions | Friends | List of all members
MBSim::DynamicSystem Class Reference

dynamic system as topmost hierarchical level More...

`#include <dynamic_system.h>`

Inheritance diagram for MBSim::DynamicSystem:
[legend]

## Public Member Functions

| DynamicSystem (const std::string &name)
| constructor
| ~DynamicSystem () override
| destructor
virtual void | updateT ()
virtual void | updateh (int k=0)
virtual void | updateM ()
virtual void | updateLLM ()
virtual void | updatedq ()
virtual void | updatedu ()
virtual void | updatedx ()
virtual void | updatezd ()
virtual void | updatewb ()
virtual void | updateW (int j=0)
virtual void | updateV (int j=0)
virtual void | updater (int j=0)
virtual void | updateJrla (int j=0)
virtual void | updateg ()
virtual void | updategd ()
virtual void | updateStopVector ()
virtual void | updateStopVectorParameters ()
virtual void | updateLinkStatus ()
virtual void | updateLinkStatusReg ()
virtual void | updateWInverseKinetics ()
virtual void | updatebInverseKinetics ()
virtual void | sethSize (int hSize_, int j=0)
virtual int | gethSize (int i=0) const
virtual int | getqSize () const
virtual int | getuSize (int i=0) const
virtual void | calcqSize ()
virtual void | calcuSize (int j=0)
virtual int | getuInd (int i=0)
virtual void | setqInd (int qInd_)
virtual void | setuInd (int uInd_, int j=0)
virtual void | sethInd (int hInd_, int j=0)
virtual void | setxInd (int xInd_)
virtual const fmatvec::Vec & | getq () const
virtual fmatvec::Vec & | getq ()
virtual const fmatvec::Vec & | getu () const
virtual fmatvec::Vec & | getu ()
void | setq (const fmatvec::Vec &q_)
void | setu (const fmatvec::Vec &u_)
void | setx (const fmatvec::Vec &x_)
void | setjsv (const fmatvec::VecInt &jsv_)
void | setInternalState (const fmatvec::Vec &internalState)
virtual H5::GroupBase * | getPlotGroup ()
std::shared_ptr< OpenMBV::Group > | getOpenMBVGrp () override
std::shared_ptr< OpenMBV::Group > | getFramesOpenMBVGrp () override
std::shared_ptr< OpenMBV::Group > | getContoursOpenMBVGrp () override
std::shared_ptr< OpenMBV::Group > | getGroupsOpenMBVGrp () override
std::shared_ptr< OpenMBV::Group > | getObjectsOpenMBVGrp () override
std::shared_ptr< OpenMBV::Group > | getLinksOpenMBVGrp () override
std::shared_ptr< OpenMBV::Group > | getConstraintsOpenMBVGrp () override
std::shared_ptr< OpenMBV::Group > | getObserversOpenMBVGrp () override
virtual void | calcxSize ()
const fmatvec::Vec & | getx () const
fmatvec::Vec & | getx ()
int | getxSize () const
void | updatexRef (fmatvec::Vec &xParent)
void | updatexdRef (fmatvec::Vec &xdParent)
void | updatedxRef (fmatvec::Vec &dxParent)
void | init (InitStage stage, const InitConfigSet &config) override
| plots time series header More...
virtual void | initz ()
virtual void | writez (H5::GroupBase *parent)
virtual void | readz0 (H5::GroupBase *parent)
void | setDynamicSystemSolver (DynamicSystemSolver *sys) override
void | plot () override
| plots time dependent data More...
void | plotAtSpecialEvent () override
| plots time dependent data at special events More...
virtual int | solveConstraintsFixpointSingle ()
| solve contact equations with single step fixed point scheme More...
virtual int | solveImpactsFixpointSingle ()
| solve impact equations with single step fixed point scheme on velocity level More...
virtual int | solveConstraintsGaussSeidel ()
| solve contact equations with Gauss-Seidel scheme More...
virtual int | solveImpactsGaussSeidel ()
| solve impact equations with Gauss-Seidel scheme on velocity level More...
virtual int | solveConstraintsRootFinding ()
| solve contact equations with Newton scheme More...
virtual int | solveImpactsRootFinding ()
| solve impact equations with Newton scheme on velocity level More...
virtual int | jacobianConstraints ()
| compute JACOBIAN of contact equations
virtual int | jacobianImpacts ()
| compute JACOBIAN of contact equations on velocity level
virtual void | checkConstraintsForTermination ()
| validate force laws concerning given tolerances
virtual void | checkImpactsForTermination ()
| validate force laws concerning given tolerances on velocity level
virtual void | updaterFactors ()
| update relaxation factors for contact equations
virtual Frame * | getFrame (const std::string &name, bool check=true) const
virtual Contour * | getContour (const std::string &name, bool check=true) const
void | setFrameOfReference (Frame *frame)
const Frame * | getFrameOfReference () const
const fmatvec::Mat & | getT (bool check=true) const
const fmatvec::Vec & | geth (int i=0, bool check=true) const
const fmatvec::SymMat & | getM (bool check=true) const
const fmatvec::SymMat & | getLLM (bool check=true) const
const fmatvec::Vec & | getdq (bool check=true) const
const fmatvec::Vec & | getdu (bool check=true) const
const fmatvec::Vec & | getdx (bool check=true) const
const fmatvec::Mat & | getW (int i=0, bool check=true) const
const fmatvec::Mat & | getV (int i=0, bool check=true) const
const fmatvec::Vec & | getla (bool check=true) const
const fmatvec::Vec & | getLa (bool check=true) const
const fmatvec::Vec & | getg (bool check=true) const
const fmatvec::Vec & | getgd (bool check=true) const
fmatvec::Vec & | getla (bool check=true)
fmatvec::Vec & | getLa (bool check=true)
void | setla (const fmatvec::Vec &la_)
void | setLa (const fmatvec::Vec &La_)
fmatvec::VecInt & | getjsv ()
const fmatvec::VecInt & | getjsv () const
fmatvec::Mat & | getW (int i=0, bool check=true)
fmatvec::SymMat & | getLLM (bool check=true)
fmatvec::Vec & | getdq (bool check=true)
fmatvec::Vec & | getdu (bool check=true)
fmatvec::Vec & | getdx (bool check=true)
fmatvec::VecInt & | getLinkStatus ()
fmatvec::VecInt & | getLinkStatusReg ()
const fmatvec::VecInt & | getLinkStatus () const
const fmatvec::VecInt & | getLinkStatusReg () const
const fmatvec::Mat & | evalT ()
const fmatvec::Vec & | evalh (int i=0)
const fmatvec::SymMat & | evalM ()
const fmatvec::SymMat & | evalLLM ()
const fmatvec::Mat & | evalW (int i=0)
const fmatvec::Mat & | evalV (int i=0)
const fmatvec::Vec & | evalwb ()
const fmatvec::Vec & | evalr (int i=0)
const fmatvec::Mat & | evalJrla (int i=0)
const fmatvec::Vec & | evalrdt ()
const fmatvec::Vec & | evalg ()
const fmatvec::Vec & | evalgd ()
const fmatvec::Mat & | evalWInverseKinetics ()
const fmatvec::Mat & | evalbInverseKinetics ()
void | setqd (const fmatvec::Vec &qd_)
void | setud (const fmatvec::Vec &ud_)
void | setxd (const fmatvec::Vec &xd_)
int | getxInd ()
int | getlaInd () const
int | gethInd (int i=0)
void | setlaInd (int ind)
void | setisInd (int ind)
void | setgInd (int ind)
void | setgdInd (int ind)
void | setrFactorInd (int ind)
virtual void | setsvInd (int svInd_)
void | setLinkStatusInd (int LinkStatusInd_)
void | setLinkStatusRegInd (int LinkStatusRegInd_)
void | setqSize (int qSize_)
void | setuSize (int uSize_, int i=0)
void | setxSize (int xSize_)
int | getisSize () const
int | getlaSize () const
int | getgSize () const
int | getgdSize () const
int | getrFactorSize () const
int | getsvSize () const
int | getLinkStatusSize () const
int | getLinkStatusRegSize () const
const std::vector< Object * > & | getObjects () const
const std::vector< Link * > & | getLinks () const
const std::vector< DynamicSystem * > & | getDynamicSystems () const
const std::vector< Frame * > & | getFrames () const
const std::vector< Contour * > & | getContours () const
const std::vector< Link * > & | getSetValuedLinks () const
void | updateqRef (fmatvec::Vec &qParent)
| references to positions of dynamic system parent More...
void | updateqdRef (fmatvec::Vec &qdParent)
| references to differentiated positions of dynamic system parent More...
void | updatedqRef (fmatvec::Vec &dqParent)
void | updateuRef (fmatvec::Vec &uParent)
| references to velocities of dynamic system parent More...
void | updateuallRef (fmatvec::Vec &uParent)
| references to velocities of dynamic system parent More...
void | updateudRef (fmatvec::Vec &udParent)
| references to differentiated velocities of dynamic system parent More...
void | updateduRef (fmatvec::Vec &duParent)
void | updateudallRef (fmatvec::Vec &udParent)
| references to velocities of dynamic system parent More...
void | updatehRef (fmatvec::Vec &hParent, int j=0)
| references to smooth right hand side of dynamic system parent More...
void | updaterRef (fmatvec::Vec &rParent, int j=0)
| references to nonsmooth right hand side of dynamic system parent More...
void | updateJrlaRef (fmatvec::Mat &rParent, int j=0)
void | updaterdtRef (fmatvec::Vec &rdtParent)
| references to nonsmooth right hand side of dynamic system parent More...
void | updateTRef (fmatvec::Mat &TParent)
| references to linear transformation matrix between differentiated positions and velocities of dynamic system parent More...
void | updateMRef (fmatvec::SymMat &MParent)
| references to mass matrix of dynamic system parent More...
void | updateLLMRef (fmatvec::SymMat &LLMParent)
| references to Cholesky decomposition of dynamic system parent More...
virtual void | updateInternalStateRef (fmatvec::Vec &curisParent, fmatvec::Vec &nextisParent)
| references to internal state of dynamic system parent
virtual void | updategRef (fmatvec::Vec &gParent)
| references to relative distances of dynamic system parent More...
virtual void | updategdRef (fmatvec::Vec &gdParent)
| references to relative velocities of dynamic system parent More...
void | updatelaRef (fmatvec::Vec &laParent)
| references to contact forces of dynamic system parent More...
void | updateLaRef (fmatvec::Vec &LaParent)
| references to contact impulses of dynamic system parent More...
void | updatelaInverseKineticsRef (fmatvec::Vec &laParent)
void | updatebInverseKineticsRef (fmatvec::Mat &bParent)
virtual void | updatewbRef (fmatvec::Vec &wbParent)
| references to TODO of dynamic system parent More...
virtual void | updateWRef (fmatvec::Mat &WParent, int j=0)
| references to contact force direction matrix of dynamic system parent More...
void | updateWInverseKineticsRef (fmatvec::Mat &WParent)
| references to contact force direction matrix of dynamic system parent More...
virtual void | updateVRef (fmatvec::Mat &VParent, int j=0)
| references to condensed contact force direction matrix of dynamic system parent More...
void | updatesvRef (fmatvec::Vec &svParent)
| references to stopvector (rootfunction for event driven integrator) of dynamic system parent More...
void | updatejsvRef (fmatvec::VecInt &jsvParent)
| references to boolean evaluation of stopvector concerning roots of dynamic system parent More...
void | updateLinkStatusRef (fmatvec::VecInt &LinkStatusParent)
| references to status vector of set valued links with piecewise link equations (which piece is valid) More...
void | updateLinkStatusRegRef (fmatvec::VecInt &LinkStatusRegParent)
| references to status vector of single valued links More...
void | updateresRef (fmatvec::Vec &resParent)
| references to residuum of contact equations of dynamic system parent More...
void | updaterFactorRef (fmatvec::Vec &rFactorParent)
| references to relaxation factors for contact equations of dynamic system parent More...
void | clearElementLists ()
void | buildListOfDynamicSystems (std::vector< DynamicSystem * > &sys)
| build flat list of dynamic systems More...
void | buildListOfObjects (std::vector< Object * > &obj)
| build flat list of objects More...
void | buildListOfLinks (std::vector< Link * > &lnk)
| build flat list of links More...
void | buildListOfConstraints (std::vector< Constraint * > &crt)
| build flat list of all constraints More...
void | buildListOfFrames (std::vector< Frame * > &frm)
| build flat list of frames More...
void | buildListOfContours (std::vector< Contour * > &cnt)
| build flat list of contours More...
void | buildListOfModels (std::vector< ModellingInterface * > &modelList)
| build flat list of models More...
void | buildListOfInverseKineticsLinks (std::vector< Link * > &iklnk)
| build flat list of inverse kinetics links More...
void | buildListOfObservers (std::vector< Observer * > &obsrv)
| build flat list of observers More...
void | setUpInverseKinetics ()
| analyse constraints of dynamic systems for usage in inverse kinetics
void | setUpLinks ()
| distribute links to set- and single valued container
bool | gActiveChanged ()
bool | gActiveChangedReg ()
bool | detectImpact ()
void | calcsvSize ()
| calculates size of stop vector
void | calclaSize (int j)
| calculates size of contact force parameters
void | calcLinkStatusSize ()
| calculates size of set-valued link status vector
void | calcLinkStatusRegSize ()
| calculates size of single-valued link status vector
void | calclaInverseKineticsSize ()
| calculates size of contact force parameters
void | calcbInverseKineticsSize ()
| calculates size of contact force parameters
void | calcisSize ()
virtual void | aboutToUpdateInternalState ()
virtual void | postprocessing ()
void | calcgSize (int j)
| calculates size of relative distances
void | calcgdSize (int j)
| calculates size of gap velocities More...
void | calcrFactorSize (int j)
| calculates size of relaxation factors for contact equations
void | setUpObjectsWithNonConstantMassMatrix ()
| rearrange vector of active setvalued links
void | setUpActiveLinks ()
| rearrange vector of active setvalued links
void | checkActive (int j)
| check if set-valued contacts are active and set corresponding attributes More...
virtual void | setGeneralizedRelativePositionTolerance (double tol)
virtual void | setGeneralizedRelativeVelocityTolerance (double tol)
virtual void | setGeneralizedRelativeAccelerationTolerance (double tol)
virtual void | setGeneralizedForceTolerance (double tol)
virtual void | setGeneralizedImpulseTolerance (double tol)
virtual void | setGeneralizedRelativePositionCorrectionValue (double corr)
virtual void | setGeneralizedRelativeVelocityCorrectionValue (double corr)
void | setrMax (double rMax)
int | frameIndex (const Frame *frame_) const
void | addFrame (FixedRelativeFrame *frame)
void | addContour (RigidContour *contour)
void | addGroup (DynamicSystem *sys)
DynamicSystem * | getGroup (const std::string &name, bool check=true) const
void | addObject (Object *obj)
Object * | getObject (const std::string &name, bool check=true) const
void | addLink (Link *lnk)
void | addConstraint (Constraint *crt)
void | addInverseKineticsLink (Link *lnk)
Observer * | getObserver (const std::string &name, bool check=true) const
void | addObserver (Observer *ele)
Link * | getLink (const std::string &name, bool check=true) const
Constraint * | getConstraint (const std::string &name, bool check=true) const
void | addModel (ModellingInterface *model_)
ModellingInterface * | getModel (const std::string &name, bool check=true) const
Frame * | getFrameI ()
Element * | getChildByContainerAndName (const std::string &container, const std::string &name) const override
| Get the Element named name in the container named container.
virtual void | updatecorr (int j)
void | updatecorrRef (fmatvec::Vec &ref)
void | calccorrSize (int j)
void | checkRoot ()
void | resetUpToDate () override
void | updateStateTable ()
H5::GroupBase * | getFramesPlotGroup () override
H5::GroupBase * | getContoursPlotGroup () override
H5::GroupBase * | getGroupsPlotGroup () override
H5::GroupBase * | getObjectsPlotGroup () override
H5::GroupBase * | getLinksPlotGroup () override
H5::GroupBase * | getConstraintsPlotGroup () override
H5::GroupBase * | getObserversPlotGroup () override
Public Member Functions inherited from MBSim::Element
| Element (const std::string &name)
| constructor
| ~Element () override=default
| destructor
void | throwError (const std::string &msg) const
const std::string & | getName () const
void | setName (const std::string &str)
void | setPath (const std::string &str)
DynamicSystemSolver * | getDynamicSystemSolver ()
virtual void | createPlotGroup ()
| creates the plotGroup for H5-output
H5::GroupBase * | getPlotGroup ()
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)
virtual void | initializeUsingXML (xercesc::DOMElement *element)
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 * | 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 | updatePositions (Frame *frame)
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

## Protected Attributes

Frame * | R
| parent frame
std::vector< Object * > | object
| container for possible ingredients
std::vector< Object * > | objectWithNonConstantMassMatrix
std::vector< Link * > | link
std::vector< Link * > | linkSingleValued
std::vector< Link * > | linkSetValued
std::vector< Link * > | linkSetValuedActive
std::vector< Link * > | linkWithStopVector
std::vector< ModellingInterface * > | model
std::vector< DynamicSystem * > | dynamicsystem
std::vector< Link * > | inverseKineticsLink
std::vector< Observer * > | observer
std::vector< Constraint * > | constraint
fmatvec::Mat | T
| linear relation matrix of position and velocity parameters
fmatvec::SymMat | M
| mass matrix
fmatvec::SymMat | LLM
| Cholesky decomposition of mass matrix.
fmatvec::Vec | q
| positions, differentiated positions, initial positions
fmatvec::Vec | qd
fmatvec::Vec | dq
fmatvec::Vec | u
| velocities, differentiated velocities, initial velocities
fmatvec::Vec | ud
fmatvec::Vec | du
fmatvec::Vec | x
| order one parameters, differentiated order one parameters, initial order one parameters
fmatvec::Vec | xd
fmatvec::Vec | dx
fmatvec::Vec | h [2]
| smooth, smooth with respect to objects, smooth with respect to links and nonsmooth
fmatvec::Vec | r [2]
fmatvec::Vec | rdt
fmatvec::Mat | Jrla [2]
| Jacobian dr/dla.
fmatvec::Mat | W [2]
fmatvec::Mat | V [2]
fmatvec::Vec | la
| contact force parameters
fmatvec::Vec | La
fmatvec::Vec | curis
fmatvec::Vec | nextis
fmatvec::Vec | g
| relative distances and velocities
fmatvec::Vec | gd
fmatvec::Vec | wb
| TODO.
fmatvec::Vec | res
| residuum of nonlinear contact equations for Newton scheme
fmatvec::Vec | rFactor
| rfactors for relaxation nonlinear contact equations
fmatvec::Vec | sv
| stop vector (root functions for event driven integration
fmatvec::VecInt | jsv
| boolean evaluation of stop vector concerning roots
fmatvec::VecInt | LinkStatus
| status of set-valued links
fmatvec::VecInt | LinkStatusReg
| status of single-valued links
int | qSize
| size and local start index of positions relative to parent
int | qInd
int | uSize [2]
| size and local start index of velocities relative to parent
int | uInd [2]
int | xSize
| size and local start index of order one parameters relative to parent
int | xInd
int | hSize [2]
| size and local start index of order smooth right hand side relative to parent
int | hInd [2]
int | isSize
int | isInd
int | gSize
| size and local start index of relative distances relative to parent
int | gInd
int | gdSize
| size and local start index of relative velocities relative to parent
int | gdInd
int | laSize
| size and local start index of contact force parameters relative to parent
int | laInd
int | rFactorSize
| size and local start index of rfactors relative to parent
int | rFactorInd
int | svSize
| size and local start index of stop vector relative to parent
int | svInd
int | LinkStatusSize
| size and local start index of set-valued link status vector relative to parent
int | LinkStatusInd
int | LinkStatusRegSize
| size and local start index of single-valued link status vector relative to parent
int | LinkStatusRegInd
std::vector< Frame * > | frame
| vector of frames and contours
std::vector< Contour * > | contour
std::shared_ptr< OpenMBV::Group > | openMBVGrp
std::shared_ptr< OpenMBV::Group > | framesOpenMBVGrp
std::shared_ptr< OpenMBV::Group > | contoursOpenMBVGrp
std::shared_ptr< OpenMBV::Group > | groupsOpenMBVGrp
std::shared_ptr< OpenMBV::Group > | objectsOpenMBVGrp
std::shared_ptr< OpenMBV::Group > | linksOpenMBVGrp
std::shared_ptr< OpenMBV::Group > | constraintsOpenMBVGrp
std::shared_ptr< OpenMBV::Group > | observersOpenMBVGrp
std::shared_ptr< H5::File > | hdf5File
Frame * | I
int | laInverseKineticsSize
| size of contact force parameters of special links relative to parent
int | bInverseKineticsSize
fmatvec::Mat | WInverseKinetics
fmatvec::Mat | bInverseKinetics
fmatvec::Vec | laInverseKinetics
int | corrSize
int | corrInd
fmatvec::Vec | corr
std::string | saved_frameOfReference
H5::GroupBase * | framesPlotGroup
H5::GroupBase * | contoursPlotGroup
H5::GroupBase * | groupsPlotGroup
H5::GroupBase * | objectsPlotGroup
H5::GroupBase * | linksPlotGroup
H5::GroupBase * | constraintsPlotGroup
H5::GroupBase * | observersPlotGroup
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

## Private Member Functions

void | addFrame (Frame *frame_)
void | addContour (Contour *contour_)

## Friends

class | DynamicSystemSolver

## 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

dynamic system as topmost hierarchical level

Author
  Martin Foerg

Date
  2009-03-26 some comments (Thorsten Schindler)
  2009-04-06 ExtraDynamicInterface included (Thorsten Schindler)
  2009-06-14 OpenMP (Thorsten Schindler)
  2009-07-08 relative dynamic system location (Thorsten Schindler)
  2009-07-16 splitted link / object right hand side (Thorsten Schindler)
  2009-07-27 implicit integration improvement (Thorsten Schindler)
  2009-07-28 splitted interfaces (Thorsten Schindler)
  2009-12-14 revised inverse kinetics (Martin Foerg)
  2010-07-06 modifications for timestepper ssc, e.g LinkStatus and buildListOfSetValuedLinks (Robert Huber)
  2012-05-08 OpenMP completely removed; will be inserted again soon (Jan Clauberg)
  2012-05-08 modifications for AutoTimeSteppingSSCIntegrator (Jan Clauberg)
  2013-06-23 removed extra dynamics (Martin Foerg)
  2014-09-16 contact forces are calculated on acceleration level (Thorsten Schindler)

## Member Function Documentation

## ◆ aboutToUpdateInternalState()

void MBSim::DynamicSystem::aboutToUpdateInternalState | ( |  | ) |

virtual

This function is called just before the internal state vector gets updated. This means that the internal state is still at its old value when this function is called but get updated immediately afterwards. You can use this function to do actions which should only be done at valid integrator states (but not at integrates states which may be rejected later on).

## ◆ addConstraint()

void MBSim::DynamicSystem::addConstraint | ( | Constraint * | crt | ) |

Parameters

  constraint | to add

## ◆ addGroup()

void MBSim::DynamicSystem::addGroup | ( | DynamicSystem * | sys | ) |

Parameters

  dynamic | system to add

## ◆ addInverseKineticsLink()

void MBSim::DynamicSystem::addInverseKineticsLink | ( | Link * | lnk | ) |

Parameters

  add | link for inverse kinetics

## ◆ addLink()

void MBSim::DynamicSystem::addLink | ( | Link * | lnk | ) |

Parameters

  link | to add

## ◆ addModel()

void MBSim::DynamicSystem::addModel | ( | ModellingInterface * | model_ | ) |

Parameters

  modell | to add

## ◆ addObject()

void MBSim::DynamicSystem::addObject | ( | Object * | obj | ) |

Parameters

  object | to add

## ◆ buildListOfConstraints()

void MBSim::DynamicSystem::buildListOfConstraints | ( | std::vector< Constraint * > & | crt | ) |

build flat list of all constraints

Parameters

  list | of constraints

## ◆ buildListOfContours()

void MBSim::DynamicSystem::buildListOfContours | ( | std::vector< Contour * > & | cnt | ) |

build flat list of contours

Parameters

  list | of contours

## ◆ buildListOfDynamicSystems()

void MBSim::DynamicSystem::buildListOfDynamicSystems | ( | std::vector< DynamicSystem * > & | sys | ) |

build flat list of dynamic systems

Parameters

  list | of dynamic systems

## ◆ buildListOfFrames()

void MBSim::DynamicSystem::buildListOfFrames | ( | std::vector< Frame * > & | frm | ) |

build flat list of frames

Parameters

  list | of frames

## ◆ buildListOfInverseKineticsLinks()

void MBSim::DynamicSystem::buildListOfInverseKineticsLinks | ( | std::vector< Link * > & | iklnk | ) |

build flat list of inverse kinetics links

Parameters

  list | of inverse kinetics links

## ◆ buildListOfLinks()

void MBSim::DynamicSystem::buildListOfLinks | ( | std::vector< Link * > & | lnk | ) |

build flat list of links

Parameters

  list | of links

## ◆ buildListOfModels()

void MBSim::DynamicSystem::buildListOfModels | ( | std::vector< ModellingInterface * > & | modelList | ) |

build flat list of models

Parameters

  list | of models

## ◆ buildListOfObjects()

void MBSim::DynamicSystem::buildListOfObjects | ( | std::vector< Object * > & | obj | ) |

build flat list of objects

Parameters

  list | of objects

## ◆ buildListOfObservers()

void MBSim::DynamicSystem::buildListOfObservers | ( | std::vector< Observer * > & | obsrv | ) |

build flat list of observers

Parameters

  list | of observers

## ◆ calcgdSize()

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

calculates size of gap velocities

Parameters

  flag | to decide which contacts are included in the calculation 0 = all contacts 1 = closed contacts 2 = contacts which stay closed 3 = sticking contacts

see SingleContact for the implementation

## ◆ checkActive()

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

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

Parameters

  flag | to decide which criteria are used to define 'activity' 1 = position level activity (gActive = normal gap not larger than tolerance) 2 = velocity level activity (if gActive, gdActive[normal] = normal gap velocity not larger than tolerance ; if gdActive[normal], gdActive[tangential] = tangential gap velocity not larger than tolerance, i.e., sticking) 3 = velocity level activity (if gActive, gdActive[normal] = new normal gap velocity AFTER impact not larger than tolerance ; if gdActive[normal], gdActive[tangential] = new tangential gap velocity AFTER impact not larger than tolerance, i.e., sticking) 4 = acceleration level activity (if gActive and gdActive[normal], gddActive[normal] = normal gap acceleration not larger than tolerance ; if gddActive[normal] and gdActive[tangential], gddActive[tangential] = tangential gap acceleration not larger than tolerance, i.e., stay sticking) 5 = activity clean-up: if there is no activity on acceleration or velocity level, also more basic levels are set to non-active 6 = closing sets all activities 7 = slip-stick transition sets tangential velocity and acceleration activity 8 = opening and stick-slip transition set corresponding acceleration activity to non-active

see SingleContact for the implementation

## ◆ detectImpact()

bool MBSim::DynamicSystem::detectImpact | ( |  | ) |

Returns
  flag, if an impact occured in the system

## ◆ frameIndex()

int MBSim::DynamicSystem::frameIndex | ( | const Frame * | frame_ | ) | const

Parameters

  frame |

Returns
  index of frame TODO renaming

## ◆ gActiveChanged()

bool MBSim::DynamicSystem::gActiveChanged | ( |  | ) |

Returns
  flag, if vector of active relative distances has changed (set-valued laws)

## ◆ gActiveChangedReg()

bool MBSim::DynamicSystem::gActiveChangedReg | ( |  | ) |

Returns
  flag, if vector of active relative distances has changed (single-valued laws)

## ◆ getConstraint()

Constraint * MBSim::DynamicSystem::getConstraint | ( | const std::string & | name,
|  | bool | check = `true`
| ) |  | const

Parameters

  name | of the constraint
  check | for existence of constraint

Returns
  constraint

## ◆ getContour()

Contour * MBSim::DynamicSystem::getContour | ( | const std::string & | name,
|  | bool | check = `true`
| ) |  | const

virtual

Parameters

  name | of the contour
  check | for existence of contour

Returns
  contour

## ◆ getFrame()

Frame * MBSim::DynamicSystem::getFrame | ( | const std::string & | name,
|  | bool | check = `true`
| ) |  | const

virtual

Parameters

  name | of the frame
  check | for existence of frame

Returns
  frame

## ◆ getFrameI()

Frame* MBSim::DynamicSystem::getFrameI | ( |  | ) |

inline

Return frame "I"

## ◆ getGroup()

DynamicSystem * MBSim::DynamicSystem::getGroup | ( | const std::string & | name,
|  | bool | check = `true`
| ) |  | const

Parameters

  name | of the dynamic system
  check | for existence of dynamic system

Returns
  dynamic system

## ◆ getLink()

Link * MBSim::DynamicSystem::getLink | ( | const std::string & | name,
|  | bool | check = `true`
| ) |  | const

Parameters

  name | of the link
  check | for existence of link

Returns
  link

## ◆ getModel()

ModellingInterface * MBSim::DynamicSystem::getModel | ( | const std::string & | name,
|  | bool | check = `true`
| ) |  | const

Parameters

  name | of the model
  check | for existence of model

Returns
  modelling interface

## ◆ getObject()

Object * MBSim::DynamicSystem::getObject | ( | const std::string & | name,
|  | bool | check = `true`
| ) |  | const

Parameters

  name | of the object
  check | for existence of object

Returns
  object

## ◆ init()

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

override virtual

plots time series header

Parameters

  invocing | parent class

Reimplemented from MBSim::Element.

Reimplemented in MBSim::DynamicSystemSolver.

## ◆ plot()

void MBSim::DynamicSystem::plot | ( |  | ) |

override virtual

plots time dependent data

Parameters

  simulation | time
  simulation | time step size for derivative calculation

Reimplemented from MBSim::Element.

Reimplemented in MBSim::DynamicSystemSolver.

## ◆ plotAtSpecialEvent()

void MBSim::DynamicSystem::plotAtSpecialEvent | ( |  | ) |

override virtual

plots time dependent data at special events

Parameters

  simulation | time
  simulation | time step size for derivative calculation

Reimplemented from MBSim::Element.

## ◆ setDynamicSystemSolver()

void MBSim::DynamicSystem::setDynamicSystemSolver | ( | DynamicSystemSolver * | sys | ) |

override virtual

DEPRECATED

Reimplemented from MBSim::Element.

## ◆ setGeneralizedForceTolerance()

void MBSim::DynamicSystem::setGeneralizedForceTolerance | ( | double | tol | ) |

virtual

Parameters

  tolerance | for contact force

## ◆ setGeneralizedImpulseTolerance()

void MBSim::DynamicSystem::setGeneralizedImpulseTolerance | ( | double | tol | ) |

virtual

Parameters

  tolerance | for impact

## ◆ setGeneralizedRelativeAccelerationTolerance()

void MBSim::DynamicSystem::setGeneralizedRelativeAccelerationTolerance | ( | double | tol | ) |

virtual

Parameters

  tolerance | for relative acceleration

## ◆ setGeneralizedRelativePositionCorrectionValue()

void MBSim::DynamicSystem::setGeneralizedRelativePositionCorrectionValue | ( | double | corr | ) |

virtual

Parameters

  correction | value for relative position

## ◆ setGeneralizedRelativePositionTolerance()

void MBSim::DynamicSystem::setGeneralizedRelativePositionTolerance | ( | double | tol | ) |

virtual

Parameters

  tolerance | for relative position

## ◆ setGeneralizedRelativeVelocityCorrectionValue()

void MBSim::DynamicSystem::setGeneralizedRelativeVelocityCorrectionValue | ( | double | corr | ) |

virtual

Parameters

  correction | value for relative velocity

## ◆ setGeneralizedRelativeVelocityTolerance()

void MBSim::DynamicSystem::setGeneralizedRelativeVelocityTolerance | ( | double | tol | ) |

virtual

Parameters

  tolerance | for relative velocity

## ◆ setrMax()

void MBSim::DynamicSystem::setrMax | ( | double | rMax | ) |

Parameters

  maximum | relaxation factor for contact equations

## ◆ solveConstraintsFixpointSingle()

int MBSim::DynamicSystem::solveConstraintsFixpointSingle | ( |  | ) |

virtual

solve contact equations with single step fixed point scheme

Returns
  iterations of solver

Reimplemented in MBSim::DynamicSystemSolver.

## ◆ solveConstraintsGaussSeidel()

int MBSim::DynamicSystem::solveConstraintsGaussSeidel | ( |  | ) |

virtual

solve contact equations with Gauss-Seidel scheme

Returns
  iterations of solver

Reimplemented in MBSim::DynamicSystemSolver.

## ◆ solveConstraintsRootFinding()

int MBSim::DynamicSystem::solveConstraintsRootFinding | ( |  | ) |

virtual

solve contact equations with Newton scheme

Returns
  iterations of solver

Reimplemented in MBSim::DynamicSystemSolver.

## ◆ solveImpactsFixpointSingle()

int MBSim::DynamicSystem::solveImpactsFixpointSingle | ( |  | ) |

virtual

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

Parameters

  time | step-size

Returns
  iterations of solver

Reimplemented in MBSim::DynamicSystemSolver.

## ◆ solveImpactsGaussSeidel()

int MBSim::DynamicSystem::solveImpactsGaussSeidel | ( |  | ) |

virtual

solve impact equations with Gauss-Seidel scheme on velocity level

Parameters

  time | step-size

Returns
  iterations of solver

Reimplemented in MBSim::DynamicSystemSolver.

## ◆ solveImpactsRootFinding()

int MBSim::DynamicSystem::solveImpactsRootFinding | ( |  | ) |

virtual

solve impact equations with Newton scheme on velocity level

Parameters

  time | step-size

Returns
  iterations of solver

Reimplemented in MBSim::DynamicSystemSolver.

## ◆ updategdRef()

void MBSim::DynamicSystem::updategdRef | ( | fmatvec::Vec & | gdParent | ) |

virtual

references to relative velocities of dynamic system parent

Parameters

  vector | to be referenced

Reimplemented in MBSim::DynamicSystemSolver.

## ◆ updategRef()

void MBSim::DynamicSystem::updategRef | ( | fmatvec::Vec & | gParent | ) |

virtual

references to relative distances of dynamic system parent

Parameters

  vector | to be referenced

Reimplemented in MBSim::DynamicSystemSolver.

## ◆ updatehRef()

void MBSim::DynamicSystem::updatehRef | ( | fmatvec::Vec & | hParent,
|  | int | j = `0`
| ) |  |

references to smooth right hand side of dynamic system parent

Parameters

  complete | vector to be referenced
  vector | concerning objects to be referenced
  vector | concerning links to be referenced
  index | of normal usage and inverse kinetics

## ◆ updatejsvRef()

void MBSim::DynamicSystem::updatejsvRef | ( | fmatvec::VecInt & | jsvParent | ) |

references to boolean evaluation of stopvector concerning roots of dynamic system parent

Parameters

  vector | to be referenced

## ◆ updatelaRef()

void MBSim::DynamicSystem::updatelaRef | ( | fmatvec::Vec & | laParent | ) |

references to contact forces of dynamic system parent

Parameters

  vector | to be referenced

## ◆ updateLaRef()

void MBSim::DynamicSystem::updateLaRef | ( | fmatvec::Vec & | LaParent | ) |

references to contact impulses of dynamic system parent

Parameters

  vector | to be referenced

## ◆ updateLinkStatusRef()

void MBSim::DynamicSystem::updateLinkStatusRef | ( | fmatvec::VecInt & | LinkStatusParent | ) |

references to status vector of set valued links with piecewise link equations (which piece is valid)

Parameters

  vector | to be referenced

## ◆ updateLinkStatusRegRef()

void MBSim::DynamicSystem::updateLinkStatusRegRef | ( | fmatvec::VecInt & | LinkStatusRegParent | ) |

references to status vector of single valued links

Parameters

  vector | to be referenced

## ◆ updateLLMRef()

void MBSim::DynamicSystem::updateLLMRef | ( | fmatvec::SymMat & | LLMParent | ) |

references to Cholesky decomposition of dynamic system parent

Parameters

  matrix | to be referenced
  index | of normal usage and inverse kinetics

## ◆ updateMRef()

void MBSim::DynamicSystem::updateMRef | ( | fmatvec::SymMat & | MParent | ) |

references to mass matrix of dynamic system parent

Parameters

  matrix | to be referenced
  index | of normal usage and inverse kinetics

## ◆ updateqdRef()

void MBSim::DynamicSystem::updateqdRef | ( | fmatvec::Vec & | qdParent | ) |

references to differentiated positions of dynamic system parent

Parameters

  vector | to be referenced

## ◆ updateqRef()

void MBSim::DynamicSystem::updateqRef | ( | fmatvec::Vec & | qParent | ) |

references to positions of dynamic system parent

Parameters

  vector | to be referenced

## ◆ updaterdtRef()

void MBSim::DynamicSystem::updaterdtRef | ( | fmatvec::Vec & | rdtParent | ) |

references to nonsmooth right hand side of dynamic system parent

Parameters

  vector | to be referenced

## ◆ updateresRef()

void MBSim::DynamicSystem::updateresRef | ( | fmatvec::Vec & | resParent | ) |

references to residuum of contact equations of dynamic system parent

Parameters

  vector | to be referenced

## ◆ updaterFactorRef()

void MBSim::DynamicSystem::updaterFactorRef | ( | fmatvec::Vec & | rFactorParent | ) |

references to relaxation factors for contact equations of dynamic system parent

Parameters

  vector | to be referenced

## ◆ updaterRef()

void MBSim::DynamicSystem::updaterRef | ( | fmatvec::Vec & | rParent,
|  | int | j = `0`
| ) |  |

references to nonsmooth right hand side of dynamic system parent

Parameters

  vector | to be referenced

## ◆ updatesvRef()

void MBSim::DynamicSystem::updatesvRef | ( | fmatvec::Vec & | svParent | ) |

references to stopvector (rootfunction for event driven integrator) of dynamic system parent

Parameters

  vector | to be referenced

## ◆ updateTRef()

void MBSim::DynamicSystem::updateTRef | ( | fmatvec::Mat & | TParent | ) |

references to linear transformation matrix between differentiated positions and velocities of dynamic system parent

Parameters

  matrix | to be referenced

## ◆ updateuallRef()

void MBSim::DynamicSystem::updateuallRef | ( | fmatvec::Vec & | uParent | ) |

references to velocities of dynamic system parent

Parameters

  vector | to be referenced

## ◆ updateudallRef()

void MBSim::DynamicSystem::updateudallRef | ( | fmatvec::Vec & | udParent | ) |

references to velocities of dynamic system parent

Parameters

  vector | to be referenced

## ◆ updateudRef()

void MBSim::DynamicSystem::updateudRef | ( | fmatvec::Vec & | udParent | ) |

references to differentiated velocities of dynamic system parent

Parameters

  vector | to be referenced

## ◆ updateuRef()

void MBSim::DynamicSystem::updateuRef | ( | fmatvec::Vec & | uParent | ) |

references to velocities of dynamic system parent

Parameters

  vector | to be referenced

## ◆ updateVRef()

void MBSim::DynamicSystem::updateVRef | ( | fmatvec::Mat & | VParent,
|  | int | j = `0`
| ) |  |

virtual

references to condensed contact force direction matrix of dynamic system parent

Parameters

  matrix | to be referenced
  index | of normal usage and inverse kinetics

Reimplemented in MBSim::DynamicSystemSolver.

## ◆ updatewbRef()

void MBSim::DynamicSystem::updatewbRef | ( | fmatvec::Vec & | wbParent | ) |

virtual

references to TODO of dynamic system parent

Parameters

  vector | to be referenced

Reimplemented in MBSim::DynamicSystemSolver.

## ◆ updateWInverseKineticsRef()

void MBSim::DynamicSystem::updateWInverseKineticsRef | ( | fmatvec::Mat & | WParent | ) |

references to contact force direction matrix of dynamic system parent

Parameters

  matrix | to be referenced
  index | of normal usage and inverse kinetics

## ◆ updateWRef()

void MBSim::DynamicSystem::updateWRef | ( | fmatvec::Mat & | WParent,
|  | int | j = `0`
| ) |  |

virtual

references to contact force direction matrix of dynamic system parent

Parameters

  matrix | to be referenced
  index | of normal usage and inverse kinetics

Reimplemented in MBSim::DynamicSystemSolver.

## Member Data Documentation

## ◆ I

Frame* MBSim::DynamicSystem::I

protected

A pointer to frame "I"

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

- /mbsim-env/mbsim/kernel/mbsim/dynamic_system.h
- /mbsim-env/mbsim/kernel/mbsim/dynamic_system.cc