Subsystem::Guts Class Reference

#include <SubsystemGuts.h>

Inheritance diagram for Subsystem::Guts:

ForceSubsystem::Guts

List of all members.


Detailed Description

The abstract parent of all Subsystems.

A Subsystem is expected to be part of a larger System and to have interdependencies with other subsystems of that same system. It must NOT have dependencies on objects which are outside the System. Consequently construction of any concrete subsystem requires specification of a system at that time. Subsystems go through an extended construction phase in which their contents and interdependencies are created. Thus all of a System's Subsystems generally need to be available simultaneously during construction, so that they can reference each other.

There are three distinct users of this class:


Public Member Functions

 Guts (const Guts &)
Gutsoperator= (const Guts &)
 Guts (const String &name="<NONAME>", const String &version="0.0.0")
virtual ~Guts ()
const StringgetName () const
const StringgetVersion () const
const VectorgetQ (const State &) const
const VectorgetU (const State &) const
const VectorgetZ (const State &) const
const VectorgetQDot (const State &) const
const VectorgetUDot (const State &) const
const VectorgetZDot (const State &) const
const VectorgetQDotDot (const State &) const
const VectorgetQErr (const State &) const
const VectorgetUErr (const State &) const
const VectorgetUDotErr (const State &) const
const VectorgetMultipliers (const State &) const
VectorupdQ (State &) const
VectorupdU (State &) const
VectorupdZ (State &) const
void setQ (State &s, const Vector &q) const
void setU (State &s, const Vector &u) const
void setZ (State &s, const Vector &z) const
VectorupdQDot (const State &) const
VectorupdUDot (const State &) const
VectorupdZDot (const State &) const
VectorupdQDotDot (const State &) const
VectorupdQErr (const State &) const
VectorupdUErr (const State &) const
VectorupdUDotErr (const State &) const
VectorupdMultipliers (const State &) const
Stage getStage (const State &) const
const AbstractValuegetDiscreteVariable (const State &, int index) const
AbstractValueupdDiscreteVariable (State &, int index) const
const AbstractValuegetCacheEntry (const State &, int index) const
AbstractValueupdCacheEntry (const State &, int index) const
int getQStart (const State &) const
int getNQ (const State &) const
int getUStart (const State &) const
int getNU (const State &) const
int getZStart (const State &) const
int getNZ (const State &) const
int getQErrStart (const State &) const
int getNQErr (const State &) const
int getUErrStart (const State &) const
int getNUErr (const State &) const
int getUDotErrStart (const State &) const
int getNUDotErr (const State &) const
int getMultipliersStart (const State &) const
int getNMultipliers (const State &) const
bool isInSystem () const
bool isInSameSystem (const Subsystem &otherSubsystem) const
const System & getSystem () const
System & updSystem ()
SubsystemIndex getMySubsystemIndex () const
const SubsystemgetOwnerSubsystemHandle () const
SubsystemupdOwnerSubsystemHandle ()
void setOwnerSubsystemHandle (Subsystem &)
bool hasOwnerSubsystemHandle () const
void setSystem (System &, SubsystemIndex)
 Guts (class GutsRep *r)
bool hasRep () const
const GutsRep & getRep () const
GutsRep & updRep () const
void setRep (GutsRep &r)
bool subsystemTopologyHasBeenRealized () const
void invalidateSubsystemTopologyCache () const
Subsystem::Gutsclone () const
void realizeSubsystemTopology (State &) const
void realizeSubsystemModel (State &) const
void realizeSubsystemInstance (const State &) const
void realizeSubsystemTime (const State &) const
void realizeSubsystemPosition (const State &) const
void realizeSubsystemVelocity (const State &) const
void realizeSubsystemDynamics (const State &) const
void realizeSubsystemAcceleration (const State &) const
void realizeSubsystemReport (const State &) const
void calcQUnitWeights (const State &, Vector &weights) const
void calcUUnitWeights (const State &, Vector &weights) const
void calcZUnitWeights (const State &, Vector &weights) const
void calcQErrUnitTolerances (const State &, Vector &tolerances) const
void calcUErrUnitTolerances (const State &, Vector &tolerances) const
void calcDecorativeGeometryAndAppend (const State &, Stage, std::vector< DecorativeGeometry > &) const
void createScheduledEvent (const State &state, EventId &eventId) const
void createTriggeredEvent (const State &state, EventId &eventId, int &triggerFunctionIndex, Stage stage) const
virtual void calcEventTriggerInfo (const State &, std::vector< System::EventTriggerInfo > &) const
virtual void calcTimeOfNextScheduledEvent (const State &, Real &tNextEvent, std::vector< EventId > &eventIds, bool includeCurrentTime) const
virtual void calcTimeOfNextScheduledReport (const State &, Real &tNextEvent, std::vector< EventId > &eventIds, bool includeCurrentTime) const
virtual void handleEvents (State &, System::EventCause, const std::vector< EventId > &eventIds, Real accuracy, const Vector &yWeights, const Vector &ooConstraintTols, Stage &lowestModified, bool &shouldTerminate) const
virtual void reportEvents (const State &, System::EventCause, const std::vector< EventId > &eventIds) const

Static Public Member Functions

static void destruct (Subsystem::Guts *)

Protected Member Functions

virtual Subsystem::GutscloneImpl () const =0
virtual int realizeSubsystemTopologyImpl (State &s) const
virtual int realizeSubsystemModelImpl (State &s) const
virtual int realizeSubsystemInstanceImpl (const State &s) const
virtual int realizeSubsystemTimeImpl (const State &s) const
virtual int realizeSubsystemPositionImpl (const State &s) const
virtual int realizeSubsystemVelocityImpl (const State &s) const
virtual int realizeSubsystemDynamicsImpl (const State &s) const
virtual int realizeSubsystemAccelerationImpl (const State &s) const
virtual int realizeSubsystemReportImpl (const State &s) const
virtual int calcQUnitWeightsImpl (const State &s, Vector &weights) const
virtual int calcUUnitWeightsImpl (const State &s, Vector &weights) const
virtual int calcZUnitWeightsImpl (const State &s, Vector &weights) const
virtual int calcQErrUnitTolerancesImpl (const State &s, Vector &tolerances) const
virtual int calcUErrUnitTolerancesImpl (const State &s, Vector &tolerances) const
virtual int calcDecorativeGeometryAndAppendImpl (const State &, Stage, std::vector< DecorativeGeometry > &) const
int allocateQ (State &s, const Vector &qInit) const
int allocateU (State &s, const Vector &uInit) const
int allocateZ (State &s, const Vector &zInit) const
int allocateQErr (const State &s, int nqerr) const
int allocateUErr (const State &s, int nuerr) const
int allocateUDotErr (const State &s, int nudoterr) const
int allocateDiscreteVariable (State &s, Stage g, AbstractValue *v) const
int allocateCacheEntry (State &s, Stage g, AbstractValue *v) const
void advanceToStage (const State &s, Stage g) const

Friends

class GutsRep
void subsystemDestructImplLocator (Subsystem::Guts *)
Subsystem::GutssubsystemCloneImplLocator (const Subsystem::Guts &)
int subsystemRealizeTopologyImplLocator (const Subsystem::Guts &, State &)
int subsystemRealizeModelImplLocator (const Subsystem::Guts &, State &)
int subsystemRealizeInstanceImplLocator (const Subsystem::Guts &, const State &)
int subsystemRealizeTimeImplLocator (const Subsystem::Guts &, const State &)
int subsystemRealizePositionImplLocator (const Subsystem::Guts &, const State &)
int subsystemRealizeVelocityImplLocator (const Subsystem::Guts &, const State &)
int subsystemRealizeDynamicsImplLocator (const Subsystem::Guts &, const State &)
int subsystemRealizeAccelerationImplLocator (const Subsystem::Guts &, const State &)
int subsystemRealizeReportImplLocator (const Subsystem::Guts &, const State &)
int subsystemCalcQUnitWeightsImplLocator (const Subsystem::Guts &, const State &, Vector &)
int subsystemCalcUUnitWeightsImplLocator (const Subsystem::Guts &, const State &, Vector &)
int subsystemCalcZUnitWeightsImplLocator (const Subsystem::Guts &, const State &, Vector &)
int subsystemCalcQErrUnitTolerancesImplLocator (const Subsystem::Guts &, const State &, Vector &)
int subsystemCalcUErrUnitTolerancesImplLocator (const Subsystem::Guts &, const State &, Vector &)
int subsystemCalcDecorativeGeometryAndAppendImplLocator (const Subsystem::Guts &, const State &, Stage, std::vector< DecorativeGeometry > &)

Constructor & Destructor Documentation

Guts ( const Guts  ) 

Guts ( const String name = "<NONAME>",
const String version = "0.0.0" 
) [inline, explicit]

virtual ~Guts (  )  [inline, virtual]

Reimplemented in ForceSubsystem::Guts.

Guts ( class GutsRep *  r  )  [inline, explicit]


Member Function Documentation

Guts& operator= ( const Guts  ) 

const String& getName (  )  const

const String& getVersion (  )  const

const Vector& getQ ( const State  )  const

const Vector& getU ( const State  )  const

const Vector& getZ ( const State  )  const

const Vector& getQDot ( const State  )  const

const Vector& getUDot ( const State  )  const

const Vector& getZDot ( const State  )  const

const Vector& getQDotDot ( const State  )  const

const Vector& getQErr ( const State  )  const

const Vector& getUErr ( const State  )  const

const Vector& getUDotErr ( const State  )  const

const Vector& getMultipliers ( const State  )  const

Vector& updQ ( State  )  const

Vector& updU ( State  )  const

Vector& updZ ( State  )  const

void setQ ( State s,
const Vector q 
) const [inline]

References VectorBase::size().

void setU ( State s,
const Vector u 
) const [inline]

References VectorBase::size().

void setZ ( State s,
const Vector z 
) const [inline]

References VectorBase::size().

Vector& updQDot ( const State  )  const

Vector& updUDot ( const State  )  const

Vector& updZDot ( const State  )  const

Vector& updQDotDot ( const State  )  const

Vector& updQErr ( const State  )  const

Vector& updUErr ( const State  )  const

Vector& updUDotErr ( const State  )  const

Vector& updMultipliers ( const State  )  const

Stage getStage ( const State  )  const

const AbstractValue& getDiscreteVariable ( const State ,
int  index 
) const

AbstractValue& updDiscreteVariable ( State ,
int  index 
) const

const AbstractValue& getCacheEntry ( const State ,
int  index 
) const

AbstractValue& updCacheEntry ( const State ,
int  index 
) const

int getQStart ( const State  )  const

int getNQ ( const State  )  const

int getUStart ( const State  )  const

int getNU ( const State  )  const

int getZStart ( const State  )  const

int getNZ ( const State  )  const

int getQErrStart ( const State  )  const

int getNQErr ( const State  )  const

int getUErrStart ( const State  )  const

int getNUErr ( const State  )  const

int getUDotErrStart ( const State  )  const

int getNUDotErr ( const State  )  const

int getMultipliersStart ( const State  )  const

int getNMultipliers ( const State  )  const

bool isInSystem (  )  const

bool isInSameSystem ( const Subsystem otherSubsystem  )  const

const System& getSystem (  )  const

System& updSystem (  ) 

SubsystemIndex getMySubsystemIndex (  )  const

const Subsystem& getOwnerSubsystemHandle (  )  const

Subsystem& updOwnerSubsystemHandle (  ) 

void setOwnerSubsystemHandle ( Subsystem  ) 

bool hasOwnerSubsystemHandle (  )  const

void setSystem ( System &  ,
SubsystemIndex   
)

bool hasRep (  )  const [inline]

const GutsRep& getRep (  )  const [inline]

GutsRep& updRep (  )  const [inline]

void setRep ( GutsRep &  r  )  [inline]

bool subsystemTopologyHasBeenRealized (  )  const

void invalidateSubsystemTopologyCache (  )  const

static void destruct ( Subsystem::Guts  )  [static]

Subsystem::Guts* clone (  )  const

void realizeSubsystemTopology ( State  )  const

void realizeSubsystemModel ( State  )  const

void realizeSubsystemInstance ( const State  )  const

void realizeSubsystemTime ( const State  )  const

void realizeSubsystemPosition ( const State  )  const

void realizeSubsystemVelocity ( const State  )  const

void realizeSubsystemDynamics ( const State  )  const

void realizeSubsystemAcceleration ( const State  )  const

void realizeSubsystemReport ( const State  )  const

void calcQUnitWeights ( const State ,
Vector weights 
) const

void calcUUnitWeights ( const State ,
Vector weights 
) const

void calcZUnitWeights ( const State ,
Vector weights 
) const

void calcQErrUnitTolerances ( const State ,
Vector tolerances 
) const

void calcUErrUnitTolerances ( const State ,
Vector tolerances 
) const

void calcDecorativeGeometryAndAppend ( const State ,
Stage  ,
std::vector< DecorativeGeometry > &   
) const

void createScheduledEvent ( const State state,
EventId &  eventId 
) const

void createTriggeredEvent ( const State state,
EventId &  eventId,
int &  triggerFunctionIndex,
Stage  stage 
) const

virtual void calcEventTriggerInfo ( const State ,
std::vector< System::EventTriggerInfo > &   
) const [virtual]

virtual void calcTimeOfNextScheduledEvent ( const State ,
Real &  tNextEvent,
std::vector< EventId > &  eventIds,
bool  includeCurrentTime 
) const [virtual]

virtual void calcTimeOfNextScheduledReport ( const State ,
Real &  tNextEvent,
std::vector< EventId > &  eventIds,
bool  includeCurrentTime 
) const [virtual]

virtual void handleEvents ( State ,
System::EventCause  ,
const std::vector< EventId > &  eventIds,
Real  accuracy,
const Vector yWeights,
const Vector ooConstraintTols,
Stage lowestModified,
bool &  shouldTerminate 
) const [virtual]

virtual void reportEvents ( const State ,
System::EventCause  ,
const std::vector< EventId > &  eventIds 
) const [virtual]

virtual Subsystem::Guts* cloneImpl (  )  const [protected, pure virtual]

virtual int realizeSubsystemTopologyImpl ( State s  )  const [protected, virtual]

virtual int realizeSubsystemModelImpl ( State s  )  const [protected, virtual]

virtual int realizeSubsystemInstanceImpl ( const State s  )  const [protected, virtual]

virtual int realizeSubsystemTimeImpl ( const State s  )  const [protected, virtual]

virtual int realizeSubsystemPositionImpl ( const State s  )  const [protected, virtual]

virtual int realizeSubsystemVelocityImpl ( const State s  )  const [protected, virtual]

virtual int realizeSubsystemDynamicsImpl ( const State s  )  const [protected, virtual]

virtual int realizeSubsystemAccelerationImpl ( const State s  )  const [protected, virtual]

virtual int realizeSubsystemReportImpl ( const State s  )  const [protected, virtual]

virtual int calcQUnitWeightsImpl ( const State s,
Vector weights 
) const [protected, virtual]

virtual int calcUUnitWeightsImpl ( const State s,
Vector weights 
) const [protected, virtual]

virtual int calcZUnitWeightsImpl ( const State s,
Vector weights 
) const [protected, virtual]

virtual int calcQErrUnitTolerancesImpl ( const State s,
Vector tolerances 
) const [protected, virtual]

virtual int calcUErrUnitTolerancesImpl ( const State s,
Vector tolerances 
) const [protected, virtual]

virtual int calcDecorativeGeometryAndAppendImpl ( const State ,
Stage  ,
std::vector< DecorativeGeometry > &   
) const [protected, virtual]

int allocateQ ( State s,
const Vector qInit 
) const [protected]

int allocateU ( State s,
const Vector uInit 
) const [protected]

int allocateZ ( State s,
const Vector zInit 
) const [protected]

int allocateQErr ( const State s,
int  nqerr 
) const [protected]

int allocateUErr ( const State s,
int  nuerr 
) const [protected]

int allocateUDotErr ( const State s,
int  nudoterr 
) const [protected]

int allocateDiscreteVariable ( State s,
Stage  g,
AbstractValue v 
) const [protected]

int allocateCacheEntry ( State s,
Stage  g,
AbstractValue v 
) const [protected]

void advanceToStage ( const State s,
Stage  g 
) const [protected]


Friends And Related Function Documentation

friend class GutsRep [friend]

void subsystemDestructImplLocator ( Subsystem::Guts sysp  )  [friend]

Referenced by Subsystem::Guts::Guts().

Subsystem::Guts* subsystemCloneImplLocator ( const Subsystem::Guts sys  )  [friend]

Referenced by Subsystem::Guts::Guts().

int subsystemRealizeTopologyImplLocator ( const Subsystem::Guts sys,
State state 
) [friend]

Referenced by Subsystem::Guts::Guts().

int subsystemRealizeModelImplLocator ( const Subsystem::Guts sys,
State state 
) [friend]

Referenced by Subsystem::Guts::Guts().

int subsystemRealizeInstanceImplLocator ( const Subsystem::Guts sys,
const State state 
) [friend]

Referenced by Subsystem::Guts::Guts().

int subsystemRealizeTimeImplLocator ( const Subsystem::Guts sys,
const State state 
) [friend]

Referenced by Subsystem::Guts::Guts().

int subsystemRealizePositionImplLocator ( const Subsystem::Guts sys,
const State state 
) [friend]

Referenced by Subsystem::Guts::Guts().

int subsystemRealizeVelocityImplLocator ( const Subsystem::Guts sys,
const State state 
) [friend]

Referenced by Subsystem::Guts::Guts().

int subsystemRealizeDynamicsImplLocator ( const Subsystem::Guts sys,
const State state 
) [friend]

Referenced by Subsystem::Guts::Guts().

int subsystemRealizeAccelerationImplLocator ( const Subsystem::Guts sys,
const State state 
) [friend]

Referenced by Subsystem::Guts::Guts().

int subsystemRealizeReportImplLocator ( const Subsystem::Guts sys,
const State state 
) [friend]

Referenced by Subsystem::Guts::Guts().

int subsystemCalcQUnitWeightsImplLocator ( const Subsystem::Guts sys,
const State s,
Vector weights 
) [friend]

Referenced by Subsystem::Guts::Guts().

int subsystemCalcUUnitWeightsImplLocator ( const Subsystem::Guts sys,
const State s,
Vector weights 
) [friend]

Referenced by Subsystem::Guts::Guts().

int subsystemCalcZUnitWeightsImplLocator ( const Subsystem::Guts sys,
const State s,
Vector weights 
) [friend]

Referenced by Subsystem::Guts::Guts().

int subsystemCalcQErrUnitTolerancesImplLocator ( const Subsystem::Guts sys,
const State s,
Vector tolerances 
) [friend]

Referenced by Subsystem::Guts::Guts().

int subsystemCalcUErrUnitTolerancesImplLocator ( const Subsystem::Guts sys,
const State s,
Vector tolerances 
) [friend]

Referenced by Subsystem::Guts::Guts().

int subsystemCalcDecorativeGeometryAndAppendImplLocator ( const Subsystem::Guts sys,
const State s,
Stage  g,
std::vector< DecorativeGeometry > &  geom 
) [friend]

Referenced by Subsystem::Guts::Guts().


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

Generated on Fri Sep 26 07:44:30 2008 for SimTKcore by  doxygen 1.5.6