OBOE 0.1
Accpm::OracleFunction Class Reference

#include <Oracle.h>

List of all members.

Public Member Functions

virtual ~OracleFunction ()
virtual int eval (const AccpmVector &y, AccpmVector &functionValue, AccpmGenMatrix &subGradients, AccpmGenMatrix *info)=0

Constructor & Destructor Documentation

virtual Accpm::OracleFunction::~OracleFunction ( ) [inline, virtual]

Member Function Documentation

virtual int Accpm::OracleFunction::eval ( const AccpmVector y,
AccpmVector functionValue,
AccpmGenMatrix subGradients,
AccpmGenMatrix info 
) [pure virtual]

The evaluate function which is called by OBOE. At every iteration, i.e. call to QpGenerator::run() function, OBOE asks the Oracle to provide it with the cut information at the current query point y.

For a given query point, y, the eval function should return the following:

Returns:
functionValue which is an vector of size NumCuts x 1 This value represents the following:

For the non-smooth function f1(.) : For optimality cuts, i.e *info = 1, functionValue is typically the function evaluation at the current query point, y. For feasiblity cuts, i.e *info = 0, however, this is a value which would make the cut described by the subGradients matrix valid in the form : functionValue + subGradients^T*(y' - y) <= 0, for all feasible points y'

For the smooth function f2(.) : It again represents the function value f2(y).

Returns:
Sub-gradient at y in matrix subGradients which of size NumVariables x NumCuts. The user can provide more than one cut for each query point, which usually is required when the NumSubProblems is more than 1.

The subgradient vector(with abuse of name) is also used to provide a valid cuts incase the given point, y, is not feasible. Hence the eval function is responsible for providing both optimality and feasibility cuts.

Returns:
AccpmGenMatrix *info: For non-smooth function f1 it is a vector of dimension NumCuts x 1. It specifies the cut type for each cut: (i) For feasibility cut, *info(i,0) = 0 (ii) For optimality cut i, *info(i,0) = i, the index of subproblem.

For the smooth function f2, this vector has the Hessian information. It is a vector of dimension NumVariables x NumVariables (if parameter diagHessian is false) otherwise its has dimension NumVariables x 1

The return value is 0 on success and 1 to terminate the Outer Iterations and hence the Query point generation process.

Note: The number of cuts, NumCuts, returned at every iteration is controlled by the user by providing the vectors and matrices of corresponding size.

Referenced by Accpm::Manager::callSmoothOracle(), and Accpm::QpGenerator::run().


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