methods and files provided by the default expressions handlers of SCIP
Topics | |
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) |
SCIP_RETCODE SCIPcreateExprAbs | ( | SCIP * | scip, |
SCIP_EXPR ** | expr, | ||
SCIP_EXPR * | child, | ||
SCIP_DECL_EXPR_OWNERCREATE((*ownercreate)) | , | ||
void * | ownercreatedata ) |
creates an absolute value expression
scip | SCIP data structure |
expr | pointer where to store expression |
child | single child |
ownercreatedata | data to pass to ownercreate |
Definition at line 528 of file expr_abs.c.
References assert(), EXPRHDLR_NAME, NULL, SCIP_CALL, SCIP_OKAY, SCIPcreateExpr(), and SCIPfindExprhdlr().
Referenced by mergeProductExprlist(), AMPLProblemHandler::OnUnary(), readExpression(), SCIP_DECL_EXPRPARSE(), and SCIP_DECL_EXPRSIMPLIFY().
indicates whether expression is of abs-type
scip | SCIP data structure |
expr | expression |
Definition at line 546 of file expr_abs.c.
References assert(), EXPRHDLR_NAME, NULL, SCIP_Bool, SCIPexprGetHdlr(), and SCIPexprhdlrGetName().
Referenced by DECL_CURVCHECK(), isEvenOperator(), printExpr(), and SCIP_DECL_EXPRSIMPLIFY().
SCIP_RETCODE SCIPcreateExprEntropy | ( | SCIP * | scip, |
SCIP_EXPR ** | expr, | ||
SCIP_EXPR * | child, | ||
SCIP_DECL_EXPR_OWNERCREATE((*ownercreate)) | , | ||
void * | ownercreatedata ) |
creates an entropy expression
scip | SCIP data structure |
expr | pointer where to store expression |
child | child expression |
ownercreatedata | data to pass to ownercreate |
Definition at line 685 of file expr_entropy.c.
References assert(), EXPRHDLR_NAME, NULL, SCIP_CALL, SCIP_OKAY, SCIPcreateExpr(), and SCIPfindExprhdlr().
Referenced by enforceSP11(), and SCIP_DECL_EXPRPARSE().
indicates whether expression is of entropy-type
scip | SCIP data structure |
expr | expression |
Definition at line 712 of file expr_entropy.c.
References assert(), EXPRHDLR_NAME, NULL, SCIP_Bool, SCIPexprGetHdlr(), and SCIPexprhdlrGetName().
SCIP_RETCODE SCIPcreateExprExp | ( | SCIP * | scip, |
SCIP_EXPR ** | expr, | ||
SCIP_EXPR * | child, | ||
SCIP_DECL_EXPR_OWNERCREATE((*ownercreate)) | , | ||
void * | ownercreatedata ) |
creates an exponential expression
scip | SCIP data structure |
expr | pointer where to store expression |
child | single child |
ownercreatedata | data to pass to ownercreate |
Definition at line 510 of file expr_exp.c.
References assert(), EXPRHDLR_NAME, NULL, SCIP_CALL, SCIP_OKAY, SCIPcreateExpr(), and SCIPfindExprhdlr().
Referenced by mergeProductExprlist(), AMPLProblemHandler::OnBinary(), AMPLProblemHandler::OnUnary(), readExpression(), SCIP_DECL_EXPRPARSE(), SCIP_DECL_EXPRSIMPLIFY(), SCIP_DECL_EXPRSIMPLIFY(), and simplifyTerm().
indicates whether expression is of exp-type
scip | SCIP data structure |
expr | expression |
Definition at line 528 of file expr_exp.c.
References assert(), EXPRHDLR_NAME, NULL, SCIP_Bool, SCIPexprGetHdlr(), and SCIPexprhdlrGetName().
Referenced by eval(), mergeProductExprlist(), SCIP_DECL_EXPRSIMPLIFY(), SCIP_DECL_EXPRSIMPLIFY(), SCIPexprintCompile(), and simplifyTerm().
SCIP_RETCODE SCIPcreateExprLog | ( | SCIP * | scip, |
SCIP_EXPR ** | expr, | ||
SCIP_EXPR * | child, | ||
SCIP_DECL_EXPR_OWNERCREATE((*ownercreate)) | , | ||
void * | ownercreatedata ) |
creates a logarithmic expression
scip | SCIP data structure |
expr | pointer where to store expression |
child | single child |
ownercreatedata | data to pass to ownercreate |
Definition at line 630 of file expr_log.c.
References assert(), EXPRHDLR_NAME, NULL, SCIP_CALL, SCIP_OKAY, SCIPcreateExpr(), and SCIPfindExprhdlr().
Referenced by AMPLProblemHandler::OnBinary(), AMPLProblemHandler::OnUnary(), readExpression(), and SCIP_DECL_EXPRPARSE().
indicates whether expression is of log-type
scip | SCIP data structure |
expr | expression |
Definition at line 648 of file expr_log.c.
References assert(), EXPRHDLR_NAME, NULL, SCIP_Bool, SCIPexprGetHdlr(), and SCIPexprhdlrGetName().
Referenced by eval(), and SCIPexprintCompile().
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
scip | SCIP data structure |
expr | pointer where to store expression |
child | single child |
exponent | exponent of the power expression |
ownercreatedata | data to pass to ownercreate |
Definition at line 3193 of file expr_pow.c.
References assert(), createData(), NULL, SCIP_CALL, SCIP_OKAY, SCIP_Real, SCIPcreateExpr(), and SCIPgetExprhdlrPower().
Referenced by addRegularScholtes(), createSOCExpression(), mergeProductExprlist(), AMPLProblemHandler::OnBinary(), AMPLProblemHandler::OnUnary(), parseFactor(), readExpression(), SCIP_DECL_CONSINITSOL(), SCIP_DECL_EXPRSIMPLIFY(), SCIP_DECL_EXPRSIMPLIFY(), SCIPaddQuadVarQuadratic(), SCIPaddSquareCoefQuadratic(), SCIPcreateConsBasicSOCNonlinear(), SCIPcreateExprMonomial(), SCIPcreateExprQuadratic(), SCIPpowerExprSum(), setQuadraticObj(), setupProblem(), and setupProblem().
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
scip | SCIP data structure |
expr | pointer where to store expression |
child | single child |
exponent | exponent of the power expression |
ownercreatedata | data to pass to ownercreate |
Definition at line 3217 of file expr_pow.c.
References assert(), createData(), NULL, SCIP_CALL, SCIP_OKAY, SCIP_Real, SCIPcreateExpr(), SCIPfindExprhdlr(), and SIGNPOWEXPRHDLR_NAME.
Referenced by mergeProductExprlist(), readExpression(), SCIP_DECL_EXPRPARSE(), SCIP_DECL_EXPRSIMPLIFY(), SCIPcreateConsBasicSignpowerNonlinear(), and setupProblem().
indicates whether expression is of signpower-type
scip | SCIP data structure |
expr | expression |
Definition at line 3242 of file expr_pow.c.
References assert(), NULL, SCIP_Bool, SCIPexprGetHdlr(), SCIPexprhdlrGetName(), and SIGNPOWEXPRHDLR_NAME.
Referenced by eval(), exprIsNonSmooth(), isEvenOperator(), mergeProductExprlist(), and SCIPexprintCompile().
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]
scip | SCIP data structure |
expr | pointer where to store expression |
nchildren | number of children |
children | children |
coefficient | constant coefficient of product |
ownercreatedata | data to pass to ownercreate |
Definition at line 2276 of file expr_product.c.
References exprnode::expr, SCIP_CALL, SCIP_OKAY, SCIP_Real, SCIPallocBlockMemory, SCIPcreateExpr(), and SCIPgetExprhdlrProduct().
Referenced by addNlrow(), createExprProductFromExprlist(), AMPLProblemHandler::OnBinary(), parseTerm(), readExpression(), SCIP_DECL_CONSINITSOL(), SCIP_DECL_EXPRSIMPLIFY(), SCIP_DECL_EXPRSIMPLIFY(), SCIPaddBilinTermQuadratic(), SCIPcreateExprMonomial(), SCIPcreateExprQuadratic(), SCIPmultiplyBySumExprSum(), SCIPpowerExprSum(), setupProblem(), setupProblem(), and simplifyTerm().
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 ) |
creates a sum expression
scip | SCIP data structure |
expr | pointer where to store expression |
nchildren | number of children |
children | children |
coefficients | array with coefficients for all children (or NULL if all 1.0) |
constant | constant term of sum |
ownercreatedata | data to pass to ownercreate |
Definition at line 1114 of file expr_sum.c.
References createData(), SCIP_CALL, SCIP_OKAY, SCIP_Real, SCIPcreateExpr(), and SCIPgetExprhdlrSum().
Referenced by addRegularScholtes(), buildSimplifiedProduct(), createConstraint(), createNlRow(), createSOCExpression(), AMPLProblemHandler::EndSum(), enforceSP10(), enforceSP11(), enforceSP12(), enforceSP12b(), getBinaryProductExpr(), getFactorizedBinaryQuadraticExpr(), AMPLProblemHandler::LinearExprHandler::LinearExprHandler(), mergeProductExprlist(), AMPLProblemHandler::OnBinary(), AMPLProblemHandler::OnUnary(), parseExpr(), readExpression(), readPolynomial(), scaleConsSides(), SCIP_DECL_EXPRSIMPLIFY(), SCIP_DECL_EXPRSIMPLIFY(), SCIP_DECL_EXPRSIMPLIFY(), SCIP_DECL_EXPRSIMPLIFY(), SCIPaddExprNonlinear(), SCIPaddLinearVarNonlinear(), SCIPcreateConsBasicSignpowerNonlinear(), SCIPcreateConsBasicSOCNonlinear(), SCIPcreateExprQuadratic(), SCIPmultiplyBySumExprSum(), SCIPpowerExprSum(), setQuadraticObj(), setupProblem(), setupProblem(), setupProblem(), and simplifyTerm().
sets the constant of a summation expression
expr | sum expression |
constant | constant |
Definition at line 1135 of file expr_sum.c.
References assert(), NULL, SCIP_Real, and SCIPexprGetData().
Referenced by readObjective(), SCIPpowerExprSum(), and simplifyTerm().
SCIP_RETCODE SCIPappendExprSumExpr | ( | SCIP * | scip, |
SCIP_EXPR * | expr, | ||
SCIP_EXPR * | child, | ||
SCIP_Real | childcoef ) |
appends an expression to a sum expression
scip | SCIP data structure |
expr | sum expression |
child | expression to be appended |
childcoef | child's coefficient |
Definition at line 1151 of file expr_sum.c.
References assert(), NULL, SCIP_CALL, SCIP_OKAY, SCIP_Real, SCIPappendExprChild(), SCIPensureBlockMemoryArray, SCIPexprGetData(), SCIPexprGetNChildren(), and SCIPisExprSum().
Referenced by AMPLProblemHandler::LinearExprHandler::AddTerm(), createConstraint(), createNlRow(), createSOCExpression(), AMPLProblemHandler::EndCommonExpr(), enforceSP12(), enforceSP12b(), mergeProductExprlist(), parseExpr(), readObjective(), SCIP_DECL_EXPRSIMPLIFY(), SCIPaddExprNonlinear(), SCIPaddLinearVarNonlinear(), SCIPcreateConsBasicSOCNonlinear(), SCIPmultiplyBySumExprSum(), SCIPpowerExprSum(), and simplifyTerm().
multiplies given sum expression by a constant
expr | sum expression |
constant | constant that multiplies sum expression |
Definition at line 1180 of file expr_sum.c.
References assert(), i, NULL, SCIP_Real, SCIPexprGetData(), and SCIPexprGetNChildren().
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
scip | SCIP data structure |
product | buffer where to store multiplied sums (expanded as sum) |
factor1 | first sum |
factor2 | second sum |
simplify | whether to simplify created terms and sum |
ownercreatedata | data to pass to ownercreate |
Definition at line 1199 of file expr_sum.c.
References assert(), NULL, SCIP_Bool, SCIP_CALL, SCIP_OKAY, SCIP_Real, SCIPappendExprSumExpr(), SCIPcreateExprProduct(), SCIPcreateExprSum(), SCIPexprGetChildren(), SCIPexprGetNChildren(), SCIPgetCoefsExprSum(), SCIPgetConstantExprSum(), SCIPisExprSum(), SCIPreleaseExpr(), and SCIPsimplifyExpr().
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
scip | SCIP data structure |
result | buffer where to store expanded power of sum |
base | sum |
exponent | exponent > 1 |
simplify | whether to simplify created terms and sum |
ownercreatedata | data to pass to ownercreate |
Definition at line 1313 of file expr_sum.c.
References assert(), i, nterms, NULL, result, 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().
SCIP_RETCODE SCIPcreateExprSin | ( | SCIP * | scip, |
SCIP_EXPR ** | expr, | ||
SCIP_EXPR * | child, | ||
SCIP_DECL_EXPR_OWNERCREATE((*ownercreate)) | , | ||
void * | ownercreatedata ) |
creates a sin expression
scip | SCIP data structure |
expr | pointer where to store expression |
child | single child |
ownercreatedata | data to pass to ownercreate |
Definition at line 1430 of file expr_trig.c.
References assert(), NULL, SCIP_CALL, SCIP_OKAY, SCIPcreateExpr(), SCIPfindExprhdlr(), and SINEXPRHDLR_NAME.
Referenced by AMPLProblemHandler::OnUnary(), readExpression(), and SCIP_DECL_EXPRPARSE().
SCIP_RETCODE SCIPcreateExprCos | ( | SCIP * | scip, |
SCIP_EXPR ** | expr, | ||
SCIP_EXPR * | child, | ||
SCIP_DECL_EXPR_OWNERCREATE((*ownercreate)) | , | ||
void * | ownercreatedata ) |
creates a cos expression
scip | SCIP data structure |
expr | pointer where to store expression |
child | single child |
ownercreatedata | data to pass to ownercreate |
Definition at line 1450 of file expr_trig.c.
References assert(), COSEXPRHDLR_NAME, NULL, SCIP_CALL, SCIP_OKAY, SCIPcreateExpr(), and SCIPfindExprhdlr().
Referenced by AMPLProblemHandler::OnUnary(), readExpression(), and SCIP_DECL_EXPRPARSE().
indicates whether expression is of sine-type
scip | SCIP data structure |
expr | expression |
Definition at line 1469 of file expr_trig.c.
References assert(), NULL, SCIP_Bool, SCIPexprGetHdlr(), SCIPexprhdlrGetName(), and SINEXPRHDLR_NAME.
indicates whether expression is of cosine-type
scip | SCIP data structure |
expr | expression |
Definition at line 1480 of file expr_trig.c.
References assert(), COSEXPRHDLR_NAME, NULL, SCIP_Bool, SCIPexprGetHdlr(), and SCIPexprhdlrGetName().
Referenced by isEvenOperator().
SCIP_RETCODE SCIPcreateExprValue | ( | SCIP * | scip, |
SCIP_EXPR ** | expr, | ||
SCIP_Real | value, | ||
SCIP_DECL_EXPR_OWNERCREATE((*ownercreate)) | , | ||
void * | ownercreatedata ) |
creates constant value expression
scip | SCIP data structure |
expr | pointer where to store expression |
value | value to be stored |
ownercreatedata | data to pass to ownercreate |
Definition at line 270 of file expr_value.c.
References assert(), NULL, SCIP_CALL, SCIP_OKAY, SCIP_Real, 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(), SCIP_DECL_EXPRSIMPLIFY(), SCIP_DECL_EXPRSIMPLIFY(), SCIP_DECL_EXPRSIMPLIFY(), SCIP_DECL_EXPRSIMPLIFY(), SCIP_DECL_EXPRSIMPLIFY(), SCIP_DECL_EXPRSIMPLIFY(), SCIP_DECL_EXPRSIMPLIFY(), SCIP_DECL_EXPRSIMPLIFY(), SCIP_DECL_EXPRSIMPLIFY(), and SCIPcreateExprMonomial().
SCIP_RETCODE SCIPcreateExprVar | ( | SCIP * | scip, |
SCIP_EXPR ** | expr, | ||
SCIP_VAR * | var, | ||
SCIP_DECL_EXPR_OWNERCREATE((*ownercreate)) | , | ||
void * | ownercreatedata ) |
creates a variable expression
scip | SCIP data structure |
expr | pointer where to store expression |
var | variable to be stored |
ownercreatedata | data to pass to ownercreate |
Definition at line 390 of file expr_var.c.
References assert(), NULL, SCIP_CALL, SCIP_OKAY, SCIPcaptureVar(), SCIPcreateExpr(), SCIPgetExprhdlrVar(), and var.
Referenced by addNlrow(), addRegularScholtes(), AMPLProblemHandler::LinearExprHandler::AddTerm(), collectLeafs(), createConstraint(), createExprVar(), createSOCExpression(), AMPLProblemHandler::OnBinaryLogical(), AMPLProblemHandler::OnHeader(), AMPLProblemHandler::OnNot(), AMPLProblemHandler::OnRelational(), parseBase(), readExpression(), readObjective(), SCIP_DECL_CONSINITSOL(), SCIP_DECL_CONSINITSOL(), SCIP_DECL_EXPR_MAPEXPR(), SCIP_DECL_EXPRSIMPLIFY(), SCIPaddBilinTermQuadratic(), SCIPaddQuadVarQuadratic(), SCIPaddSquareCoefQuadratic(), SCIPcreateConsBasicSignpowerNonlinear(), SCIPcreateConsBasicSOCNonlinear(), SCIPcreateExprMonomial(), SCIPcreateExprQuadratic(), setupProblem(), setupProblem(), and setupProblem().
SCIP_RETCODE SCIPcreateExprVaridx | ( | SCIP * | scip, |
SCIP_EXPR ** | expr, | ||
int | varidx, | ||
SCIP_DECL_EXPR_OWNERCREATE((*ownercreate)) | , | ||
void * | ownercreatedata ) |
creates a variable index expression
scip | SCIP data structure |
expr | pointer where to store expression |
varidx | variable index to represent |
ownercreatedata | data to pass to ownercreate |
Definition at line 220 of file expr_varidx.c.
References assert(), EXPRHDLR_NAME, NULL, SCIP_CALL, SCIP_ERROR, SCIP_OKAY, SCIPABORT, SCIPcreateExpr(), SCIPerrorMessage, SCIPfindExprhdlr(), and varidx.
Referenced by SCIP_DECL_EXPR_MAPEXPR(), SCIP_DECL_EXPR_MAPEXPR(), and setQuadraticObj().
indicates whether expression is varidx expression
scip | SCIP data structure |
expr | expression |
Definition at line 252 of file expr_varidx.c.
References assert(), EXPRHDLR_NAME, FALSE, NULL, SCIP_Bool, SCIPexprGetHdlr(), SCIPexprGetNChildren(), and SCIPexprhdlrGetName().
Referenced by eval(), SCIPcreateNlpiProblemFromNlRows(), SCIPexprintCompile(), SCIPnlpiOracleDelVarSet(), SCIPnlpiOracleGetJacobianSparsity(), tryAddGadgetEvenOperator(), and updateVariableCounts().
int SCIPgetIndexExprVaridx | ( | SCIP_EXPR * | expr | ) |
gives the index stored in a varidx expression
expr | varindex expression |
Definition at line 267 of file expr_varidx.c.
References assert(), EXPRHDLR_NAME, NULL, SCIPexprGetData(), SCIPexprGetHdlr(), and SCIPexprhdlrGetName().
Referenced by eval(), SCIP_DECL_EXPRCOMPARE(), SCIP_DECL_EXPRHASH(), SCIP_DECL_EXPRPRINT(), SCIPcreateNlpiProblemFromNlRows(), SCIPexprintCompile(), SCIPnlpiOracleDelVarSet(), SCIPnlpiOracleGetJacobianSparsity(), and updateVariableCounts().
void SCIPsetIndexExprVaridx | ( | SCIP_EXPR * | expr, |
int | newindex ) |
sets the index stored in a varidx expression
expr | varindex expression |
newindex | new index |
Definition at line 278 of file expr_varidx.c.
References assert(), EXPRHDLR_NAME, NULL, SCIPexprGetHdlr(), SCIPexprhdlrGetName(), and SCIPexprSetData().
Referenced by SCIPnlpiOracleDelVarSet().