Manages working sets of constraints. More...
#include <Constraints.hpp>
Manages working sets of constraints.
This class manages working sets of constraints by storing index sets and other status information.
This class manages working sets of constraints by storing index sets and other status information.
Definition at line 50 of file examples/code_generation/mpc_mhe/getting_started_export/qpoases/INCLUDE/Constraints.hpp.
Default constructor.
Definition at line 46 of file examples/code_generation/mpc_mhe/getting_started_export/qpoases/SRC/Constraints.cpp.
Constraints::Constraints | ( | const Constraints & | rhs | ) |
Copy constructor (deep copy).
rhs | Rhs object. |
Definition at line 58 of file examples/code_generation/mpc_mhe/getting_started_export/qpoases/SRC/Constraints.cpp.
Destructor.
Definition at line 72 of file examples/code_generation/mpc_mhe/getting_started_export/qpoases/SRC/Constraints.cpp.
Default constructor.
Constraints::Constraints | ( | const Constraints & | rhs | ) |
Copy constructor (deep copy).
rhs | Rhs object. |
Destructor.
Default constructor.
Constraints::Constraints | ( | int | _n | ) |
Constructor which takes the number of constraints.
_n | Number of constraints. |
Definition at line 58 of file external_packages/qpOASES-3.0beta/src/Constraints.cpp.
Constraints::Constraints | ( | const Constraints & | rhs | ) |
Copy constructor (deep copy).
rhs | Rhs object. |
virtual Constraints::~Constraints | ( | ) | [virtual] |
Destructor.
returnValue Constraints::clear | ( | ) | [protected] |
Frees all allocated memory.
Reimplemented from SubjectTo.
Definition at line 423 of file external_packages/qpOASES-3.0beta/src/Constraints.cpp.
returnValue Constraints::copy | ( | const Constraints & | rhs | ) | [protected] |
Copies all members from given rhs object.
rhs | Rhs object. |
Definition at line 432 of file external_packages/qpOASES-3.0beta/src/Constraints.cpp.
returnValue Constraints::flipFixed | ( | int | number | ) |
Flip fixed constraint.
Definition at line 227 of file external_packages/qpOASES-3.0beta/src/Constraints.cpp.
Indexlist* Constraints::getActive | ( | ) | [inline] |
Returns a pointer to active constraints index list.
Indexlist* Constraints::getActive | ( | ) | [inline] |
Returns a pointer to active constraints index list.
Indexlist* Constraints::getActive | ( | ) | [inline] |
Returns a pointer to active constraints index list.
Indexlist* Constraints::getInactive | ( | ) | [inline] |
Returns a pointer to inactive constraints index list.
Indexlist* Constraints::getInactive | ( | ) | [inline] |
Returns a pointer to inactive constraints index list.
Indexlist* Constraints::getInactive | ( | ) | [inline] |
Returns a pointer to inactive constraints index list.
int Constraints::getNAC | ( | ) | [inline] |
Returns the number of active constraints.
int Constraints::getNAC | ( | ) | [inline] |
Returns the number of active constraints.
int Constraints::getNAC | ( | ) | const [inline] |
Returns the number of active constraints.
int Constraints::getNC | ( | ) | const [inline] |
Returns the number of constraints.
int Constraints::getNC | ( | ) | const [inline] |
Returns the number of constraints.
int Constraints::getNC | ( | ) | const [inline] |
Returns the number of constraints.
int Constraints::getNEC | ( | ) | const [inline] |
Returns the number of implicit equality constraints.
int Constraints::getNEC | ( | ) | const [inline] |
Returns the number of implicit equality constraints.
int Constraints::getNEC | ( | ) | const [inline] |
Returns the number of implicit equality constraints.
int Constraints::getNIAC | ( | ) | [inline] |
Returns the number of inactive constraints.
int Constraints::getNIAC | ( | ) | [inline] |
Returns the number of inactive constraints.
int Constraints::getNIAC | ( | ) | const [inline] |
Returns the number of inactive constraints.
int Constraints::getNIC | ( | ) | const [inline] |
Returns the number of "real" inequality constraints.
int Constraints::getNIC | ( | ) | const [inline] |
Returns the number of "real" inequality constraints.
int Constraints::getNIC | ( | ) | const [inline] |
Returns the number of "real" inequality constraints.
int Constraints::getNUC | ( | ) | const [inline] |
Returns the number of unbounded constraints (i.e. without any bounds).
int Constraints::getNUC | ( | ) | const [inline] |
Returns the number of unbounded constraints (i.e. without any bounds).
int Constraints::getNUC | ( | ) | const [inline] |
Returns the number of unbounded constraints (i.e. without any bounds).
returnValue Constraints::init | ( | int | n | ) |
Pseudo-constructor takes the number of constraints.
n | Number of constraints. |
Reimplemented from SubjectTo.
returnValue Constraints::init | ( | int | n | ) |
Pseudo-constructor takes the number of constraints.
n | Number of constraints. |
Reimplemented from SubjectTo.
Definition at line 102 of file examples/code_generation/mpc_mhe/getting_started_export/qpoases/SRC/Constraints.cpp.
returnValue Constraints::init | ( | int | _n = 0 | ) |
Initialises object with given number of constraints.
_n | Number of constraints. |
Reimplemented from SubjectTo.
returnValue Constraints::moveActiveToInactive | ( | int | _number | ) |
Moves index of a constraint from index list of active to that of inactive constraints.
_number | Number of constraint to become inactive. |
Definition at line 207 of file examples/code_generation/mpc_mhe/getting_started_export/qpoases/SRC/Constraints.cpp.
returnValue Constraints::moveActiveToInactive | ( | int | _number | ) |
Moves index of a constraint from index list of active to that of inactive constraints.
_number | Number of constraint to become inactive. |
returnValue Constraints::moveActiveToInactive | ( | int | number | ) |
Moves index of a constraint from index list of active to that of inactive constraints.
number | Number of constraint to become inactive. |
returnValue Constraints::moveInactiveToActive | ( | int | _number, |
SubjectToStatus | _status | ||
) |
Moves index of a constraint from index list of inactive to that of active constraints.
_number | Number of constraint to become active. |
_status | Status of constraint to become active. |
Definition at line 227 of file examples/code_generation/mpc_mhe/getting_started_export/qpoases/SRC/Constraints.cpp.
returnValue Constraints::moveInactiveToActive | ( | int | _number, |
SubjectToStatus | _status | ||
) |
Moves index of a constraint from index list of inactive to that of active constraints.
_number | Number of constraint to become active. |
_status | Status of constraint to become active. |
returnValue Constraints::moveInactiveToActive | ( | int | number, |
SubjectToStatus | _status | ||
) |
Moves index of a constraint from index list of inactive to that of active constraints.
number | Number of constraint to become active. |
_status | Status of constraint to become active. |
Constraints& Constraints::operator= | ( | const Constraints & | rhs | ) |
Assignment operator (deep copy).
rhs | Rhs object. |
Constraints & Constraints::operator= | ( | const Constraints & | rhs | ) |
Assignment operator (deep copy).
rhs | Rhs object. |
Definition at line 80 of file examples/code_generation/mpc_mhe/getting_started_export/qpoases/SRC/Constraints.cpp.
Constraints& Constraints::operator= | ( | const Constraints & | rhs | ) |
Assignment operator (deep copy).
rhs | Rhs object. |
Prints information on constraints object (in particular, lists of inactive and active constraints.
Definition at line 384 of file external_packages/qpOASES-3.0beta/src/Constraints.cpp.
returnValue Constraints::rotate | ( | int | offset | ) | [virtual] |
Rotates forward type and status of all constraints by a given offset. This offset has to lie within the range [0,n]. Example for offset = 2:
rotate( {c/b1,c/b2,c/b3,c/b4,c/b5,c/b6} ) = {c/b3,c/b4,c/b5,c/b6,c/b1,c/b2}
offset | Rotation offset within the range [0,n]. |
Implements SubjectTo.
Definition at line 309 of file external_packages/qpOASES-3.0beta/src/Constraints.cpp.
returnValue Constraints::setNEC | ( | int | n | ) | [inline] |
Sets number of implicit equality constraints.
n | Number of implicit equality constraints. |
returnValue Constraints::setNEC | ( | int | n | ) | [inline] |
Sets number of implicit equality constraints.
n | Number of implicit equality constraints. |
returnValue Constraints::setNIC | ( | int | n | ) | [inline] |
Sets number of "real" inequality constraints.
n | Number of "real" inequality constraints. |
returnValue Constraints::setNIC | ( | int | n | ) | [inline] |
Sets number of "real" inequality constraints.
n | Number of "real" inequality constraints. |
returnValue Constraints::setNUC | ( | int | n | ) | [inline] |
Sets number of unbounded constraints (i.e. without any bounds).
n | Number of unbounded constraints (i.e. without any bounds). |
returnValue Constraints::setNUC | ( | int | n | ) | [inline] |
Sets number of unbounded constraints (i.e. without any bounds).
n | Number of unbounded constraints (i.e. without any bounds). |
returnValue Constraints::setupAll | ( | SubjectToStatus | _status | ) | [protected] |
Initially adds all numbers of new (i.e. not yet in the list) bounds to to the index set corresponding to the desired status; the order depends on the SujectToType of each index.
_status | Desired initial status for all bounds. |
Definition at line 446 of file external_packages/qpOASES-3.0beta/src/Constraints.cpp.
Initially adds all enabled numbers of new (i.e. not yet in the list) constraints to to the index set of inactive constraints; the order depends on the SujectToType of each index. Only disabled constraints are added to index set of disabled constraints!
Initially adds all enabled numbers of new (i.e. not yet in the list) constraints to to the index set of inactive constraints; the order depends on the SujectToType of each index. Only disabled constraints are added to index set of disabled constraints!
Definition at line 155 of file examples/code_generation/mpc_mhe/getting_started_export/qpoases/SRC/Constraints.cpp.
Initially adds all enabled numbers of new (i.e. not yet in the list) constraints to to the index set of inactive constraints; the order depends on the SujectToType of each index. Only disabled constraints are added to index set of disabled constraints!
Initially adds all enabled numbers of new (i.e. not yet in the list) constraints to to the index set of active constraints (on their lower bounds); the order depends on the SujectToType of each index. Only disabled constraints are added to index set of disabled constraints!
Definition at line 168 of file external_packages/qpOASES-3.0beta/src/Constraints.cpp.
Initially adds all enabled numbers of new (i.e. not yet in the list) constraints to to the index set of active constraints (on their upper bounds); the order depends on the SujectToType of each index. Only disabled constraints are added to index set of disabled constraints!
Definition at line 177 of file external_packages/qpOASES-3.0beta/src/Constraints.cpp.
returnValue Constraints::setupConstraint | ( | int | _number, |
SubjectToStatus | _status | ||
) |
Initially adds number of a new (i.e. not yet in the list) constraint to a given index set.
_number | Number of new constraint. |
_status | Status of new constraint. |
returnValue Constraints::setupConstraint | ( | int | _number, |
SubjectToStatus | _status | ||
) |
Initially adds number of a new (i.e. not yet in the list) constraint to a given index set.
_number | Number of new constraint. |
_status | Status of new constraint. |
Definition at line 119 of file examples/code_generation/mpc_mhe/getting_started_export/qpoases/SRC/Constraints.cpp.
returnValue Constraints::setupConstraint | ( | int | number, |
SubjectToStatus | _status | ||
) |
Initially adds number of a new (i.e. not yet in the list) constraint to a given index set.
number | Number of new constraint. |
_status | Status of new constraint. |
returnValue Constraints::shift | ( | int | offset | ) | [virtual] |
Shifts forward type and status of all constraints by a given offset. This offset has to lie within the range [0,n/2] and has to be an integer divisor of the total number of constraints n. Type and status of the first <offset> constraints is thrown away, type and status of the last <offset> constraints is real_td, e.g. for offset = 2:
shift( {c/b1,c/b2,c/b3,c/b4,c/b5,c/b6} ) = {c/b3,c/b4,c/b5,c/b6,c/b5,c/b6}
offset | Shift offset within the range [0,n/2] and integer divisor of n. |
Implements SubjectTo.
Definition at line 248 of file external_packages/qpOASES-3.0beta/src/Constraints.cpp.
Indexlist Constraints::active [protected] |
Index list of active constraints.
Definition at line 169 of file examples/code_generation/mpc_mhe/getting_started_export/qpoases/INCLUDE/Constraints.hpp.
Indexlist Constraints::inactive [protected] |
Index list of inactive constraints.
Definition at line 170 of file examples/code_generation/mpc_mhe/getting_started_export/qpoases/INCLUDE/Constraints.hpp.
int Constraints::nC [protected] |
Number of constraints (nC = nEC + nIC + nUC).
Definition at line 164 of file examples/code_generation/mpc_mhe/getting_started_export/qpoases/INCLUDE/Constraints.hpp.
int Constraints::nEC [protected] |
Number of implicit equality constraints.
Definition at line 165 of file examples/code_generation/mpc_mhe/getting_started_export/qpoases/INCLUDE/Constraints.hpp.
int Constraints::nIC [protected] |
Number of "real" inequality constraints.
Definition at line 166 of file examples/code_generation/mpc_mhe/getting_started_export/qpoases/INCLUDE/Constraints.hpp.
int Constraints::nUC [protected] |
Number of unbounded constraints (i.e. without any bounds).
Definition at line 167 of file examples/code_generation/mpc_mhe/getting_started_export/qpoases/INCLUDE/Constraints.hpp.