Scippy

SCIP

Solving Constraint Integer Programs

Detailed Description

methods and files provided by the default expressions handlers of SCIP

Modules

 Inclusion methods
 methods to include specific expression handlers into SCIP
 

Files

file  expr_abs.h
 absolute expression handler
 
file  expr_entropy.h
 handler for -x*log(x) expressions
 
file  expr_exp.h
 exponential expression handler
 
file  expr_log.h
 logarithm expression handler
 
file  expr_pow.h
 power and signed power expression handlers
 
file  expr_product.h
 product expression handler
 
file  expr_sum.h
 sum expression handler
 
file  expr_trig.h
 handler for sin expressions
 
file  expr_value.h
 constant value expression handler
 
file  expr_var.h
 variable expression handler
 
file  expr_varidx.h
 handler for variable index expressions
 

Absolute value expression

This expression handler provides the absolute-value function, that is,

\[ x \mapsto |x|. \]

SCIP_RETCODE SCIPcreateExprAbs (SCIP *scip, SCIP_EXPR **expr, SCIP_EXPR *child, SCIP_DECL_EXPR_OWNERCREATE((*ownercreate)), void *ownercreatedata)
 
SCIP_Bool SCIPisExprAbs (SCIP *scip, SCIP_EXPR *expr)
 

Entropy value expression

This expression handler provides the entropy function, that is,

\[ x \mapsto \begin{cases} -x\log(x), & \mathrm{if} x > 0,\\ 0, & \mathrm{if} x = 0, \\ \mathrm{undefined}, & \mathrm{else}. \end{cases} \]

SCIP_RETCODE SCIPcreateExprEntropy (SCIP *scip, SCIP_EXPR **expr, SCIP_EXPR *child, SCIP_DECL_EXPR_OWNERCREATE((*ownercreate)), void *ownercreatedata)
 
SCIP_Bool SCIPisExprEntropy (SCIP *scip, SCIP_EXPR *expr)
 

Exponential value expression

This expression handler provides the exponential function, that is,

\[ x \mapsto \exp(x). \]

SCIP_RETCODE SCIPcreateExprExp (SCIP *scip, SCIP_EXPR **expr, SCIP_EXPR *child, SCIP_DECL_EXPR_OWNERCREATE((*ownercreate)), void *ownercreatedata)
 
SCIP_Bool SCIPisExprExp (SCIP *scip, SCIP_EXPR *expr)
 

Logarithm expression

This expression handler provides the natural logarithm function, that is,

\[ x \mapsto \ln(x). \]

SCIP_RETCODE SCIPcreateExprLog (SCIP *scip, SCIP_EXPR **expr, SCIP_EXPR *child, SCIP_DECL_EXPR_OWNERCREATE((*ownercreate)), void *ownercreatedata)
 
SCIP_Bool SCIPisExprLog (SCIP *scip, SCIP_EXPR *expr)
 

Power and signed power expression

These expression handlers provide the power function, that is,

\[ x \mapsto \begin{cases} x^e & \textrm{if}\; x \geq 0\; \textrm{or}\; e\in\mathbb{Z}, \\ \textrm{undefined}, & \textrm{otherwise}. \end{cases} \]

and the signed power function, that is,

\[ x \mapsto \textrm{sign}(x) |x|^e \]

for some exponent \(e\).

SCIP_RETCODE SCIPcreateExprPow (SCIP *scip, SCIP_EXPR **expr, SCIP_EXPR *child, SCIP_Real exponent, SCIP_DECL_EXPR_OWNERCREATE((*ownercreate)), void *ownercreatedata)
 
SCIP_RETCODE SCIPcreateExprSignpower (SCIP *scip, SCIP_EXPR **expr, SCIP_EXPR *child, SCIP_Real exponent, SCIP_DECL_EXPR_OWNERCREATE((*ownercreate)), void *ownercreatedata)
 
SCIP_Bool SCIPisExprSignpower (SCIP *scip, SCIP_EXPR *expr)
 

Product expression

This expression handler provides the product function, that is,

\[ x \mapsto c\,\prod_{i=1}^n x_i \]

for some constant coefficient c.

SCIP_RETCODE SCIPcreateExprProduct (SCIP *scip, SCIP_EXPR **expr, int nchildren, SCIP_EXPR **children, SCIP_Real coefficient, SCIP_DECL_EXPR_OWNERCREATE((*ownercreate)), void *ownercreatedata)
 

Sum expression

This expression handler provides the sum function, that is,

\[ x \mapsto c + \sum_{i=1}^n a_i x_i \]

for some constant c and constant coefficients \(a_i\).

SCIP_RETCODE SCIPcreateExprSum (SCIP *scip, SCIP_EXPR **expr, int nchildren, SCIP_EXPR **children, SCIP_Real *coefficients, SCIP_Real constant, SCIP_DECL_EXPR_OWNERCREATE((*ownercreate)), void *ownercreatedata)
 
void SCIPsetConstantExprSum (SCIP_EXPR *expr, SCIP_Real constant)
 
SCIP_RETCODE SCIPappendExprSumExpr (SCIP *scip, SCIP_EXPR *expr, SCIP_EXPR *child, SCIP_Real childcoef)
 
void SCIPmultiplyByConstantExprSum (SCIP_EXPR *expr, SCIP_Real constant)
 
SCIP_RETCODE SCIPmultiplyBySumExprSum (SCIP *scip, SCIP_EXPR **product, SCIP_EXPR *factor1, SCIP_EXPR *factor2, SCIP_Bool simplify, SCIP_DECL_EXPR_OWNERCREATE((*ownercreate)), void *ownercreatedata)
 
SCIP_RETCODE SCIPpowerExprSum (SCIP *scip, SCIP_EXPR **result, SCIP_EXPR *base, int exponent, SCIP_Bool simplify, SCIP_DECL_EXPR_OWNERCREATE((*ownercreate)), void *ownercreatedata)
 

Sine and Cosine expression

These expression handlers provide the sine and cosine functions, that is,

\[ x \mapsto \sin(x) \]

and

\[ x \mapsto \cos(x). \]

SCIP_RETCODE SCIPcreateExprSin (SCIP *scip, SCIP_EXPR **expr, SCIP_EXPR *child, SCIP_DECL_EXPR_OWNERCREATE((*ownercreate)), void *ownercreatedata)
 
SCIP_RETCODE SCIPcreateExprCos (SCIP *scip, SCIP_EXPR **expr, SCIP_EXPR *child, SCIP_DECL_EXPR_OWNERCREATE((*ownercreate)), void *ownercreatedata)
 
SCIP_Bool SCIPisExprSin (SCIP *scip, SCIP_EXPR *expr)
 
SCIP_Bool SCIPisExprCos (SCIP *scip, SCIP_EXPR *expr)
 

Constant value expression

This expression handler handles a constant value. It cannot have children.

SCIP_RETCODE SCIPcreateExprValue (SCIP *scip, SCIP_EXPR **expr, SCIP_Real value, SCIP_DECL_EXPR_OWNERCREATE((*ownercreate)), void *ownercreatedata)
 

SCIP variable expression

This expression handler handles a SCIP variables. It cannot have children.

SCIP_RETCODE SCIPcreateExprVar (SCIP *scip, SCIP_EXPR **expr, SCIP_VAR *var, SCIP_DECL_EXPR_OWNERCREATE((*ownercreate)), void *ownercreatedata)
 

Index variable expression

This expression handler handles a variable that is given by a variable index. It cannot have children.

This expression handler is used for expressions that are passed to a NLP solver via the NLPI.

SCIP_RETCODE SCIPcreateExprVaridx (SCIP *scip, SCIP_EXPR **expr, int varidx, SCIP_DECL_EXPR_OWNERCREATE((*ownercreate)), void *ownercreatedata)
 
SCIP_Bool SCIPisExprVaridx (SCIP *scip, SCIP_EXPR *expr)
 
int SCIPgetIndexExprVaridx (SCIP_EXPR *expr)
 
void SCIPsetIndexExprVaridx (SCIP_EXPR *expr, int newindex)
 

Function Documentation

◆ SCIPcreateExprAbs()

SCIP_RETCODE SCIPcreateExprAbs ( SCIP scip,
SCIP_EXPR **  expr,
SCIP_EXPR child,
SCIP_DECL_EXPR_OWNERCREATE((*ownercreate))  ,
void *  ownercreatedata 
)

creates an absolute value expression

Parameters
scipSCIP data structure
exprpointer where to store expression
childsingle child
ownercreatedatadata to pass to ownercreate

Definition at line 528 of file expr_abs.c.

References EXPRHDLR_NAME, NULL, SCIP_CALL, SCIP_OKAY, SCIPcreateExpr(), and SCIPfindExprhdlr().

Referenced by mergeProductExprlist(), AMPLProblemHandler::OnUnary(), readExpression(), SCIP_DECL_EXPRPARSE(), and SCIP_DECL_EXPRSIMPLIFY().

◆ SCIPisExprAbs()

SCIP_Bool SCIPisExprAbs ( SCIP scip,
SCIP_EXPR expr 
)

indicates whether expression is of abs-type

Parameters
scipSCIP data structure
exprexpression

Definition at line 546 of file expr_abs.c.

References EXPRHDLR_NAME, NULL, SCIPexprGetHdlr(), and SCIPexprhdlrGetName().

Referenced by DECL_CURVCHECK(), isEvenOperator(), printExpr(), and SCIP_DECL_EXPRSIMPLIFY().

◆ SCIPcreateExprEntropy()

SCIP_RETCODE SCIPcreateExprEntropy ( SCIP scip,
SCIP_EXPR **  expr,
SCIP_EXPR child,
SCIP_DECL_EXPR_OWNERCREATE((*ownercreate))  ,
void *  ownercreatedata 
)

creates an entropy expression

Parameters
scipSCIP data structure
exprpointer where to store expression
childchild expression
ownercreatedatadata to pass to ownercreate

Definition at line 685 of file expr_entropy.c.

References EXPRHDLR_NAME, NULL, SCIP_CALL, SCIP_OKAY, SCIPcreateExpr(), and SCIPfindExprhdlr().

Referenced by enforceSP11(), and SCIP_DECL_EXPRPARSE().

◆ SCIPisExprEntropy()

SCIP_Bool SCIPisExprEntropy ( SCIP scip,
SCIP_EXPR expr 
)

indicates whether expression is of entropy-type

Parameters
scipSCIP data structure
exprexpression

Definition at line 712 of file expr_entropy.c.

References EXPRHDLR_NAME, NULL, SCIPexprGetHdlr(), and SCIPexprhdlrGetName().

◆ SCIPcreateExprExp()

SCIP_RETCODE SCIPcreateExprExp ( SCIP scip,
SCIP_EXPR **  expr,
SCIP_EXPR child,
SCIP_DECL_EXPR_OWNERCREATE((*ownercreate))  ,
void *  ownercreatedata 
)

creates an exponential expression

Parameters
scipSCIP data structure
exprpointer where to store expression
childsingle child
ownercreatedatadata to pass to ownercreate

Definition at line 510 of file expr_exp.c.

References EXPRHDLR_NAME, NULL, SCIP_CALL, SCIP_OKAY, SCIPcreateExpr(), and SCIPfindExprhdlr().

Referenced by mergeProductExprlist(), AMPLProblemHandler::OnBinary(), AMPLProblemHandler::OnUnary(), readExpression(), SCIP_DECL_EXPRPARSE(), SCIP_DECL_EXPRSIMPLIFY(), and simplifyTerm().

◆ SCIPisExprExp()

SCIP_Bool SCIPisExprExp ( SCIP scip,
SCIP_EXPR expr 
)

indicates whether expression is of exp-type

Parameters
scipSCIP data structure
exprexpression

Definition at line 528 of file expr_exp.c.

References EXPRHDLR_NAME, NULL, SCIPexprGetHdlr(), and SCIPexprhdlrGetName().

Referenced by eval(), mergeProductExprlist(), SCIP_DECL_EXPRSIMPLIFY(), SCIPexprintCompile(), and simplifyTerm().

◆ SCIPcreateExprLog()

SCIP_RETCODE SCIPcreateExprLog ( SCIP scip,
SCIP_EXPR **  expr,
SCIP_EXPR child,
SCIP_DECL_EXPR_OWNERCREATE((*ownercreate))  ,
void *  ownercreatedata 
)

creates a logarithmic expression

Parameters
scipSCIP data structure
exprpointer where to store expression
childsingle child
ownercreatedatadata to pass to ownercreate

Definition at line 630 of file expr_log.c.

References EXPRHDLR_NAME, NULL, SCIP_CALL, SCIP_OKAY, SCIPcreateExpr(), and SCIPfindExprhdlr().

Referenced by AMPLProblemHandler::OnBinary(), AMPLProblemHandler::OnUnary(), readExpression(), and SCIP_DECL_EXPRPARSE().

◆ SCIPisExprLog()

SCIP_Bool SCIPisExprLog ( SCIP scip,
SCIP_EXPR expr 
)

indicates whether expression is of log-type

Parameters
scipSCIP data structure
exprexpression

Definition at line 648 of file expr_log.c.

References EXPRHDLR_NAME, NULL, SCIPexprGetHdlr(), and SCIPexprhdlrGetName().

Referenced by eval(), and SCIPexprintCompile().

◆ SCIPcreateExprPow()

SCIP_RETCODE SCIPcreateExprPow ( SCIP scip,
SCIP_EXPR **  expr,
SCIP_EXPR child,
SCIP_Real  exponent,
SCIP_DECL_EXPR_OWNERCREATE((*ownercreate))  ,
void *  ownercreatedata 
)

creates a power expression

Parameters
scipSCIP data structure
exprpointer where to store expression
childsingle child
exponentexponent of the power expression
ownercreatedatadata to pass to ownercreate

Definition at line 3193 of file expr_pow.c.

References createData(), NULL, SCIP_CALL, SCIP_OKAY, SCIPcreateExpr(), and SCIPgetExprhdlrPower().

Referenced by addRegularScholtes(), createSOCExpression(), mergeProductExprlist(), AMPLProblemHandler::OnBinary(), AMPLProblemHandler::OnUnary(), parseFactor(), readExpression(), SCIP_DECL_CONSINITSOL(), SCIP_DECL_EXPRSIMPLIFY(), SCIPaddQuadVarQuadratic(), SCIPaddSquareCoefQuadratic(), SCIPcreateConsBasicSOCNonlinear(), SCIPcreateExprMonomial(), SCIPcreateExprQuadratic(), SCIPpowerExprSum(), setQuadraticObj(), and setupProblem().

◆ SCIPcreateExprSignpower()

SCIP_RETCODE SCIPcreateExprSignpower ( SCIP scip,
SCIP_EXPR **  expr,
SCIP_EXPR child,
SCIP_Real  exponent,
SCIP_DECL_EXPR_OWNERCREATE((*ownercreate))  ,
void *  ownercreatedata 
)

creates a signpower expression

Parameters
scipSCIP data structure
exprpointer where to store expression
childsingle child
exponentexponent of the power expression
ownercreatedatadata to pass to ownercreate

Definition at line 3217 of file expr_pow.c.

References createData(), NULL, SCIP_CALL, SCIP_OKAY, SCIPcreateExpr(), SCIPfindExprhdlr(), and SIGNPOWEXPRHDLR_NAME.

Referenced by mergeProductExprlist(), readExpression(), SCIP_DECL_EXPRPARSE(), SCIP_DECL_EXPRSIMPLIFY(), SCIPcreateConsBasicSignpowerNonlinear(), and setupProblem().

◆ SCIPisExprSignpower()

SCIP_Bool SCIPisExprSignpower ( SCIP scip,
SCIP_EXPR expr 
)

indicates whether expression is of signpower-type

Parameters
scipSCIP data structure
exprexpression

Definition at line 3242 of file expr_pow.c.

References NULL, SCIPexprGetHdlr(), SCIPexprhdlrGetName(), and SIGNPOWEXPRHDLR_NAME.

Referenced by eval(), exprIsNonSmooth(), isEvenOperator(), mergeProductExprlist(), and SCIPexprintCompile().

◆ SCIPcreateExprProduct()

SCIP_RETCODE SCIPcreateExprProduct ( SCIP scip,
SCIP_EXPR **  expr,
int  nchildren,
SCIP_EXPR **  children,
SCIP_Real  coefficient,
SCIP_DECL_EXPR_OWNERCREATE((*ownercreate))  ,
void *  ownercreatedata 
)

creates a product expression

! [SnippetCreateExprProduct]

! [SnippetCreateExprProduct]

Parameters
scipSCIP data structure
exprpointer where to store expression
nchildrennumber of children
childrenchildren
coefficientconstant coefficient of product
ownercreatedatadata to pass to ownercreate

Definition at line 2275 of file expr_product.c.

References exprnode::expr, SCIP_CALL, SCIP_OKAY, SCIPallocBlockMemory, SCIPcreateExpr(), and SCIPgetExprhdlrProduct().

Referenced by addNlrow(), createExprProductFromExprlist(), AMPLProblemHandler::OnBinary(), parseTerm(), readExpression(), SCIP_DECL_CONSINITSOL(), SCIP_DECL_EXPRSIMPLIFY(), SCIPaddBilinTermQuadratic(), SCIPcreateExprMonomial(), SCIPcreateExprQuadratic(), SCIPmultiplyBySumExprSum(), SCIPpowerExprSum(), setupProblem(), and simplifyTerm().

◆ SCIPcreateExprSum()

SCIP_RETCODE SCIPcreateExprSum ( SCIP scip,
SCIP_EXPR **  expr,
int  nchildren,
SCIP_EXPR **  children,
SCIP_Real coefficients,
SCIP_Real  constant,
SCIP_DECL_EXPR_OWNERCREATE((*ownercreate))  ,
void *  ownercreatedata 
)

◆ SCIPsetConstantExprSum()

void SCIPsetConstantExprSum ( SCIP_EXPR expr,
SCIP_Real  constant 
)

sets the constant of a summation expression

Parameters
exprsum expression
constantconstant

Definition at line 1135 of file expr_sum.c.

References NULL, and SCIPexprGetData().

Referenced by readObjective(), SCIPpowerExprSum(), and simplifyTerm().

◆ SCIPappendExprSumExpr()

◆ SCIPmultiplyByConstantExprSum()

void SCIPmultiplyByConstantExprSum ( SCIP_EXPR expr,
SCIP_Real  constant 
)

multiplies given sum expression by a constant

Parameters
exprsum expression
constantconstant that multiplies sum expression

Definition at line 1180 of file expr_sum.c.

References NULL, SCIPexprGetData(), and SCIPexprGetNChildren().

◆ SCIPmultiplyBySumExprSum()

SCIP_RETCODE SCIPmultiplyBySumExprSum ( SCIP scip,
SCIP_EXPR **  product,
SCIP_EXPR factor1,
SCIP_EXPR factor2,
SCIP_Bool  simplify,
SCIP_DECL_EXPR_OWNERCREATE((*ownercreate))  ,
void *  ownercreatedata 
)

constructs the expanded product of two sum expressions

Parameters
scipSCIP data structure
productbuffer where to store multiplied sums (expanded as sum)
factor1first sum
factor2second sum
simplifywhether to simplify created terms and sum
ownercreatedatadata to pass to ownercreate

Definition at line 1199 of file expr_sum.c.

References NULL, SCIP_Bool, SCIP_CALL, SCIP_OKAY, SCIP_Real, SCIPappendExprSumExpr(), SCIPcreateExprProduct(), SCIPcreateExprSum(), SCIPexprGetChildren(), SCIPexprGetNChildren(), SCIPgetCoefsExprSum(), SCIPgetConstantExprSum(), SCIPisExprSum(), SCIPreleaseExpr(), and SCIPsimplifyExpr().

◆ SCIPpowerExprSum()

SCIP_RETCODE SCIPpowerExprSum ( SCIP scip,
SCIP_EXPR **  result,
SCIP_EXPR base,
int  exponent,
SCIP_Bool  simplify,
SCIP_DECL_EXPR_OWNERCREATE((*ownercreate))  ,
void *  ownercreatedata 
)

constructs the expanded power of a sum expression

Attention
The number of terms in the expansion grows exponential with the exponent. Be aware of what you wish for.
Parameters
scipSCIP data structure
resultbuffer where to store expanded power of sum
basesum
exponentexponent > 1
simplifywhether to simplify created terms and sum
ownercreatedatadata to pass to ownercreate

Definition at line 1313 of file expr_sum.c.

References nterms, NULL, SCIP_Bool, SCIP_CALL, SCIP_OKAY, SCIP_Real, SCIPallocBufferArray, SCIPallocClearBufferArray, SCIPappendExprChild(), SCIPappendExprSumExpr(), SCIPcreateExprPow(), SCIPcreateExprProduct(), SCIPcreateExprSum(), SCIPdebugMsg, SCIPdebugPrintf, SCIPexprGetChildren(), SCIPexprGetNChildren(), SCIPfreeBufferArray, SCIPgetCoefsExprSum(), SCIPgetConstantExprSum(), SCIPinfoMessage(), SCIPisExprSum(), SCIPprintExpr(), SCIPreleaseExpr(), SCIPsetConstantExprSum(), SCIPsimplifyExpr(), and TRUE.

Referenced by SCIP_DECL_EXPRSIMPLIFY().

◆ SCIPcreateExprSin()

SCIP_RETCODE SCIPcreateExprSin ( SCIP scip,
SCIP_EXPR **  expr,
SCIP_EXPR child,
SCIP_DECL_EXPR_OWNERCREATE((*ownercreate))  ,
void *  ownercreatedata 
)

creates a sin expression

Parameters
scipSCIP data structure
exprpointer where to store expression
childsingle child
ownercreatedatadata to pass to ownercreate

Definition at line 1430 of file expr_trig.c.

References NULL, SCIP_CALL, SCIP_OKAY, SCIPcreateExpr(), SCIPfindExprhdlr(), and SINEXPRHDLR_NAME.

Referenced by AMPLProblemHandler::OnUnary(), readExpression(), and SCIP_DECL_EXPRPARSE().

◆ SCIPcreateExprCos()

SCIP_RETCODE SCIPcreateExprCos ( SCIP scip,
SCIP_EXPR **  expr,
SCIP_EXPR child,
SCIP_DECL_EXPR_OWNERCREATE((*ownercreate))  ,
void *  ownercreatedata 
)

creates a cos expression

Parameters
scipSCIP data structure
exprpointer where to store expression
childsingle child
ownercreatedatadata to pass to ownercreate

Definition at line 1450 of file expr_trig.c.

References COSEXPRHDLR_NAME, NULL, SCIP_CALL, SCIP_OKAY, SCIPcreateExpr(), and SCIPfindExprhdlr().

Referenced by AMPLProblemHandler::OnUnary(), readExpression(), and SCIP_DECL_EXPRPARSE().

◆ SCIPisExprSin()

SCIP_Bool SCIPisExprSin ( SCIP scip,
SCIP_EXPR expr 
)

indicates whether expression is of sine-type

Parameters
scipSCIP data structure
exprexpression

Definition at line 1469 of file expr_trig.c.

References NULL, SCIPexprGetHdlr(), SCIPexprhdlrGetName(), and SINEXPRHDLR_NAME.

◆ SCIPisExprCos()

SCIP_Bool SCIPisExprCos ( SCIP scip,
SCIP_EXPR expr 
)

indicates whether expression is of cosine-type

Parameters
scipSCIP data structure
exprexpression

Definition at line 1480 of file expr_trig.c.

References COSEXPRHDLR_NAME, NULL, SCIPexprGetHdlr(), and SCIPexprhdlrGetName().

Referenced by isEvenOperator().

◆ SCIPcreateExprValue()

SCIP_RETCODE SCIPcreateExprValue ( SCIP scip,
SCIP_EXPR **  expr,
SCIP_Real  value,
SCIP_DECL_EXPR_OWNERCREATE((*ownercreate))  ,
void *  ownercreatedata 
)

creates constant value expression

Parameters
scipSCIP data structure
exprpointer where to store expression
valuevalue to be stored
ownercreatedatadata to pass to ownercreate

Definition at line 270 of file expr_value.c.

References NULL, SCIP_CALL, SCIP_OKAY, SCIPallocBlockMemory, SCIPcreateExpr(), SCIPgetExprhdlrValue(), and SCIPisFinite.

Referenced by enforceSP10(), getBinaryProductExpr(), AMPLProblemHandler::OnBinaryLogical(), AMPLProblemHandler::OnBool(), AMPLProblemHandler::OnHeader(), AMPLProblemHandler::OnNot(), AMPLProblemHandler::OnNumber(), AMPLProblemHandler::OnRelational(), parseBase(), readExpression(), SCIP_DECL_EXPRSIMPLIFY(), and SCIPcreateExprMonomial().

◆ SCIPcreateExprVar()

◆ SCIPcreateExprVaridx()

SCIP_RETCODE SCIPcreateExprVaridx ( SCIP scip,
SCIP_EXPR **  expr,
int  varidx,
SCIP_DECL_EXPR_OWNERCREATE((*ownercreate))  ,
void *  ownercreatedata 
)

creates a variable index expression

Parameters
scipSCIP data structure
exprpointer where to store expression
varidxvariable index to represent
ownercreatedatadata to pass to ownercreate

Definition at line 220 of file expr_varidx.c.

References EXPRHDLR_NAME, NULL, SCIP_CALL, SCIP_ERROR, SCIP_OKAY, SCIPABORT, SCIPcreateExpr(), SCIPerrorMessage, and SCIPfindExprhdlr().

Referenced by SCIP_DECL_EXPR_MAPEXPR(), and setQuadraticObj().

◆ SCIPisExprVaridx()

SCIP_Bool SCIPisExprVaridx ( SCIP scip,
SCIP_EXPR expr 
)

indicates whether expression is varidx expression

Parameters
scipSCIP data structure
exprexpression

Definition at line 252 of file expr_varidx.c.

References EXPRHDLR_NAME, FALSE, NULL, SCIPexprGetHdlr(), SCIPexprGetNChildren(), and SCIPexprhdlrGetName().

Referenced by eval(), SCIPcreateNlpiProblemFromNlRows(), SCIPexprintCompile(), SCIPnlpiOracleDelVarSet(), SCIPnlpiOracleGetJacobianSparsity(), tryAddGadgetEvenOperator(), and updateVariableCounts().

◆ SCIPgetIndexExprVaridx()

int SCIPgetIndexExprVaridx ( SCIP_EXPR expr)

◆ SCIPsetIndexExprVaridx()

void SCIPsetIndexExprVaridx ( SCIP_EXPR expr,
int  newindex 
)

sets the index stored in a varidx expression

Parameters
exprvarindex expression
newindexnew index

Definition at line 278 of file expr_varidx.c.

References EXPRHDLR_NAME, NULL, SCIPexprGetHdlr(), SCIPexprhdlrGetName(), and SCIPexprSetData().

Referenced by SCIPnlpiOracleDelVarSet().