LSBlackBoxEvaluationPoint Class

class

An evaluation point associated with a black-box function.

Evaluation points are used to specify known points for a function in advance. It can be useful to warm-start the solver when the function is particularly expensive to evaluate, or if you already have a good estimate of the optimal point.

Note: This information is used by the solver to drive the solution process. You must be careful about the data you provide: if an incorrect value is given, the solver may have an unexpected behavior.

See:LSBlackBoxContext::createEvaluationPoint()
See:LSBlackBoxContext::getEvaluationPoint(int pos)
Since:10.0

Summary

Functions
addArgument Adds an integer argument with the given value.
setArgument Sets the value of the argument at the given position.
setReturnValue Sets the return value of this evaluation point.
isIntReturnValue Returns true if the black-box function associated with this evaluation point is an integer function, false otherwise.
isDoubleReturnValue Returns true if the black-box function associated with this evaluation point is a double function, false otherwise.
isIntArgument Returns true if the argument at this given position is an integer, false otherwise.
isDoubleArgument Returns true if the argument at this given position is a double, false otherwise.
getIntArgument Returns the value of the argument at the given position.
getDoubleArgument Returns the value of the argument at the given position.
getIntReturnValue Returns the return value of this evaluation point.
getDoubleReturnValue Returns the return value of this evaluation point.

Functions

void localsolver::LSBlackBoxEvaluationPoint::addArgument(lsint value)

Adds an integer argument with the given value.

Only allowed if the associated decision variable is an integer or a boolean. Only allowed in state S_Stopped.

Parameters:value - Value of the argument.

void localsolver::LSBlackBoxEvaluationPoint::addArgument(lsdouble value)

Adds a double argument with the given value.

Only allowed if the associated decision variable is a double. Only allowed in state S_Stopped.

Parameters:value - Value of the argument.

void localsolver::LSBlackBoxEvaluationPoint::setArgument(int pos, lsint value)

Sets the value of the argument at the given position.

Only allowed if this argument is an integer or a boolean. Only allowed in state S_Stopped.

Parameters:
  • pos - Position in the argument list.
  • value - Value of the argument.

void localsolver::LSBlackBoxEvaluationPoint::setArgument(int pos, lsdouble value)

Sets the value of the argument at the given position.

Only allowed if this argument is a double. Only allowed in state S_Stopped.

Parameters:
  • pos - Position in the argument list.
  • value - Value of the argument.

void localsolver::LSBlackBoxEvaluationPoint::setReturnValue(lsint value)

Sets the return value of this evaluation point.

Only allowed if the black-box function associated with this evaluation point is an integer function. Only allowed in state S_Stopped.

Parameters:value - Return value of this point.

void localsolver::LSBlackBoxEvaluationPoint::setReturnValue(lsdouble value)

Sets the return value of this evaluation point.

Only allowed if the black-box function associated with this evaluation point is a double function. Only allowed in state S_Stopped.

Parameters:value - Return value of this point.

bool localsolver::LSBlackBoxEvaluationPoint::isIntReturnValue()

Returns true if the black-box function associated with this evaluation point is an integer function, false otherwise.

You can retrieve the value with getIntReturnValue. Only allowed in state S_Stopped.

Return:True if the return value is an integer.

bool localsolver::LSBlackBoxEvaluationPoint::isDoubleReturnValue()

Returns true if the black-box function associated with this evaluation point is a double function, false otherwise.

You can retrieve the value with getDoubleReturnValue. Only allowed in state S_Stopped.

Return:True if the return value is a double.

bool localsolver::LSBlackBoxEvaluationPoint::isIntArgument(int pos)

Returns true if the argument at this given position is an integer, false otherwise.

You can retrieve the value with getIntArgument. Only allowed in state S_Stopped.

Return:True if the argument at this given position is an integer.
Parameters:pos - Position in the argument list.

bool localsolver::LSBlackBoxEvaluationPoint::isDoubleArgument(int pos)

Returns true if the argument at this given position is a double, false otherwise.

You can retrieve the value with getDoubleArgument. Only allowed in state S_Stopped.

Return:True if the argument at this given position is a double.
Parameters:pos - Position in the argument list.

lsint localsolver::LSBlackBoxEvaluationPoint::getIntArgument(int pos)

Returns the value of the argument at the given position.

Only allowed if this argument is an integer or a boolean. Only allowed in state S_Stopped.

Return:Value of the argument.
Parameters:pos - Position in the argument list.

lsdouble localsolver::LSBlackBoxEvaluationPoint::getDoubleArgument(int pos)

Returns the value of the argument at the given position.

Only allowed if this argument is a double. Only allowed in state S_Stopped.

Return:Value of the argument.
Parameters:pos - Position in the argument list.

lsint localsolver::LSBlackBoxEvaluationPoint::getIntReturnValue()

Returns the return value of this evaluation point.

Only allowed if the black-box function associated with this evaluation point is an integer function. Only allowed in state S_Stopped.

Return:Return value of this point.

lsdouble localsolver::LSBlackBoxEvaluationPoint::getDoubleReturnValue()

Returns the return value of this evaluation point.

Only allowed if the black-box function associated with this evaluation point is a double function. Only allowed in state S_Stopped.

Return:Return value of this point.