qpOASES  3.2.1
An Implementation of the Online Active Set Strategy
Constraints.hpp
Go to the documentation of this file.
1 /*
2  * This file is part of qpOASES.
3  *
4  * qpOASES -- An Implementation of the Online Active Set Strategy.
5  * Copyright (C) 2007-2017 by Hans Joachim Ferreau, Andreas Potschka,
6  * Christian Kirches et al. All rights reserved.
7  *
8  * qpOASES is free software; you can redistribute it and/or
9  * modify it under the terms of the GNU Lesser General Public
10  * License as published by the Free Software Foundation; either
11  * version 2.1 of the License, or (at your option) any later version.
12  *
13  * qpOASES is distributed in the hope that it will be useful,
14  * but WITHOUT ANY WARRANTY; without even the implied warranty of
15  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
16  * See the GNU Lesser General Public License for more details.
17  *
18  * You should have received a copy of the GNU Lesser General Public
19  * License along with qpOASES; if not, write to the Free Software
20  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
21  *
22  */
23 
24 
36 #ifndef QPOASES_CONSTRAINTS_HPP
37 #define QPOASES_CONSTRAINTS_HPP
38 
39 
40 #include <qpOASES/SubjectTo.hpp>
41 
42 
44 
45 
56 class Constraints : public SubjectTo
57 {
58  /*
59  * PUBLIC MEMBER FUNCTIONS
60  */
61  public:
63  Constraints( );
64 
66  Constraints( int_t _n
67  );
68 
70  Constraints( const Constraints& rhs
71  );
72 
74  virtual ~Constraints( );
75 
77  Constraints& operator=( const Constraints& rhs
78  );
79 
80 
84  returnValue init( int_t _n = 0
85  );
86 
87 
95  SubjectToStatus _status
96  );
97 
104 
111 
118 
119 
124  );
125 
130  SubjectToStatus _status
131  );
132 
137  returnValue flipFixed( int_t number );
138 
139 
142  inline int_t getNC( ) const;
143 
146  inline int_t getNEC( ) const;
147 
150  inline int_t getNIC( ) const;
151 
154  inline int_t getNUC( ) const;
155 
158  inline int_t getNAC( ) const;
159 
162  inline int_t getNIAC( ) const;
163 
164 
167  inline Indexlist* getActive( );
168 
171  inline Indexlist* getInactive( );
172 
173 
185  virtual returnValue shift( int_t offset
186  );
187 
195  virtual returnValue rotate( int_t offset
196  );
197 
198 
203  returnValue print( );
204 
205 
206  /*
207  * PROTECTED MEMBER FUNCTIONS
208  */
209  protected:
212  returnValue clear( );
213 
216  returnValue copy( const Constraints& rhs
217  );
218 
219 
226  );
227 
228 
229  /*
230  * PROTECTED MEMBER VARIABLES
231  */
232  protected:
235 };
236 
238 
239 #include <qpOASES/Constraints.ipp>
240 
241 #endif /* QPOASES_CONSTRAINTS_HPP */
242 
243 
244 /*
245  * end of file
246  */
Constraints::getNIC
int_t getNIC() const
Definition: Constraints.ipp:65
Constraints::getNAC
int_t getNAC() const
Definition: Constraints.ipp:83
Constraints::setupConstraint
returnValue setupConstraint(int_t number, SubjectToStatus _status)
Definition: Constraints.cpp:123
Constraints::inactive
Indexlist inactive
Definition: Constraints.hpp:234
SubjectTo.hpp
Constraints::getNEC
int_t getNEC() const
Definition: Constraints.ipp:56
END_NAMESPACE_QPOASES
#define END_NAMESPACE_QPOASES
Definition: Types.hpp:110
Constraints::setupAllLower
returnValue setupAllLower()
Definition: Constraints.cpp:168
Constraints
Manages working sets of constraints.
Definition: Constraints.hpp:56
BEGIN_NAMESPACE_QPOASES
#define BEGIN_NAMESPACE_QPOASES
Definition: Types.hpp:107
Constraints::rotate
virtual returnValue rotate(int_t offset)
Definition: Constraints.cpp:309
Constraints::clear
returnValue clear()
Definition: Constraints.cpp:422
Constraints::setupAllInactive
returnValue setupAllInactive()
Definition: Constraints.cpp:159
Constraints::getNC
int_t getNC() const
Definition: Constraints.ipp:47
Constraints::active
Indexlist active
Definition: Constraints.hpp:233
Constraints::~Constraints
virtual ~Constraints()
Definition: Constraints.cpp:76
Constraints::getNUC
int_t getNUC() const
Definition: Constraints.ipp:74
Constraints::setupAll
returnValue setupAll(SubjectToStatus _status)
Definition: Constraints.cpp:445
Constraints::copy
returnValue copy(const Constraints &rhs)
Definition: Constraints.cpp:431
SubjectTo
Base class for managing working sets of bounds and constraints.
Definition: SubjectTo.hpp:56
SubjectToStatus
SubjectToStatus
Definition: Types.hpp:272
returnValue
returnValue
Defines all symbols for global return values.
Definition: MessageHandling.hpp:64
Constraints::moveInactiveToActive
returnValue moveInactiveToActive(int_t number, SubjectToStatus _status)
Definition: Constraints.cpp:206
Constraints::flipFixed
returnValue flipFixed(int_t number)
Definition: Constraints.cpp:227
Constraints::shift
virtual returnValue shift(int_t offset)
Definition: Constraints.cpp:248
Constraints::Constraints
Constraints()
Definition: Constraints.cpp:50
Constraints::getNIAC
int_t getNIAC() const
Definition: Constraints.ipp:92
Constraints::getInactive
Indexlist * getInactive()
Definition: Constraints.ipp:111
Constraints::moveActiveToInactive
returnValue moveActiveToInactive(int_t number)
Definition: Constraints.cpp:186
Constraints::getActive
Indexlist * getActive()
Definition: Constraints.ipp:102
Constraints::setupAllUpper
returnValue setupAllUpper()
Definition: Constraints.cpp:177
Indexlist
Stores and manages index lists.
Definition: Indexlist.hpp:55
Constraints.ipp
Constraints::print
returnValue print()
Definition: Constraints.cpp:384
Constraints::operator=
Constraints & operator=(const Constraints &rhs)
Definition: Constraints.cpp:85
Constraints::init
returnValue init(int_t _n=0)
Definition: Constraints.cpp:101
int_t
int int_t
Definition: Types.hpp:180