49 #define PROP_NAME "obbt" 50 #define PROP_DESC "optimization-based bound tightening propagator" 51 #define PROP_TIMING SCIP_PROPTIMING_AFTERLPLOOP 52 #define PROP_PRIORITY -1000000 54 #define PROP_DELAY TRUE 57 #define DEFAULT_CREATE_GENVBOUNDS TRUE 58 #define DEFAULT_FILTERING_NORM TRUE 60 #define DEFAULT_APPLY_FILTERROUNDS FALSE 62 #define DEFAULT_APPLY_TRIVIALFITLERING TRUE 63 #define DEFAULT_GENVBDSDURINGFILTER TRUE 64 #define DEFAULT_DUALFEASTOL 1e-9 66 #define DEFAULT_CONDITIONLIMIT -1.0 67 #define DEFAULT_BOUNDSTREPS 0.001 68 #define DEFAULT_FILTERING_MIN 2 70 #define DEFAULT_ITLIMITFACTOR 10.0 72 #define DEFAULT_MINITLIMIT 5000L 73 #define DEFAULT_ONLYNONCONVEXVARS FALSE 74 #define DEFAULT_TIGHTINTBOUNDSPROBING TRUE 76 #define DEFAULT_TIGHTCONTBOUNDSPROBING FALSE 78 #define DEFAULT_ORDERINGALGO 1 80 #define OBBT_SCOREBASE 5 81 #define GENVBOUND_PROP_NAME "genvbounds" 82 #define INTERVALINFTY 1E+43 84 #define DEFAULT_SEPARATESOL FALSE 87 #define DEFAULT_SEPAMINITER 0 88 #define DEFAULT_SEPAMAXITER 10 89 #define DEFAULT_GENVBDSDURINGSEPA TRUE 90 #define DEFAULT_PROPAGATEFREQ 0 97 #define infty2infty(infty1, infty2, val) ((val) >= (infty1) ? (infty2) : (val)) 111 unsigned int found:1;
158 int ntrivialfiltered;
160 int ngenvboundsprobing;
161 int ngenvboundsaggrfil;
162 int ngenvboundstrivfil;
168 int propagatecounter;
188 assert(scip !=
NULL);
189 assert(itlimit == -1 || itlimit >= 0);
191 assert(optimal !=
NULL);
203 SCIPwarningMessage(scip,
" error while solving LP in obbt propagator; LP solve terminated with code <%d>\n", retcode);
204 SCIPwarningMessage(scip,
" this does not affect the remaining solution procedure --> continue\n");
225 SCIPdebugMsg(scip,
" reached time limit while solving lp\n");
234 SCIPdebugMsg(scip,
" an error occured during solving lp\n");
240 SCIPdebugMsg(scip,
" received an unexpected solstat during solving lp: %d\n", lpsolstat);
264 assert(propdata !=
NULL);
265 assert(propdata->cutoffrow ==
NULL);
269 SCIPdebugMsg(scip,
"no objective cutoff since there is no cutoff bound\n");
273 SCIPdebugMsg(scip,
"create objective cutoff and add it to the LP\n");
283 for( i = 0; i < nvars; i++ )
292 propdata->cutoffrow = row;
324 assert( scip !=
NULL );
325 assert( propdata !=
NULL );
326 assert( bound !=
NULL );
343 for( i = 0; i < nvars; ++i )
349 assert((counter == 0 && coef == 0.0) || (counter == 1 && coef != 0.0));
364 assert(scip !=
NULL);
392 assert(scip !=
NULL);
393 assert(nolditerations >= 0);
394 assert(itlimit == -1 || itlimit >= 0);
404 itsleft =
MAX(itsleft, 0);
405 itsleft =
MIN(itsleft, INT_MAX);
407 SCIPdebugMsg(scip,
"iterations left: %d\n", (
int) itsleft);
408 return (
int) itsleft;
424 assert(scip !=
NULL);
425 assert(propdata !=
NULL);
440 if( propdata->normalize )
495 assert(scip !=
NULL);
496 assert(bound !=
NULL);
497 assert(propdata !=
NULL);
498 assert(propdata->genvboundprop !=
NULL);
499 assert(found !=
NULL);
540 for( k = 0; k < nvars; k++ )
544 assert(vars[k] != xi);
550 if( propdata->cutoffrow ==
NULL )
566 if( ncoefs > 0 || !
SCIPisZero(scip, gamma_dual) )
590 for( k = 0; k < nvars; k++ )
609 addgenvbound =
FALSE;
614 assert(idx < ncoefs);
615 genvboundvars[idx] = xk;
616 genvboundcoefs[idx] = redcost;
626 assert(!addgenvbound || idx == ncoefs);
649 SCIPdebugMsg(scip,
" found multiplier for <%s>: %g, skipping\n",
665 assert(i >= 0 && i < propdata->nbounds);
666 assert(propdata->lastidx >= 0 && propdata->lastidx < propdata->nbounds);
669 if( propdata->lastidx != i )
673 tmp = propdata->bounds[i];
674 propdata->bounds[i] = propdata->bounds[propdata->lastidx];
675 propdata->bounds[propdata->lastidx] = tmp;
678 propdata->lastidx -= 1;
692 assert(scip !=
NULL);
693 assert(propdata !=
NULL);
694 assert(nfiltered !=
NULL);
701 SCIPdebugMsg(scip,
"can't filter using existing lp solution since it was not solved to optimality\n");
706 for( i = propdata->nbounds - 1; i >= 0; --i )
713 bound = propdata->bounds[i];
765 assert(propdata->nprobingiterations >= 0);
768 if( optimal && propdata->genvboundprop !=
NULL 778 propdata->ngenvboundstrivfil += 1;
779 SCIPdebugMsg(scip,
"found genvbound during trivial filtering\n");
789 if( propdata->lastidx >= 0 )
820 assert(scip !=
NULL);
822 assert(propdata !=
NULL);
823 assert(itlimit == -1 || itlimit >= 0);
824 assert(nfiltered !=
NULL);
825 assert(objcoefs !=
NULL);
826 assert(objcoefsinds !=
NULL);
827 assert(nobjcoefs >= 0);
838 assert(propdata->nfilterlpiters >= 0);
842 SCIPdebugMsg(scip,
"skipping filter round since the LP was not solved to optimality\n");
849 for( i = 0; i < propdata->nbounds; i++ )
856 bound = propdata->bounds[i];
888 for( j = 0; j < nobjcoefs; ++j )
892 filterbound = propdata->bounds[ objcoefsinds[j] ];
893 assert(filterbound !=
NULL);
899 for( j = 0; j < nvars; ++j )
910 assert(propdata->nfilterlpiters >= 0);
913 if( optimal && propdata->genvboundprop !=
NULL 923 propdata->ngenvboundsaggrfil += 1;
924 SCIPdebugMsg(scip,
"found genvbound during aggressive filtering\n");
930 for( j = 0; j < nobjcoefs; ++j )
934 filterbound = propdata->bounds[ objcoefsinds[j] ];
935 assert(filterbound !=
NULL);
981 assert(scip !=
NULL);
983 assert(propdata !=
NULL);
984 assert(itlimit == -1 || itlimit >= 0);
1003 for( i = 0; i < nvars; i++ )
1008 for( i = 0; i < propdata->nbounds; i++ )
1011 && !propdata->bounds[i]->done )
1022 objcoefs[nobjcoefs] = objcoef;
1023 objcoefsinds[nobjcoefs] = i;
1032 SCIP_CALL(
filterRound(scip, propdata, nleftiterations, &nfiltered, objcoefs, objcoefsinds, nobjcoefs) );
1033 ntotalfiltered += nfiltered;
1034 SCIPdebugMsg(scip,
"filtered %d more bounds in lower bounds round\n", nfiltered);
1039 while( nfiltered >= propdata->nminfilter && ( nleftiterations == -1 || nleftiterations > 0 ) );
1046 for( i = 0; i < nobjcoefs; i++ )
1050 assert(objcoefsinds[i] >= 0 && objcoefsinds[i] < propdata->nbounds);
1051 bound = propdata->bounds[ objcoefsinds[i] ];
1052 assert(bound !=
NULL);
1060 for( i = 0; i < nvars; ++i )
1064 for( i = 0; i < propdata->nbounds; i++ )
1077 objcoefs[nobjcoefs] = objcoef;
1078 objcoefsinds[nobjcoefs] = i;
1087 SCIP_CALL(
filterRound(scip, propdata, nleftiterations, &nfiltered, objcoefs, objcoefsinds, nobjcoefs) );
1088 SCIPdebugMsg(scip,
"filtered %d more bounds in upper bounds round\n", nfiltered);
1089 ntotalfiltered += nfiltered;
1093 while( nfiltered >= propdata->nminfilter && ( nleftiterations == -1 || nleftiterations > 0 ) );
1095 SCIPdebugMsg(scip,
"filtered %d this round\n", ntotalfiltered);
1096 propdata->nfiltered += ntotalfiltered;
1118 assert(scip !=
NULL);
1120 assert(propdata !=
NULL);
1121 assert(result !=
NULL);
1126 for( i = 0; i < propdata->nbounds; i++ )
1132 bound = propdata->bounds[i];
1138 : SCIPvarGetUbLocal(bound->
var) );
1184 assert(scip !=
NULL);
1187 assert(tightened !=
NULL);
1252 diff = (!bound1->
done ? 1 : 0) - (!bound2->
done ? 1 : 0);
1276 assert(scip !=
NULL);
1277 assert(propdata !=
NULL);
1280 SCIPsortDownPtr((
void**) propdata->bounds, compBoundsBoundtype, propdata->nbounds);
1292 assert(scip !=
NULL);
1293 assert(bound !=
NULL);
1313 assert(scip !=
NULL);
1314 assert(propdata !=
NULL);
1319 for( k = 0; k <= propdata->lastidx; ++k )
1322 tmpbound = propdata->bounds[k];
1324 assert(tmpbound !=
NULL);
1331 if( propdata->orderingalgo == 0 )
1337 boundval = (propdata->orderingalgo == 2) ? -1.0 * boundval : boundval;
1339 if( bestidx == -1 || boundval < bestval )
1366 assert(nleftiterations !=
NULL);
1375 for( i = 0; i <= propdata->sepamaxiter; ++i )
1401 SCIPdebugMsg(scip,
"applySeparation() - optimal=%u error=%u lpiter=%" SCIP_LONGINT_FORMAT
"\n", optimal, error, nlpiter);
1405 if( error || !optimal )
1409 if( inroot && propdata->genvboundprop !=
NULL && propdata->genvbdsduringsepa )
1413 propdata->ngenvboundsprobing += found ? 1 : 0;
1421 SCIPdebugMsg(scip,
"apply separation - tightened=%u oldval=%e newval=%e\n", tightened, oldval,
1424 *success |= tightened;
1428 if( !tightened && i >= propdata->sepaminiter )
1450 assert(scip !=
NULL);
1451 assert(propdata !=
NULL);
1452 assert(nleftiterations !=
NULL);
1456 itlimit = *nleftiterations;
1458 iterationsleft = (*nleftiterations == -1) || (*nleftiterations > 0);
1470 if( propdata->bounds[0]->done || propdata->bounds[0]->filtered )
1472 SCIPdebugMsg(scip,
"no unprocessed/unfiltered bound left\n");
1477 propdata->lastidx = 0;
1478 while( propdata->lastidx < propdata->nbounds - 1 && !propdata->bounds[propdata->lastidx]->done &&
1479 !propdata->bounds[propdata->lastidx]->filtered )
1480 ++propdata->lastidx;
1482 SCIPdebugMsg(scip,
"lastidx = %d\n", propdata->lastidx);
1486 nextboundidx =
nextBound(scip, propdata, convexphase);
1489 if( nextboundidx == -1 )
1491 SCIPdebugMsg(scip,
"no unprocessed/unfiltered bound left\n");
1495 currbound = propdata->bounds[nextboundidx];
1505 assert(currbound !=
NULL);
1516 SCIPdebugMsg(scip,
"before solving Boundtype: %d , LB: %e , UB: %e\n",
1518 SCIPvarGetUbLocal(currbound->
var) );
1519 SCIPdebugMsg(scip,
"before solving var <%s>, LP value: %f\n",
1530 propdata->nsolvedbounds++;
1533 SCIPdebugMsg(scip,
"OPT: %u ERROR: %u\n" , optimal, error);
1534 SCIPdebugMsg(scip,
"after solving Boundtype: %d , LB: %e , UB: %e\n",
1536 SCIPvarGetUbLocal(currbound->
var) );
1537 SCIPdebugMsg(scip,
"after solving var <%s>, LP value: %f\n",
1542 iterationsleft = (*nleftiterations == -1) || (*nleftiterations > 0);
1565 && propdata->genvboundprop !=
NULL )
1572 propdata->ngenvboundsprobing += 1;
1582 SCIPdebugMsg(scip,
"tightening bound %s\n", success ?
"successful" :
"not successful");
1589 SCIPdebugMsg(scip,
"tightening bound %s\n", success ?
"successful" :
"not successful");
1593 if( iterationsleft && propdata->separatesol )
1621 if( propdata->applytrivialfilter )
1624 SCIPdebugMsg(scip,
"filtered %d bounds via inspecting present LP solution\n", nfiltered);
1625 propdata->ntrivialfiltered += nfiltered;
1628 propdata->propagatecounter += success ? 1 : 0;
1631 if( propdata->propagatefreq != 0 && propdata->propagatecounter >= propdata->propagatefreq )
1637 SCIPdebugMsg(scip,
"propagation - cutoff %u ndomreds %" SCIP_LONGINT_FORMAT
"\n", cutoff, ndomredsfound);
1639 propdata->npropagatedomreds += ndomredsfound;
1640 propdata->propagatecounter = 0;
1648 nextboundidx =
nextBound(scip, propdata, convexphase);
1651 if( nextboundidx == -1 )
1653 SCIPdebugMsg(scip,
"NO unvisited/unfiltered bound left!\n");
1657 currbound = propdata->bounds[nextboundidx];
1661 if( iterationsleft )
1663 SCIPdebugMsg(scip,
"still iterations left: %" SCIP_LONGINT_FORMAT
"\n", *nleftiterations);
1698 assert(scip !=
NULL);
1699 assert(propdata !=
NULL);
1700 assert(itlimit == -1 || itlimit >= 0);
1706 lastnpropagatedomreds = propdata->npropagatedomreds;
1707 nleftiterations = itlimit;
1709 propdata->lastidx = -1;
1714 if( propdata->propagatefreq > 0 )
1721 for( i = 0; i < propdata->nbounds; i++ )
1723 BOUND* bound = propdata->bounds[i];
1727 if( oldlbs !=
NULL && oldubs !=
NULL )
1753 if( propdata->applytrivialfilter && !continuenode )
1756 SCIPdebugMsg(scip,
"filtered %d bounds via inspecting present LP solution\n", nfiltered);
1757 propdata->ntrivialfiltered += nfiltered;
1768 if( propdata->dualfeastol < olddualfeastol )
1775 if( !hasconditionlimit )
1777 SCIPwarningMessage(scip,
"obbt propagator could not set condition limit in LP solver - running without\n");
1779 else if( propdata->conditionlimit > 0.0 && (oldconditionlimit < 0.0 || propdata->conditionlimit < oldconditionlimit) )
1786 if( !
SCIPisEQ(scip, oldboundstreps, propdata->boundstreps) )
1795 if( propdata->applyfilterrounds )
1803 for( i = 0; i < nvars; ++i )
1817 if( nleftiterations > 0 || itlimit < 0 )
1824 if( hasconditionlimit )
1830 if( oldlbs !=
NULL && oldubs !=
NULL && propdata->npropagatedomreds - lastnpropagatedomreds > 0 )
1832 assert(propdata->propagatefreq > 0);
1833 for( i = 0; i < propdata->nbounds; ++i )
1835 BOUND* bound = propdata->bounds[i];
1852 oldlb = oldlbs[bound->
index];
1853 oldub = oldubs[bound->
index];
1880 if( propdata->cutoffrow !=
NULL )
1907 assert(scip !=
NULL);
1908 assert(bound !=
NULL);
1909 assert(nlcount >= 0);
1910 assert(maxnlcount >= nlcount);
1954 assert(nlcounts !=
NULL);
1955 assert(nlrow !=
NULL);
1971 assert(bilinvar1 !=
NULL);
1972 assert(bilinvar2 !=
NULL);
1982 if( bilinvar1 != bilinvar2 )
1990 if( exprtree !=
NULL )
1996 for( t = 0; t < nexprtreevars; ++t)
1999 var = exprtreevars[t];
2000 assert(var !=
NULL);
2024 assert(nlcounts !=
NULL);
2031 if( conshdlr !=
NULL )
2038 SCIPdebugMsg(scip,
"nconss(quadratic) = %d\n", nconss);
2040 for( i = 0; i < nconss; ++i )
2047 assert(nlrow !=
NULL);
2056 if( conshdlr !=
NULL )
2061 SCIPdebugMsg(scip,
"nconss(nonlinear) = %d\n", nconss);
2063 for( i = 0; i < nconss; ++i )
2073 assert(nlrow !=
NULL);
2082 if( conshdlr !=
NULL )
2087 SCIPdebugMsg(scip,
"nconss(bivariate) = %d\n", nconss);
2089 for( i = 0; i < nconss; ++i )
2097 if( exprtree !=
NULL )
2130 if( conshdlr !=
NULL )
2137 for( i = 0; i < nconss; ++i )
2142 assert(nlrow !=
NULL);
2184 assert(scip !=
NULL);
2185 assert(propdata !=
NULL);
2203 for( i = 0; i < nvars; i++ )
2205 if( maxnlcount < nlcount[i] )
2206 maxnlcount = nlcount[i];
2210 propdata->boundssize = 2 * nvars;
2215 for( i = 0; i < nvars; i++ )
2217 if(
varIsInteresting(scip, vars[i], (propdata->onlynonconvexvars ? nccount[i] : nlcount[i])) )
2222 bdaddress = &(propdata->bounds[bdidx]);
2225 propdata->bounds[bdidx]->var = vars[i];
2226 propdata->bounds[bdidx]->found =
FALSE;
2227 propdata->bounds[bdidx]->filtered =
FALSE;
2228 propdata->bounds[bdidx]->newval = 0.0;
2229 propdata->bounds[bdidx]->score =
getScore(scip, propdata->bounds[bdidx], nlcount[i], maxnlcount);
2230 propdata->bounds[bdidx]->done =
FALSE;
2231 propdata->bounds[bdidx]->nonconvex = (nccount[i] > 0);
2232 propdata->bounds[bdidx]->index = bdidx;
2236 bdaddress = &(propdata->bounds[bdidx]);
2239 propdata->bounds[bdidx]->var = vars[i];
2240 propdata->bounds[bdidx]->found =
FALSE;
2241 propdata->bounds[bdidx]->filtered =
FALSE;
2242 propdata->bounds[bdidx]->newval = 0.0;
2243 propdata->bounds[bdidx]->score =
getScore(scip, propdata->bounds[bdidx], nlcount[i], maxnlcount);
2244 propdata->bounds[bdidx]->done =
FALSE;
2245 propdata->bounds[bdidx]->nonconvex = (nccount[i] > 0);
2246 propdata->bounds[bdidx]->index = bdidx;
2252 assert(nlcount !=
NULL);
2253 assert(nccount !=
NULL);
2258 propdata->nbounds = bdidx;
2261 if( propdata->nbounds <= 0 )
2263 assert(propdata->nbounds == 0);
2264 assert(propdata->boundssize >= 0 );
2268 SCIPdebugMsg(scip,
"problem has %d/%d interesting bounds\n", propdata->nbounds, 2 * nvars);
2270 if( propdata->nbounds > 0 )
2276 SCIPsortDownPtr((
void**) propdata->bounds, compBoundsScore, propdata->nbounds);
2295 assert(scip !=
NULL);
2296 assert(prop !=
NULL);
2311 assert(scip !=
NULL);
2312 assert(prop !=
NULL);
2317 assert(propdata !=
NULL);
2320 propdata->nbounds = -1;
2321 propdata->boundssize = 0;
2322 propdata->cutoffrow =
NULL;
2323 propdata->lastnode = -1;
2328 SCIPdebugMsg(scip,
"creating genvbounds: %s\n", propdata->genvboundprop !=
NULL ?
"true" :
"false");
2340 assert(scip !=
NULL);
2341 assert(prop !=
NULL);
2357 SCIPdebugMsg(scip,
"NLP not constructed, skipping obbt\n");
2366 SCIPdebugMsg(scip,
"not all columns in LP, skipping obbt\n");
2375 assert(propdata !=
NULL);
2378 if( propdata->nbounds == -1 )
2391 assert(propdata->nbounds >= 0);
2395 if( propdata->nbounds <= 0 )
2397 SCIPdebugMsg(scip,
"there are no interesting bounds\n");
2414 SCIPdebugMsg(scip,
"aborting since no optimal LP solution is at hand\n");
2419 if( propdata->itlimitfactor > 0.0 )
2421 propdata->minitlimit);
2451 assert(scip !=
NULL);
2452 assert(prop !=
NULL);
2457 assert(propdata !=
NULL);
2462 SCIPstatisticMessage(
"DIVE-LP: %" SCIP_LONGINT_FORMAT
" NFILTERED: %d NTRIVIALFILTERED: %d NSOLVED: %d " 2463 "FILTER-LP: %" SCIP_LONGINT_FORMAT
" NGENVB(dive): %d NGENVB(aggr.): %d NGENVB(triv.) %d\n",
2464 propdata->nprobingiterations, propdata->nfiltered, propdata->ntrivialfiltered, propdata->nsolvedbounds,
2465 propdata->nfilterlpiters, propdata->ngenvboundsprobing, propdata->ngenvboundsaggrfil, propdata->ngenvboundstrivfil);
2468 if( propdata->nbounds > 0 )
2471 for( i = propdata->nbounds - 1; i >= 0; i-- )
2478 propdata->nbounds = -1;
2493 assert(propdata !=
NULL);
2519 propdata->nprobingiterations = 0;
2520 propdata->nfiltered = 0;
2521 propdata->ntrivialfiltered = 0;
2522 propdata->nsolvedbounds = 0;
2523 propdata->ngenvboundsprobing = 0;
2524 propdata->ngenvboundsaggrfil = 0;
2525 propdata->ngenvboundstrivfil = 0;
2526 propdata->nfilterlpiters = 0;
2527 propdata->lastidx = -1;
2528 propdata->propagatecounter = 0;
2529 propdata->npropagatedomreds = 0;
2533 propExecObbt, propdata) );
2542 "should obbt try to provide genvbounds if possible?",
2546 "should coefficients in filtering be normalized w.r.t. the domains sizes?",
2550 "try to filter bounds in so-called filter rounds by solving auxiliary LPs?",
2554 "try to filter bounds with the LP solution after each solve?",
2558 "should we try to generate genvbounds during trivial and aggressive filtering?",
2562 "try to create genvbounds during separation process?",
2566 "minimal number of filtered bounds to apply another filter round",
2570 "multiple of root node LP iterations used as total LP iteration limit for obbt (<= 0: no limit )",
2574 "minimum LP iteration limit",
2578 "feasibility tolerance for reduced costs used in obbt; this value is used if SCIP's dual feastol is greater",
2582 "maximum condition limit used in LP solver (-1.0: no limit)",
2586 "minimal relative improve for strengthening bounds",
2590 "only apply obbt on non-convex variables",
2594 "should integral bounds be tightened during the probing mode?",
2598 "should continuous bounds be tightened during the probing mode?",
2602 "select the type of ordering algorithm which should be used (0: no special ordering, 1: greedy, 2: greedy reverse)",
2606 "should the obbt LP solution be separated?",
2610 "minimum number of iteration spend to separate an obbt LP solution",
2614 "maximum number of iteration spend to separate an obbt LP solution",
2618 "trigger a propagation round after that many bound tightenings (0: no propagation)",
enum SCIP_Result SCIP_RESULT
static SCIP_RETCODE countNLRowVarsNonConvexity(SCIP *scip, int *nlcounts, SCIP_NLROW *nlrow)
#define SCIPfreeBlockMemoryArray(scip, ptr, num)
#define DEFAULT_APPLY_FILTERROUNDS
#define DEFAULT_GENVBDSDURINGFILTER
enum SCIP_BoundType SCIP_BOUNDTYPE
SCIP_Bool SCIPinRepropagation(SCIP *scip)
SCIP_Longint SCIPgetNRootLPIterations(SCIP *scip)
#define SCIPallocBlockMemoryArray(scip, ptr, num)
SCIP_Bool SCIPisNLPConstructed(SCIP *scip)
SCIP_RETCODE SCIPtightenVarLb(SCIP *scip, SCIP_VAR *var, SCIP_Real newbound, SCIP_Bool force, SCIP_Bool *infeasible, SCIP_Bool *tightened)
SCIP_RETCODE SCIPcacheRowExtensions(SCIP *scip, SCIP_ROW *row)
SCIP_Bool SCIPisFeasEQ(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_NODE * SCIPgetCurrentNode(SCIP *scip)
static SCIP_DECL_SORTPTRCOMP(compBoundsScore)
SCIP_STAGE SCIPgetStage(SCIP *scip)
static SCIP_RETCODE filterExistingLP(SCIP *scip, SCIP_PROPDATA *propdata, int *nfiltered, BOUND *currbound)
#define DEFAULT_MINITLIMIT
SCIP_Longint SCIPgetNLPIterations(SCIP *scip)
static SCIP_RETCODE sortBounds(SCIP *scip, SCIP_PROPDATA *propdata)
SCIP_RETCODE SCIPcreateEmptyRowUnspec(SCIP *scip, SCIP_ROW **row, const char *name, SCIP_Real lhs, SCIP_Real rhs, SCIP_Bool local, SCIP_Bool modifiable, SCIP_Bool removable)
static void exchangeBounds(SCIP_PROPDATA *propdata, int i)
SCIP_CONSHDLR * SCIPfindConshdlr(SCIP *scip, const char *name)
SCIP_Real SCIPgetCutoffbound(SCIP *scip)
SCIP_RETCODE SCIPflushRowExtensions(SCIP *scip, SCIP_ROW *row)
SCIP_Bool SCIPisUbBetter(SCIP *scip, SCIP_Real newub, SCIP_Real oldlb, SCIP_Real oldub)
enum SCIP_BaseStat SCIP_BASESTAT
SCIP_RETCODE SCIPapplyCutsProbing(SCIP *scip, SCIP_Bool *cutoff)
#define DEFAULT_BOUNDSTREPS
SCIP_PROP * SCIPfindProp(SCIP *scip, const char *name)
SCIP_Real SCIPvarGetLbGlobal(SCIP_VAR *var)
#define infty2infty(infty1, infty2, val)
SCIP_RETCODE SCIPgetRealParam(SCIP *scip, const char *name, SCIP_Real *value)
#define DEFAULT_SEPAMAXITER
SCIP_BASESTAT SCIPcolGetBasisStatus(SCIP_COL *col)
static SCIP_DECL_PROPEXITSOL(propExitsolObbt)
SCIP_RETCODE SCIPaddVarToRow(SCIP *scip, SCIP_ROW *row, SCIP_VAR *var, SCIP_Real val)
#define DEFAULT_ITLIMITFACTOR
SCIP_Real SCIPgetVarRedcost(SCIP *scip, SCIP_VAR *var)
SCIP_Bool SCIPisPositive(SCIP *scip, SCIP_Real val)
SCIP_Real SCIPvarGetLbLocal(SCIP_VAR *var)
static SCIP_RETCODE filterRound(SCIP *scip, SCIP_PROPDATA *propdata, int itlimit, int *nfiltered, SCIP_Real *objcoefs, int *objcoefsinds, int nobjcoefs)
SCIP_RETCODE SCIPincludePropObbt(SCIP *scip)
SCIP_Bool SCIPvarIsBinary(SCIP_VAR *var)
SCIP_Real SCIPdualfeastol(SCIP *scip)
SCIP_Bool SCIPisFeasGE(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_RETCODE SCIPgetVarsData(SCIP *scip, SCIP_VAR ***vars, int *nvars, int *nbinvars, int *nintvars, int *nimplvars, int *ncontvars)
static int nextBound(SCIP *scip, SCIP_PROPDATA *propdata, SCIP_Bool convexphase)
SCIP_CONS ** SCIPconshdlrGetConss(SCIP_CONSHDLR *conshdlr)
#define DEFAULT_SEPAMINITER
SCIP_RETCODE SCIPaddLongintParam(SCIP *scip, const char *name, const char *desc, SCIP_Longint *valueptr, SCIP_Bool isadvanced, SCIP_Longint defaultvalue, SCIP_Longint minvalue, SCIP_Longint maxvalue, SCIP_DECL_PARAMCHGD((*paramchgd)), SCIP_PARAMDATA *paramdata)
int SCIPgetSubscipDepth(SCIP *scip)
SCIP_Real SCIPinfinity(SCIP *scip)
int SCIPsnprintf(char *t, int len, const char *s,...)
SCIP_Bool SCIPisNegative(SCIP *scip, SCIP_Real val)
#define DEFAULT_APPLY_TRIVIALFITLERING
SCIP_RETCODE SCIPgetNlRowNonlinear(SCIP *scip, SCIP_CONS *cons, SCIP_NLROW **nlrow)
enum SCIP_Retcode SCIP_RETCODE
#define SCIPstatisticMessage
static SCIP_Real getFilterCoef(SCIP *scip, SCIP_PROPDATA *propdata, SCIP_VAR *var, SCIP_BOUNDTYPE boundtype)
int SCIPvarGetProbindex(SCIP_VAR *var)
SCIP_Real SCIPnlrowGetRhs(SCIP_NLROW *nlrow)
SCIP_RETCODE SCIPgetCurvatureNonlinear(SCIP *scip, SCIP_CONS *cons, SCIP_Bool checkcurv, SCIP_EXPRCURV *curvature)
void SCIPintervalSetBounds(SCIP_INTERVAL *resultant, SCIP_Real inf, SCIP_Real sup)
SCIP_RETCODE SCIPtightenVarUb(SCIP *scip, SCIP_VAR *var, SCIP_Real newbound, SCIP_Bool force, SCIP_Bool *infeasible, SCIP_Bool *tightened)
#define SCIPfreeBlockMemory(scip, ptr)
SCIP_RETCODE SCIPchgVarLbProbing(SCIP *scip, SCIP_VAR *var, SCIP_Real newbound)
SCIP_RETCODE SCIPgetNLPVarsNonlinearity(SCIP *scip, int *nlcount)
SCIP_Bool SCIPisEQ(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
#define GENVBOUND_PROP_NAME
#define SCIPfreeBufferArray(scip, ptr)
enum SCIP_LPSolStat SCIP_LPSOLSTAT
#define SCIPallocBlockMemory(scip, ptr)
SCIP_RETCODE SCIPsetRealParam(SCIP *scip, const char *name, SCIP_Real value)
SCIP_Real SCIProwGetDualsol(SCIP_ROW *row)
void SCIPwarningMessage(SCIP *scip, const char *formatstr,...)
SCIP_RETCODE SCIPaddIntParam(SCIP *scip, const char *name, const char *desc, int *valueptr, SCIP_Bool isadvanced, int defaultvalue, int minvalue, int maxvalue, SCIP_DECL_PARAMCHGD((*paramchgd)), SCIP_PARAMDATA *paramdata)
SCIP_VAR ** SCIPexprtreeGetVars(SCIP_EXPRTREE *tree)
static SCIP_RETCODE tightenBoundProbing(SCIP *scip, BOUND *bound, SCIP_Real newval, SCIP_Bool *tightened)
int SCIPnlrowGetNQuadElems(SCIP_NLROW *nlrow)
#define DEFAULT_ORDERINGALGO
static unsigned int getScore(SCIP *scip, BOUND *bound, int nlcount, int maxnlcount)
const char * SCIPgetProbName(SCIP *scip)
SCIP_Bool SCIProwIsInLP(SCIP_ROW *row)
SCIP_EXPRTREE * SCIPgetExprtreeBivariate(SCIP *scip, SCIP_CONS *cons)
SCIP_RETCODE SCIPexprtreeCheckCurvature(SCIP_EXPRTREE *tree, SCIP_Real infinity, SCIP_INTERVAL *varbounds, SCIP_EXPRCURV *curv, SCIP_INTERVAL *bounds)
SCIP_Bool SCIPisLbBetter(SCIP *scip, SCIP_Real newlb, SCIP_Real oldlb, SCIP_Real oldub)
SCIP_Longint SCIPnodeGetNumber(SCIP_NODE *node)
static SCIP_RETCODE createGenVBound(SCIP *scip, SCIP_PROPDATA *propdata, BOUND *bound, SCIP_Bool *found)
SCIP_Real SCIPvarGetUbGlobal(SCIP_VAR *var)
#define DEFAULT_DUALFEASTOL
#define DEFAULT_FILTERING_NORM
int SCIPgetNNLPVars(SCIP *scip)
static SCIP_RETCODE applyBoundChgs(SCIP *scip, SCIP_PROPDATA *propdata, SCIP_RESULT *result)
SCIP_VAR ** SCIPnlrowGetQuadVars(SCIP_NLROW *nlrow)
static SCIP_Bool includeVarGenVBound(SCIP *scip, SCIP_VAR *var)
SCIP_Bool SCIPisLT(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_RETCODE SCIPpropagateProbing(SCIP *scip, int maxproprounds, SCIP_Bool *cutoff, SCIP_Longint *ndomredsfound)
static SCIP_DECL_PROPRESPROP(propRespropObbt)
void SCIPsortDownPtr(void **ptrarray, SCIP_DECL_SORTPTRCOMP((*ptrcomp)), int len)
SCIP_RETCODE SCIPgenVBoundAdd(SCIP *scip, SCIP_PROP *genvboundprop, SCIP_VAR **vars, SCIP_VAR *var, SCIP_Real *coefs, int ncoefs, SCIP_Real coefcutoffbound, SCIP_Real constant, SCIP_BOUNDTYPE boundtype)
#define SCIPfreeBufferArrayNull(scip, ptr)
SCIP_RETCODE SCIPendProbing(SCIP *scip)
const char * SCIPvarGetName(SCIP_VAR *var)
constraint handler for quadratic constraints
#define DEFAULT_GENVBDSDURINGSEPA
SCIP_RETCODE SCIPchgDualfeastol(SCIP *scip, SCIP_Real dualfeastol)
SCIP_Real SCIPvarGetLPSol(SCIP_VAR *var)
int SCIPexprtreeGetNVars(SCIP_EXPRTREE *tree)
SCIP_RETCODE SCIPgetNlRowQuadratic(SCIP *scip, SCIP_CONS *cons, SCIP_NLROW **nlrow)
static SCIP_Bool varIsInteresting(SCIP *scip, SCIP_VAR *var, int nlcount)
SCIP_QUADELEM * SCIPnlrowGetQuadElems(SCIP_NLROW *nlrow)
SCIP_Real SCIPgetVarObjProbing(SCIP *scip, SCIP_VAR *var)
#define DEFAULT_PROPAGATEFREQ
SCIP_RETCODE SCIPsolveProbingLP(SCIP *scip, int itlim, SCIP_Bool *lperror, SCIP_Bool *cutoff)
static SCIP_RETCODE getNLPVarsNonConvexity(SCIP *scip, int *nlcounts)
SCIP_Bool SCIPisFeasLE(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
static int getIterationsLeft(SCIP *scip, SCIP_Longint nolditerations, SCIP_Longint itlimit)
#define SCIPallocBufferArray(scip, ptr, num)
SCIP_LPSOLSTAT SCIPgetLPSolstat(SCIP *scip)
SCIP_RETCODE SCIPseparateSol(SCIP *scip, SCIP_SOL *sol, SCIP_Bool pretendroot, SCIP_Bool onlydelayed, SCIP_Bool *delayed, SCIP_Bool *cutoff)
int SCIPgetDepth(SCIP *scip)
constraint handler for nonlinear constraints
optimization-based bound tightening propagator
SCIP_RETCODE SCIPgetNlRowAbspower(SCIP *scip, SCIP_CONS *cons, SCIP_NLROW **nlrow)
#define DEFAULT_CREATE_GENVBOUNDS
SCIP_Real SCIPvarGetObj(SCIP_VAR *var)
SCIP_RETCODE SCIPsetPropCopy(SCIP *scip, SCIP_PROP *prop, SCIP_DECL_PROPCOPY((*propcopy)))
static SCIP_DECL_PROPFREE(propFreeObbt)
SCIP_COL * SCIPvarGetCol(SCIP_VAR *var)
constraint handler for bivariate nonlinear constraints
SCIP_Bool SCIPisInfinity(SCIP *scip, SCIP_Real val)
static SCIP_RETCODE applySeparation(SCIP *scip, SCIP_PROPDATA *propdata, BOUND *currbound, SCIP_Longint *nleftiterations, SCIP_Bool *success)
Constraint handler for absolute power constraints .
static SCIP_RETCODE setObjProbing(SCIP *scip, SCIP_PROPDATA *propdata, BOUND *bound, SCIP_Real coef)
SCIP_RETCODE SCIPsetPropExitsol(SCIP *scip, SCIP_PROP *prop, SCIP_DECL_PROPEXITSOL((*propexitsol)))
int SCIPconshdlrGetNActiveConss(SCIP_CONSHDLR *conshdlr)
static SCIP_DECL_PROPCOPY(propCopyObbt)
SCIP_Bool SCIPinProbing(SCIP *scip)
const char * SCIPpropGetName(SCIP_PROP *prop)
int SCIPgetNVars(SCIP *scip)
SCIP_EXPRTREE * SCIPnlrowGetExprtree(SCIP_NLROW *nlrow)
static SCIP_RETCODE solveLP(SCIP *scip, int itlimit, SCIP_Bool *error, SCIP_Bool *optimal)
enum SCIP_ExprCurv SCIP_EXPRCURV
SCIP_RETCODE SCIPreleaseRow(SCIP *scip, SCIP_ROW **row)
SCIP_RETCODE SCIPsetPropResprop(SCIP *scip, SCIP_PROP *prop, SCIP_DECL_PROPRESPROP((*propresprop)))
SCIP_Real SCIPgetLPObjval(SCIP *scip)
SCIP_Bool SCIPisGT(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
#define DEFAULT_SEPARATESOL
int SCIPgetNCuts(SCIP *scip)
SCIP_RETCODE SCIPaddRowProbing(SCIP *scip, SCIP_ROW *row)
static SCIP_RETCODE findNewBounds(SCIP *scip, SCIP_PROPDATA *propdata, SCIP_Longint *nleftiterations, SCIP_Bool convexphase)
#define DEFAULT_ONLYNONCONVEXVARS
SCIP_VAR ** SCIPgetVars(SCIP *scip)
SCIP_RETCODE SCIPsetPropInitsol(SCIP *scip, SCIP_PROP *prop, SCIP_DECL_PROPINITSOL((*propinitsol)))
SCIP_VARSTATUS SCIPvarGetStatus(SCIP_VAR *var)
struct SCIP_PropData SCIP_PROPDATA
SCIP_Bool SCIPisStopped(SCIP *scip)
static SCIP_Real evalBound(SCIP *scip, BOUND *bound)
SCIP_RETCODE SCIPsetPropFree(SCIP *scip, SCIP_PROP *prop, SCIP_DECL_PROPFREE((*propfree)))
SCIP_PROPDATA * SCIPpropGetData(SCIP_PROP *prop)
void SCIPpropSetData(SCIP_PROP *prop, SCIP_PROPDATA *propdata)
static SCIP_RETCODE filterBounds(SCIP *scip, SCIP_PROPDATA *propdata, SCIP_Longint itlimit)
SCIP_Bool SCIPallColsInLP(SCIP *scip)
#define DEFAULT_TIGHTCONTBOUNDSPROBING
static SCIP_RETCODE addObjCutoff(SCIP *scip, SCIP_PROPDATA *propdata)
static SCIP_Bool varIsFixedLocal(SCIP *scip, SCIP_VAR *var)
static SCIP_DECL_PROPINITSOL(propInitsolObbt)
SCIP_VARTYPE SCIPvarGetType(SCIP_VAR *var)
SCIP_Bool SCIPisZero(SCIP *scip, SCIP_Real val)
#define DEFAULT_CONDITIONLIMIT
SCIP_Real SCIPvarGetUbLocal(SCIP_VAR *var)
#define DEFAULT_TIGHTINTBOUNDSPROBING
SCIP_RETCODE SCIPstartProbing(SCIP *scip)
#define BMSclearMemoryArray(ptr, num)
static SCIP_RETCODE initBounds(SCIP *scip, SCIP_PROPDATA *propdata)
SCIP_Real SCIPceil(SCIP *scip, SCIP_Real val)
static SCIP_DECL_PROPEXEC(propExecObbt)
SCIP_Real SCIPnlrowGetLhs(SCIP_NLROW *nlrow)
static SCIP_RETCODE applyObbt(SCIP *scip, SCIP_PROPDATA *propdata, SCIP_Longint itlimit, SCIP_RESULT *result)
SCIP_Bool SCIPvarIsIntegral(SCIP_VAR *var)
SCIP_RETCODE SCIPchgVarUbProbing(SCIP *scip, SCIP_VAR *var, SCIP_Real newbound)
#define DEFAULT_FILTERING_MIN
SCIP_RETCODE SCIPaddRealParam(SCIP *scip, const char *name, const char *desc, SCIP_Real *valueptr, SCIP_Bool isadvanced, SCIP_Real defaultvalue, SCIP_Real minvalue, SCIP_Real maxvalue, SCIP_DECL_PARAMCHGD((*paramchgd)), SCIP_PARAMDATA *paramdata)
SCIP_Real SCIPfloor(SCIP *scip, SCIP_Real val)
SCIP_Bool SCIPisConvexQuadratic(SCIP *scip, SCIP_CONS *cons)
SCIP_Bool SCIPallowObjProp(SCIP *scip)
SCIP_RETCODE SCIPaddBoolParam(SCIP *scip, const char *name, const char *desc, SCIP_Bool *valueptr, SCIP_Bool isadvanced, SCIP_Bool defaultvalue, SCIP_DECL_PARAMCHGD((*paramchgd)), SCIP_PARAMDATA *paramdata)
generalized variable bounds propagator
SCIP_RETCODE SCIPincludePropBasic(SCIP *scip, SCIP_PROP **propptr, const char *name, const char *desc, int priority, int freq, SCIP_Bool delay, SCIP_PROPTIMING timingmask, SCIP_DECL_PROPEXEC((*propexec)), SCIP_PROPDATA *propdata)
SCIP_RETCODE SCIPchgVarObjProbing(SCIP *scip, SCIP_VAR *var, SCIP_Real newobj)