OpenSim
OpenSim 3.1
|
MuscleActiveFiberPowerProbe is a ModelComponent probe for computing an operation on the active fiber power of a muscle. More...
#include <MuscleActiveFiberPowerProbe.h>
Property declarations | |
These are the serializable properties associated with this class. | |
OpenSim_DECLARE_LIST_PROPERTY (muscle_names, std::string,"Specify a list of muscles whose work should be calculated. ""If multiple muscles are given, the probe value will be the summation"" of all actuator powers.") | |
List of Muscles to probe. | |
MuscleActiveFiberPowerProbe () | |
Default constructor. | |
MuscleActiveFiberPowerProbe (const Array< std::string > muscle_names) | |
Convenience constructor. | |
const Property< std::string > & | getMuscleNames () const |
Returns the names of the Actuators being probed. | |
void | setMuscleNames (const Array< std::string > &muscleNames) |
Sets the names of the Actuators being probed. | |
SimTK::Vector | computeProbeInputs (const SimTK::State &state) const override |
Compute the Actuator power upon which the Probe operation will be based. | |
int | getNumProbeInputs () const override |
Returns the number of probe inputs in the vector returned by computeProbeInputs(). | |
virtual OpenSim::Array < std::string > | getProbeOutputLabels () const override |
Returns the column labels of the probe values for reporting. |
Additional Inherited Members | |
Public Member Functions inherited from OpenSim::Probe | |
Probe () | |
void | reset (SimTK::State &s) |
Reset (initialize) the underlying Probe SimTK::Measure. | |
int | getNumInternalMeasureStates () const |
Get the number of states in the underlying SimTK::Measure. | |
bool | isDisabled () const |
Returns true if the Probe is disabled or false if the probe is enabled. | |
void | setDisabled (bool isDisabled) |
Set the Probe as disabled (true) or enabled (false). | |
std::string | getOperation () const |
Return the operation being performed on the probe value. | |
void | setOperation (std::string probe_operation) |
Set the operation being performed on the probe value. | |
SimTK::Vector | getInitialConditions () const |
Return the initial conditions (when the probe_operation is set to 'integrate'). | |
void | setInitialConditions (SimTK::Vector initial_conditions_for_integration) |
Set the initial conditions (when the probe_operation is set to 'integrate'). | |
double | getGain () const |
Return the gain to apply to the probe output. | |
void | setGain (double gain) |
Set the gain to apply to the probe output. | |
SimTK::Vector | getProbeOutputs (const SimTK::State &state) const |
Returns the values of the probe after the operation has been performed. | |
OpenSim_DECLARE_PROPERTY (isDisabled, bool,"Flag indicating whether the Probe is disabled or not.") | |
Enabled by default. | |
OpenSim_DECLARE_PROPERTY (probe_operation, std::string,"The operation to perform on the probe input value: ""'value'(no operation, just return the probe value), 'integrate', ""'differentiate', 'minimum', 'minabs', 'maximum', 'maxabs'.") | |
OpenSim_DECLARE_LIST_PROPERTY (initial_conditions_for_integration, double,"Array of initial conditions to be specified if the 'integrate' operation is ""selected. Note that the size of initial conditions must be the same size as ""the data being integrated, otherwise an exception will be thrown.") | |
OpenSim_DECLARE_PROPERTY (gain, double,"Constant gain to scale the probe output by.") | |
Static Public Member Functions inherited from OpenSim::Object | |
static void | registerType (const Object &defaultObject) |
Register an instance of a class; if the class is already registered it will be replaced. | |
static void | renameType (const std::string &oldTypeName, const std::string &newTypeName) |
Support versioning by associating the current Object type with an old name. | |
static const Object * | getDefaultInstanceOfType (const std::string &concreteClassName) |
Return a pointer to the default instance of the registered (concrete) Object whose class name is given, or NULL if the type is not registered. | |
template<class T > | |
static bool | isObjectTypeDerivedFrom (const std::string &concreteClassName) |
Return true if the given concrete object type represents a subclass of the template object type T, and thus could be referenced with a T*. | |
static Object * | newInstanceOfType (const std::string &concreteClassName) |
Create a new instance of the concrete Object type whose class name is given as concreteClassName. | |
static void | getRegisteredTypenames (Array< std::string > &typeNames) |
Retrieve all the typenames registered so far. | |
template<class T > | |
static void | getRegisteredObjectsOfGivenType (ArrayPtrs< T > &rArray) |
Return an array of pointers to the default instances of all registered (concrete) Object types that derive from a given Object-derived type that does not have to be concrete. | |
static void | PrintPropertyInfo (std::ostream &os, const std::string &classNameDotPropertyName) |
Dump formatted property information to a given output stream, useful for creating a "help" facility for registered objects. | |
static void | PrintPropertyInfo (std::ostream &os, const std::string &className, const std::string &propertyName) |
Same as the other signature but the class name and property name are provided as two separate strings. | |
static Object * | makeObjectFromFile (const std::string &fileName) |
Create an OpenSim object whose type is based on the tag at the root node of the XML file passed in. | |
static const std::string & | getClassName () |
Return the name of this class as a string; i.e., "Object". | |
static void | setSerializeAllDefaults (bool shouldSerializeDefaults) |
Static function to control whether all registered objects and their properties are written to the defaults section of output files rather than only those values for which the default was explicitly overwritten when read in from an input file or set programmatically. | |
static bool | getSerializeAllDefaults () |
Report the value of the "serialize all defaults" flag. | |
static bool | isKindOf (const char *type) |
Returns true if the passed-in string is "Object"; each Object-derived class defines a method of this name for its own class name. | |
static void | setDebugLevel (int newLevel) |
Set the debug level to get verbose output. | |
static int | getDebugLevel () |
Get current setting of debug level. | |
static Object * | SafeCopy (const Object *aObject) |
Use the clone() method to duplicate the given object unless the pointer is null in which case null is returned. | |
static void | RegisterType (const Object &defaultObject) |
OBSOLETE alternate name for registerType(). | |
static void | RenameType (const std::string &oldName, const std::string &newName) |
OBSOLETE alternate name for renameType(). | |
Static Public Attributes inherited from OpenSim::Object | |
static const std::string | DEFAULT_NAME |
Name used for default objects when they are serialized. | |
Protected Member Functions inherited from OpenSim::Probe | |
void | connectToModel (Model &model) override |
Concrete probes may override; be sure to invoke Super::connectToModel() at the beginning of the overriding method. | |
void | addToSystem (SimTK::MultibodySystem &system) const override |
Concrete probes may override; be sure to invoke Super::addToSystem() at the beginning of the overriding method. | |
Protected Attributes inherited from OpenSim::ModelComponent | |
Model * | _model |
The model this component belongs to. | |
Related Functions inherited from OpenSim::Object | |
#define | OpenSim_DECLARE_CONCRETE_OBJECT(ConcreteClass, SuperClass) |
Macro to be included as the first line of the class declaration for any non-templatized, concrete class that derives from OpenSim::Object. | |
#define | OpenSim_DECLARE_ABSTRACT_OBJECT(ConcreteClass, SuperClass) |
Macro to be included as the first line of the class declaration for any still-abstract class that derives from OpenSim::Object. | |
#define | OpenSim_DECLARE_CONCRETE_OBJECT_T(ConcreteClass, TArg, SuperClass) |
Macro to be included as the first line of the class declaration for any templatized, concrete class that derives from OpenSim::Object, like Set<T>. | |
#define | OpenSim_DECLARE_ABSTRACT_OBJECT_T(ConcreteClass, TArg, SuperClass) |
Macro to be included as the first line of the class declaration for any templatized, still-abstract class that derives from OpenSim::Object. |
MuscleActiveFiberPowerProbe is a ModelComponent probe for computing an operation on the active fiber power of a muscle.
OpenSim::MuscleActiveFiberPowerProbe::MuscleActiveFiberPowerProbe | ( | ) |
Default constructor.
OpenSim::MuscleActiveFiberPowerProbe::MuscleActiveFiberPowerProbe | ( | const Array< std::string > | muscle_names | ) |
Convenience constructor.
|
overridevirtual |
Compute the Actuator power upon which the Probe operation will be based.
Implements OpenSim::Probe.
const Property<std::string>& OpenSim::MuscleActiveFiberPowerProbe::getMuscleNames | ( | ) | const |
Returns the names of the Actuators being probed.
|
overridevirtual |
Returns the number of probe inputs in the vector returned by computeProbeInputs().
Implements OpenSim::Probe.
|
overridevirtual |
Returns the column labels of the probe values for reporting.
Currently uses the Probe name as the column label, so be sure to name your probe appropiately!
Implements OpenSim::Probe.
OpenSim::MuscleActiveFiberPowerProbe::OpenSim_DECLARE_LIST_PROPERTY | ( | muscle_names | , |
std::string | , | ||
"Specify a list of muscles whose work should be calculated. ""If multiple muscles are | given, | ||
the probe value will be the summation""of all actuator powers." | |||
) |
List of Muscles to probe.
void OpenSim::MuscleActiveFiberPowerProbe::setMuscleNames | ( | const Array< std::string > & | muscleNames | ) |
Sets the names of the Actuators being probed.