qpOASES 3.2.1
An Implementation of the Online Active Set Strategy
Public Member Functions | Protected Attributes | List of all members
MyConstraintProduct Class Reference

Example illustrating the use of the ConstraintProduct class. More...

Inheritance diagram for MyConstraintProduct:
ConstraintProduct

Public Member Functions

 MyConstraintProduct ()
 
 MyConstraintProduct (int_t _nV, int_t _nC, real_t *_A)
 
 MyConstraintProduct (const MyConstraintProduct &rhs)
 
virtual ~MyConstraintProduct ()
 
MyConstraintProductoperator= (const MyConstraintProduct &rhs)
 
virtual int_t operator() (int_t constrIndex, const real_t *const x, real_t *const constrValue) const
 

Protected Attributes

int_t nV
 
int_t nC
 
real_tA
 

Detailed Description

Example illustrating the use of the ConstraintProduct class.

Author
Hans Joachim Ferreau
Version
3.2
Date
2007-2017

Constructor & Destructor Documentation

◆ MyConstraintProduct() [1/3]

MyConstraintProduct::MyConstraintProduct ( )
inline

Default constructor.

◆ MyConstraintProduct() [2/3]

MyConstraintProduct::MyConstraintProduct ( int_t  _nV,
int_t  _nC,
real_t _A 
)
inline

Constructor.

References A, nC, and nV.

◆ MyConstraintProduct() [3/3]

MyConstraintProduct::MyConstraintProduct ( const MyConstraintProduct rhs)
inline

Copy constructor (flat copy).

References A, nC, and nV.

◆ ~MyConstraintProduct()

virtual MyConstraintProduct::~MyConstraintProduct ( )
inlinevirtual

Destructor.

Member Function Documentation

◆ operator()()

virtual int_t MyConstraintProduct::operator() ( int_t  constrIndex,
const real_t *const  x,
real_t *const  constrValue 
) const
inlinevirtual

Evaluates the product of a given constraint with the current iterate. This function needs to be implemented in a derived class for the user-defined constraint product function.

Returns
0: successful
otherwise: not successful
Parameters
constrIndexNumber of constraint to be evaluated.
xArray containing current primal iterate.
constrValueOutput: Scalar value of the evaluated constraint.

Implements ConstraintProduct.

References A, and nV.

◆ operator=()

MyConstraintProduct & MyConstraintProduct::operator= ( const MyConstraintProduct rhs)
inline

Assignment operator (flat copy).

References A, nC, and nV.

Member Data Documentation

◆ A

real_t* MyConstraintProduct::A
protected

Pointer to full constraint matrix (typically not needed!).

Referenced by MyConstraintProduct(), operator()(), and operator=().

◆ nC

int_t MyConstraintProduct::nC
protected

Number of constraints.

Referenced by MyConstraintProduct(), and operator=().

◆ nV

int_t MyConstraintProduct::nV
protected

Number of variables.

Referenced by MyConstraintProduct(), operator()(), and operator=().


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