Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   Related Pages  

rdMuscleZajac Class Reference

A class that represents a lumped parameter muscle in series with a linear tendon. More...

#include <rdMuscleZajac.h>

Inheritance diagram for rdMuscleZajac:

rdForce rdActuator rdObject List of all members.

Public Member Functions

 rdMuscleZajac (int aQID=-1, int aNX=1, int aNY=2, int aNYP=0)
 Default constructor.

 rdMuscleZajac (IDOM_Element *aElement, int aNX=1, int aNY=2, int aNYP=0)
 Construct the actuator from an XML Element.

 rdMuscleZajac (const rdMuscleZajac &aActuator)
 Copy constructor.

virtual ~rdMuscleZajac ()
 Destructor.

virtual rdActuatorcopy () const
 Copy this actuator and return a pointer to the copy.

virtual rdActuatorcopy (IDOM_Element *aElement) const
 Copy this actuator and modify the copy so that it is consistent with a specified XML element node.

rdMuscleZajac & operator= (const rdMuscleZajac &aActuator)
 Assignment operator.

virtual void setControls (const double aX[])
 Set the controls.

virtual void getControls (double rX[]) const
 Get the controls.

virtual void setStates (const double aY[])
 Set the states.

virtual void getStates (double rY[]) const
 Get the states.

void setRiseTime (double aTime)
 Set the activation rise time.

double getRiseTime () const
 Get the activation rise time.

void setFallTime (double aTime)
 Set the activation fall time.

double getFallTime () const
 Get the activation fall time.

void setOptimalForce (double aForce)
 Set the optimal force of the muscle.

double getOptimalForce () const
 Get the optimal force of the muscle.

void setOptimalFiberLength (double aLength)
 Set the optimal muscle fiber length.

double getOptimalFiberLength () const
 Get the optimal muscle fiber length.

void setOptimalPennationAngle (double aAngle)
 Set the optimal muscle fiber pennation angle.

double getOptimalPennationAngle () const
 Get the optimal muscle fiber pennation angle.

void setTendonSlackLength (double aLength)
 Set the slack length of the tendon.

double getTendonSlackLength () const
 Get the slack length of the tendon.

void setMaxShorteningVelocity (double aVelocity)
 Set the maximum shortening velocity of the muscle.

double getMaxShorteningVelocity () const
 Get the maximum shortening velocity of the muscle.

virtual void promoteControlsToStates (const double aX[], double aDT)
 Set the activation level of this actuator equal to the neural excitation.

virtual void computeActuation ()
 Compute all quantities necessary for applying the actuator force to the model.

virtual void computeStateDerivatives (double rDYDT[])
 Compute the time derivatives of the states for this actuator.

virtual double computeDFDT ()
 Compute the time derivative of actuator force.

virtual void updateObject (bool aDeep=true)
 Update this object based on its XML node.

virtual void updateNode (bool aDeep=true)
 Update the XML node representing this object.

virtual void generateNode (IDOM_Element *aParent)
 Generate an XML node representing this object.

void updateData ()
 Update the member data of this object based on its XML node.


Static Public Member Functions

double ComputeForceLengthCurve (double aLmNorm)
 Compute the normalized isometric muscle force based on the force-length curve.

double ComputeShorteningVelocity (double aFmNormIso, double aFmNorm)
 Compute the normalized shortening velocity of the contractile element.


Static Public Attributes

const char PROP_RISE_TIME [] = "activation_rise_time"
const char PROP_FALL_TIME [] = "activation_fall_time"
const char PROP_OPTIMAL_FORCE [] = "optimal_force"
const char PROP_OPTIMAL_FIBER_LENGTH [] = "optimal_fiber_length"
const char PROP_OPTIMAL_PENNATION_ANGLE []
const char PROP_TENDON_SLACK_LENGTH []
const char PROP_MAX_SHORTENING_VELOCITY []
const double C1 = 18.0
const double C2 = 0.020833
const double PE1 = 0.1
const double SIG0 = 0.01
const double LMNORMMAX = 1.6
const double flcoef [][6]
const double fvcoef [][6]

Protected Attributes

double _x
 Excitation (control 0).

double _a
 Activation level (state 0).

double _tRise
 Rise time of muscle activation in seconds.

double _tFall
 Fall time of muscle activation in seconds.

double _fmOpt
 Optimal muscle force in Newtons.

double _lmOpt
 Optimal muscle fiber length in meters.

double _alphaOpt
 Optimal muscle pennation angle in degrees.

double _vmMax
 Maximum muscle fiber shortening velocity in optimal fiber lengths per second.

double _ltSlack
 Tendon slack length in meters.

double _lmOptRecip
 Reciprocal of muscle length.

double _width
 Muscle width in meters.

double _widthSquared
 Muscle width squared.

double _ktRecip
 Reciprocal of normalized tendon stiffness.

double _ktLmOptRecip
 Reciprocal of normalized tendon stiffness times optimal fiber length.

double _lmt
 Actuator length.


Private Member Functions

void setNull ()
 Set the data members of this actuator to their null values.

void copyData (const rdMuscleZajac &aActuator)
 Copy the member data of the specified actuator.


Detailed Description

A class that represents a lumped parameter muscle in series with a linear tendon.

The muscle is comprised of three elements: the contractile element models the force-length-velocity properties of muscle; the series elastic element is in series with the contractile element an models the short-range elastic response of muscle; the parallel elastic element is in parallel with both the series elastic element and the contractile element and models the passive elastic properties of muscle.

For details concerning this model consult Zajac, F.E. (1989). ??. Reviews in Sports Science ??.

Controls (1): 0) excitation

States (2): 0) activation level 1) musculotendon force

Author:
Frank C. Anderson
Version:
1.0


Constructor & Destructor Documentation

rdMuscleZajac::rdMuscleZajac IDOM_Element *  aElement,
int  aNX = 1,
int  aNY = 2,
int  aNYP = 0
 

Construct the actuator from an XML Element.

Parameters:
aElement XML element.
aNX Number of controls.
aNY Number of states.
aNYP Number of pseudo-states.

rdMuscleZajac::rdMuscleZajac const rdMuscleZajac &  aActuator  ) 
 

Copy constructor.

Parameters:
aActuator Actuator to be copied.


Member Function Documentation

double rdMuscleZajac::computeDFDT  )  [virtual]
 

Compute the time derivative of actuator force.

Returns:
Time derivative of normalized muscle force.

double rdMuscleZajac::ComputeForceLengthCurve double  aLmNorm  )  [static]
 

Compute the normalized isometric muscle force based on the force-length curve.

Parameters:
aLmNorm Normalized muscle force.
Returns:
Muscle (or sarcomere) force.

double rdMuscleZajac::ComputeShorteningVelocity double  aFmNormIso,
double  aFmNorm
[static]
 

Compute the normalized shortening velocity of the contractile element.

To get the actual shortening velocity the returned quantity must be multiplied by the maximum shortening velocity.

Parameters:
aFmNormIsometric Normalized force that would be generated by the muscle under isometric conditions. This value can be computed by calling computeForceLengthCurve().
aFmNorm Normalized force currently being generated by the muscle.
Returns:
Contractile shortening velocity in optimal fibers per second. Positive values indicate shortening.

void rdMuscleZajac::computeStateDerivatives double  rDYDT[]  )  [virtual]
 

Compute the time derivatives of the states for this actuator.

Parameters:
rDYDT Time derivatives of the states-- should have a length of at least the value returned by getNY().
See also:
getNY()

Reimplemented from rdActuator.

rdActuator * rdMuscleZajac::copy IDOM_Element *  aElement  )  const [virtual]
 

Copy this actuator and modify the copy so that it is consistent with a specified XML element node.

The copy is constructed by first using the contructor for the IDOM_Element in order to establish the relationship of the rdForce object with the XML node. Then, the assignment operator is used to set all data members of the copy to the values of this object. Finally, the data members of the copy are updated from the IDOM_Elment using updateObject().

Parameters:
aElement XML element.
Returns:
Pointer to a copy of this actuator.

Reimplemented from rdForce.

rdActuator * rdMuscleZajac::copy  )  const [virtual]
 

Copy this actuator and return a pointer to the copy.

The copy constructor for this class is used.

Returns:
Pointer to a copy of this actuator.

Reimplemented from rdForce.

void rdMuscleZajac::generateNode IDOM_Element *  aParent  )  [virtual]
 

Generate an XML node representing this object.

Parameters:
aParent Intended parent of the node to be generated. If aParent is NULL, the intent is for this object to serve as the root element of a new document.
See also:
rdObject::generateNode()

Reimplemented from rdForce.

void rdMuscleZajac::getControls double  rX[]  )  const [virtual]
 

Get the controls.

This actuator has 1 control: excitation.

Parameters:
rX Control array- should have a length of at least 1.

Reimplemented from rdForce.

double rdMuscleZajac::getFallTime  )  const
 

Get the activation fall time.

Returns:
Fall time of activation dynamics.

double rdMuscleZajac::getMaxShorteningVelocity  )  const
 

Get the maximum shortening velocity of the muscle.

Returns:
Maximum shortening velocity in optimal muscle fiber lengths per second- should be positive.

double rdMuscleZajac::getOptimalFiberLength  )  const
 

Get the optimal muscle fiber length.

Returns:
Optimal muscle fiber length.

double rdMuscleZajac::getOptimalForce  )  const
 

Get the optimal force of the muscle.

Returns:
Optimal muscle force.

double rdMuscleZajac::getOptimalPennationAngle  )  const
 

Get the optimal muscle fiber pennation angle.

Returns:
Optimal muscle fiber pennation angle in degrees.

double rdMuscleZajac::getRiseTime  )  const
 

Get the activation rise time.

Returns:
Rise time of activation dynamics.

void rdMuscleZajac::getStates double  rY[]  )  const [virtual]
 

Get the states.

This actuator has 2 states: activation and actuator force.

Parameters:
rY States array- should have a length of at least 2.

Reimplemented from rdActuator.

double rdMuscleZajac::getTendonSlackLength  )  const
 

Get the slack length of the tendon.

Returns:
Tendon slack length in meters.

rdMuscleZajac & rdMuscleZajac::operator= const rdMuscleZajac &  aActuator  ) 
 

Assignment operator.

Returns:
Reference to the altered object.

void rdMuscleZajac::setControls const double  aX[]  )  [virtual]
 

Set the controls.

This actuator has 1 control: excitation.

Parameters:
aX Control array- should have a length of at least 1.

Reimplemented from rdForce.

void rdMuscleZajac::setFallTime double  aTime  ) 
 

Set the activation fall time.

Parameters:
aTime Fall time of activation dynamics.

void rdMuscleZajac::setMaxShorteningVelocity double  aVelocity  ) 
 

Set the maximum shortening velocity of the muscle.

Parameters:
aVelocity Maximum shortening velocity in optimal muscle fiber lengths per second- should be positive.

void rdMuscleZajac::setOptimalFiberLength double  aLength  ) 
 

Set the optimal muscle fiber length.

Parameters:
aLength Optimal muscle fiber length in meters- should be positive.

void rdMuscleZajac::setOptimalForce double  aForce  ) 
 

Set the optimal force of the muscle.

Parameters:
aForce Optimal muscle force.

void rdMuscleZajac::setOptimalPennationAngle double  aAngle  ) 
 

Set the optimal muscle fiber pennation angle.

Note that during a simulation, the pennation angle of the muscle fibers changes. The optimal pennation angle is the pennation angle when the muscle is at its optimal muscle fiber length.

The width of the muscle is assumed to be constant. The width is computed from the optimal pennation angle and the optimal muscle fiber length (width = lmOpt * sin(pennation)) every time this method is called.

Parameters:
aAngleDeg Optimal pennation angle in degrees- should be positive.

void rdMuscleZajac::setRiseTime double  aTime  ) 
 

Set the activation rise time.

Parameters:
aTime Rise time of activation dynamics.

void rdMuscleZajac::setStates const double  aY[]  )  [virtual]
 

Set the states.

This actuator has 2 states: activation and actuator force.

Parameters:
aY States array- should have a length of at least 2.

Reimplemented from rdActuator.

void rdMuscleZajac::setTendonSlackLength double  aLength  ) 
 

Set the slack length of the tendon.

Parameters:
aLength Tendon slack length in meters.

void rdMuscleZajac::updateData  ) 
 

Update the member data of this object based on its XML node.

Member objects (children) are not updated.

Reimplemented from rdForce.

void rdMuscleZajac::updateNode bool  aDeep = true  )  [virtual]
 

Update the XML node representing this object.

Parameters:
aDeep If true, update the XML node of this object AND the XML nodes of all class members that are rdObjects (child nodes); if false, update only the XML node of this object without updating the XML nodes of its children.

Reimplemented from rdForce.

void rdMuscleZajac::updateObject bool  aDeep = true  )  [virtual]
 

Update this object based on its XML node.

Parameters:
aDeep If true, update this object and all its child objects (that is, member variables that are rdObject's); if false, update only the member variables that are not rdObject's.

Reimplemented from rdForce.


Member Data Documentation

const char rdMuscleZajac::PROP_MAX_SHORTENING_VELOCITY [static]
 

Initial value:

            "max_shortening_velocity"

const char rdMuscleZajac::PROP_OPTIMAL_PENNATION_ANGLE [static]
 

Initial value:

 
            "optimal_pennation_angle"

const char rdMuscleZajac::PROP_TENDON_SLACK_LENGTH [static]
 

Initial value:

            "tendon_slack_length"


The documentation for this class was generated from the following files:
Generated on Wed Aug 20 02:17:12 2003 for Simulation Software by doxygen1.3