OPTPP::CompoundConstraint Class Reference

#include <CompoundConstraint.h>

Inheritance diagram for OPTPP::CompoundConstraint:

OPTPP::ConstraintBase List of all members.

Public Member Functions

 CompoundConstraint ()
 CompoundConstraint (const Constraint &c1)
 CompoundConstraint (const Constraint &c1, const Constraint &c2)
 CompoundConstraint (const OptppArray< Constraint > &constraints)
 CompoundConstraint (const CompoundConstraint &cc)
 ~CompoundConstraint ()
CompoundConstraintoperator= (const CompoundConstraint &cc)
 Assignment Operator.
int compare (const Constraint &c1, const Constraint &c2)
int getNumOfSets () const
int getNumOfNLCons () const
virtual int getNumOfCons () const
virtual int getNumOfVars () const
virtual NEWMAT::ColumnVector getLower () const
virtual NEWMAT::ColumnVector getUpper () const
virtual NEWMAT::ColumnVector getConstraintType () const
virtual NEWMAT::ColumnVector getConstraintValue () const
virtual NEWMAT::ColumnVector getConstraintViolation () const
NEWMAT::ColumnVector getNLConstraintValue () const
virtual OptppArray< int > getConstraintMappingIndices () const
Constraintoperator[] (int i)
const Constraintoperator[] (int i) const
void computeFeasibleBounds (NEWMAT::ColumnVector &xcurrent, double epsilon)
void computeFeasibleInequalities (NEWMAT::ColumnVector &xcurrent, double ftol)
void insertSort ()
void printConstraints ()
virtual NEWMAT::ColumnVector evalResidual (const NEWMAT::ColumnVector &xcurrent) const
virtual void evalCFGH (const NEWMAT::ColumnVector &xcurrent) const
virtual NEWMAT::Matrix evalGradient (const NEWMAT::ColumnVector &xcurrent) const
NEWMAT::SymmetricMatrix evalHessian (NEWMAT::ColumnVector &xcurrent, const NEWMAT::ColumnVector &LagMultiplier) const
virtual NEWMAT::SymmetricMatrix evalHessian (NEWMAT::ColumnVector &xcurrent) const
virtual OptppArray< NEWMAT::SymmetricMatrix > evalHessian (NEWMAT::ColumnVector &xcurrent, int darg) const
virtual bool amIFeasible (const NEWMAT::ColumnVector &xcurrent, double epsilon) const

Private Member Functions

void insertSort (const OptppArray< Constraint > &constraints)

Private Attributes

OptppArray< Constraintconstraints_
 Array of constraints.
int numOfSets_
 Number of constraint sets.
NEWMAT::ColumnVector lower_
 Lower bound on the constraints.
NEWMAT::ColumnVector upper_
 Upper bound on the constraints.

Constructor & Destructor Documentation

OPTPP::CompoundConstraint::CompoundConstraint (  ) 

Default Constructor

See also:
CompoundConstraint(const Constraint& c1)

CompoundConstraint(const Constraint& c1, const Constraint& c2)

CompoundConstraint(const OptppArray<Constraint>& constraints)

CompoundConstraint(const CompoundConstraint& cc)

OPTPP::CompoundConstraint::CompoundConstraint ( const Constraint c1  ) 

Parameters:
c1 a Constraint
See also:
CompoundConstraint(const Constraint& c1, const Constraint& c2)

CompoundConstraint(const OptppArray<Constraint>& constraints)

CompoundConstraint(const CompoundConstraint& cc)

OPTPP::CompoundConstraint::CompoundConstraint ( const Constraint c1,
const Constraint c2 
)

Parameters:
c1 a Constraint
c2 a Constraint
See also:
CompoundConstraint(const Constraint& c1)

CompoundConstraint(const OptppArray<Constraint>& constraints)

CompoundConstraint(const CompoundConstraint& cc)

OPTPP::CompoundConstraint::CompoundConstraint ( const OptppArray< Constraint > &  constraints  ) 

Parameters:
constraints an array of Constraints
See also:
CompoundConstraint(const Constraint& c1)

CompoundConstraint(const Constraint& c1, const Constraint& c2)

CompoundConstraint(const CompoundConstraint& cc)

OPTPP::CompoundConstraint::CompoundConstraint ( const CompoundConstraint cc  ) 

Copy constructor

Parameters:
cc a CompoundConstraint
See also:
CompoundConstraint(const Constraint& c1)

CompoundConstraint(const Constraint& c1, const Constraint& c2)

CompoundConstraint(const OptppArray<Constraint>& constraints)

OPTPP::CompoundConstraint::~CompoundConstraint (  )  [inline]

Destructor


Member Function Documentation

virtual bool OPTPP::CompoundConstraint::amIFeasible ( const NEWMAT::ColumnVector &  xcurrent,
double  epsilon 
) const [virtual]

Takes two arguments and returns a bool.

Parameters:
xcurrent a ColumnVector
epsilon a real argument
Returns:
true - constraints are feasible

false - constraints are infeasible

Implements OPTPP::ConstraintBase.

int OPTPP::CompoundConstraint::compare ( const Constraint c1,
const Constraint c2 
)

Returns:
Integer

void OPTPP::CompoundConstraint::computeFeasibleBounds ( NEWMAT::ColumnVector &  xcurrent,
double  epsilon 
)

Returns:
Feasible vector with respect to bounds

void OPTPP::CompoundConstraint::computeFeasibleInequalities ( NEWMAT::ColumnVector &  xcurrent,
double  ftol 
)

Returns:
Feasible vector with respect to linear and nonlinear inequalities

virtual void OPTPP::CompoundConstraint::evalCFGH ( const NEWMAT::ColumnVector &  xcurrent  )  const [virtual]

Implements OPTPP::ConstraintBase.

virtual NEWMAT::Matrix OPTPP::CompoundConstraint::evalGradient ( const NEWMAT::ColumnVector &  xcurrent  )  const [virtual]

Takes one argument and returns a real Matrix.

Parameters:
xcurrent a ColumnVector
Returns:
The gradient of the constraints.

Implements OPTPP::ConstraintBase.

virtual OptppArray<NEWMAT::SymmetricMatrix> OPTPP::CompoundConstraint::evalHessian ( NEWMAT::ColumnVector &  xcurrent,
int  darg 
) const [virtual]

Takes two arguments and returns an array of real SymmetricMatrices

Parameters:
xcurrent a ColumnVector
darg an integer argument
Returns:
An array of Hessians.

Implements OPTPP::ConstraintBase.

virtual NEWMAT::SymmetricMatrix OPTPP::CompoundConstraint::evalHessian ( NEWMAT::ColumnVector &  xcurrent  )  const [virtual]

Takes one arguments and returns a NEWMAT::SymmetricMatrix

Parameters:
xcurrent a ColumnVector
Returns:
The Hessian of the constraints.

Implements OPTPP::ConstraintBase.

NEWMAT::SymmetricMatrix OPTPP::CompoundConstraint::evalHessian ( NEWMAT::ColumnVector &  xcurrent,
const NEWMAT::ColumnVector &  LagMultiplier 
) const

Takes two arguments and returns a real SymmetricMatrix

Parameters:
xcurrent a ColumnVector
LagMultiplier a ColumnVector
Returns:
The Hessian of the constraints multiplied by its assoc. multiplier.

virtual NEWMAT::ColumnVector OPTPP::CompoundConstraint::evalResidual ( const NEWMAT::ColumnVector &  xcurrent  )  const [virtual]

Takes one argument and returns a ColumnVector

Parameters:
xcurrent a ColumnVector
Returns:
The residual of the constraints.

Implements OPTPP::ConstraintBase.

OptppArray< int > OPTPP::CompoundConstraint::getConstraintMappingIndices (  )  const [virtual]

Returns:
Indices of the constraints with finite bounds

Implements OPTPP::ConstraintBase.

ColumnVector OPTPP::CompoundConstraint::getConstraintType (  )  const [virtual]

Returns:
Constraint type

Implements OPTPP::ConstraintBase.

ColumnVector OPTPP::CompoundConstraint::getConstraintValue (  )  const [virtual]

Returns:
Value of the entire constraint set

Implements OPTPP::ConstraintBase.

ColumnVector OPTPP::CompoundConstraint::getConstraintViolation (  )  const [virtual]

Returns:
Violation of the entire constraint set

Implements OPTPP::ConstraintBase.

ColumnVector OPTPP::CompoundConstraint::getLower (  )  const [virtual]

Returns:
Lower bounds on the constraints

Implements OPTPP::ConstraintBase.

ColumnVector OPTPP::CompoundConstraint::getNLConstraintValue (  )  const

Returns:
Value of the nonlinear constraints only

int OPTPP::CompoundConstraint::getNumOfCons (  )  const [virtual]

Returns:
Number of total constraints.

Implements OPTPP::ConstraintBase.

int OPTPP::CompoundConstraint::getNumOfNLCons (  )  const

Returns:
Number of nonlinear constraints.

int OPTPP::CompoundConstraint::getNumOfSets (  )  const [inline]

Returns:
Number of different constraint sets.

int OPTPP::CompoundConstraint::getNumOfVars (  )  const [virtual]

Returns:
Number of variables.

Implements OPTPP::ConstraintBase.

ColumnVector OPTPP::CompoundConstraint::getUpper (  )  const [virtual]

Returns:
Upper bounds on the constraints

Implements OPTPP::ConstraintBase.

void OPTPP::CompoundConstraint::insertSort ( const OptppArray< Constraint > &  constraints  )  [private]

Sorts an array of constraints. Equations are followed by inequalities.

void OPTPP::CompoundConstraint::insertSort (  ) 

Returns:
Sorted constraints - equations followed by inequalities

CompoundConstraint & OPTPP::CompoundConstraint::operator= ( const CompoundConstraint cc  ) 

Assignment Operator.

const Constraint& OPTPP::CompoundConstraint::operator[] ( int  i  )  const [inline]

Returns:
Const reference to constraint i

Constraint& OPTPP::CompoundConstraint::operator[] ( int  i  )  [inline]

Returns:
Reference to constraint i

void OPTPP::CompoundConstraint::printConstraints (  ) 

Returns:
Output constraint values to the screen


Member Data Documentation

OptppArray<Constraint> OPTPP::CompoundConstraint::constraints_ [private]

Array of constraints.

NEWMAT::ColumnVector OPTPP::CompoundConstraint::lower_ [private]

Lower bound on the constraints.

int OPTPP::CompoundConstraint::numOfSets_ [private]

Number of constraint sets.

NEWMAT::ColumnVector OPTPP::CompoundConstraint::upper_ [private]

Upper bound on the constraints.


The documentation for this class was generated from the following files:
Bug Reports    OPT++ Developers    Copyright Information    GNU Lesser General Public License
Documentation, generated by , last revised August 30, 2006.