A class implementing a SIMM muscle. More...
#include <Schutte1993Muscle.h>
Public Member Functions | |
Schutte1993Muscle () | |
Default constructor. | |
Schutte1993Muscle (const std::string &aName, double aMaxIsometricForce, double aOptimalFiberLength, double aTendonSlackLength, double aPennationAngle) | |
Constructor. | |
Schutte1993Muscle (const Schutte1993Muscle &aMuscle) | |
Copy constructor. | |
virtual | ~Schutte1993Muscle () |
Destructor. | |
virtual Object * | copy () const |
Copy this muscle point and return a pointer to the copy. | |
Schutte1993Muscle & | operator= (const Schutte1993Muscle &aMuscle) |
Assignment operator. | |
void | copyData (const Schutte1993Muscle &aMuscle) |
Copy data members from one Schutte1993Muscle to another. | |
virtual double | getTimeScale () const |
virtual double | getDamping () const |
virtual bool | setTimeScale (double aTimeScale) |
Set the scale factor for normalizing time. | |
virtual bool | setActivation1 (double aActivation1) |
Set the time constant of ramping up of muscle force. | |
virtual bool | setActivation2 (double aActivation2) |
Set the time constant of ramping up and ramping down of muscle force. | |
virtual bool | setDamping (double aDamping) |
Set the damping factor related to maximum contraction velocity. | |
virtual double | getDamping () |
virtual void | computeEquilibrium (SimTK::State &s) const |
Compute the equilibrium states. | |
virtual double | computeActuation (const SimTK::State &s) const |
Compute the actuation for the muscle. | |
virtual double | computeIsometricForce (SimTK::State &s, double activation) const |
computeIsometricForce: this function finds the force in a muscle, assuming static equilibrium. | |
virtual Function * | getActiveForceLengthCurve () const |
Get the active force-length curve. | |
virtual bool | setActiveForceLengthCurve (Function *aActiveForceLengthCurve) |
Set the active force-length curve. | |
virtual Function * | getPassiveForceLengthCurve () const |
Get the passive force-length curve. | |
virtual bool | setPassiveForceLengthCurve (Function *aPassiveForceLengthCurve) |
Get the passive force-length curve. | |
virtual Function * | getTendonForceLengthCurve () const |
Get the tendon force-length curve. | |
virtual bool | setTendonForceLengthCurve (Function *aTendonForceLengthCurve) |
Get the tendon force-length curve. | |
virtual int | getStateVariableYIndex (int index) const |
Get the YIndex of a state variable allocated by this ModelComponent. | |
OPENSIM_DECLARE_DERIVED (Schutte1993Muscle, ActivationFiberLengthMuscle) | |
Protected Member Functions | |
virtual void | setup (Model &aModel) |
Perform some set up functions that happen after the object has been deserialized or copied. | |
virtual void | createSystem (SimTK::MultibodySystem &system) const |
allocate and initialize the SimTK state for this acuator. | |
virtual SimTK::Vector | computeStateVariableDerivatives (const SimTK::State &s) const |
Compute the derivatives of the muscle states. | |
Protected Attributes | |
PropertyDbl | _timeScaleProp |
Scale factor for normalizing time. | |
double & | _timeScale |
PropertyDbl | _activation1Prop |
Parameter used in time constant of ramping up of muscle force. | |
double & | _activation1 |
PropertyDbl | _activation2Prop |
Parameter used in time constant of ramping up and ramping down of muscle force. | |
double & | _activation2 |
PropertyDbl | _dampingProp |
Damping factor related to maximum contraction velocity. | |
double & | _damping |
PropertyObjPtr< Function > | _tendonForceLengthCurveProp |
Function *& | _tendonForceLengthCurve |
PropertyObjPtr< Function > | _activeForceLengthCurveProp |
Function *& | _activeForceLengthCurve |
PropertyObjPtr< Function > | _passiveForceLengthCurveProp |
Function *& | _passiveForceLengthCurve |
Static Protected Attributes | |
static const int | STATE_ACTIVATION = 0 |
static const int | STATE_FIBER_LENGTH = 1 |
A class implementing a SIMM muscle.
Schutte1993Muscle::Schutte1993Muscle | ( | ) |
Default constructor.
Schutte1993Muscle::Schutte1993Muscle | ( | const std::string & | aName, | |
double | aMaxIsometricForce, | |||
double | aOptimalFiberLength, | |||
double | aTendonSlackLength, | |||
double | aPennationAngle | |||
) |
Constructor.
Schutte1993Muscle::Schutte1993Muscle | ( | const Schutte1993Muscle & | aMuscle | ) |
Copy constructor.
aMuscle | Schutte1993Muscle to be copied. |
Schutte1993Muscle::~Schutte1993Muscle | ( | ) | [virtual] |
Destructor.
double Schutte1993Muscle::computeActuation | ( | const SimTK::State & | s | ) | const [virtual] |
Compute the actuation for the muscle.
This function assumes that computeDerivatives has already been called.
Implements OpenSim::ActivationFiberLengthMuscle.
void Schutte1993Muscle::computeEquilibrium | ( | SimTK::State & | s | ) | const [virtual] |
Compute the equilibrium states.
This method computes a fiber length for the muscle that is consistent with the muscle's activation level.
Reimplemented from OpenSim::Actuator_.
double Schutte1993Muscle::computeIsometricForce | ( | SimTK::State & | s, | |
double | aActivation | |||
) | const [virtual] |
computeIsometricForce: this function finds the force in a muscle, assuming static equilibrium.
Using the total muscle-tendon length, it finds the fiber and tendon lengths so that the forces in each match. This routine takes pennation angle into account, so its definition of static equilibrium is when tendon_force = fiber_force * cos(pennation_angle). This funcion will modify the object's values for length, fiberLength, and passiveForce.
aActivation | Activation of the muscle. |
Implements OpenSim::ActivationFiberLengthMuscle.
SimTK::Vector Schutte1993Muscle::computeStateVariableDerivatives | ( | const SimTK::State & | s | ) | const [protected, virtual] |
Compute the derivatives of the muscle states.
rDYDT | the state derivatives are returned here. |
Reimplemented from OpenSim::ModelComponent.
Object * Schutte1993Muscle::copy | ( | ) | const [virtual] |
Copy this muscle point and return a pointer to the copy.
The copy constructor for this class is used.
Implements OpenSim::ActivationFiberLengthMuscle.
void Schutte1993Muscle::copyData | ( | const Schutte1993Muscle & | aMuscle | ) |
Copy data members from one Schutte1993Muscle to another.
aMuscle | Schutte1993Muscle to be copied. |
Reimplemented from OpenSim::ActivationFiberLengthMuscle.
void Schutte1993Muscle::createSystem | ( | SimTK::MultibodySystem & | system | ) | const [protected, virtual] |
allocate and initialize the SimTK state for this acuator.
Reimplemented from OpenSim::ActivationFiberLengthMuscle.
Function * Schutte1993Muscle::getActiveForceLengthCurve | ( | ) | const [virtual] |
Get the active force-length curve.
virtual double OpenSim::Schutte1993Muscle::getDamping | ( | ) | [inline, virtual] |
virtual double OpenSim::Schutte1993Muscle::getDamping | ( | ) | const [inline, virtual] |
Function * Schutte1993Muscle::getPassiveForceLengthCurve | ( | ) | const [virtual] |
Get the passive force-length curve.
int Schutte1993Muscle::getStateVariableYIndex | ( | int | index | ) | const [virtual] |
Get the YIndex of a state variable allocated by this ModelComponent.
The default implementation throws an exception, so subclasses that allocate state variables must override it.
index | the index of the state variable (0 to getNumStateVariables()-1) |
Reimplemented from OpenSim::ModelComponent.
Function * Schutte1993Muscle::getTendonForceLengthCurve | ( | ) | const [virtual] |
Get the tendon force-length curve.
virtual double OpenSim::Schutte1993Muscle::getTimeScale | ( | ) | const [inline, virtual] |
OpenSim::Schutte1993Muscle::OPENSIM_DECLARE_DERIVED | ( | Schutte1993Muscle | , | |
ActivationFiberLengthMuscle | ||||
) |
Schutte1993Muscle & Schutte1993Muscle::operator= | ( | const Schutte1993Muscle & | aMuscle | ) |
Assignment operator.
Reimplemented from OpenSim::ActivationFiberLengthMuscle.
bool Schutte1993Muscle::setActivation1 | ( | double | aActivation1 | ) | [virtual] |
Set the time constant of ramping up of muscle force.
aActivation1 | The time constant of ramping up of muscle force. |
bool Schutte1993Muscle::setActivation2 | ( | double | aActivation2 | ) | [virtual] |
Set the time constant of ramping up and ramping down of muscle force.
aActivation1 | The time constant of ramping up and ramping down of muscle force. |
bool Schutte1993Muscle::setActiveForceLengthCurve | ( | Function * | aActiveForceLengthCurve | ) | [virtual] |
bool Schutte1993Muscle::setDamping | ( | double | aDamping | ) | [virtual] |
Set the damping factor related to maximum contraction velocity.
aDamping | The damping factor related to maximum contraction velocity. |
bool Schutte1993Muscle::setPassiveForceLengthCurve | ( | Function * | aPassiveForceLengthCurve | ) | [virtual] |
Get the passive force-length curve.
aPassiveForceLengthCurve | Pointer to a passive force-length curve (Function). |
bool Schutte1993Muscle::setTendonForceLengthCurve | ( | Function * | aTendonForceLengthCurve | ) | [virtual] |
Get the tendon force-length curve.
aTendonForceLengthCurve | Pointer to a tendon force-length curve (Function). |
bool Schutte1993Muscle::setTimeScale | ( | double | aTimeScale | ) | [virtual] |
Set the scale factor for normalizing time.
aTimeScale | The scale factor for normalizing time. |
void Schutte1993Muscle::setup | ( | Model & | aModel | ) | [protected, virtual] |
Perform some set up functions that happen after the object has been deserialized or copied.
aModel | model containing this Schutte1993Muscle. |
Reimplemented from OpenSim::ActivationFiberLengthMuscle.
double& OpenSim::Schutte1993Muscle::_activation1 [protected] |
Parameter used in time constant of ramping up of muscle force.
double& OpenSim::Schutte1993Muscle::_activation2 [protected] |
Parameter used in time constant of ramping up and ramping down of muscle force.
Function*& OpenSim::Schutte1993Muscle::_activeForceLengthCurve [protected] |
double& OpenSim::Schutte1993Muscle::_damping [protected] |
PropertyDbl OpenSim::Schutte1993Muscle::_dampingProp [protected] |
Damping factor related to maximum contraction velocity.
Function*& OpenSim::Schutte1993Muscle::_passiveForceLengthCurve [protected] |
Function*& OpenSim::Schutte1993Muscle::_tendonForceLengthCurve [protected] |
double& OpenSim::Schutte1993Muscle::_timeScale [protected] |
Scale factor for normalizing time.
const int Schutte1993Muscle::STATE_ACTIVATION = 0 [static, protected] |
Reimplemented from OpenSim::ActivationFiberLengthMuscle.
const int Schutte1993Muscle::STATE_FIBER_LENGTH = 1 [static, protected] |
Reimplemented from OpenSim::ActivationFiberLengthMuscle.