#include <CoordinateActuator.h>
Public Member Functions | |
CoordinateActuator (std::string aCoordinateName="") | |
CoordinateActuator (const CoordinateActuator &aGenForce) | |
Copy constructor. | |
virtual | ~CoordinateActuator () |
Destructor. | |
virtual Object * | copy () const |
Copy this actuator and return a pointer to the copy. | |
void | copyData (const CoordinateActuator &aGenForce) |
Copy the member data of the specified actuator. | |
CoordinateActuator & | operator= (const CoordinateActuator &aGenForce) |
Assignment operator. | |
void | setCoordinate (Coordinate *aCoordinate) |
Set the generalized coordinate to which the coordinate actuator is applied. | |
Coordinate * | getCoordinate () const |
Get the generalized coordinate to which the coordinate actuator is applied. | |
void | setOptimalForce (double aOptimalForce) |
Set the optimal force of the force. | |
double | getOptimalForce () const |
Get the optimal force of the force. | |
double | getStress (const SimTK::State &s) const |
Get the stress of the force. | |
virtual void | initStateCache (SimTK::State &s, SimTK::SubsystemIndex subsystemIndex, Model &model) |
virtual void | computeForce (const SimTK::State &s) const |
Apply the actuator force to BodyA and BodyB. | |
virtual double | computeActuation (const SimTK::State &s) const |
Compute all quantities necessary for applying the actuator force to the model. | |
virtual bool | check () const |
Check that this coordinate actuator actuator is valid. | |
virtual bool | isCoordinateValid () const |
Is the. | |
void | createSystem (SimTK::MultibodySystem &system) const |
setup sets the actual Coordinate reference _coord | |
virtual OpenSim::Array < std::string > | getRecordLabels () const |
Methods to query a Force for the value actually applied during simulation The names of the quantities (column labels) is returned by this first function getRecordLabels(). | |
virtual OpenSim::Array< double > | getRecordValues (const SimTK::State &state) const |
Given SimTK::State object extract all the values necessary to report forces, application location frame, etc. | |
virtual void | updateFromXMLNode () |
Update this object based on its XML node. | |
OPENSIM_DECLARE_DERIVED (CoordinateActuator, Actuator) | |
Static Public Member Functions | |
static ForceSet * | CreateForceSetOfCoordinateActuatorsForModel (const SimTK::State &s, Model &aModel, double aOptimalForce=1, bool aIncludeLockedAndConstrainedCoordinates=true) |
Protected Attributes | |
PropertyStr | _propCoordinateName |
Name of coordinate to which the coordinate actuator is applied. | |
PropertyDbl | _propOptimalForce |
Optimal force. | |
std::string & | _coordName |
double & | _optimalForce |
Coordinate * | _coord |
Corresponding generalized coordinate to which the coordinate actuator is applied. |
OpenSim::CoordinateActuator::CoordinateActuator | ( | std::string | aCoordinateName = "" |
) |
CoordinateActuator::CoordinateActuator | ( | const CoordinateActuator & | aGenForce | ) |
Copy constructor.
aForce | Force to be copied. |
CoordinateActuator::~CoordinateActuator | ( | ) | [virtual] |
Destructor.
bool CoordinateActuator::check | ( | ) | const [virtual] |
Check that this coordinate actuator actuator is valid.
Reimplemented from OpenSim::Actuator.
double CoordinateActuator::computeActuation | ( | const SimTK::State & | s | ) | const [virtual] |
Compute all quantities necessary for applying the actuator force to the model.
Implements OpenSim::Actuator.
void CoordinateActuator::computeForce | ( | const SimTK::State & | s | ) | const [virtual] |
Apply the actuator force to BodyA and BodyB.
Implements OpenSim::CustomActuator.
Object * CoordinateActuator::copy | ( | ) | const [virtual] |
Copy this actuator and return a pointer to the copy.
The copy constructor for this class is used.
Implements OpenSim::Actuator.
Reimplemented in OpenSim::PassiveJointTorque.
void CoordinateActuator::copyData | ( | const CoordinateActuator & | aGenForce | ) |
Copy the member data of the specified actuator.
ForceSet * CoordinateActuator::CreateForceSetOfCoordinateActuatorsForModel | ( | const SimTK::State & | s, | |
Model & | aModel, | |||
double | aOptimalForce = 1 , |
|||
bool | aIncludeLockedAndConstrainedCoordinates = true | |||
) | [static] |
void CoordinateActuator::createSystem | ( | SimTK::MultibodySystem & | system | ) | const [virtual] |
setup sets the actual Coordinate reference _coord
Reimplemented from OpenSim::CustomActuator.
Coordinate * CoordinateActuator::getCoordinate | ( | ) | const |
Get the generalized coordinate to which the coordinate actuator is applied.
double CoordinateActuator::getOptimalForce | ( | ) | const [virtual] |
OpenSim::Array< std::string > CoordinateActuator::getRecordLabels | ( | ) | const [virtual] |
Methods to query a Force for the value actually applied during simulation The names of the quantities (column labels) is returned by this first function getRecordLabels().
Reimplemented from OpenSim::Force.
OpenSim::Array< double > CoordinateActuator::getRecordValues | ( | const SimTK::State & | state | ) | const [virtual] |
Given SimTK::State object extract all the values necessary to report forces, application location frame, etc.
used in conjunction with getRecordLabels and should return same size Array
Reimplemented from OpenSim::Force.
double CoordinateActuator::getStress | ( | const SimTK::State & | s | ) | const [virtual] |
void CoordinateActuator::initStateCache | ( | SimTK::State & | s, | |
SimTK::SubsystemIndex | subsystemIndex, | |||
Model & | model | |||
) | [virtual] |
Reimplemented from OpenSim::Actuator.
bool CoordinateActuator::isCoordinateValid | ( | ) | const [virtual] |
Is the.
OpenSim::CoordinateActuator::OPENSIM_DECLARE_DERIVED | ( | CoordinateActuator | , | |
Actuator | ||||
) |
Reimplemented from OpenSim::CustomActuator.
Reimplemented in OpenSim::PassiveJointTorque.
CoordinateActuator & CoordinateActuator::operator= | ( | const CoordinateActuator & | aGenForce | ) |
Assignment operator.
Reimplemented from OpenSim::Actuator.
Reimplemented in OpenSim::PassiveJointTorque.
void CoordinateActuator::setCoordinate | ( | Coordinate * | aCoordinate | ) |
Set the generalized coordinate to which the coordinate actuator is applied.
aCoordinate | Pointer to the generalized coordinate. |
void CoordinateActuator::setOptimalForce | ( | double | aOptimalForce | ) |
Set the optimal force of the force.
aOptimalForce | Optimal force. |
void CoordinateActuator::updateFromXMLNode | ( | ) | [virtual] |
Update this object based on its XML node.
This method simply calls Object::updateFromXMLNode() and then calls a few methods in this class to ensure that variable members have been set in a consistent manner.
Reimplemented from OpenSim::Object.
Coordinate* OpenSim::CoordinateActuator::_coord [mutable, protected] |
Corresponding generalized coordinate to which the coordinate actuator is applied.
std::string& OpenSim::CoordinateActuator::_coordName [protected] |
double& OpenSim::CoordinateActuator::_optimalForce [protected] |
Name of coordinate to which the coordinate actuator is applied.
Optimal force.