Control Libraries 7.4.0
Loading...
Searching...
No Matches
Public Member Functions | List of all members
dynamical_systems::PointAttractor< S > Class Template Reference

Represents a dynamical system to move towards an attractor. More...

#include <PointAttractor.hpp>

Inheritance diagram for dynamical_systems::PointAttractor< S >:
dynamical_systems::IDynamicalSystem< S > state_representation::ParameterMap

Public Member Functions

 PointAttractor ()
 Empty constructor.
 
 PointAttractor (const std::list< std::shared_ptr< state_representation::ParameterInterface > > &parameters)
 Constructor from an initial parameter list.
 
void set_base_frame (const S &base_frame) override
 Set the base frame of the dynamical system.
 
compute_dynamics (const S &state) const override
 Compute the dynamics of the input state. Internal function, to be redefined based on the type of dynamical system, called by the evaluate function.
 
bool is_compatible (const S &state) const override
 Check compatibility between a state and the dynamical system.
 
bool is_compatible (const JointState &state) const
 
void set_base_frame (const CartesianState &base_frame)
 
CartesianState compute_dynamics (const CartesianState &state) const
 
JointState compute_dynamics (const JointState &state) const
 
- Public Member Functions inherited from dynamical_systems::IDynamicalSystem< S >
 IDynamicalSystem ()=default
 Empty constructor.
 
evaluate (const S &state) const
 Evaluate the value of the dynamical system at a given state.
 
get_base_frame () const
 Return the base frame of the dynamical system.
 
- Public Member Functions inherited from state_representation::ParameterMap
 ParameterMap ()=default
 Empty constructor.
 
 ParameterMap (const ParameterInterfaceList &parameters)
 Construct the parameter map with an initial list of parameters.
 
 ParameterMap (const ParameterInterfaceMap &parameters)
 Construct the parameter map with an initial map of parameters.
 
std::shared_ptr< ParameterInterfaceget_parameter (const std::string &name) const
 Get a parameter by its name.
 
ParameterInterfaceMap get_parameters () const
 Get a map of all the <name, parameter> pairs.
 
template<typename T >
get_parameter_value (const std::string &name) const
 Get a parameter value by its name.
 
ParameterInterfaceList get_parameter_list () const
 Get a list of all the parameters.
 
void set_parameter (const std::shared_ptr< ParameterInterface > &parameter)
 Set a parameter.
 
void set_parameters (const ParameterInterfaceList &parameters)
 Set parameters from a list of parameters.
 
void set_parameters (const ParameterInterfaceMap &parameters)
 Set parameters from a map with <name, parameter> pairs.
 
template<typename T >
void set_parameter_value (const std::string &name, const T &value)
 Set a parameter value by its name.
 
void remove_parameter (const std::string &name)
 Remove a parameter from the parameter map.
 

Additional Inherited Members

- Protected Member Functions inherited from state_representation::ParameterMap
void assert_parameter_valid (const std::shared_ptr< ParameterInterface > &parameter)
 Check if a parameter exists and has the expected type, throw an exception otherwise.
 
- Protected Attributes inherited from state_representation::ParameterMap
ParameterInterfaceMap parameters_
 map of parameters by name
 

Detailed Description

template<class S>
class dynamical_systems::PointAttractor< S >

Represents a dynamical system to move towards an attractor.

Template Parameters
SUnderlying state type of the dynamical system

Definition at line 14 of file PointAttractor.hpp.

Constructor & Destructor Documentation

◆ PointAttractor() [1/3]

template<class S >
dynamical_systems::PointAttractor< S >::PointAttractor ( const std::list< std::shared_ptr< state_representation::ParameterInterface > > &  parameters)
explicit

Constructor from an initial parameter list.

Parameters
parametersA parameter list containing initial attractor and gain values

Definition at line 65 of file PointAttractor.hpp.

◆ PointAttractor() [2/3]

Definition at line 19 of file PointAttractor.cpp.

◆ PointAttractor() [3/3]

Definition at line 27 of file PointAttractor.cpp.

Member Function Documentation

◆ compute_dynamics() [1/3]

CartesianState dynamical_systems::PointAttractor< CartesianState >::compute_dynamics ( const CartesianState state) const

Definition at line 180 of file PointAttractor.cpp.

◆ compute_dynamics() [2/3]

JointState dynamical_systems::PointAttractor< JointState >::compute_dynamics ( const JointState state) const

Definition at line 190 of file PointAttractor.cpp.

◆ compute_dynamics() [3/3]

template<class S >
S dynamical_systems::PointAttractor< S >::compute_dynamics ( const S &  state) const
overridevirtual

Compute the dynamics of the input state. Internal function, to be redefined based on the type of dynamical system, called by the evaluate function.

Parameters
stateThe input state
Returns
The output state

Implements dynamical_systems::IDynamicalSystem< S >.

Definition at line 175 of file PointAttractor.cpp.

◆ is_compatible() [1/2]

bool dynamical_systems::PointAttractor< JointState >::is_compatible ( const JointState state) const

Definition at line 42 of file PointAttractor.cpp.

◆ is_compatible() [2/2]

template<class S >
template bool dynamical_systems::PointAttractor< S >::is_compatible ( const S &  state) const
overridevirtual

Check compatibility between a state and the dynamical system.

Parameters
stateThe state to check for compatibility
Returns
True if the state is compatible with the dynamical system

Reimplemented from dynamical_systems::IDynamicalSystem< S >.

Definition at line 35 of file PointAttractor.cpp.

◆ set_base_frame() [1/2]

void dynamical_systems::PointAttractor< CartesianState >::set_base_frame ( const CartesianState base_frame)

Definition at line 129 of file PointAttractor.cpp.

◆ set_base_frame() [2/2]

template<class S >
template void dynamical_systems::PointAttractor< S >::set_base_frame ( const S &  base_frame)
overridevirtual

Set the base frame of the dynamical system.

Parameters
base_frameThe new base frame

Reimplemented from dynamical_systems::IDynamicalSystem< S >.

Definition at line 122 of file PointAttractor.cpp.


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