![]() |
- 3.0.2 core module.
|
A constant controller. More...
#include <ConstantController.h>
Public Member Functions | |
| EIGEN_MAKE_ALIGNED_OPERATOR_NEW | ConstantController () |
| Default constructor. More... | |
| ConstantController (ControlVector< CONTROL_DIM, SCALAR > &u) | |
| Constructor. More... | |
| ConstantController (const ConstantController< STATE_DIM, CONTROL_DIM, SCALAR > &other) | |
| Copy constructor. More... | |
| virtual | ~ConstantController () |
| Destructor. More... | |
| ConstantController< STATE_DIM, CONTROL_DIM, SCALAR > * | clone () const override |
| Clone operator. More... | |
| void | computeControl (const StateVector< STATE_DIM, SCALAR > &state, const SCALAR &t, ControlVector< CONTROL_DIM, SCALAR > &controlAction) override |
| Computes current control. More... | |
| void | computeControl (const StateVector< STATE_DIM, SCALAR > &state, const int n, ControlVector< CONTROL_DIM, SCALAR > &controlAction) override |
| Equivalent method for discrete version. More... | |
| void | setControl (const ControlVector< CONTROL_DIM, SCALAR > &u) |
| Sets the control signal. More... | |
| const ControlVector< CONTROL_DIM, SCALAR > & | getControl () const |
| Get the fixed control signal. More... | |
| virtual ControlMatrix< CONTROL_DIM, SCALAR > | getDerivativeU0 (const StateVector< STATE_DIM, SCALAR > &state, const SCALAR time) override |
| Returns the the derivative of the control with respect to the initial control input u0. More... | |
Public Member Functions inherited from ct::core::Controller< STATE_DIM, CONTROL_DIM, SCALAR > | |
| EIGEN_MAKE_ALIGNED_OPERATOR_NEW | Controller () |
| Default constructor. More... | |
| Controller (const Controller &other) | |
| Copy constructor. More... | |
| virtual | ~Controller () |
| Destructor. More... | |
| virtual ControlMatrix< CONTROL_DIM, SCALAR > | getDerivativeUf (const StateVector< STATE_DIM, SCALAR > &state, const SCALAR time) |
| Returns the the derivative of the control with respect to the final control input uF. More... | |
Public Member Functions inherited from ct::core::DiscreteController< STATE_DIM, CONTROL_DIM, SCALAR > | |
| DiscreteController () | |
| Default constructor. More... | |
| DiscreteController (const DiscreteController &other) | |
| Copy constructor. More... | |
| virtual | ~DiscreteController () |
| Destructor. More... | |
| virtual void | computeControl (const state_vector_t &state, const int n, control_vector_t &controlAction)=0 |
| Compute control signal. More... | |
Additional Inherited Members | |
Public Types inherited from ct::core::DiscreteController< STATE_DIM, CONTROL_DIM, SCALAR > | |
| typedef ControlVector< CONTROL_DIM, SCALAR > | control_vector_t |
Public Attributes inherited from ct::core::DiscreteController< STATE_DIM, CONTROL_DIM, SCALAR > | |
| EIGEN_MAKE_ALIGNED_OPERATOR_NEW typedef StateVector< STATE_DIM, SCALAR > | state_vector_t |
A constant controller.
Implements a controller that is time and state invariant, i.e. fully constant. This class is useful to integrate a ControlledSystem forward subject to a constant control input.
| ct::core::ConstantController< STATE_DIM, CONTROL_DIM, SCALAR >::ConstantController | ( | ) |
Default constructor.
Sets the control signal to zero
| ct::core::ConstantController< STATE_DIM, CONTROL_DIM, SCALAR >::ConstantController | ( | ControlVector< CONTROL_DIM, SCALAR > & | u | ) |
Constructor.
Initializes the control to a fixed value
| u | The fixed control signal |
| ct::core::ConstantController< STATE_DIM, CONTROL_DIM, SCALAR >::ConstantController | ( | const ConstantController< STATE_DIM, CONTROL_DIM, SCALAR > & | other | ) |
Copy constructor.
|
virtual |
Destructor.
|
overridevirtual |
Clone operator.
Clones the controller. Used for cloning ControlledSystem's
Implements ct::core::Controller< STATE_DIM, CONTROL_DIM, SCALAR >.
|
overridevirtual |
Computes current control.
Returns the fixed control signal. Therefore, the return value is invariant to the parameters.
| state | The current state of the system (ignored) |
| t | The time of the system (ignored) |
| controlAction | The (fixed) control action |
Implements ct::core::Controller< STATE_DIM, CONTROL_DIM, SCALAR >.
Referenced by ct::core::ConstantController< STATE_DIM, CONTROL_DIM, SCALAR >::computeControl().
|
override |
Equivalent method for discrete version.
References ct::core::ConstantController< STATE_DIM, CONTROL_DIM, SCALAR >::computeControl().
| void ct::core::ConstantController< STATE_DIM, CONTROL_DIM, SCALAR >::setControl | ( | const ControlVector< CONTROL_DIM, SCALAR > & | u | ) |
Sets the control signal.
| u | The fixed control signal |
| const ControlVector< CONTROL_DIM, SCALAR > & ct::core::ConstantController< STATE_DIM, CONTROL_DIM, SCALAR >::getControl | ( | ) | const |
Get the fixed control signal.
| u | The control input to write the signal to. |
|
overridevirtual |
Returns the the derivative of the control with respect to the initial control input u0.
| [in] | state | The state at which the method will be evaluated |
| [in] | time | The time at which the method will be evaluated |
Reimplemented from ct::core::Controller< STATE_DIM, CONTROL_DIM, SCALAR >.