Biorbd Release_1.13.0
Loading...
Searching...
No Matches
BIORBD_NAMESPACE::internal_forces::muscles::MuscleGroup Class Reference

A muscle group is muscle that share parents for both origin and insertion. More...

#include <MuscleGroup.h>

Public Member Functions

 MuscleGroup ()
 Construct a muscle group.
 MuscleGroup (const MuscleGroup &other)
 Construct a muscle group from another muscle group.
 MuscleGroup (const utils::String &name, const utils::String &originName, const utils::String &insertionName)
 Construct a muscle group.
virtual ~MuscleGroup ()
 Destroy class properly.
MuscleGroup DeepCopy () const
 Deep copy of a muscle group.
void DeepCopy (const MuscleGroup &other)
 Deep copy of a muscle group in new muscle group.
virtual void addMuscle (const utils::String &name, MUSCLE_TYPE type, const MuscleGeometry &geometry, const Characteristics &characteristics, STATE_TYPE stateType=STATE_TYPE::NO_STATE_TYPE, STATE_FATIGUE_TYPE dynamicFatigueType=STATE_FATIGUE_TYPE::NO_FATIGUE_STATE_TYPE)
 To add a muscle to the group.
virtual void addMuscle (const utils::String &name, MUSCLE_TYPE type, const MuscleGeometry &geometry, const Characteristics &characteristics, STATE_FATIGUE_TYPE dynamicFatigueType)
 To add a muscle to the group.
virtual void addMuscle (const utils::String &name, MUSCLE_TYPE type, const MuscleGeometry &geometry, const Characteristics &characteristics, const internal_forces::PathModifiers &pathModifiers, STATE_TYPE stateType=STATE_TYPE::NO_STATE_TYPE, STATE_FATIGUE_TYPE dynamicFatigueType=STATE_FATIGUE_TYPE::NO_FATIGUE_STATE_TYPE)
 To add a muscle to the group.
virtual void addMuscle (const utils::String &name, MUSCLE_TYPE type, const MuscleGeometry &geometry, const Characteristics &characteristics, const internal_forces::PathModifiers &pathModifiers, STATE_FATIGUE_TYPE dynamicFatigueType)
 To add a muscle to the group.
virtual void addMuscle (const Muscle &muscle)
 To add a muscle to the group.
size_t nbMuscles () const
 Return the number of muscles in the group.
std::vector< std::shared_ptr< Muscle > > & muscles ()
 Return the muscles in the group.
const std::vector< std::shared_ptr< Muscle > > & muscles () const
 Return the muscles in the group.
Muscle & muscle (size_t idx)
 Return the muscle of a specific index in the group.
const Muscle & muscle (size_t idx) const
 Return the muscle of a specific index in the group.
int muscleID (const utils::String &name)
 Return the muscle index.
void setName (const utils::String &name)
 Set the name of the muscle group.
const utils::String & name () const
 Return the name of the muscle group.
void setOrigin (const utils::String &name)
 Set the origin segment name where the origin lies.
const utils::String & origin () const
 Return the origin segment name.
void setInsertion (const utils::String &name)
 Set the insertion segment name where the origin lies.
const utils::String & insertion () const
 Return the insertion segment name.

Protected Attributes

std::shared_ptr< std::vector< std::shared_ptr< Muscle > > > m_mus
 The set of muscles.
std::shared_ptr< utils::String > m_name
 The muscle group name.
std::shared_ptr< utils::String > m_originName
 The origin name.
std::shared_ptr< utils::String > m_insertName
 The insertion name.

Detailed Description

A muscle group is muscle that share parents for both origin and insertion.

Definition at line 28 of file MuscleGroup.h.

Constructor & Destructor Documentation

◆ MuscleGroup() [1/3]

internal_forces::muscles::MuscleGroup::MuscleGroup ( )

Construct a muscle group.

Definition at line 17 of file MuscleGroup.cpp.

◆ MuscleGroup() [2/3]

internal_forces::muscles::MuscleGroup::MuscleGroup ( const MuscleGroup & other)

Construct a muscle group from another muscle group.

Parameters
otherThe other muscle group

Definition at line 25 of file MuscleGroup.cpp.

◆ MuscleGroup() [3/3]

internal_forces::muscles::MuscleGroup::MuscleGroup ( const utils::String & name,
const utils::String & originName,
const utils::String & insertionName )

Construct a muscle group.

Parameters
nameThe name of the muscle group
originNameThe segment name where the origin lies
insertionNameThe segment name where the insertion lies

Definition at line 32 of file MuscleGroup.cpp.

◆ ~MuscleGroup()

internal_forces::muscles::MuscleGroup::~MuscleGroup ( )
virtual

Destroy class properly.

Definition at line 43 of file MuscleGroup.cpp.

Member Function Documentation

◆ addMuscle() [1/5]

void internal_forces::muscles::MuscleGroup::addMuscle ( const Muscle & muscle)
virtual

To add a muscle to the group.

Parameters
muscleThe muscle to add

Definition at line 336 of file MuscleGroup.cpp.

◆ addMuscle() [2/5]

void internal_forces::muscles::MuscleGroup::addMuscle ( const utils::String & name,
MUSCLE_TYPE type,
const MuscleGeometry & geometry,
const Characteristics & characteristics,
const internal_forces::PathModifiers & pathModifiers,
STATE_FATIGUE_TYPE dynamicFatigueType )
virtual

To add a muscle to the group.

Parameters
nameName of the muscle
typeThe muscle type
geometryThe geometry of the muscle
characteristicsThe muscle characteristics
pathModifiersThe set of path modifiers
dynamicFatigueTypeThe dynamic state fatigue type

Definition at line 289 of file MuscleGroup.cpp.

◆ addMuscle() [3/5]

void internal_forces::muscles::MuscleGroup::addMuscle ( const utils::String & name,
MUSCLE_TYPE type,
const MuscleGeometry & geometry,
const Characteristics & characteristics,
const internal_forces::PathModifiers & pathModifiers,
STATE_TYPE stateType = STATE_TYPE::NO_STATE_TYPE,
STATE_FATIGUE_TYPE dynamicFatigueType = STATE_FATIGUE_TYPE::NO_FATIGUE_STATE_TYPE )
virtual

To add a muscle to the group.

Parameters
nameThe name of the muscle
typeThe muscle type
geometryThe geometry of the muscle
characteristicsThe muscle characteristics
pathModifiersThe set of path modifiers
stateTypeThe state stype
dynamicFatigueTypeThe dynamic state fatigue type

Definition at line 222 of file MuscleGroup.cpp.

◆ addMuscle() [4/5]

void internal_forces::muscles::MuscleGroup::addMuscle ( const utils::String & name,
MUSCLE_TYPE type,
const MuscleGeometry & geometry,
const Characteristics & characteristics,
STATE_FATIGUE_TYPE dynamicFatigueType )
virtual

To add a muscle to the group.

Parameters
nameThe name of the muscle
typeThe muscle type
geometryThe geometry of the muscle
characteristicsThe muscle characteristics
dynamicFatigueTypeThe dynamic state fatigue type

Definition at line 177 of file MuscleGroup.cpp.

◆ addMuscle() [5/5]

void internal_forces::muscles::MuscleGroup::addMuscle ( const utils::String & name,
MUSCLE_TYPE type,
const MuscleGeometry & geometry,
const Characteristics & characteristics,
STATE_TYPE stateType = STATE_TYPE::NO_STATE_TYPE,
STATE_FATIGUE_TYPE dynamicFatigueType = STATE_FATIGUE_TYPE::NO_FATIGUE_STATE_TYPE )
virtual

To add a muscle to the group.

Parameters
nameThe name of the muscle
typeThe muscle type
geometryThe geometry of the muscle
characteristicsThe muscle characteristics
stateTypeThe state stype
dynamicFatigueTypeThe dynamic state fatigue type

Definition at line 116 of file MuscleGroup.cpp.

◆ DeepCopy() [1/2]

internal_forces::muscles::MuscleGroup internal_forces::muscles::MuscleGroup::DeepCopy ( ) const

Deep copy of a muscle group.

Returns
A deep copy of a muscle group

Definition at line 46 of file MuscleGroup.cpp.

◆ DeepCopy() [2/2]

void internal_forces::muscles::MuscleGroup::DeepCopy ( const MuscleGroup & other)

Deep copy of a muscle group in new muscle group.

Parameters
otherThe muscle group to copy

Definition at line 52 of file MuscleGroup.cpp.

◆ insertion()

const utils::String & internal_forces::muscles::MuscleGroup::insertion ( ) const

Return the insertion segment name.

Returns
The insertion segment name

Definition at line 445 of file MuscleGroup.cpp.

◆ muscle() [1/2]

internal_forces::muscles::Muscle & internal_forces::muscles::MuscleGroup::muscle ( size_t idx)

Return the muscle of a specific index in the group.

Parameters
idxThe muscle index
Returns
The muscle of a specific index

Definition at line 388 of file MuscleGroup.cpp.

◆ muscle() [2/2]

const internal_forces::muscles::Muscle & internal_forces::muscles::MuscleGroup::muscle ( size_t idx) const

Return the muscle of a specific index in the group.

Parameters
idxThe muscle index
Returns
The muscle of a specific index

Definition at line 395 of file MuscleGroup.cpp.

◆ muscleID()

int internal_forces::muscles::MuscleGroup::muscleID ( const utils::String & name)

Return the muscle index.

Parameters
nameThe name of the muscle
Returns
The muscle index

Definition at line 415 of file MuscleGroup.cpp.

◆ muscles() [1/2]

std::vector< std::shared_ptr< internal_forces::muscles::Muscle > > & internal_forces::muscles::MuscleGroup::muscles ( )

Return the muscles in the group.

Returns
The muscles

Definition at line 406 of file MuscleGroup.cpp.

◆ muscles() [2/2]

const std::vector< std::shared_ptr< internal_forces::muscles::Muscle > > & internal_forces::muscles::MuscleGroup::muscles ( ) const

Return the muscles in the group.

Returns
The muscles

Definition at line 411 of file MuscleGroup.cpp.

◆ name()

const utils::String & internal_forces::muscles::MuscleGroup::name ( ) const

Return the name of the muscle group.

Returns
The name of the muscle

Definition at line 429 of file MuscleGroup.cpp.

◆ nbMuscles()

size_t internal_forces::muscles::MuscleGroup::nbMuscles ( ) const

Return the number of muscles in the group.

Returns
The number of muscles in the group

Definition at line 401 of file MuscleGroup.cpp.

◆ origin()

const utils::String & internal_forces::muscles::MuscleGroup::origin ( ) const

Return the origin segment name.

Returns
The origin segment name

Definition at line 437 of file MuscleGroup.cpp.

◆ setInsertion()

void internal_forces::muscles::MuscleGroup::setInsertion ( const utils::String & name)

Set the insertion segment name where the origin lies.

Parameters
nameThe insertion segment name where the origin lies

Definition at line 441 of file MuscleGroup.cpp.

◆ setName()

void internal_forces::muscles::MuscleGroup::setName ( const utils::String & name)

Set the name of the muscle group.

Parameters
nameThe name of the muscle group

Definition at line 426 of file MuscleGroup.cpp.

◆ setOrigin()

void internal_forces::muscles::MuscleGroup::setOrigin ( const utils::String & name)

Set the origin segment name where the origin lies.

Parameters
nameThe origin segment name where the origin lies

Definition at line 433 of file MuscleGroup.cpp.

Member Data Documentation

◆ m_insertName

std::shared_ptr<utils::String> BIORBD_NAMESPACE::internal_forces::muscles::MuscleGroup::m_insertName
protected

The insertion name.

Definition at line 227 of file MuscleGroup.h.

◆ m_mus

std::shared_ptr<std::vector<std::shared_ptr<Muscle> > > BIORBD_NAMESPACE::internal_forces::muscles::MuscleGroup::m_mus
protected

The set of muscles.

Definition at line 224 of file MuscleGroup.h.

◆ m_name

std::shared_ptr<utils::String> BIORBD_NAMESPACE::internal_forces::muscles::MuscleGroup::m_name
protected

The muscle group name.

Definition at line 225 of file MuscleGroup.h.

◆ m_originName

std::shared_ptr<utils::String> BIORBD_NAMESPACE::internal_forces::muscles::MuscleGroup::m_originName
protected

The origin name.

Definition at line 226 of file MuscleGroup.h.


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