power and signed power expression handlers
Definition in file expr_pow.h.
Go to the source code of this file.
Functions | |
SCIP_RETCODE | SCIPincludeExprhdlrPow (SCIP *scip) |
SCIP_RETCODE | SCIPincludeExprhdlrSignpower (SCIP *scip) |
void | SCIPaddSquareLinearization (SCIP *scip, SCIP_Real sqrcoef, SCIP_Real refpoint, SCIP_Bool isint, SCIP_Real *lincoef, SCIP_Real *linconstant, SCIP_Bool *success) |
void | SCIPaddSquareSecant (SCIP *scip, SCIP_Real sqrcoef, SCIP_Real lb, SCIP_Real ub, SCIP_Real *lincoef, SCIP_Real *linconstant, SCIP_Bool *success) |
void | SCIPestimateRoot (SCIP *scip, SCIP_Real exponent, SCIP_Bool overestimate, SCIP_Real xlb, SCIP_Real xub, SCIP_Real xref, SCIP_Real *constant, SCIP_Real *slope, SCIP_Bool *islocal, SCIP_Bool *success) |
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) |
void SCIPaddSquareLinearization | ( | SCIP * | scip, |
SCIP_Real | sqrcoef, | ||
SCIP_Real | refpoint, | ||
SCIP_Bool | isint, | ||
SCIP_Real * | lincoef, | ||
SCIP_Real * | linconstant, | ||
SCIP_Bool * | success ) |
computes coefficients of linearization of a square term in a reference point
scip | SCIP data structure |
sqrcoef | coefficient of square term |
refpoint | point where to linearize |
isint | whether corresponding variable is a discrete variable, and thus linearization could be moved |
lincoef | buffer to add coefficient of linearization |
linconstant | buffer to add constant of linearization |
success | buffer to set to FALSE if linearization has failed due to large numbers |
Definition at line 3253 of file expr_pow.c.
References assert(), FALSE, NULL, REALABS, SCIP_Bool, SCIP_Real, SCIPfloor(), SCIPisInfinity(), and SCIPisIntegral().
Referenced by addBilinearTermToCut(), addRltTerm(), and buildPowEstimator().
void SCIPaddSquareSecant | ( | SCIP * | scip, |
SCIP_Real | sqrcoef, | ||
SCIP_Real | lb, | ||
SCIP_Real | ub, | ||
SCIP_Real * | lincoef, | ||
SCIP_Real * | linconstant, | ||
SCIP_Bool * | success ) |
computes coefficients of secant of a square term
scip | SCIP data structure |
sqrcoef | coefficient of square term |
lb | lower bound on variable |
ub | upper bound on variable |
lincoef | buffer to add coefficient of secant |
linconstant | buffer to add constant of secant |
success | buffer to set to FALSE if secant has failed due to large numbers or unboundedness |
Definition at line 3321 of file expr_pow.c.
References assert(), FALSE, NULL, REALABS, SCIP_Bool, SCIP_Real, SCIPisInfinity(), and SCIPisLE().
Referenced by addBilinearTermToCut(), addRltTerm(), and buildPowEstimator().
void SCIPestimateRoot | ( | SCIP * | scip, |
SCIP_Real | exponent, | ||
SCIP_Bool | overestimate, | ||
SCIP_Real | xlb, | ||
SCIP_Real | xub, | ||
SCIP_Real | xref, | ||
SCIP_Real * | constant, | ||
SCIP_Real * | slope, | ||
SCIP_Bool * | islocal, | ||
SCIP_Bool * | success ) |
Separation for roots with exponent in [0,1]
Separation for roots with exponent in [0,1]
8 +----------------------------------------------------------------------+ | + + + + | 7 |-+ x**0.5 ********| | *********| | ******** | 6 |-+ ******** +-| | ****** | 5 |-+ ****** +-| | ****** | | ***** | 4 |-+ **** +-| | ***** | 3 |-+ **** +-| | *** | | *** | 2 |-+ ** +-| | ** | 1 |** +-| |* | |* + + + + | 0 +----------------------------------------------------------------------+ 0 10 20 30 40 50
scip | SCIP data structure |
exponent | exponent |
overestimate | should the power be overestimated? |
xlb | lower bound on x |
xub | upper bound on x |
xref | reference point (where to linearize) |
constant | buffer to store constant term of estimator |
slope | buffer to store slope of estimator |
islocal | buffer to store whether estimator only locally valid, that is, it depends on given bounds |
success | buffer to store whether estimator could be computed |
Definition at line 3395 of file expr_pow.c.
References assert(), computeSecant(), computeTangent(), FALSE, NULL, SCIP_Bool, SCIP_Real, SCIPisZero(), and TRUE.
Referenced by buildPowEstimator(), and estimateSpecialPower().