96#define CONSHDLR_NAME "linear"
97#define CONSHDLR_DESC "linear constraints of the form lhs <= a^T x <= rhs"
98#define CONSHDLR_SEPAPRIORITY +100000
99#define CONSHDLR_ENFOPRIORITY -1000000
100#define CONSHDLR_CHECKPRIORITY -1000000
101#define CONSHDLR_SEPAFREQ 0
102#define CONSHDLR_PROPFREQ 1
103#define CONSHDLR_EAGERFREQ 100
105#define CONSHDLR_MAXPREROUNDS -1
106#define CONSHDLR_DELAYSEPA FALSE
107#define CONSHDLR_DELAYPROP FALSE
108#define CONSHDLR_NEEDSCONS TRUE
110#define CONSHDLR_PRESOLTIMING (SCIP_PRESOLTIMING_FAST | SCIP_PRESOLTIMING_EXHAUSTIVE)
111#define CONSHDLR_PROP_TIMING SCIP_PROPTIMING_BEFORELP
113#define EVENTHDLR_NAME "linear"
114#define EVENTHDLR_DESC "bound change event handler for linear constraints"
116#define CONFLICTHDLR_NAME "linear"
117#define CONFLICTHDLR_DESC "conflict handler creating linear constraints"
118#define CONFLICTHDLR_PRIORITY -1000000
120#define DEFAULT_TIGHTENBOUNDSFREQ 1
121#define DEFAULT_MAXROUNDS 5
122#define DEFAULT_MAXROUNDSROOT -1
123#define DEFAULT_MAXSEPACUTS 50
124#define DEFAULT_MAXSEPACUTSROOT 200
125#define DEFAULT_PRESOLPAIRWISE TRUE
126#define DEFAULT_PRESOLUSEHASHING TRUE
127#define DEFAULT_NMINCOMPARISONS 200000
128#define DEFAULT_MINGAINPERNMINCOMP 1e-06
130#define DEFAULT_SORTVARS TRUE
132#define DEFAULT_CHECKRELMAXABS FALSE
134#define DEFAULT_MAXAGGRNORMSCALE 0.0
136#define DEFAULT_MAXEASYACTIVITYDELTA 1e6
138#define DEFAULT_MAXCARDBOUNDDIST 0.0
140#define DEFAULT_SEPARATEALL FALSE
142#define DEFAULT_AGGREGATEVARIABLES TRUE
143#define DEFAULT_SIMPLIFYINEQUALITIES TRUE
144#define DEFAULT_DUALPRESOLVING TRUE
145#define DEFAULT_SINGLETONSTUFFING TRUE
146#define DEFAULT_SINGLEVARSTUFFING FALSE
148#define DEFAULT_DETECTCUTOFFBOUND TRUE
151#define DEFAULT_DETECTLOWERBOUND TRUE
154#define DEFAULT_DETECTPARTIALOBJECTIVE TRUE
156#define DEFAULT_RANGEDROWPROPAGATION TRUE
157#define DEFAULT_RANGEDROWARTCONS TRUE
158#define DEFAULT_RANGEDROWMAXDEPTH INT_MAX
159#define DEFAULT_RANGEDROWFREQ 1
161#define DEFAULT_MULTAGGRREMOVE FALSE
163#define DEFAULT_MAXMULTAGGRQUOT 1e+03
164#define DEFAULT_MAXDUALMULTAGGRQUOT 1e+20
165#define DEFAULT_EXTRACTCLIQUES TRUE
167#define MAXDNOM 10000LL
168#define MAXSCALEDCOEF 0
169#define MAXSCALEDCOEFINTEGER 0
172#define MAXACTVAL 1e+09
176#define MAXVALRECOMP 1e+06
177#define MINVALRECOMP 1e-05
180#define NONLINCONSUPGD_PRIORITY 1000000
198 SCIP_Real lastminactivity;
200 SCIP_Real lastmaxactivity;
206 SCIP_Real lastglbminactivity;
208 SCIP_Real lastglbmaxactivity;
210 SCIP_Real maxactdelta;
212 uint64_t possignature;
213 uint64_t negsignature;
219 int minactivityneginf;
220 int minactivityposinf;
221 int maxactivityneginf;
222 int maxactivityposinf;
223 int minactivityneghuge;
224 int minactivityposhuge;
225 int maxactivityneghuge;
226 int maxactivityposhuge;
227 int glbminactivityneginf;
228 int glbminactivityposinf;
229 int glbmaxactivityneginf;
230 int glbmaxactivityposinf;
231 int glbminactivityneghuge;
232 int glbminactivityposhuge;
233 int glbmaxactivityneghuge;
234 int glbmaxactivityposhuge;
240 unsigned int boundstightened:2;
241 unsigned int rangedrowpropagated:2;
243 unsigned int validmaxabsval:1;
244 unsigned int validminabsval:1;
245 unsigned int validactivities:1;
246 unsigned int validminact:1;
247 unsigned int validmaxact:1;
248 unsigned int validglbminact:1;
249 unsigned int validglbmaxact:1;
250 unsigned int presolved:1;
251 unsigned int removedfixings:1;
252 unsigned int validsignature:1;
253 unsigned int changed:1;
254 unsigned int normalized:1;
255 unsigned int upgradetried:1;
256 unsigned int upgraded:1;
257 unsigned int indexsorted:1;
258 unsigned int merged:1;
259 unsigned int cliquesadded:1;
260 unsigned int implsadded:1;
261 unsigned int coefsorted:1;
262 unsigned int varsdeleted:1;
263 unsigned int hascontvar:1;
264 unsigned int hasnonbinvar:1;
265 unsigned int hasnonbinvalid:1;
266 unsigned int checkabsolute:1;
278struct SCIP_ConshdlrData
282 SCIP_Real maxaggrnormscale;
284 SCIP_Real maxcardbounddist;
286 SCIP_Real mingainpernmincomp;
287 SCIP_Real maxeasyactivitydelta;
289 int linconsupgradessize;
290 int nlinconsupgrades;
291 int tightenboundsfreq;
298 SCIP_Bool presolpairwise;
299 SCIP_Bool presolusehashing;
300 SCIP_Bool separateall;
302 SCIP_Bool aggregatevariables;
303 SCIP_Bool simplifyinequalities;
304 SCIP_Bool dualpresolving;
305 SCIP_Bool singletonstuffing;
306 SCIP_Bool singlevarstuffing;
309 SCIP_Bool checkrelmaxabs;
311 SCIP_Bool detectcutoffbound;
314 SCIP_Bool detectlowerbound;
317 SCIP_Bool detectpartialobjective;
319 SCIP_Bool rangedrowpropagation;
322 SCIP_Bool rangedrowartcons;
323 int rangedrowmaxdepth;
325 SCIP_Bool multaggrremove;
327 SCIP_Real maxmultaggrquot;
328 SCIP_Real maxdualmultaggrquot;
329 SCIP_Bool extractcliques;
364 unsigned int proprule:8;
380 inferinfo.val.asint =
i;
391 return inferinfo.val.asint;
400 return (
int) inferinfo.val.asbits.proprule;
409 return (
int) inferinfo.val.asbits.pos;
425 inferinfo.val.asbits.proprule = (
unsigned int) proprule;
426 inferinfo.val.asbits.pos = (
unsigned int) pos;
456 assert(conshdlrdata->nlinconsupgrades <= conshdlrdata->linconsupgradessize);
458 if( num > conshdlrdata->linconsupgradessize )
464 conshdlrdata->linconsupgradessize =
newsize;
481 assert(consdata->nvars <= consdata->varssize);
483 if( num > consdata->varssize )
490 if( consdata->eventdata !=
NULL )
521 (*linconsupgrade)->priority = priority;
522 (*linconsupgrade)->active =
TRUE;
554 (*conshdlrdata)->linconsupgrades =
NULL;
555 (*conshdlrdata)->linconsupgradessize = 0;
556 (*conshdlrdata)->nlinconsupgrades = 0;
557 (*conshdlrdata)->naddconss = 0;
560 (*conshdlrdata)->eventhdlr = eventhdlr;
578 for(
i = 0;
i < (*conshdlrdata)->nlinconsupgrades; ++
i )
603 for(
i = conshdlrdata->nlinconsupgrades - 1;
i >= 0; --
i )
605 if( conshdlrdata->linconsupgrades[
i]->linconsupgd ==
linconsupgd )
633 for(
i = conshdlrdata->nlinconsupgrades;
634 i > 0 && conshdlrdata->linconsupgrades[
i-1]->priority <
linconsupgrade->priority; --
i )
636 conshdlrdata->linconsupgrades[
i] = conshdlrdata->linconsupgrades[
i-1];
640 conshdlrdata->nlinconsupgrades++;
741 consdata->eventdata[pos]->cons = cons;
742 consdata->eventdata[pos]->varpos = pos;
747 eventhdlr, consdata->eventdata[pos], &consdata->eventdata[pos]->filterpos) );
749 consdata->removedfixings = consdata->removedfixings &&
SCIPvarIsActive(consdata->vars[pos]);
776 assert(consdata->eventdata[pos]->cons == cons);
777 assert(consdata->eventdata[pos]->varpos == pos);
782 eventhdlr, consdata->eventdata[pos], consdata->eventdata[pos]->filterpos) );
813 for(
i = 0;
i < consdata->nvars; ++
i )
840 for(
i = consdata->nvars - 1;
i >= 0; --
i )
890 (*consdata)->varssize = 0;
891 (*consdata)->nvars =
nvars;
892 (*consdata)->hascontvar =
FALSE;
893 (*consdata)->hasnonbinvar =
FALSE;
894 (*consdata)->hasnonbinvalid =
TRUE;
895 (*consdata)->vars =
NULL;
896 (*consdata)->vals =
NULL;
912 for( v = 0; v <
nvars; ++v )
935 if( !(*consdata)->hascontvar )
941 (*consdata)->hasnonbinvar =
TRUE;
944 (*consdata)->hascontvar =
TRUE;
950 (*consdata)->nvars =
k;
957 (*consdata)->varssize =
k;
964 (*consdata)->eventdata =
NULL;
976 (*consdata)->row =
NULL;
977 (*consdata)->nlrow =
NULL;
978 (*consdata)->lhs = lhs;
979 (*consdata)->rhs = rhs;
987 (*consdata)->maxactdeltavar =
NULL;
988 (*consdata)->minactivityneginf = -1;
989 (*consdata)->minactivityposinf = -1;
990 (*consdata)->maxactivityneginf = -1;
991 (*consdata)->maxactivityposinf = -1;
992 (*consdata)->minactivityneghuge = -1;
993 (*consdata)->minactivityposhuge = -1;
994 (*consdata)->maxactivityneghuge = -1;
995 (*consdata)->maxactivityposhuge = -1;
1000 (*consdata)->glbminactivityneginf = -1;
1001 (*consdata)->glbminactivityposinf = -1;
1002 (*consdata)->glbmaxactivityneginf = -1;
1003 (*consdata)->glbmaxactivityposinf = -1;
1004 (*consdata)->glbminactivityneghuge = -1;
1005 (*consdata)->glbminactivityposhuge = -1;
1006 (*consdata)->glbmaxactivityneghuge = -1;
1007 (*consdata)->glbmaxactivityposhuge = -1;
1008 (*consdata)->possignature = 0;
1009 (*consdata)->negsignature = 0;
1010 (*consdata)->validmaxabsval =
FALSE;
1011 (*consdata)->validminabsval =
FALSE;
1012 (*consdata)->validactivities =
FALSE;
1013 (*consdata)->validminact =
FALSE;
1014 (*consdata)->validmaxact =
FALSE;
1015 (*consdata)->validglbminact =
FALSE;
1016 (*consdata)->validglbmaxact =
FALSE;
1017 (*consdata)->boundstightened = 0;
1018 (*consdata)->presolved =
FALSE;
1019 (*consdata)->removedfixings =
FALSE;
1020 (*consdata)->validsignature =
FALSE;
1021 (*consdata)->changed =
TRUE;
1022 (*consdata)->normalized =
FALSE;
1023 (*consdata)->upgradetried =
FALSE;
1024 (*consdata)->upgraded =
FALSE;
1025 (*consdata)->indexsorted = (
nvars <= 1);
1026 (*consdata)->merged = (
nvars <= 1);
1027 (*consdata)->cliquesadded =
FALSE;
1028 (*consdata)->implsadded =
FALSE;
1029 (*consdata)->coefsorted =
FALSE;
1030 (*consdata)->nbinvars = -1;
1031 (*consdata)->varsdeleted =
FALSE;
1032 (*consdata)->rangedrowpropagated = 0;
1033 (*consdata)->checkabsolute =
FALSE;
1042 for( v = 0; v < (*consdata)->nvars; v++ )
1045 if( (*consdata)->vars[v] ==
NULL )
1072 assert((*consdata)->varssize >= 0);
1075 if( (*consdata)->row !=
NULL )
1081 if( (*consdata)->nlrow !=
NULL )
1087 for( v = 0; v < (*consdata)->nvars; v++ )
1119 if( consdata->nvars == 0 )
1166 if( consdata->nvars == 0 )
1173 for( v = 0; v < consdata->nvars; ++v )
1175 if( consdata->vals !=
NULL )
1177 if( consdata->vals[v] == 1.0 )
1182 else if( consdata->vals[v] == -1.0 )
1187 else if( consdata->nvars > 0 )
1220 consdata->validactivities =
FALSE;
1221 consdata->validminact =
FALSE;
1222 consdata->validmaxact =
FALSE;
1223 consdata->validglbminact =
FALSE;
1224 consdata->validglbmaxact =
FALSE;
1225 consdata->validmaxabsval =
FALSE;
1226 consdata->validminabsval =
FALSE;
1227 consdata->hasnonbinvalid =
FALSE;
1235 consdata->maxactdeltavar =
NULL;
1236 consdata->minactivityneginf = -1;
1237 consdata->minactivityposinf = -1;
1238 consdata->maxactivityneginf = -1;
1239 consdata->maxactivityposinf = -1;
1240 consdata->minactivityneghuge = -1;
1241 consdata->minactivityposhuge = -1;
1242 consdata->maxactivityneghuge = -1;
1243 consdata->maxactivityposhuge = -1;
1248 consdata->glbminactivityneginf = -1;
1249 consdata->glbminactivityposinf = -1;
1250 consdata->glbmaxactivityneginf = -1;
1251 consdata->glbmaxactivityposinf = -1;
1252 consdata->glbminactivityneghuge = -1;
1253 consdata->glbminactivityposhuge = -1;
1254 consdata->glbmaxactivityneghuge = -1;
1255 consdata->glbmaxactivityposhuge = -1;
1268 SCIP_Real pseudoactivity;
1276 for(
i = consdata->nvars - 1;
i >= 0; --
i )
1278 val = consdata->vals[
i];
1297 pseudoactivity += val *
bound;
1308 return pseudoactivity;
1323 for(
i = consdata->nvars - 1;
i >= 0; --
i )
1332 consdata->validminact =
TRUE;
1335 consdata->lastminactivity =
QUAD_TO_DBL(consdata->minactivity);
1350 for(
i = consdata->nvars - 1;
i >= 0; --
i )
1359 consdata->validmaxact =
TRUE;
1362 consdata->lastmaxactivity =
QUAD_TO_DBL(consdata->maxactivity);
1377 for(
i = consdata->nvars - 1;
i >= 0; --
i )
1386 consdata->validglbminact =
TRUE;
1389 consdata->lastglbminactivity =
QUAD_TO_DBL(consdata->glbminactivity);
1404 for(
i = consdata->nvars - 1;
i >= 0; --
i )
1413 consdata->validglbmaxact =
TRUE;
1416 consdata->lastglbmaxactivity =
QUAD_TO_DBL(consdata->glbmaxactivity);
1429 assert(!consdata->validmaxabsval);
1432 consdata->validmaxabsval =
TRUE;
1433 consdata->maxabsval = 0.0;
1434 for(
i = 0;
i < consdata->nvars; ++
i )
1438 if(
absval > consdata->maxabsval )
1439 consdata->maxabsval =
absval;
1453 assert(!consdata->validminabsval);
1456 consdata->validminabsval =
TRUE;
1458 if( consdata->nvars > 0 )
1459 consdata->minabsval =
REALABS(consdata->vals[0]);
1461 consdata->minabsval = 0.0;
1463 for(
i = 1;
i < consdata->nvars; ++
i )
1468 consdata->minabsval =
absval;
1480 assert(!consdata->hasnonbinvalid);
1481 consdata->hasnonbinvar =
FALSE;
1482 consdata->hascontvar =
FALSE;
1484 for( v = consdata->nvars - 1; v >= 0; --v )
1490 consdata->hasnonbinvar =
TRUE;
1494 consdata->hascontvar =
TRUE;
1499 assert(consdata->hascontvar || v < 0);
1501 consdata->hasnonbinvalid =
TRUE;
1505#ifdef CHECKMAXACTDELTA
1515 SCIP_Real maxactdelta = 0.0;
1522 for( v = consdata->nvars - 1; v >= 0; --v )
1534 delta =
REALABS(consdata->vals[v]) * domain;
1536 if( delta > maxactdelta )
1538 maxactdelta = delta;
1545#define checkMaxActivityDelta(scip, consdata)
1558 consdata->maxactdelta = 0.0;
1560 if( !consdata->hasnonbinvalid )
1564 if( !consdata->hasnonbinvar )
1566 for( v = consdata->nvars - 1; v >= 0; --v )
1570 delta =
REALABS(consdata->vals[v]);
1572 if( delta > consdata->maxactdelta )
1574 consdata->maxactdelta = delta;
1575 consdata->maxactdeltavar = consdata->vars[v];
1582 for( v = consdata->nvars - 1; v >= 0; --v )
1594 consdata->maxactdeltavar = consdata->vars[v];
1599 delta =
REALABS(consdata->vals[v]) * domain;
1601 if( delta > consdata->maxactdelta )
1603 consdata->maxactdelta = delta;
1604 consdata->maxactdeltavar = consdata->vars[v];
1640 assert(consdata->validactivities);
1645 assert(consdata->minactivityneginf >= 0);
1646 assert(consdata->minactivityposinf >= 0);
1647 assert(consdata->maxactivityneginf >= 0);
1648 assert(consdata->maxactivityposinf >= 0);
1649 assert(consdata->minactivityneghuge >= 0);
1650 assert(consdata->minactivityposhuge >= 0);
1651 assert(consdata->maxactivityneghuge >= 0);
1652 assert(consdata->maxactivityposhuge >= 0);
1657 assert(consdata->glbminactivityneginf >= 0);
1658 assert(consdata->glbminactivityposinf >= 0);
1659 assert(consdata->glbmaxactivityneginf >= 0);
1660 assert(consdata->glbmaxactivityposinf >= 0);
1661 assert(consdata->glbminactivityneghuge >= 0);
1662 assert(consdata->glbminactivityposhuge >= 0);
1663 assert(consdata->glbmaxactivityneghuge >= 0);
1664 assert(consdata->glbmaxactivityposhuge >= 0);
1687 validact = consdata->validglbminact;
1697 validact = consdata->validglbmaxact;
1710 validact = consdata->validglbmaxact;
1720 validact = consdata->validglbminact;
1789 if( oldbound > 0.0 )
1797 (*activityposinf)--;
1801 (*activityneginf)++;
1806 (*activityposhuge)++;
1825 (*activityneginf)--;
1829 (*activityposinf)++;
1834 (*activityposhuge)++;
1854 (*activityposhuge)--;
1859 if( newbound > 0.0 )
1860 (*activityposinf)++;
1869 (*activityposhuge)++;
1887 (*activityneghuge)--;
1892 if( newbound > 0.0 )
1893 (*activityposinf)++;
1902 (*activityposhuge)++;
1920 if( newbound > 0.0 )
1922 (*activityposinf)++;
1932 (*activityneginf)++;
1941 (*activityposhuge)++;
1946 (*activityneghuge)++;
1979 SCIPdebugMsg(
scip,
"%s activity of linear constraint unreliable after update: %16.9g\n",
1986 consdata->validglbminact =
FALSE;
1988 consdata->validglbmaxact =
FALSE;
1993 consdata->validminact =
FALSE;
1995 consdata->validmaxact =
FALSE;
2018 if( consdata->validactivities )
2043 if( consdata->validactivities )
2066 if( consdata->validactivities )
2089 if( consdata->validactivities )
2113 if( consdata->validmaxabsval )
2120 consdata->maxabsval =
MAX(consdata->maxabsval,
absval);
2123 if( consdata->validminabsval )
2130 consdata->minabsval =
MIN(consdata->minabsval,
absval);
2134 if( consdata->validactivities )
2163 if( consdata->validmaxabsval )
2171 consdata->validmaxabsval =
FALSE;
2177 if( consdata->validminabsval )
2185 consdata->validminabsval =
FALSE;
2191 if( consdata->validactivities )
2227 if( consdata->validmaxabsval )
2235 consdata->maxabsval =
absval;
2244 consdata->validmaxabsval =
FALSE;
2251 if( consdata->validminabsval )
2259 consdata->minabsval =
absval;
2268 consdata->validminabsval =
FALSE;
2284 delta =
REALABS(newval) * domain;
2286 if( delta > consdata->maxactdelta )
2288 consdata->maxactdelta = delta;
2289 consdata->maxactdeltavar =
var;
2294 if( consdata->maxactdeltavar ==
var )
2312 if( !consdata->validmaxabsval )
2314 assert(consdata->validmaxabsval);
2317 return consdata->maxabsval;
2328 if( !consdata->validminabsval )
2330 assert(consdata->validminabsval);
2333 return consdata->minabsval;
2349 assert(!consdata->validactivities);
2355 consdata->validmaxabsval =
TRUE;
2356 consdata->validminabsval =
TRUE;
2357 consdata->validactivities =
TRUE;
2358 consdata->validminact =
TRUE;
2359 consdata->validmaxact =
TRUE;
2360 consdata->validglbminact =
TRUE;
2361 consdata->validglbmaxact =
TRUE;
2362 consdata->maxabsval = 0.0;
2363 consdata->minabsval = (consdata->nvars == 0 ? 0.0 :
REALABS(consdata->vals[0]));
2366 consdata->lastminactivity = 0.0;
2367 consdata->lastmaxactivity = 0.0;
2368 consdata->minactivityneginf = 0;
2369 consdata->minactivityposinf = 0;
2370 consdata->maxactivityneginf = 0;
2371 consdata->maxactivityposinf = 0;
2372 consdata->minactivityneghuge = 0;
2373 consdata->minactivityposhuge = 0;
2374 consdata->maxactivityneghuge = 0;
2375 consdata->maxactivityposhuge = 0;
2378 consdata->lastglbminactivity = 0.0;
2379 consdata->lastglbmaxactivity = 0.0;
2380 consdata->glbminactivityneginf = 0;
2381 consdata->glbminactivityposinf = 0;
2382 consdata->glbmaxactivityneginf = 0;
2383 consdata->glbmaxactivityposinf = 0;
2384 consdata->glbminactivityneghuge = 0;
2385 consdata->glbminactivityposhuge = 0;
2386 consdata->glbmaxactivityneghuge = 0;
2387 consdata->glbmaxactivityposhuge = 0;
2389 for(
i = 0;
i < consdata->nvars; ++
i )
2392 consdata->lastminactivity =
QUAD_TO_DBL(consdata->minactivity);
2393 consdata->lastmaxactivity =
QUAD_TO_DBL(consdata->maxactivity);
2394 consdata->lastglbminactivity =
QUAD_TO_DBL(consdata->glbminactivity);
2395 consdata->lastglbmaxactivity =
QUAD_TO_DBL(consdata->glbmaxactivity);
2413 SCIP_Real* minactivity,
2464 if( !consdata->validglbminact )
2466 assert(consdata->validglbminact);
2472 if( !consdata->validminact )
2474 assert(consdata->validminact);
2514 SCIP_Real* maxactivity,
2565 if( !consdata->validglbmaxact )
2567 assert(consdata->validglbmaxact);
2573 if( !consdata->validmaxact )
2575 assert(consdata->validmaxact);
2607 SCIP_Real* minactivity,
2608 SCIP_Real* maxactivity,
2627 if( !consdata->validactivities )
2630 assert(consdata->validminact);
2631 assert(consdata->validmaxact);
2635 assert(consdata->minactivityneginf >= 0);
2636 assert(consdata->minactivityposinf >= 0);
2637 assert(consdata->maxactivityneginf >= 0);
2638 assert(consdata->maxactivityposinf >= 0);
2640 getMinActivity(
scip, consdata, consdata->minactivityposinf, consdata->minactivityneginf,
2641 consdata->minactivityposhuge, consdata->minactivityneghuge, 0.0,
FALSE,
goodrelax,
2644 getMaxActivity(
scip, consdata, consdata->maxactivityposinf, consdata->maxactivityneginf,
2645 consdata->maxactivityposhuge, consdata->maxactivityneghuge, 0.0,
FALSE,
goodrelax,
2673 for( v = 0; v < consdata->nvars; ++v )
2675 var = consdata->vars[v];
2680 val = consdata->vals[v];
2766 if( !consdata->validactivities )
2769 assert(consdata->validminact);
2770 assert(consdata->validmaxact);
2774 assert(consdata->minactivityneginf >= 0);
2775 assert(consdata->minactivityposinf >= 0);
2776 assert(consdata->maxactivityneginf >= 0);
2777 assert(consdata->maxactivityposinf >= 0);
2778 assert(consdata->minactivityneghuge >= 0);
2779 assert(consdata->minactivityposhuge >= 0);
2780 assert(consdata->maxactivityneghuge >= 0);
2781 assert(consdata->maxactivityposhuge >= 0);
2801 assert(consdata->minactivityposinf >= 1);
2803 getMinActivity(
scip, consdata, consdata->minactivityposinf - 1, consdata->minactivityneginf,
2804 consdata->minactivityposhuge, consdata->minactivityneghuge, 0.0,
FALSE,
goodrelax,
2809 assert(consdata->minactivityneginf >= 1);
2811 getMinActivity(
scip, consdata, consdata->minactivityposinf, consdata->minactivityneginf - 1,
2812 consdata->minactivityposhuge, consdata->minactivityneghuge, 0.0,
FALSE,
goodrelax,
2817 assert(consdata->minactivityposhuge >= 1);
2819 getMinActivity(
scip, consdata, consdata->minactivityposinf, consdata->minactivityneginf,
2820 consdata->minactivityposhuge - 1, consdata->minactivityneghuge, 0.0,
FALSE,
goodrelax,
2825 assert(consdata->minactivityneghuge >= 1);
2827 getMinActivity(
scip, consdata, consdata->minactivityposinf, consdata->minactivityneginf,
2828 consdata->minactivityposhuge, consdata->minactivityneghuge - 1, 0.0,
FALSE,
goodrelax,
2833 getMinActivity(
scip, consdata, consdata->minactivityposinf, consdata->minactivityneginf,
2843 assert(consdata->maxactivityneginf >= 1);
2845 getMaxActivity(
scip, consdata, consdata->maxactivityposinf, consdata->maxactivityneginf - 1,
2846 consdata->maxactivityposhuge, consdata->maxactivityneghuge, 0.0,
FALSE,
goodrelax,
2851 assert(consdata->maxactivityposinf >= 1);
2853 getMaxActivity(
scip, consdata, consdata->maxactivityposinf - 1, consdata->maxactivityneginf,
2854 consdata->maxactivityposhuge, consdata->maxactivityneghuge, 0.0,
FALSE,
goodrelax,
2859 assert(consdata->maxactivityposhuge >= 1);
2861 getMaxActivity(
scip, consdata, consdata->maxactivityposinf, consdata->maxactivityneginf,
2862 consdata->maxactivityposhuge - 1, consdata->maxactivityneghuge, 0.0,
FALSE,
goodrelax,
2867 assert(consdata->maxactivityneghuge >= 1);
2869 getMaxActivity(
scip, consdata, consdata->maxactivityposinf, consdata->maxactivityneginf,
2870 consdata->maxactivityposhuge, consdata->maxactivityneghuge - 1, 0.0,
FALSE,
goodrelax,
2875 getMaxActivity(
scip, consdata, consdata->maxactivityposinf, consdata->maxactivityneginf,
2905 if( !consdata->validactivities )
2908 assert(consdata->validglbminact);
2909 assert(consdata->validglbmaxact);
2913 assert(consdata->glbminactivityneginf >= 0);
2914 assert(consdata->glbminactivityposinf >= 0);
2915 assert(consdata->glbmaxactivityneginf >= 0);
2916 assert(consdata->glbmaxactivityposinf >= 0);
2917 assert(consdata->glbminactivityneghuge >= 0);
2918 assert(consdata->glbminactivityposhuge >= 0);
2919 assert(consdata->glbmaxactivityneghuge >= 0);
2920 assert(consdata->glbmaxactivityposhuge >= 0);
2927 getMinActivity(
scip, consdata, consdata->glbminactivityposinf, consdata->glbminactivityneginf,
2928 consdata->glbminactivityposhuge, consdata->glbminactivityneghuge, 0.0,
TRUE,
goodrelax,
2937 getMaxActivity(
scip, consdata, consdata->glbmaxactivityposinf, consdata->glbmaxactivityneginf,
2938 consdata->glbmaxactivityposhuge, consdata->glbmaxactivityneghuge, 0.0,
TRUE,
goodrelax,
2975 if( !consdata->validactivities )
2980 assert(consdata->glbminactivityneginf >= 0);
2981 assert(consdata->glbminactivityposinf >= 0);
2982 assert(consdata->glbmaxactivityneginf >= 0);
2983 assert(consdata->glbmaxactivityposinf >= 0);
3008 assert(consdata->glbminactivityposinf >= 1);
3010 getMinActivity(
scip, consdata, consdata->glbminactivityposinf - 1, consdata->glbminactivityneginf,
3011 consdata->glbminactivityposhuge, consdata->glbminactivityneghuge, 0.0,
TRUE,
goodrelax,
3016 assert(consdata->glbminactivityneginf >= 1);
3018 getMinActivity(
scip, consdata, consdata->glbminactivityposinf, consdata->glbminactivityneginf - 1,
3019 consdata->glbminactivityposhuge, consdata->glbminactivityneghuge, 0.0,
TRUE,
goodrelax,
3024 assert(consdata->glbminactivityposhuge >= 1);
3026 getMinActivity(
scip, consdata, consdata->glbminactivityposinf, consdata->glbminactivityneginf,
3027 consdata->glbminactivityposhuge - 1, consdata->glbminactivityneghuge, 0.0,
TRUE,
goodrelax,
3032 assert(consdata->glbminactivityneghuge >= 1);
3034 getMinActivity(
scip, consdata, consdata->glbminactivityposinf, consdata->glbminactivityneginf,
3035 consdata->glbminactivityposhuge, consdata->glbminactivityneghuge - 1, 0.0,
TRUE,
goodrelax,
3040 getMinActivity(
scip, consdata, consdata->glbminactivityposinf, consdata->glbminactivityneginf,
3056 assert(consdata->glbmaxactivityneginf >= 1);
3058 getMaxActivity(
scip, consdata, consdata->glbmaxactivityposinf, consdata->glbmaxactivityneginf - 1,
3059 consdata->glbmaxactivityposhuge, consdata->glbmaxactivityneghuge, 0.0,
TRUE,
goodrelax,
3064 assert(consdata->glbmaxactivityposinf >= 1);
3066 getMaxActivity(
scip, consdata, consdata->glbmaxactivityposinf - 1, consdata->glbmaxactivityneginf,
3067 consdata->glbmaxactivityposhuge, consdata->glbmaxactivityneghuge, 0.0,
TRUE,
goodrelax,
3072 assert(consdata->glbmaxactivityposhuge >= 1);
3074 getMaxActivity(
scip, consdata, consdata->glbmaxactivityposinf, consdata->glbmaxactivityneginf,
3075 consdata->glbmaxactivityposhuge - 1, consdata->glbmaxactivityneghuge, 0.0,
TRUE,
goodrelax,
3080 assert(consdata->glbmaxactivityneghuge >= 1);
3082 getMaxActivity(
scip, consdata, consdata->glbmaxactivityposinf, consdata->glbmaxactivityneginf,
3083 consdata->glbmaxactivityposhuge, consdata->glbmaxactivityneghuge - 1, 0.0,
TRUE,
goodrelax,
3088 getMaxActivity(
scip, consdata, consdata->glbmaxactivityposinf, consdata->glbmaxactivityneginf,
3122 for( v = 0; v < consdata->nvars; ++v )
3126 if( consdata->vals[v] < 0 )
3136 activity += consdata->vals[v] * solval;
3140 SCIPdebugMsg(
scip,
"activity of linear constraint: %.15g, %d positive infinity values, %d negative infinity values \n", activity,
nposinf,
nneginf);
3144 activity = (consdata->rhs + consdata->lhs) / 2;
3150 SCIPdebugMsg(
scip,
"corrected activity of linear constraint: %.15g\n", activity);
3155 else if( activity < 0 )
3181 return MIN(consdata->rhs - activity, activity - consdata->lhs);
3197 assert(consdata->validsignature);
3202 val = consdata->vals[pos];
3203 if( (val > 0.0 && ub > 0.0) || (val < 0.0 && lb < 0.0) )
3217 if( !consdata->validsignature )
3221 consdata->validsignature =
TRUE;
3222 consdata->possignature = 0;
3223 consdata->negsignature = 0;
3224 for(
i = 0;
i < consdata->nvars; ++
i )
3358 for( v = 0; v <
nvars; ++v )
3362 varv = consdata->vars[v];
3363 valv = consdata->vals[v];
3364 if( consdata->eventdata !=
NULL )
3371 consdata->vars[
i] = consdata->vars[perm[
i]];
3372 consdata->vals[
i] = consdata->vals[perm[
i]];
3373 if( consdata->eventdata !=
NULL )
3375 consdata->eventdata[
i] = consdata->eventdata[perm[
i]];
3376 consdata->eventdata[
i]->varpos =
i;
3382 while( perm[
i] != v );
3383 consdata->vars[
i] =
varv;
3384 consdata->vals[
i] =
valv;
3385 if( consdata->eventdata !=
NULL )
3388 consdata->eventdata[
i]->varpos =
i;
3395 for( v = 0; v <
nvars; ++v )
3398 assert(consdata->eventdata ==
NULL || consdata->eventdata[v]->varpos == v);
3425 if( consdata->nvars <= 1 )
3427 consdata->indexsorted =
TRUE;
3428 consdata->coefsorted =
TRUE;
3429 consdata->nbinvars = (consdata->nvars == 1 ? (int)
SCIPvarIsBinary(consdata->vars[0]) : 0);
3453 consdata->indexsorted =
FALSE;
3454 consdata->coefsorted =
TRUE;
3457 consdata->nbinvars = 0;
3458 for( v = 0; v < consdata->nvars; ++v )
3461 ++consdata->nbinvars;
3468 consdata->indexsorted =
TRUE;
3469 consdata->coefsorted =
FALSE;
3503 assert(consdata->nvars == 0 || (consdata->vars !=
NULL && consdata->vals !=
NULL));
3513 consdata->rhs = lhs;
3531 vars = consdata->vars;
3532 vals = consdata->vals;
3534 for( v = 0; v < consdata->nvars; ++v )
3556 vars = consdata->vars;
3557 vals = consdata->vals;
3559 for( v = 0; v < consdata->nvars; ++v )
3579 consdata->boundstightened = 0;
3580 consdata->presolved =
FALSE;
3581 consdata->cliquesadded =
FALSE;
3582 consdata->implsadded =
FALSE;
3592 consdata->lhs = lhs;
3593 consdata->changed =
TRUE;
3594 consdata->normalized =
FALSE;
3595 consdata->upgradetried =
FALSE;
3596 consdata->rangedrowpropagated = 0;
3599 if( consdata->row !=
NULL )
3629 assert(consdata->nvars == 0 || (consdata->vars !=
NULL && consdata->vals !=
NULL));
3639 consdata->lhs = rhs;
3659 vars = consdata->vars;
3660 vals = consdata->vals;
3662 for( v = 0; v < consdata->nvars; ++v )
3684 vars = consdata->vars;
3685 vals = consdata->vals;
3687 for( v = 0; v < consdata->nvars; ++v )
3707 consdata->boundstightened = 0;
3708 consdata->presolved =
FALSE;
3709 consdata->cliquesadded =
FALSE;
3710 consdata->implsadded =
FALSE;
3720 consdata->rhs = rhs;
3721 consdata->changed =
TRUE;
3722 consdata->normalized =
FALSE;
3723 consdata->upgradetried =
FALSE;
3724 consdata->rangedrowpropagated = 0;
3727 if( consdata->row !=
NULL )
3745 SCIP_Bool transformed;
3773 consdata->vars[consdata->nvars] =
var;
3774 consdata->vals[consdata->nvars] = val;
3783 if( consdata->eventdata !=
NULL )
3795 consdata->eventdata[consdata->nvars-1] =
NULL;
3816 consdata->maxactdeltavar =
var;
3820 SCIP_Real domain = ub - lb;
3821 SCIP_Real delta =
REALABS(val) * domain;
3823 if( delta > consdata->maxactdelta )
3825 consdata->maxactdelta = delta;
3826 consdata->maxactdeltavar =
var;
3841 consdata->boundstightened = 0;
3842 consdata->presolved =
FALSE;
3845 if( consdata->validsignature )
3848 consdata->changed =
TRUE;
3849 consdata->normalized =
FALSE;
3850 consdata->upgradetried =
FALSE;
3851 consdata->cliquesadded =
FALSE;
3852 consdata->implsadded =
FALSE;
3853 consdata->rangedrowpropagated = 0;
3855 if( consdata->nvars == 1 )
3857 consdata->indexsorted =
TRUE;
3858 consdata->coefsorted =
TRUE;
3859 consdata->merged =
TRUE;
3863 consdata->merged =
FALSE;
3867 consdata->indexsorted = consdata->indexsorted && (
consdataCompVar((
void*)consdata, consdata->nvars-2, consdata->nvars-1) <= 0);
3868 consdata->coefsorted =
FALSE;
3872 consdata->indexsorted =
FALSE;
3873 consdata->coefsorted = consdata->coefsorted && (
consdataCompVarProp((
void*)consdata, consdata->nvars-2, consdata->nvars-1) <= 0);
3878 if( consdata->hasnonbinvalid && !consdata->hascontvar )
3884 consdata->hasnonbinvar =
TRUE;
3887 consdata->hascontvar =
TRUE;
3892 if( consdata->row !=
NULL )
3919 var = consdata->vars[pos];
3920 val = consdata->vals[pos];
3939 if( consdata->eventdata !=
NULL )
3947 if( pos != consdata->nvars - 1 )
3949 consdata->vars[pos] = consdata->vars[consdata->nvars-1];
3950 consdata->vals[pos] = consdata->vals[consdata->nvars-1];
3952 if( consdata->eventdata !=
NULL )
3954 consdata->eventdata[pos] = consdata->eventdata[consdata->nvars-1];
3956 consdata->eventdata[pos]->varpos = pos;
3959 consdata->indexsorted = consdata->indexsorted && (pos + 2 >= consdata->nvars);
3960 consdata->coefsorted = consdata->coefsorted && (pos + 2 >= consdata->nvars);
3967 if( consdata->nvars <= 1 )
3979 if( consdata->maxactdeltavar ==
var )
3982 consdata->maxactdeltavar =
NULL;
3993 consdata->boundstightened = 0;
3994 consdata->presolved =
FALSE;
3995 consdata->validsignature =
FALSE;
3996 consdata->changed =
TRUE;
3997 consdata->normalized =
FALSE;
3998 consdata->upgradetried =
FALSE;
3999 consdata->cliquesadded =
FALSE;
4000 consdata->implsadded =
FALSE;
4001 consdata->rangedrowpropagated = 0;
4006 consdata->hasnonbinvalid =
FALSE;
4010 if( consdata->row !=
NULL )
4045 var = consdata->vars[pos];
4046 val = consdata->vals[pos];
4055 if( locked && newval * val < 0.0 )
4067 consdata->vals[pos] = newval;
4069 if( consdata->coefsorted )
4087 consdata->boundstightened = 0;
4088 consdata->presolved =
FALSE;
4089 consdata->validsignature = consdata->validsignature && (newval * val > 0.0);
4090 consdata->changed =
TRUE;
4091 consdata->normalized =
FALSE;
4092 consdata->upgradetried =
FALSE;
4093 consdata->cliquesadded =
FALSE;
4094 consdata->implsadded =
FALSE;
4095 consdata->rangedrowpropagated = 0;
4124 SCIPwarningMessage(
scip,
"skipped scaling for linear constraint <%s> to avoid numerical troubles (scalar: %.15g)\n",
4131 for(
i = consdata->nvars - 1;
i >= 0; --
i )
4133 newval = scalar * consdata->vals[
i];
4143 SCIPwarningMessage(
scip,
"coefficient %.15g of variable <%s> in linear constraint <%s> scaled to zero (scalar: %.15g)\n",
4148 consdata->vals[
i] = newval;
4156 lhs = consdata->lhs;
4157 consdata->lhs = -consdata->rhs;
4158 consdata->rhs = -lhs;
4171 consdata->lhs = newval;
4183 consdata->rhs = newval;
4187 consdata->cliquesadded =
FALSE;
4188 consdata->implsadded =
FALSE;
4213 for(
i = 0;
i < nconss;
i++ )
4218 if( consdata->varsdeleted )
4221 for( v = consdata->nvars - 1; v >= 0; --v )
4228 consdata->varsdeleted =
FALSE;
4257 SCIP_Bool* infeasible
4269 SCIP_Real maxabsval;
4270 SCIP_Real minabsval;
4283 *infeasible =
FALSE;
4294 if( consdata->normalized )
4298 vals = consdata->vals;
4299 nvars = consdata->nvars;
4304 consdata->normalized =
TRUE;
4324 scalar = 2.0 / (minabsval + maxabsval);
4329 SCIPdebugMsg(
scip,
"divide linear constraint with %g, because all coefficients are in absolute value the same\n", maxabsval);
4334 vals = consdata->vals;
4335 nvars = consdata->nvars;
4344 consdata->normalized =
TRUE;
4360 if( !consdata->hasnonbinvalid )
4367 if( !consdata->hascontvar )
4480 if( consdata->validmaxabsval )
4482 consdata->maxabsval *=
REALABS((SCIP_Real)
scm);
4485 consdata->validmaxabsval =
FALSE;
4491 if( consdata->validminabsval )
4493 consdata->minabsval *=
REALABS((SCIP_Real)
scm);
4496 consdata->validminabsval =
FALSE;
4503 vals = consdata->vals;
4504 nvars = consdata->nvars;
4544 if( consdata->validmaxabsval )
4546 consdata->maxabsval /=
REALABS((SCIP_Real)
gcd);
4548 if( consdata->validminabsval )
4550 consdata->minabsval /=
REALABS((SCIP_Real)
gcd);
4556 consdata->normalized =
TRUE;
4582 if( consdata->merged )
4592 v = consdata->nvars-1;
4595 var = consdata->vars[v];
4596 if( consdata->vars[v-1] ==
var )
4598 valsum = consdata->vals[v];
4603 valsum += consdata->vals[v];
4605 while( v >= 1 && consdata->vars[v-1] ==
var );
4616 if( consdata->maxactdeltavar ==
var )
4619 consdata->maxactdeltavar =
NULL;
4630 consdata->merged =
TRUE;
4640 SCIP_Bool* infeasible
4659 if( infeasible !=
NULL )
4660 *infeasible =
FALSE;
4665 if( consdata->eventdata ==
NULL )
4681 if( !consdata->removedfixings )
4700 var = consdata->vars[v];
4701 val = consdata->vals[v];
4728 if( infeasible !=
NULL )
4749 if( infeasible !=
NULL )
4802 for(
i = 0;
i < naggrvars; ++
i )
4867 consdata->removedfixings =
TRUE;
4880 assert(consdata->removedfixings);
4884 for( v = 0; v < consdata->nvars; ++v )
4919 vars = consdata->vars;
4920 vals = consdata->vals;
4921 nvars = consdata->nvars;
5097 vars = consdata->vars;
5098 nvars = consdata->nvars;
5106 for( v =
nvars - 1; v >= 0; --v )
5157 for( v =
nvars - 1; v >= 0; --v )
5219 vars = consdata->vars;
5220 nvars = consdata->nvars;
5222 vals = consdata->vals;
5275 SCIPerrorMessage(
"invalid inference information %d in linear constraint <%s> at position %d for %s bound of variable <%s>\n",
5324 + consdata->minactivityposinf
5325 + consdata->minactivityneghuge
5326 + consdata->minactivityposhuge;
5328 + consdata->maxactivityposinf
5329 + consdata->maxactivityneghuge
5330 + consdata->maxactivityposhuge;
5355 SCIP_Bool infeasible;
5356 SCIP_Bool tightened;
5363 var = consdata->vars[pos];
5373 SCIPdebugMsg(
scip,
"linear constraint <%s>: tighten <%s>, old bds=[%.15g,%.15g], val=%.15g, activity=[%.15g,%.15g], sides=[%.15g,%.15g] -> newub=%.15g\n",
5384 SCIPdebugMsg(
scip,
"linear constraint <%s>: cutoff <%s>, new bds=[%.15g,%.15g]\n",
5392 else if( tightened )
5395 SCIPdebugMsg(
scip,
"linear constraint <%s>: tighten <%s>, new bds=[%.15g,%.15g]\n",
5402 consdata->upgradetried =
FALSE;
5425 SCIP_Bool infeasible;
5426 SCIP_Bool tightened;
5433 var = consdata->vars[pos];
5443 SCIPdebugMsg(
scip,
"linear constraint <%s>: tighten <%s>, old bds=[%.15g,%.15g], val=%.15g, activity=[%.15g,%.15g], sides=[%.15g,%.15g] -> newlb=%.15g\n",
5454 SCIPdebugMsg(
scip,
"linear constraint <%s>: cutoff <%s>, new bds=[%.15g,%.15g]\n",
5462 else if( tightened )
5465 SCIPdebugMsg(
scip,
"linear constraint <%s>: tighten <%s>, new bds=[%.15g,%.15g]\n",
5472 consdata->upgradetried =
FALSE;
5512 var = consdata->vars[pos];
5519 val = consdata->vals[pos];
5520 lhs = consdata->lhs;
5521 rhs = consdata->rhs;
5531 if( !consdata->validactivities )
5533 assert(consdata->validactivities);
5534 if( !consdata->validminact )
5536 assert(consdata->validminact);
5547 assert(consdata->validminact);
5552 SCIPdebugMsg(
scip,
"linear constraint <%s>: cutoff <%s>, minactivity=%.15g > rhs=%.15g\n",
5567 alpha = val * (ub - lb);
5575 newub = lb + (slack / val);
5581 SCIPdebugMsg(
scip,
"linear constraint <%s>: cutoff <%s>, new bds=[%.15g,%.15g]\n",
5599 if( !consdata->validmaxact )
5603 assert(consdata->validmaxact);
5608 SCIPdebugMsg(
scip,
"linear constraint <%s>: cutoff <%s>, maxactivity=%.15g < lhs=%.15g\n",
5623 alpha = val * (ub - lb);
5631 newlb = ub - (slack / val);
5637 SCIPdebugMsg(
scip,
"linear constraint <%s>: cutoff <%s>, new bds=[%.15g,%.15g]\n",
5654 assert(consdata->validminact);
5659 SCIPdebugMsg(
scip,
"linear constraint <%s>: cutoff <%s>, minactivity=%.15g > rhs=%.15g\n",
5674 alpha = val * (lb - ub);
5682 newlb = ub + slack / val;
5688 SCIPdebugMsg(
scip,
"linear constraint <%s>: cutoff <%s>, new bds=[%.15g,%.15g]\n",
5705 if( !consdata->validmaxact )
5709 assert(consdata->validmaxact);
5714 SCIPdebugMsg(
scip,
"linear constraint <%s>: cutoff <%s>, maxactivity=%.15g < lhs=%.15g\n",
5729 alpha = val * (lb - ub);
5737 newub = lb - (slack / val);
5743 SCIPdebugMsg(
scip,
"linear constraint <%s>: cutoff <%s>, new bds=[%.15g,%.15g]\n",
5867 if( consdata->rangedrowpropagated == 2 )
5871 if( consdata->nvars < 3 )
5888 consdata->rangedrowpropagated = 2;
5895 if( consdata->rangedrowpropagated > 0 )
5898 consdata->rangedrowpropagated = 1;
5903 for( v = consdata->nvars - 1; v >= 0; --v )
5993 if( v == consdata->nvars )
6010 for( ; v < consdata->nvars; ++v )
6123 SCIPdebugMsg(
scip,
"minactinfvarsinvalid = %u, minactinfvars = %g, maxactinfvarsinvalid = %u, maxactinfvars = %g, gcd = %lld, ninfcheckvars = %d, ncontvars = %d\n",
6149 else if( ncontvars == 0 )
6207 assert(nsols < 2 || minvalue <= maxvalue);
6231 assert(maxvalue > minvalue);
6239 SCIPdebugMsg(
scip,
"here nsols %s %d, minsolvalue = %g, maxsolvalue = %g, ninfcheckvars = %d, nunfixedvars = %d\n",
6245 SCIPdebugMsg(
scip,
"gcdinfvars = %lld, gcd = %lld, correctedlhs = %g, correctedrhs = %g\n",
6257 else if( nsols == 1 )
6259 assert(minvalue == maxvalue);
6268 SCIPdebugMsg(
scip,
"fixing single variable <%s> with bounds [%.15g,%.15g] to %.15g\n",
6299 for( v = 0; v < consdata->nvars - 1; ++v )
6325 if( consdata->vals[v] < 0 )
6334 SCIPdebugMsg(
scip,
"fixing variable <%s> with bounds [%.15g,%.15g] to %.15g\n",
6347 consdata->vars[v],
bound) );
6363 assert(v == consdata->nvars - 1);
6366 if( consdata->vals[v] < 0 )
6375 SCIPdebugMsg(
scip,
"fixing variable <%s> with bounds [%.15g,%.15g] to %.15g\n",
6388 consdata->vars[v],
bound) );
6403 ++conshdlrdata->naddconss;
6408 maxvalue, maxvalue,
TRUE,
TRUE,
TRUE,
FALSE,
TRUE,
TRUE,
FALSE,
FALSE,
TRUE,
FALSE) );
6427 SCIP_Bool tightened;
6448 SCIPdebugMsg(
scip,
"tightening lower bound of variable <%s> from %g to %g\n",
6469 SCIPdebugMsg(
scip,
"tightening upper bound of variable <%s> from %g to %g\n",
6491 SCIP_Bool tightened;
6497 assert(minvalue < maxvalue);
6500 for( v = 0; v < consdata->nvars - 1; ++v )
6526 if( consdata->vals[v] < 0 )
6541 SCIPdebugMsg(
scip,
"tightening lower bound of variable <%s> from %g to %g\n",
6553 consdata->vars[v],
newlb) );
6563 SCIPdebugMsg(
scip,
"tightening upper bound of variable <%s> from %g to %g\n",
6575 consdata->vars[v],
newub) );
6592 assert(v == consdata->nvars - 1);
6595 if( consdata->vals[v] < 0 )
6610 SCIPdebugMsg(
scip,
"tightening lower bound of variable <%s> from %g to %g\n",
6631 SCIPdebugMsg(
scip,
"tightening upper bound of variable <%s> from %g to %g\n",
6660 assert(maxvalue > minvalue);
6676 ++conshdlrdata->naddconss;
6702 for( v = 0; v < consdata->nvars; ++v )
6714 if( consdata->vals[v] > 0.0 )
6715 maxact += consdata->vals[v];
6717 minact += consdata->vals[v];
6725 if( consdata->vals[v] > 0.0 )
6776 ++conshdlrdata->naddconss;
6818 SCIP_Bool infeasible;
6819 SCIP_Bool tightened;
6840 var = consdata->vars[pos];
6846 val = consdata->vals[pos];
6847 lhs = consdata->lhs;
6848 rhs = consdata->rhs;
6888 SCIPdebugMsg(
scip,
"linear constraint <%s>: tighten <%s>, old bds=[%.15g,%.15g], val=%.15g, resactivity=[%.15g,%.15g], sides=[%.15g,%.15g] -> newub=%.15g\n",
6891 &infeasible, &tightened) );
6894 SCIPdebugMsg(
scip,
"linear constraint <%s>: cutoff <%s>, new bds=[%.15g,%.15g]\n",
6909 SCIPdebugMsg(
scip,
"linear constraint <%s>: tighten <%s>, new bds=[%.15g,%.15g]\n",
6937 SCIPdebugMsg(
scip,
"linear constraint <%s>: tighten <%s>, old bds=[%.15g,%.15g], val=%.15g, resactivity=[%.15g,%.15g], sides=[%.15g,%.15g] -> newlb=%.15g\n",
6940 &infeasible, &tightened) );
6943 SCIPdebugMsg(
scip,
"linear constraint <%s>: cutoff <%s>, new bds=[%.15g,%.15g]\n",
6957 SCIPdebugMsg(
scip,
"linear constraint <%s>: tighten <%s>, new bds=[%.15g,%.15g]\n",
6990 SCIPdebugMsg(
scip,
"linear constraint <%s>: tighten <%s>, old bds=[%.15g,%.15g], val=%.15g, resactivity=[%.15g,%.15g], sides=[%.15g,%.15g] -> newlb=%.15g\n",
6993 &infeasible, &tightened) );
6996 SCIPdebugMsg(
scip,
"linear constraint <%s>: cutoff <%s>, new bds=[%.15g,%.15g]\n",
7010 SCIPdebugMsg(
scip,
"linear constraint <%s>: tighten <%s>, new bds=[%.15g,%.15g]\n",
7038 SCIPdebugMsg(
scip,
"linear constraint <%s>: tighten <%s>, old bds=[%.15g,%.15g], val=%.15g, resactivity=[%.15g,%.15g], sides=[%.15g,%.15g], newub=%.15g\n",
7041 &infeasible, &tightened) );
7044 SCIPdebugMsg(
scip,
"linear constraint <%s>: cutoff <%s>, new bds=[%.15g,%.15g]\n",
7058 SCIPdebugMsg(
scip,
"linear constraint <%s>: tighten <%s>, new bds=[%.15g,%.15g]\n",
7068#define MAXTIGHTENROUNDS 10
7075 SCIP_Real maxeasyactivitydelta,
7120 nvars = consdata->nvars;
7130 if( !force && (consdata->boundstightened >=
tightenmode) )
7137 assert(consdata->coefsorted);
7156 SCIP_Real minactivity;
7157 SCIP_Real maxactivity;
7197 assert(consdata->coefsorted);
7201 consdata->boundstightened = (
unsigned int)
tightenmode;
7228 v = consdata->nbinvars;
7241 if( force &&
SCIPisEQ(
scip, consdata->lhs, consdata->rhs) )
7255 SCIP_Bool checkrelmaxabs,
7279 if( consdata->row !=
NULL )
7291 SCIPdebugMsg(
scip,
" consdata activity=%.15g (lhs=%.15g, rhs=%.15g, row=%p, checklprows=%u, rowinlp=%u, sol=%p, hascurrentnodelp=%u)\n",
7292 activity, consdata->lhs, consdata->rhs, (
void*)consdata->row,
checklprows,
7297 lhsviol = consdata->lhs - activity;
7298 rhsviol = activity - consdata->rhs;
7302 if( (lhsviol > 0) && (lhsviol > rhsviol) )
7307 else if( rhsviol > 0 )
7332 if( !checkrelmaxabs )
7356 for( v = 0; v < consdata->nvars; ++v )
7358 if( consdata->vals !=
NULL )
7360 coef = consdata->vals[v];
7374 if( (consdata->lhs - activity) <= (1
e-15 *
maxabs) )
7376 SCIPdebugMsg(
scip,
" lhs violated due to random noise: violation=%16.9g, maxabs=%16.9g\n",
7377 consdata->lhs - activity,
maxabs);
7391 SCIPdebugMsg(
scip,
" lhs violated absolutely (violation=%16.9g), but feasible when using relative tolerance w.r.t. maximum absolute value (%16.9g)\n",
7392 consdata->lhs - activity,
maxabs);
7428 if( (activity - consdata->rhs) <= (1
e-15 *
maxabs) )
7430 SCIPdebugMsg(
scip,
" rhs violated due to random noise: violation=%16.9g, maxabs=%16.9g\n",
7431 activity - consdata->rhs,
maxabs);
7445 SCIPdebugMsg(
scip,
" rhs violated absolutely (violation=%16.9g), but feasible when using relative tolerance w.r.t. maximum absolute value (%16.9g)\n",
7446 activity - consdata->rhs,
maxabs);
7480 else if( consdata->checkabsolute &&
7548 if( consdata->row ==
NULL )
7565 if( consdata->nvars == 0 )
7613 if( consdata->nlrow ==
NULL )
7615 assert(consdata->lhs <= consdata->rhs);
7639 SCIP_Bool separateall,
7672 if( !separateall &&
sol ==
NULL )
7685 consdata->vals, +1.0, consdata->rhs,
sol,
cutoff, ncuts) );
7693 consdata->vals, -1.0, -consdata->lhs,
sol,
cutoff, ncuts) );
7703 consdata->vals, +1.0, consdata->rhs,
sol,
cutoff, ncuts) );
7708 consdata->vals, -1.0, -consdata->lhs,
sol,
cutoff, ncuts) );
7713 if( *ncuts > oldncuts )
7726 SCIP_Bool tightenbounds,
7727 SCIP_Bool rangedrowpropagation,
7728 SCIP_Real maxeasyactivitydelta,
7735 SCIP_Real minactivity;
7736 SCIP_Real maxactivity;
7752 if( consdata->eventdata ==
NULL )
7795 if( rangedrowpropagation && tightenbounds && !(*
cutoff) )
7815 if( nfixedvars > 0 )
7816 *nchgbds += 2*nfixedvars;
7827 SCIPdebugMsg(
scip,
"linear constraint <%s> is infeasible (rhs): activitybounds=[%.15g,%.15g], sides=[%.15g,%.15g]\n",
7828 SCIPconsGetName(cons), minactivity, maxactivity, consdata->lhs, consdata->rhs);
7838 SCIPdebugMsg(
scip,
"linear constraint <%s> is infeasible (lhs): activitybounds=[%.15g,%.15g], sides=[%.15g,%.15g]\n",
7839 SCIPconsGetName(cons), minactivity, maxactivity, consdata->lhs, consdata->rhs);
7849 SCIPdebugMsg(
scip,
"linear constraint <%s> is redundant: activitybounds=[%.15g,%.15g], sides=[%.15g,%.15g]\n",
7850 SCIPconsGetName(cons), minactivity, maxactivity, consdata->lhs, consdata->rhs);
7853 if( consdata->nvars > 0 )
7884 SCIP_Bool infeasible;
7895 for( v = 0; v < consdata->nvars; ++v )
7898 var = consdata->vars[v];
7910 SCIPdebugMsg(
scip,
"converting variable <%s> with fixed bounds [%.15g,%.15g] into fixed variable fixed at %.15g\n",
7934 assert(consdata->removedfixings);
7939#define MAX_CLIQUE_NONZEROS_PER_CONS 1000000
8009 SCIP_Real maxeasyactivitydelta,
8029 SCIP_Bool infeasible;
8048 if( consdata->nvars < 2 )
8057 if( !consdata->implsadded )
8075 nvars = consdata->nvars;
8076 vars = consdata->vars;
8077 vals = consdata->vals;
8080 if( !consdata->validactivities )
8082 assert(consdata->validactivities);
8086 finitenegminact = (consdata->glbminactivityneginf == 0 && consdata->glbminactivityneghuge == 0);
8087 finitenegmaxact = (consdata->glbmaxactivityneginf == 0 && consdata->maxactivityneghuge == 0);
8088 finiteposminact = (consdata->glbminactivityposinf == 0 && consdata->glbminactivityposhuge == 0);
8089 finiteposmaxact = (consdata->glbmaxactivityposinf == 0 && consdata->glbmaxactivityposhuge == 0);
8107 assert(consdata->validglbminact);
8113 assert(consdata->validglbmaxact);
8115 assert(consdata->validglbminact || consdata->validglbmaxact);
8120 for( v =
nvars - 1; v >= 0; --v )
8162 for( v =
nvars - 1; v >= 0; --v )
8174 *nchgbds += nbdchgs;
8181 *nchgbds += nbdchgs;
8203 for( v =
nvars - 1; v >= 0; --v )
8215 *nchgbds += nbdchgs;
8222 *nchgbds += nbdchgs;
8268 consdata->implsadded =
TRUE;
8272 if( consdata->cliquesadded )
8275 consdata->cliquesadded =
TRUE;
8282 nvars = consdata->nvars;
8283 vars = consdata->vars;
8284 vals = consdata->vals;
8289 if( !consdata->validactivities )
8291 assert(consdata->validactivities);
8295 finitenegminact = (consdata->glbminactivityneginf == 0 && consdata->glbminactivityneghuge == 0);
8296 finitenegmaxact = (consdata->glbmaxactivityneginf == 0 && consdata->maxactivityneghuge == 0);
8297 finiteposminact = (consdata->glbminactivityposinf == 0 && consdata->glbminactivityposhuge == 0);
8298 finiteposmaxact = (consdata->glbmaxactivityposinf == 0 && consdata->glbmaxactivityposhuge == 0);
8357 assert(consdata->validglbminact);
8363 assert(consdata->validglbmaxact);
8365 assert(consdata->validglbminact || consdata->validglbmaxact);
8377#ifdef SCIP_DISABLED_CODE
8400 *nchgbds += nbdchgs;
8433 *nchgbds += nbdchgs;
8475 if( !consdata->validactivities )
8477 assert(consdata->validactivities);
8479 nvars = consdata->nvars;
8480 vars = consdata->vars;
8481 vals = consdata->vals;
8550 *nchgbds += nbdchgs;
8586 *nchgbds += nbdchgs;
8628 if( !consdata->validactivities )
8630 assert(consdata->validactivities);
8632 nvars = consdata->nvars;
8633 vars = consdata->vars;
8634 vals = consdata->vals;
8710 *nchgbds += nbdchgs;
8746 *nchgbds += nbdchgs;
8790 if( !consdata->validactivities )
8792 assert(consdata->validactivities);
8794 nvars = consdata->nvars;
8795 vars = consdata->vars;
8796 vals = consdata->vals;
8868 *nchgbds += nbdchgs;
8901 *nchgbds += nbdchgs;
8955 SCIPdebugMsg(
scip,
"linear constraint <%s>: adding clique with %d vars (%d pos, %d neg)\n",
8967 *nchgbds += nbdchgs;
8980 SCIP_Bool* infeasible
8999 *infeasible =
FALSE;
9009 for(
i = 0;
i < consdata->nvars && integral; ++
i )
9030 SCIPdebugMsg(
scip,
"rounding sides=[%.15g,%.15g] of linear constraint <%s> with integral coefficients and variables only "
9031 "is infeasible\n", consdata->lhs, consdata->rhs,
SCIPconsGetName(cons));
9037 SCIPdebugMsg(
scip,
"linear constraint <%s>: make sides integral: sides=[%.15g,%.15g]\n",
9045 if( !consdata->upgraded )
9053 if( !consdata->upgraded )
9056 SCIPdebugMsg(
scip,
"linear constraint <%s>: new integral sides: sides=[%.15g,%.15g]\n",
9107 SCIP_Real minactivity;
9109 SCIP_Real maxactivity;
9139 if( (consdata->validmaxabsval && consdata->maxabsval >
MAXVALRECOMP)
9140 || (consdata->validminabsval && consdata->minabsval <
MINVALRECOMP) )
9157 var = consdata->vars[
i];
9162 val = consdata->vals[
i];
9178 lval = consdata->lhs - minactivity;
9179 rval = maxactivity - consdata->rhs;
9182 if( consdata->nvars == 2 )
9189 lval = consdata->lhs - val*lb;
9195 rval = val*ub - consdata->rhs;
9204 newlhs = consdata->lhs - val * lb;
9206 newrhs = consdata->rhs - val * ub;
9211 SCIPdebugMsg(
scip,
"linear constraint <%s>: change coefficient %+.15g<%s> to %+.15g<%s>, act=[%.15g,%.15g], side=[%.15g,%.15g]\n",
9213 minactivity, maxactivity, consdata->lhs, consdata->rhs);
9285 lval = minactivity - consdata->lhs;
9286 rval = consdata->rhs - maxactivity;
9289 if( consdata->nvars == 2 )
9296 lval = val*ub - consdata->lhs;
9302 rval = consdata->rhs - val*lb;
9311 newlhs = consdata->lhs - val * ub;
9313 newrhs = consdata->rhs - val * lb;
9318 SCIPdebugMsg(
scip,
"linear constraint <%s>: change coefficient %+.15g<%s> to %+.15g<%s>, act=[%.15g,%.15g], side=[%.15g,%.15g]\n",
9320 minactivity, maxactivity, consdata->lhs, consdata->rhs);
9434 var = consdata->vars[
i];
9441 val = consdata->vals[
i];
9451 SCIPdebugMsg(
scip,
"minactivity = %g\tval = %g\tlhs = %g\n", minactivity, val, consdata->lhs);
9452 SCIPdebugMsg(
scip,
"maxactivity = %g\tval = %g\trhs = %g\n", maxactivity, val, consdata->rhs);
9453 SCIPdebugMsg(
scip,
"linear constraint <%s>: remove variable <%s> with coefficient <%g> from constraint since it is redundant\n",
9479 SCIPdebugMsg(
scip,
"linear constraint <%s>: remove variable <%s> with coefficient <%g> from constraint since it is redundant\n",
9544 SCIP_Bool infeasible;
9555 assert(consdata->nvars == 1);
9559 var = consdata->vars[0];
9560 val = consdata->vals[0];
9580 if( !consdata->upgraded )
9597 SCIP_Bool infeasible;
9598 SCIP_Bool redundant;
9609 assert(consdata->nvars == 2);
9612 SCIPdebugMsg(
scip,
"linear constraint <%s>: aggregate %.15g<%s> + %.15g<%s> == %.15g\n",
9614 consdata->vals[1],
SCIPvarGetName(consdata->vars[1]), consdata->rhs);
9618 consdata->rhs, &infeasible, &redundant, &
aggregated) );
9637 if( !consdata->upgraded )
9717 SCIP_Real minabsval;
9718 SCIP_Real maxabsval;
9723 SCIP_Bool infeasible;
9749 assert(consdata->nvars > 2);
9759 lhs = consdata->lhs;
9760 rhs = consdata->rhs;
9762 if( consdata->nvars == 3 )
9769 else if( consdata->nvars == 4 )
9798 vars = consdata->vars;
9799 vals = consdata->vals;
9815 for( v = 0; v < consdata->nvars; ++v )
9845 if( maxabsval / minabsval > conshdlrdata->maxmultaggrquot )
9949 if( conshdlrdata->multaggrremove && !
removescons )
9989 for( v = 0; v < consdata->nvars; ++v )
10029 SCIPdebugMsg(
scip,
"do not perform multi-aggregation: infimum and supremum are both infinite\n");
10078 for( v = 0; v < consdata->nvars; ++v )
10083 SCIPdebugMsgPrint(
scip,
" %+.15g, bounds of <%s>: [%.15g,%.15g], nlocks=%d, maxnlocks=%d, removescons=%u\n",
10111 if( !consdata->upgraded )
10115 else if( ncontvars == 1 )
10129 SCIPdebugMsg(
scip,
"linear constraint <%s>: converting continuous variable <%s> to implicit integer variable\n",
10147 SCIP_Bool redundant;
10161#ifdef WITH_DEBUG_SOLUTION
10171 SCIPdebugMsg(
scip,
"linear constraint <%s>: aggregating continuous variable <%s> to newly created implicit integer variable <%s>, aggregation factor = %g\n",
10179 SCIPdebugMsg(
scip,
"infeasible aggregation of variable <%s> to implicit variable <%s>, domain is empty\n",
10201 consdata->boundstightened = 0;
10202 consdata->rangedrowpropagated = 0;
10203 consdata->presolved =
FALSE;
10223 SCIPdebugMsg(
scip,
"linear constraint <%s>: converting integer variable <%s> to implicit integer variable\n",
10257 vars = consdata->vars;
10258 nvars = consdata->nvars;
10262 for( v = 0; v <
nvars; ++v )
10286 val = consdata->vals[v];
10293 (*scale) = val / -
objval;
10305 (*scale) = val /
objval;
10328 SCIP_Bool applicable;
10341 nvars = consdata->nvars;
10350 (
nvars == nobjvars && (!conshdlrdata->detectcutoffbound || !conshdlrdata->detectlowerbound)) )
10363 vars = consdata->vars;
10368 SCIPdebugMsg(
scip,
"linear equality constraint <%s> == %g (offset %g) is a subset of the objective function\n",
10376 for( v = 0; v <
nvars; ++v )
10396 SCIP_Real cutoffbound;
10445 SCIP_Bool applicable;
10460 nvars = consdata->nvars;
10475 if( nobjvars == 0 )
10490 if( conshdlrdata->detectcutoffbound &&
rhsfinite )
10496 SCIPdebugMsg(
scip,
"constraint <%s> is parallel to objective function and provides a cutoff bound <%g>\n",
10502 if( conshdlrdata->detectlowerbound &&
lhsfinite )
10504 SCIP_Real lowerbound;
10506 lowerbound = (consdata->lhs -
offset) / scale;
10508 SCIPdebugMsg(
scip,
"constraint <%s> is parallel to objective function and provides a lower bound <%g>\n",
10514 if( (conshdlrdata->detectcutoffbound && (conshdlrdata->detectlowerbound || !
lhsfinite)) ||
10515 (conshdlrdata->detectlowerbound && !
rhsfinite) )
10524 if( conshdlrdata->detectlowerbound &&
rhsfinite )
10526 SCIP_Real lowerbound;
10528 lowerbound = (consdata->rhs -
offset) / scale;
10530 SCIPdebugMsg(
scip,
"constraint <%s> is parallel to objective function and provides a lower bound <%g>\n",
10536 if( conshdlrdata->detectcutoffbound &&
lhsfinite )
10542 SCIPdebugMsg(
scip,
"constraint <%s> is parallel to objective function and provides a cutoff bound <%g>\n",
10548 if( (conshdlrdata->detectcutoffbound && (conshdlrdata->detectlowerbound || !
rhsfinite)) ||
10549 (conshdlrdata->detectlowerbound && !
lhsfinite) )
10585 assert(consdata->removedfixings);
10592 if( consdata->nvars == 1 )
10597 else if( consdata->nvars == 2 )
10631 for( v = 0; v < consdata->nvars; ++v )
10704 SCIP_Real minabsval;
10705 SCIP_Real maxabsval;
10748 if( consdata->nvars <= 2 )
10750 else if( consdata->nvars == 3 )
10752 else if( consdata->nvars == 4 )
10775 val = consdata->vals[
i];
10779 if(
absval < minabsval )
10781 if(
absval > maxabsval )
10785 if( maxabsval / minabsval > conshdlrdata->maxdualmultaggrquot )
10788 var = consdata->vars[
i];
10804 val = consdata->vals[
i];
10989 SCIP_Bool infeasible;
11020 for(
j = 0;
j < consdata->nvars; ++
j )
11035 SCIPdebugMsg(
scip,
"do not perform multi-aggregation: too large aggregation coefficients\n");
11098 infeasible =
FALSE;
11132 SCIPdebugMsg(
scip,
"do not perform multi-aggregation: infimum and supremum are both infinite\n");
11151 if( !consdata->upgraded )
11166#define CONTWEIGHT 8
11234 SCIP_Bool infeasible;
11237 SCIP_Bool redundant;
11245 lhs = consdata->lhs;
11246 vars = consdata->vars;
11247 vals = consdata->vals;
11248 nvars = consdata->nvars;
11288 SCIPdebugMsg(
scip,
"linear constraint <%s>: try fixing variable <%s> to <%g>\n",
11317 SCIPdebugMsg(
scip,
"linear constraint <%s>: try aggregation of variables <%s> and <%s>\n",
11405 return (value > 0 ? +1 : (value < 0 ? -1 : 0));
11442 nvars = consdata->nvars;
11448 lhs = consdata->lhs;
11449 rhs = consdata->rhs;
11458 vals = consdata->vals;
11459 vars = consdata->vars;
11467 for( v =
nvars - 1; v >= 0; --v )
11491 for( v =
nvars - 1; v >= 0; --v )
11495 (*nchgcoefs) +=
nvars;
11531 SCIP_Bool* infeasible
11578 *infeasible =
FALSE;
11590 nvars = consdata->nvars;
11614 consdata->normalized =
FALSE;
11623 if( !consdata->normalized )
11626 lhs = consdata->lhs;
11627 rhs = consdata->rhs;
11645 if( haslhs && hasrhs )
11651 assert(haslhs != hasrhs);
11667 consdata->indexsorted =
FALSE;
11668 consdata->coefsorted =
FALSE;
11670 vars = consdata->vars;
11671 vals = consdata->vals;
11708 side = haslhs ? lhs : rhs;
11779 for(
w = 0;
w < v; ++
w )
11804 SCIP_Bool redundant =
FALSE;
11836 for( ; v <
nvars - 1; ++v )
11915 SCIPdebugMsg(
scip,
"stopped at pos %d (of %d), subactivities [%g, %g], redundant = %u, hasrhs = %u, siderest = %g, gcd = %" SCIP_LONGINT_FORMAT ", offset position for 'side' coefficients = %d\n",
11979 SCIPdebugMsg(
scip,
"removing %d last variables from constraint <%s>, because they never change anything on the feasibility of this constraint\n",
11987 (*nchgcoefs) += (
nvars - v);
11996 assert(vals == consdata->vals);
12011 rhs = consdata->rhs;
12018 lhs = consdata->lhs;
12029 nvars = consdata->nvars;
12219 (*nchgcoefs) += (
offsetv + 1);
12227 assert(vals == consdata->vals);
12233 nvars = consdata->nvars;
12238 lhs = consdata->lhs;
12239 rhs = consdata->rhs;
12255 for( v =
nvars - 1; v >= 0; --v )
12272 SCIP_Real
frac = 0.0;
12273 SCIP_Bool found =
FALSE;
12288 for( v =
nvars - 1; v >= 0; --v )
12324 SCIPdebugMsg(
scip,
"rounding all non-integral coefficients and the right hand side down\n");
12329 for( v =
nvars - 1; v >= 0; --v )
12381 for( v =
nvars - 1; v >= 0; --v )
12429 SCIPdebugMsg(
scip,
"rounding all non-integral coefficients and the left hand side down\n");
12434 for( v =
nvars - 1; v >= 0; --v )
12473 assert(vals == consdata->vals);
12478 rhs = consdata->rhs;
12479 lhs = consdata->lhs;
12486 nvars = consdata->nvars;
12493 for( v =
nvars - 1; v >= 0; --v )
12536 for( v =
nvars - 1; v >= 0; --v )
12719 SCIPdebugMsg(
scip,
"gcd = %" SCIP_LONGINT_FORMAT ", rest = %" SCIP_LONGINT_FORMAT ", restcoef = %" SCIP_LONGINT_FORMAT "; changing coef of variable <%s> to %g and %s by %" SCIP_LONGINT_FORMAT "\n",
gcd,
rest,
restcoef,
SCIPvarGetName(
vars[
candpos]),
newcoef, hasrhs ?
"reduced rhs" :
"increased lhs", hasrhs ?
rest : (
rest > 0 ?
gcd -
rest : 0));
12736 assert(vals == consdata->vals);
12743 rhs = consdata->rhs;
12744 lhs = consdata->lhs;
12748 nvars = consdata->nvars;
12752 while(
nvars >= 2 );
12778 SCIP_Real maxaggrnormscale,
12781 SCIP_Bool* infeasible
12816 *infeasible =
FALSE;
12952 SCIPdebugMsg(
scip,
"aggregate linear constraints <%s> := %.15g*<%s> + %.15g*<%s> -> nvars: %d -> %d, weight: %d -> %d\n",
13174 assert(consdata->nvars > 0);
13176 assert(consdata->indexsorted);
13181 scale =
COPYSIGN(1.0/consdata->maxabsval, consdata->vals[0]);
13204 return (((
unsigned int)consdata->upgraded)<<31) + (
unsigned int)
SCIPconsGetPos(cons);
13299 hashtablesize = nconss;
13306 for(
c = 0;
c < nconss; ++
c )
13397 SCIPdebugMsg(
scip,
"aggregate linear constraints <%s> and <%s> with equal coefficients into single ranged row\n",
13411 SCIPdebugMsg(
scip,
"aggregate linear constraints <%s> and <%s> with negated coefficients into single ranged row\n",
13443 rhs = (lhs + rhs)/2;
13458#ifdef SCIP_MORE_DEBUG
13480 SCIP_Real maxaggrnormscale,
13788 SCIPdebugMsg(
scip,
"aggregate linear constraints <%s> and <%s> with %s coefficients into single ranged row\n",
13866 SCIPdebugMsg(
scip,
"left hand side of linear constraint <%s> is dominated by <%s>:\n",
13897 SCIPdebugMsg(
scip,
"left hand side of linear constraint <%s> is dominated by <%s>:\n",
13927 SCIPdebugMsg(
scip,
"right hand side of linear constraint <%s> is dominated by <%s>:\n",
13958 SCIPdebugMsg(
scip,
"right hand side of linear constraint <%s> is dominated by <%s>:\n",
14082 SCIP_Bool singletonstuffing,
14083 SCIP_Bool singlevarstuffing,
14099 SCIP_Real minactivity;
14100 SCIP_Real maxactivity;
14127 if( singlevarstuffing )
14145 rhs = -consdata->lhs;
14147 maxactivity = -minactivity;
14153 rhs = consdata->rhs;
14157 nvars = consdata->nvars;
14158 vars = consdata->vars;
14159 vals = consdata->vals;
14162 if( singletonstuffing )
14164 for( v = 0; v <
nvars; ++v )
14180 assert(singletonstuffing);
14191 for( v = 0; v <
nvars; ++v )
14302 SCIP_Bool tightened;
14315 val =
factor * vals[idx];
14335 delta = -(lb - ub) * val;
14337 delta = (ub - lb) * val;
14447 for( v = 0; v <
nvars; ++v )
14530 SCIP_Bool tightened =
FALSE;
14625 for( v = 0; v <
nvars; ++v )
14635 for( v = 0; v <
nvars; ++v )
14640 if(
factor * vals[v] < 0 )
14743 for( v = 0; v <
nvars; ++v )
14755 for( v = 0; v < ncontvars; v++ )
14782 for(
c = 0;
c < nconss; ++
c )
14809 for(
i = 0;
i < consdata->nvars; ++
i )
14813 var = consdata->vars[
i];
14835 for(
i = 0;
i < consdata->nvars; ++
i )
14849 var = consdata->vars[
i];
14850 val = consdata->vals[
i];
15014 for( v = 0; v <
nvars; ++v )
15018 SCIP_Bool infeasible;
15019 SCIP_Bool tightened;
15044 SCIPdebugMsg(
scip,
"variable <%s> only locked down in linear constraints: dual presolve <%s>[%.15g,%.15g] <= %.15g\n",
15073 SCIPdebugMsg(
scip,
"variable <%s> only locked up in linear constraints: dual presolve <%s>[%.15g,%.15g] >= %.15g\n",
15091 SCIP_Bool infeasible;
15117 SCIPdebugMsg(
scip,
"dual presolve: converting continuous variable <%s>[%g,%g] to implicit integer\n",
15148 SCIP_Bool checkrelmaxabs;
15149 SCIP_Bool violated;
15161 checkrelmaxabs = conshdlrdata->checkrelmaxabs;
15163 SCIPdebugMsg(
scip,
"Enforcement method of linear constraints for %s solution\n",
sol ==
NULL ?
"LP" :
"relaxation");
15220 SCIP_Real constant = 0.0;
15244 vars[
i] = consdata->vars[
i];
15245 vals[
i] = consdata->vals[
i];
15249 lhs = consdata->lhs - constant;
15250 rhs = consdata->rhs - constant;
15333 conshdlrdata->naddconss = 0;
15336 for(
c = 0;
c < nconss; ++
c )
15361 for(
c = nconss - 1;
c >= 0; --
c )
15368 if( consdata->eventdata !=
NULL )
15442 for(
c = 0;
c < nconss;
c++ )
15461 rhs = consdata->rhs;
15462 lhs = consdata->lhs;
15466 for(
i = 0;
i < consdata->nvars;
i++ )
15472 if( consdata->nvars == 0 )
15492 if( consdata->nvars == 1 )
15502 if( consdata->nvars == 2 &&
SCIPisEQ(
scip, lhs, rhs) )
15512 if( consdata->nvars == 2 )
15517 if(
SCIPisEQ(
scip, consdata->vals[0], -consdata->vals[1])
15545 scale =
REALABS(consdata->vals[0]);
15555 if( consdata->vals[
i] < 0.0 )
15647 b -= consdata->vals[
i];
15667 for(
i = 0;
i < consdata->nvars && !
matched;
i++ )
15755#ifdef SCIP_STATISTIC
15766#ifdef SCIP_STATISTIC
15774 for(
c = 0;
c < nconss; ++
c )
15784 if( consdata->upgraded )
15791 if(
SCIPisLT(
scip, consdata->maxactdelta, conshdlrdata->maxeasyactivitydelta) )
15800 for(
c = 0;
c < nconss; ++
c )
15810 if( consdata->upgraded )
15835 for(
c = 0;
c < nconss; ++
c )
15853 for(
c = 0;
c < nconss; ++
c )
15860 if( consdata->row !=
NULL )
15865 if( consdata->nlrow !=
NULL )
15881 if( ncutsadded > 0 )
15884 "(restart) converted %d cuts from the global cut pool into linear constraints\n", ncutsadded);
15935 if( consdata->eventdata !=
NULL )
15963 if( (*consdata)->eventdata !=
NULL )
16010 for(n =
targetdata->nvars - 1; n >= 0; --n )
16035 *infeasible =
FALSE;
16037 for(
c = 0;
c < nconss && !(*infeasible); ++
c )
16054 SCIP_Real cutoffbound;
16079 if( (
depth == 0 && conshdlrdata->maxroundsroot >= 0 &&
nrounds >= conshdlrdata->maxroundsroot)
16080 || (
depth > 0 && conshdlrdata->maxrounds >= 0 &&
nrounds >= conshdlrdata->maxrounds) )
16084 maxsepacuts = (
depth == 0 ? conshdlrdata->maxsepacutsroot : conshdlrdata->maxsepacuts);
16108 else if( ncuts > 0 )
16145 if( (
depth == 0 && conshdlrdata->maxroundsroot >= 0 &&
nrounds >= conshdlrdata->maxroundsroot)
16146 || (
depth > 0 && conshdlrdata->maxrounds >= 0 &&
nrounds >= conshdlrdata->maxrounds) )
16150 maxsepacuts = (
depth == 0 ? conshdlrdata->maxsepacutsroot : conshdlrdata->maxsepacuts);
16166 else if( ncuts > 0 )
16199 SCIP_Bool checkrelmaxabs;
16200 SCIP_Bool violated;
16211 checkrelmaxabs = conshdlrdata->checkrelmaxabs;
16218 SCIPdebugMsg(
scip,
"-> pseudo solution is objective infeasible, return.\n");
16226 for(
c = 0;
c < nconss && !violated; ++
c )
16247 SCIP_Bool checkrelmaxabs;
16260 checkrelmaxabs = conshdlrdata->checkrelmaxabs;
16267 SCIP_Bool violated =
FALSE;
16277 SCIP_Real activity;
16306 SCIP_Bool rangedrowpropagation =
FALSE;
16307 SCIP_Bool tightenbounds;
16325 tightenbounds =
TRUE;
16330 int tightenboundsfreq;
16335 tightenboundsfreq = propfreq * conshdlrdata->tightenboundsfreq;
16336 tightenbounds = (conshdlrdata->tightenboundsfreq >= 0)
16337 && ((tightenboundsfreq == 0 &&
depth == 0) || (tightenboundsfreq >= 1 && (
depth % tightenboundsfreq == 0)));
16340 rangedrowpropagation = conshdlrdata->rangedrowpropagation;
16342 rangedrowpropagation = rangedrowpropagation && (
depth <= conshdlrdata->rangedrowmaxdepth);
16343 rangedrowfreq = propfreq * conshdlrdata->rangedrowfreq;
16344 rangedrowpropagation = rangedrowpropagation && (conshdlrdata->rangedrowfreq >= 0)
16345 && ((rangedrowfreq == 0 &&
depth == 0) || (rangedrowfreq >= 1 && (
depth % rangedrowfreq == 0)));
16356 conshdlrdata->maxeasyactivitydelta, conshdlrdata->sortvars, &
cutoff, &nchgbds) );
16362 else if( nchgbds > 0 )
16371#define MAXCONSPRESOLROUNDS 10
16379 SCIP_Real minactivity;
16380 SCIP_Real maxactivity;
16424 SCIP_Bool infeasible;
16426 infeasible =
FALSE;
16436 consdata->lhs = consdata->rhs;
16440 if( consdata->eventdata ==
NULL )
16463 assert(consdata->removedfixings);
16478 if( consdata->presolved )
16496 consdata->presolved =
TRUE;
16514 SCIPdebugMsg(
scip,
" -> infeasibility detected during tightening sides\n");
16522 SCIPdebugMsg(
scip,
"linear constraint <%s> is infeasible: sides=[%.15g,%.15g]\n",
16543 SCIPdebugMsg(
scip,
"linear constraint <%s> is infeasible: activitybounds=[%.15g,%.15g], sides=[%.15g,%.15g]\n",
16544 SCIPconsGetName(cons), minactivity, maxactivity, consdata->lhs, consdata->rhs);
16550 SCIPdebugMsg(
scip,
"linear constraint <%s> is redundant: activitybounds=[%.15g,%.15g], sides=[%.15g,%.15g]\n",
16551 SCIPconsGetName(cons), minactivity, maxactivity, consdata->lhs, consdata->rhs);
16555 if( !consdata->upgraded )
16561 SCIPdebugMsg(
scip,
"linear constraint <%s> left hand side is redundant: activitybounds=[%.15g,%.15g], sides=[%.15g,%.15g]\n",
16562 SCIPconsGetName(cons), minactivity, maxactivity, consdata->lhs, consdata->rhs);
16564 if( !consdata->upgraded )
16569 SCIPdebugMsg(
scip,
"linear constraint <%s> right hand side is redundant: activitybounds=[%.15g,%.15g], sides=[%.15g,%.15g]\n",
16570 SCIPconsGetName(cons), minactivity, maxactivity, consdata->lhs, consdata->rhs);
16572 if( !consdata->upgraded )
16577 if( consdata->nvars == 0 )
16581 SCIPdebugMsg(
scip,
"empty linear constraint <%s> is infeasible: sides=[%.15g,%.15g]\n",
16587 SCIPdebugMsg(
scip,
"empty linear constraint <%s> is redundant: sides=[%.15g,%.15g]\n",
16592 if( !consdata->upgraded )
16602 if( conshdlrdata->simplifyinequalities )
16611 if( conshdlrdata->aggregatevariables )
16622 if( conshdlrdata->rangedrowpropagation )
16624 int lastnfixedvars;
16626 lastnfixedvars = *nfixedvars;
16631 if( lastnfixedvars < *nfixedvars )
16642 nfixedvars, nchgbds, &
cutoff) );
16649 SCIPdebugMsg(
scip,
"empty linear constraint <%s> is infeasible: sides=[%.15g,%.15g]\n",
16655 SCIPdebugMsg(
scip,
"empty linear constraint <%s> is redundant: sides=[%.15g,%.15g]\n",
16660 if( !consdata->upgraded )
16698 conshdlrdata->singlevarstuffing, &
cutoff, nfixedvars, nchgbds) );
16701 if( consdata->nvars == 0 )
16705 SCIPdebugMsg(
scip,
"empty linear constraint <%s> is infeasible: sides=[%.15g,%.15g]\n",
16711 SCIPdebugMsg(
scip,
"empty linear constraint <%s> is redundant: sides=[%.15g,%.15g]\n",
16716 if( !consdata->upgraded )
16735 ndelconss, nchgsides) );
16755 for(
c = 0;
c < nconss; ++
c )
16781 &
cutoff, ndelconss, nchgsides, nchgcoefs) );
16831 if( consdata->upgradetried )
16834 if( !consdata->presolved )
16837 consdata->upgradetried =
TRUE;
16853 assert(!consdata->upgraded);
16854 consdata->upgraded =
TRUE;
16860 || !conshdlrdata->presolpairwise
16861 || (conshdlrdata->maxaggrnormscale == 0.0) )
16915 for(
i = 0;
i < consdata->nvars; ++
i )
16980 const char* consname;
16999 initial, separate, enforce, check,
propagate, local, modifiable, dynamic, removable, stickingatnode, global,
valid) );
17034 SCIP_Bool found =
FALSE;
17045 if( curr[1] ==
'=' )
17054 if(
strncmp(curr,
"[free]", 6) == 0 )
17085 else if(
strncmp(curr,
"<=", 2) != 0 )
17138 (*success) =
FALSE;
17257 initial, separate, enforce, check,
propagate, local, modifiable, dynamic, removable, stickingatnode) );
17277 (*success) =
FALSE;
17299 (*nvars) = consdata->nvars;
17343 cons = eventdata->cons;
17357 SCIP_Real oldbound;
17358 SCIP_Real newbound;
17362 varpos = eventdata->varpos;
17368 val = consdata->vals[varpos];
17387 consdata->presolved =
FALSE;
17388 consdata->rangedrowpropagated = 0;
17396 if( consdata->maxactdeltavar ==
var )
17399 consdata->maxactdeltavar =
NULL;
17403 if( consdata->boundstightened > 0)
17405 switch( eventtype )
17409 consdata->boundstightened = 0;
17413 consdata->boundstightened = 0;
17435 delta =
REALABS(val) * domain;
17437 if( delta > consdata->maxactdelta )
17439 consdata->maxactdelta = delta;
17440 consdata->maxactdeltavar =
var;
17447 consdata->presolved =
FALSE;
17448 consdata->removedfixings =
FALSE;
17449 consdata->rangedrowpropagated = 0;
17452 if( consdata->maxactdeltavar ==
var )
17455 consdata->maxactdeltavar =
NULL;
17463 consdata->presolved =
FALSE;
17467 SCIP_Real oldbound;
17468 SCIP_Real newbound;
17472 varpos = eventdata->varpos;
17478 val = consdata->vals[varpos];
17480 consdata->rangedrowpropagated = 0;
17495 consdata->indexsorted =
FALSE;
17497 consdata->coefsorted =
FALSE;
17513 consdata->varsdeleted =
TRUE;
17536 assert(bdchginfos !=
NULL || nbdchginfos == 0);
17552 for(
i = 0;
i < nbdchginfos; ++
i )
17573 if(
i == nbdchginfos )
17660 consdata->checkabsolute =
TRUE;
17742 "multiplier on propagation frequency, how often the bounds are tightened (-1: never, 0: only at root)",
17746 "maximal number of separation rounds per node (-1: unlimited)",
17750 "maximal number of separation rounds per node in the root node (-1: unlimited)",
17754 "maximal number of cuts separated per separation round",
17758 "maximal number of cuts separated per separation round in the root node",
17762 "should pairwise constraint comparison be performed in presolving?",
17766 "should hash table be used for detecting redundant constraints in advance",
17770 "number for minimal pairwise presolve comparisons",
17774 "minimal gain per minimal pairwise presolve comparisons to repeat pairwise comparison round",
17778 "maximal allowed relative gain in maximum norm for constraint aggregation (0.0: disable constraint aggregation)",
17782 "maximum activity delta to run easy propagation on linear constraint (faster, but numerically less stable)",
17786 "maximal relative distance from current node's dual bound to primal bound compared to best node's dual bound for separating knapsack cardinality cuts",
17790 "should all constraints be subject to cardinality cut generation instead of only the ones with non-zero dual value?",
17794 "should presolving search for aggregations in equations",
17798 "should presolving try to simplify inequalities",
17802 "should dual presolving steps be performed?",
17806 "should stuffing of singleton continuous variables be performed?",
17810 "should single variable stuffing be performed, which tries to fulfill constraints using the cheapest variable?",
17813 "constraints/" CONSHDLR_NAME "/sortvars",
"apply binaries sorting in decr. order of coeff abs value?",
17817 "should the violation for a constraint with side 0.0 be checked relative to 1.0 (FALSE) or to the maximum absolute value in the activity (TRUE)?",
17821 "should presolving try to detect constraints parallel to the objective function defining an upper bound and prevent these constraints from entering the LP?",
17825 "should presolving try to detect constraints parallel to the objective function defining a lower bound and prevent these constraints from entering the LP?",
17829 "should presolving try to detect subsets of constraints parallel to the objective function?",
17833 "should presolving and propagation try to improve bounds, detect infeasibility, and extract sub-constraints from ranged rows and equations?",
17837 "should presolving and propagation extract sub-constraints from ranged rows and equations?",
17841 "maximum depth to apply ranged row propagation",
17845 "frequency for applying ranged row propagation",
17849 "should multi-aggregations only be performed if the constraint can be removed afterwards?",
17853 "maximum coefficient dynamism (ie. maxabsval / minabsval) for primal multiaggregation",
17857 "maximum coefficient dynamism (ie. maxabsval / minabsval) for dual multiaggregation",
17861 "should Cliques be extracted?",
17887 if( conshdlr ==
NULL )
17931 SCIP_Bool separate,
17941 SCIP_Bool modifiable,
17947 SCIP_Bool removable,
17949 SCIP_Bool stickingatnode
17963 if( conshdlr ==
NULL )
17986 SCIP_Real constant = 0.0;
18010 if( constant < 0.0 )
18017 SCIPerrorMessage(
"try to generate inconsistent constraint <%s>, active variables leads to a infinite constant constradict the infinite left hand side of the constraint\n", name);
18027 SCIPerrorMessage(
"try to generate inconsistent constraint <%s>, active variables leads to a infinite constant constradict the infinite right hand side of the constraint\n", name);
18043 SCIPerrorMessage(
"try to generate inconsistent constraint <%s>, active variables leads to a infinite constant constradict the infinite left hand side of the constraint\n", name);
18053 SCIPerrorMessage(
"try to generate inconsistent constraint <%s>, active variables leads to a infinite constant constradict the infinite right hand side of the constraint\n", name);
18097 if( check || enforce )
18100 for(n = consdata->nvars - 1; n >= 0; --n )
18106 SCIP_CALL(
SCIPcreateCons(
scip, cons, name, conshdlr, consdata, initial, separate, enforce, check,
propagate,
18107 local, modifiable, dynamic, removable, stickingatnode) );
18155 SCIP_Bool separate,
18160 SCIP_Bool modifiable,
18162 SCIP_Bool removable,
18163 SCIP_Bool stickingatnode,
18172 SCIP_Real constant;
18188 initial, separate, enforce, check,
propagate, local, modifiable, dynamic, removable, stickingatnode) );
18203 for( v = 0; v <
nvars; ++v )
18227 for( v = 0; v <
nvars; ++v )
18259 initial, separate, enforce, check,
propagate, local, modifiable, dynamic, removable, stickingatnode) );
18297 SCIP_Real constant = 0.0;
18326 lhs = consdata->lhs;
18327 rhs = consdata->rhs;
18333 if( constant < 0.0 )
18406 for( v = nconsvars - 1; v >= 0; --v )
18457 SCIPerrorMessage(
"method may only be called during problem creation stage for original constraints and variables\n");
18464 vars = consdata->vars;
18537 return consdata->lhs;
18561 return consdata->rhs;
18624 return consdata->nvars;
18648 return consdata->vars;
18672 return consdata->vals;
18701 if( consdata->row !=
NULL )
18729 if( consdata->row !=
NULL )
18757 if( consdata->row !=
NULL )
18785 if( consdata->row !=
NULL )
18814 return consdata->row;
18833 SCIP_Bool infeasible;
18834 SCIP_Bool integral;
18883 if( consdata->upgraded )
18887 if( consdata->row !=
NULL )
18891 SCIPerrorMessage(
"cannot upgrade linear constraint that is already stored as row in the LP\n");
18944 for(
i = 0;
i < consdata->nvars; ++
i )
18946 var = consdata->vars[
i];
18947 val = consdata->vals[
i];
19024 SCIPdebugMsg(
scip,
"upgrading linear constraint <%s> (%d upgrade methods):\n",
19026 SCIPdebugMsg(
scip,
" +bin=%d -bin=%d +int=%d -int=%d +impl=%d -impl=%d +cont=%d -cont=%d +1=%d -1=%d +I=%d -I=%d +F=%d -F=%d possum=%.15g negsum=%.15g integral=%u\n",
19032 for(
i = 0;
i < conshdlrdata->nlinconsupgrades && *
upgdcons ==
NULL; ++
i )
19034 if( conshdlrdata->linconsupgrades[
i]->active )
19036 SCIP_CALL( conshdlrdata->linconsupgrades[
i]->linconsupgd(
scip, cons, consdata->nvars,
19037 consdata->vars, consdata->vals, consdata->lhs, consdata->rhs,
19038 nposbin,
nnegbin,
nposint,
nnegint,
nposimpl,
nnegimpl,
nposimplbin,
nnegimplbin,
nposcont,
nnegcont,
19061 SCIP_Bool* infeasible
19070 if( conshdlr ==
NULL )
19074 *infeasible =
FALSE;
19079 for(
i = 0;
i < nconss; ++
i )
struct InferInfo INFERINFO
Constraint handler for knapsack constraints of the form , x binary and .
#define MAX_CLIQUE_NONZEROS_PER_CONS
static SCIP_RETCODE addCoef(SCIP *scip, SCIP_CONS *cons, SCIP_VAR *var, SCIP_Real val)
#define DEFAULT_AGGREGATEVARIABLES
static SCIP_RETCODE consdataPrint(SCIP *scip, SCIP_CONSDATA *consdata, FILE *file)
#define DEFAULT_NMINCOMPARISONS
#define DEFAULT_MULTAGGRREMOVE
#define DEFAULT_DUALPRESOLVING
#define DEFAULT_EXTRACTCLIQUES
static void permSortConsdata(SCIP_CONSDATA *consdata, int *perm, int nvars)
#define CONSHDLR_NEEDSCONS
static void consdataRecomputeMaxActivityDelta(SCIP *scip, SCIP_CONSDATA *consdata)
#define CONSHDLR_SEPAFREQ
static SCIP_RETCODE checkCons(SCIP *scip, SCIP_CONS *cons, SCIP_SOL *sol, SCIP_Bool checklprows, SCIP_Bool checkrelmaxabs, SCIP_Bool *violated)
static SCIP_RETCODE addRelaxation(SCIP *scip, SCIP_CONS *cons, SCIP_Bool *cutoff)
#define CONFLICTHDLR_PRIORITY
static void consdataGetReliableResidualActivity(SCIP *scip, SCIP_CONSDATA *consdata, SCIP_VAR *cancelvar, SCIP_Real *resactivity, SCIP_Bool isminresact, SCIP_Bool useglobalbounds)
static SCIP_Bool checkEqualObjective(SCIP *scip, SCIP_CONSDATA *consdata, SCIP_Real *scale, SCIP_Real *offset)
#define CONFLICTHDLR_NAME
static SCIP_RETCODE conshdlrdataIncludeUpgrade(SCIP *scip, SCIP_CONSHDLRDATA *conshdlrdata, SCIP_LINCONSUPGRADE *linconsupgrade)
static SCIP_RETCODE extractCliques(SCIP *scip, SCIP_CONS *cons, SCIP_Real maxeasyactivitydelta, SCIP_Bool sortvars, int *nfixedvars, int *nchgbds, SCIP_Bool *cutoff)
static void getMaxActivity(SCIP *scip, SCIP_CONSDATA *consdata, int posinf, int neginf, int poshuge, int neghuge, SCIP_Real delta, SCIP_Bool global, SCIP_Bool goodrelax, SCIP_Real *maxactivity, SCIP_Bool *isrelax, SCIP_Bool *issettoinfinity)
#define CONSHDLR_CHECKPRIORITY
static SCIP_RETCODE createRow(SCIP *scip, SCIP_CONS *cons)
static int getVarWeight(SCIP_VAR *var)
static SCIP_RETCODE convertBinaryEquality(SCIP *scip, SCIP_CONS *cons, SCIP_Bool *cutoff, int *naggrvars, int *ndelconss)
static void consdataRecomputeMinactivity(SCIP *scip, SCIP_CONSDATA *consdata)
static SCIP_RETCODE addConflictFixedVars(SCIP *scip, SCIP_CONS *cons, SCIP_VAR *infervar, SCIP_BDCHGIDX *bdchgidx, int inferpos)
#define DEFAULT_DETECTCUTOFFBOUND
static SCIP_RETCODE tightenVarLb(SCIP *scip, SCIP_CONS *cons, int pos, PROPRULE proprule, SCIP_Real newlb, SCIP_Real oldlb, SCIP_Bool *cutoff, int *nchgbds, SCIP_Bool force)
#define CONSHDLR_PROP_TIMING
static SCIP_Real consdataComputePseudoActivity(SCIP *scip, SCIP_CONSDATA *consdata)
static SCIP_RETCODE conshdlrdataEnsureLinconsupgradesSize(SCIP *scip, SCIP_CONSHDLRDATA *conshdlrdata, int num)
static SCIP_RETCODE retrieveParallelConstraints(SCIP_HASHTABLE *hashtable, SCIP_CONS **querycons, SCIP_CONS **parallelconss, int *nparallelconss)
#define CONFLICTHDLR_DESC
static void conshdlrdataFree(SCIP *scip, SCIP_CONSHDLRDATA **conshdlrdata)
static void calculateMinvalAndMaxval(SCIP *scip, SCIP_Real side, SCIP_Real val, SCIP_Real minresactivity, SCIP_Real maxresactivity, SCIP_Real *minval, SCIP_Real *maxval)
static SCIP_RETCODE lockRounding(SCIP *scip, SCIP_CONS *cons, SCIP_VAR *var, SCIP_Real val)
static void consdataRecomputeGlbMinactivity(SCIP *scip, SCIP_CONSDATA *consdata)
static void consdataGetActivityResiduals(SCIP *scip, SCIP_CONSDATA *consdata, SCIP_VAR *var, SCIP_Real val, SCIP_Bool goodrelax, SCIP_Real *minresactivity, SCIP_Real *maxresactivity, SCIP_Bool *minisrelax, SCIP_Bool *maxisrelax, SCIP_Bool *isminsettoinfinity, SCIP_Bool *ismaxsettoinfinity)
static void consdataUpdateActivitiesUb(SCIP *scip, SCIP_CONSDATA *consdata, SCIP_VAR *var, SCIP_Real oldub, SCIP_Real newub, SCIP_Real val, SCIP_Bool checkreliability)
static SCIP_RETCODE tightenSides(SCIP *scip, SCIP_CONS *cons, int *nchgsides, SCIP_Bool *infeasible)
static void consdataUpdateActivitiesGlbLb(SCIP *scip, SCIP_CONSDATA *consdata, SCIP_Real oldlb, SCIP_Real newlb, SCIP_Real val, SCIP_Bool checkreliability)
static void consdataUpdateActivitiesLb(SCIP *scip, SCIP_CONSDATA *consdata, SCIP_VAR *var, SCIP_Real oldlb, SCIP_Real newlb, SCIP_Real val, SCIP_Bool checkreliability)
#define CONSHDLR_MAXPREROUNDS
static SCIP_Bool conshdlrdataHasUpgrade(SCIP *scip, SCIP_CONSHDLRDATA *conshdlrdata, SCIP_DECL_LINCONSUPGD((*linconsupgd)), const char *conshdlrname)
static SCIP_RETCODE chgCoefPos(SCIP *scip, SCIP_CONS *cons, int pos, SCIP_Real newval)
static void consdataRecomputeMaxactivity(SCIP *scip, SCIP_CONSDATA *consdata)
static SCIP_RETCODE linconsupgradeCreate(SCIP *scip, SCIP_LINCONSUPGRADE **linconsupgrade, SCIP_DECL_LINCONSUPGD((*linconsupgd)), int priority)
#define DEFAULT_PRESOLPAIRWISE
#define DEFAULT_MAXAGGRNORMSCALE
static SCIP_RETCODE performVarDeletions(SCIP *scip, SCIP_CONSHDLR *conshdlr, SCIP_CONS **conss, int nconss)
#define checkMaxActivityDelta(scip, consdata)
#define CONSHDLR_SEPAPRIORITY
static SCIP_Bool isFiniteNonnegativeIntegral(SCIP *scip, SCIP_Real x)
#define DEFAULT_SINGLETONSTUFFING
#define DEFAULT_MAXROUNDSROOT
static void consdataUpdateSignatures(SCIP_CONSDATA *consdata, int pos)
#define DEFAULT_MAXCARDBOUNDDIST
#define DEFAULT_MAXEASYACTIVITYDELTA
static SCIP_RETCODE scaleCons(SCIP *scip, SCIP_CONS *cons, SCIP_Real scalar)
static int inferInfoGetPos(INFERINFO inferinfo)
static SCIP_RETCODE detectRedundantConstraints(SCIP *scip, BMS_BLKMEM *blkmem, SCIP_CONS **conss, int nconss, int *firstchange, SCIP_Bool *cutoff, int *ndelconss, int *nchgsides)
static void consdataGetActivityBounds(SCIP *scip, SCIP_CONSDATA *consdata, SCIP_Bool goodrelax, SCIP_Real *minactivity, SCIP_Real *maxactivity, SCIP_Bool *minisrelax, SCIP_Bool *maxisrelax, SCIP_Bool *isminsettoinfinity, SCIP_Bool *ismaxsettoinfinity)
#define DEFAULT_CHECKRELMAXABS
#define DEFAULT_MAXDUALMULTAGGRQUOT
static void linconsupgradeFree(SCIP *scip, SCIP_LINCONSUPGRADE **linconsupgrade)
static SCIP_RETCODE aggregateConstraints(SCIP *scip, SCIP_CONS *cons0, SCIP_CONS *cons1, int *commonidx0, int *commonidx1, int *diffidx0minus1, int *diffidx1minus0, int nvarscommon, int commonidxweight, int diffidx0minus1weight, int diffidx1minus0weight, SCIP_Real maxaggrnormscale, int *nchgcoefs, SCIP_Bool *aggregated, SCIP_Bool *infeasible)
static SCIP_RETCODE analyzeConflict(SCIP *scip, SCIP_CONS *cons, SCIP_Bool reasonisrhs)
static SCIP_RETCODE rangedRowPropagation(SCIP *scip, SCIP_CONS *cons, SCIP_Bool *cutoff, int *nfixedvars, int *nchgbds, int *naddconss)
static INFERINFO intToInferInfo(int i)
static SCIP_RETCODE mergeMultiples(SCIP *scip, SCIP_CONS *cons)
static SCIP_RETCODE separateCons(SCIP *scip, SCIP_CONS *cons, SCIP_CONSHDLRDATA *conshdlrdata, SCIP_SOL *sol, SCIP_Bool separatecards, SCIP_Bool separateall, int *ncuts, SCIP_Bool *cutoff)
static SCIP_RETCODE addSymmetryInformation(SCIP *scip, SYM_SYMTYPE symtype, SCIP_CONS *cons, SYM_GRAPH *graph, SCIP_Bool *success)
static SCIP_RETCODE convertLongEquality(SCIP *scip, SCIP_CONSHDLRDATA *conshdlrdata, SCIP_CONS *cons, SCIP_Bool *cutoff, int *naggrvars, int *ndelconss)
static void consdataCheckNonbinvar(SCIP_CONSDATA *consdata)
static SCIP_RETCODE chgLhs(SCIP *scip, SCIP_CONS *cons, SCIP_Real lhs)
#define DEFAULT_MAXMULTAGGRQUOT
static void consdataUpdateActivitiesGlbUb(SCIP *scip, SCIP_CONSDATA *consdata, SCIP_Real oldub, SCIP_Real newub, SCIP_Real val, SCIP_Bool checkreliability)
static void consdataGetGlbActivityBounds(SCIP *scip, SCIP_CONSDATA *consdata, SCIP_Bool goodrelax, SCIP_Real *glbminactivity, SCIP_Real *glbmaxactivity, SCIP_Bool *minisrelax, SCIP_Bool *maxisrelax, SCIP_Bool *isminsettoinfinity, SCIP_Bool *ismaxsettoinfinity)
static SCIP_RETCODE consCatchEvent(SCIP *scip, SCIP_CONS *cons, SCIP_EVENTHDLR *eventhdlr, int pos)
static void consdataCalcMinAbsval(SCIP_CONSDATA *consdata)
static SCIP_RETCODE addConflictBounds(SCIP *scip, SCIP_CONS *cons, SCIP_VAR *infervar, SCIP_BDCHGIDX *bdchgidx, int inferpos, SCIP_Bool reasonisrhs)
#define MAXCONSPRESOLROUNDS
static SCIP_RETCODE consdataEnsureVarsSize(SCIP *scip, SCIP_CONSDATA *consdata, int num)
#define NONLINCONSUPGD_PRIORITY
#define DEFAULT_MAXSEPACUTSROOT
static SCIP_RETCODE tightenBounds(SCIP *scip, SCIP_CONS *cons, SCIP_Real maxeasyactivitydelta, SCIP_Bool sortvars, SCIP_Bool *cutoff, int *nchgbds)
static void consdataCalcMaxAbsval(SCIP_CONSDATA *consdata)
#define DEFAULT_RANGEDROWPROPAGATION
static SCIP_RETCODE consDropAllEvents(SCIP *scip, SCIP_CONS *cons, SCIP_EVENTHDLR *eventhdlr)
#define DEFAULT_PRESOLUSEHASHING
static SCIP_Real consdataGetActivity(SCIP *scip, SCIP_CONSDATA *consdata, SCIP_SOL *sol)
static SCIP_RETCODE consdataTightenCoefs(SCIP *scip, SCIP_CONS *cons, int *nchgcoefs, int *nchgsides)
static SCIP_RETCODE normalizeCons(SCIP *scip, SCIP_CONS *cons, SCIP_Bool *infeasible)
static SCIP_RETCODE presolStuffing(SCIP *scip, SCIP_CONS *cons, SCIP_Bool singletonstuffing, SCIP_Bool singlevarstuffing, SCIP_Bool *cutoff, int *nfixedvars, int *nchgbds)
static SCIP_RETCODE unlockRounding(SCIP *scip, SCIP_CONS *cons, SCIP_VAR *var, SCIP_Real val)
static void consdataCalcSignatures(SCIP_CONSDATA *consdata)
static SCIP_RETCODE addConflictReasonVars(SCIP *scip, SCIP_VAR **vars, int nvars, SCIP_VAR *var, SCIP_Real bound)
#define DEFAULT_RANGEDROWFREQ
static SCIP_RETCODE propagateCons(SCIP *scip, SCIP_CONS *cons, SCIP_Bool tightenbounds, SCIP_Bool rangedrowpropagation, SCIP_Real maxeasyactivitydelta, SCIP_Bool sortvars, SCIP_Bool *cutoff, int *nchgbds)
static SCIP_RETCODE updateCutoffbound(SCIP *scip, SCIP_CONS *cons, SCIP_Real primalbound)
static void consdataUpdateDelCoef(SCIP *scip, SCIP_CONSDATA *consdata, SCIP_VAR *var, SCIP_Real val, SCIP_Bool checkreliability)
#define DEFAULT_RANGEDROWARTCONS
static SCIP_RETCODE delCoefPos(SCIP *scip, SCIP_CONS *cons, int pos)
#define MAXSCALEDCOEFINTEGER
static void consdataUpdateAddCoef(SCIP *scip, SCIP_CONSDATA *consdata, SCIP_VAR *var, SCIP_Real val, SCIP_Bool checkreliability)
static SCIP_RETCODE consdataCreate(SCIP *scip, SCIP_CONSDATA **consdata, int nvars, SCIP_VAR **vars, SCIP_Real *vals, SCIP_Real lhs, SCIP_Real rhs)
static SCIP_RETCODE chgRhs(SCIP *scip, SCIP_CONS *cons, SCIP_Real rhs)
#define DEFAULT_SIMPLIFYINEQUALITIES
#define CONSHDLR_PROPFREQ
static SCIP_RETCODE tightenVarBoundsEasy(SCIP *scip, SCIP_CONS *cons, int pos, SCIP_Bool *cutoff, int *nchgbds, SCIP_Bool force)
static void consdataUpdateActivities(SCIP *scip, SCIP_CONSDATA *consdata, SCIP_VAR *var, SCIP_Real oldbound, SCIP_Real newbound, SCIP_Real val, SCIP_BOUNDTYPE boundtype, SCIP_Bool global, SCIP_Bool checkreliability)
static SCIP_RETCODE convertEquality(SCIP *scip, SCIP_CONS *cons, SCIP_CONSHDLRDATA *conshdlrdata, SCIP_Bool *cutoff, int *nfixedvars, int *naggrvars, int *ndelconss)
static unsigned int getParallelConsKey(SCIP_CONS *cons)
static SCIP_RETCODE fixVariables(SCIP *scip, SCIP_CONS *cons, SCIP_Bool *cutoff, int *nfixedvars)
#define CONSHDLR_PRESOLTIMING
#define DEFAULT_DETECTPARTIALOBJECTIVE
static SCIP_RETCODE enforceConstraint(SCIP *scip, SCIP_CONSHDLR *conshdlr, SCIP_CONS **conss, int nconss, int nusefulconss, SCIP_SOL *sol, SCIP_RESULT *result)
static SCIP_RETCODE consdataFree(SCIP *scip, SCIP_CONSDATA **consdata)
static SCIP_RETCODE dualPresolve(SCIP *scip, SCIP_CONSHDLRDATA *conshdlrdata, SCIP_CONS *cons, SCIP_Bool *cutoff, int *nfixedvars, int *naggrvars, int *ndelconss)
#define DEFAULT_MAXSEPACUTS
static SCIP_Real consdataGetMaxAbsval(SCIP_CONSDATA *consdata)
static SCIP_RETCODE addNlrow(SCIP *scip, SCIP_CONS *cons)
static SCIP_RETCODE consPrintConsSol(SCIP *scip, SCIP_CONS *cons, SCIP_SOL *sol, FILE *file)
#define CONSHDLR_EAGERFREQ
#define DEFAULT_TIGHTENBOUNDSFREQ
static void getNewSidesAfterAggregation(SCIP *scip, SCIP_CONSDATA *consdata, SCIP_VAR *slackvar, SCIP_Real slackcoef, SCIP_Real *newlhs, SCIP_Real *newrhs)
static SCIP_RETCODE convertUnaryEquality(SCIP *scip, SCIP_CONS *cons, SCIP_Bool *cutoff, int *nfixedvars, int *ndelconss)
static void consdataUpdateChgCoef(SCIP *scip, SCIP_CONSDATA *consdata, SCIP_VAR *var, SCIP_Real oldval, SCIP_Real newval, SCIP_Bool checkreliability)
static SCIP_RETCODE conshdlrdataCreate(SCIP *scip, SCIP_CONSHDLRDATA **conshdlrdata, SCIP_EVENTHDLR *eventhdlr)
static void consdataRecomputeGlbMaxactivity(SCIP *scip, SCIP_CONSDATA *consdata)
static SCIP_RETCODE applyFixings(SCIP *scip, SCIP_CONS *cons, SCIP_Bool *infeasible)
static void consdataCalcActivities(SCIP *scip, SCIP_CONSDATA *consdata)
#define DEFAULT_MAXROUNDS
#define CONSHDLR_ENFOPRIORITY
static SCIP_RETCODE tightenVarUb(SCIP *scip, SCIP_CONS *cons, int pos, PROPRULE proprule, SCIP_Real newub, SCIP_Real oldub, SCIP_Bool *cutoff, int *nchgbds, SCIP_Bool force)
static int getInferInt(PROPRULE proprule, int pos)
static int inferInfoGetProprule(INFERINFO inferinfo)
#define DEFAULT_MINGAINPERNMINCOMP
static SCIP_Real consdataGetFeasibility(SCIP *scip, SCIP_CONSDATA *consdata, SCIP_SOL *sol)
static SCIP_RETCODE rangedRowSimplify(SCIP *scip, SCIP_CONS *cons, int *nchgcoefs, int *nchgsides)
static SCIP_RETCODE aggregateVariables(SCIP *scip, SCIP_CONS *cons, SCIP_Bool *cutoff, int *nfixedvars, int *naggrvars)
#define CONSHDLR_DELAYSEPA
static void consdataInvalidateActivities(SCIP_CONSDATA *consdata)
#define DEFAULT_RANGEDROWMAXDEPTH
static SCIP_RETCODE analyzeConflictRangedRow(SCIP *scip, SCIP_CONS *cons, SCIP_VAR **vars, int nvars, SCIP_VAR *var, SCIP_Real bound)
static SCIP_RETCODE consDropEvent(SCIP *scip, SCIP_CONS *cons, SCIP_EVENTHDLR *eventhdlr, int pos)
static SCIP_RETCODE tightenVarBounds(SCIP *scip, SCIP_CONS *cons, int pos, SCIP_Bool *cutoff, int *nchgbds, SCIP_Bool force)
static SCIP_Real consdataGetMinAbsval(SCIP_CONSDATA *consdata)
static SCIP_Bool consdataIsResidualIntegral(SCIP *scip, SCIP_CONSDATA *consdata, int pos, SCIP_Real val)
static int inferInfoToInt(INFERINFO inferinfo)
static SCIP_RETCODE preprocessConstraintPairs(SCIP *scip, SCIP_CONS **conss, int firstchange, int chkind, SCIP_Real maxaggrnormscale, SCIP_Bool *cutoff, int *ndelconss, int *nchgsides, int *nchgcoefs)
static SCIP_RETCODE consdataSort(SCIP *scip, SCIP_CONSDATA *consdata)
#define DEFAULT_SINGLEVARSTUFFING
static SCIP_RETCODE checkParallelObjective(SCIP *scip, SCIP_CONS *cons, SCIP_CONSHDLRDATA *conshdlrdata)
static SCIP_RETCODE simplifyInequalities(SCIP *scip, SCIP_CONS *cons, int *nchgcoefs, int *nchgsides, SCIP_Bool *infeasible)
static SCIP_RETCODE consCatchAllEvents(SCIP *scip, SCIP_CONS *cons, SCIP_EVENTHDLR *eventhdlr)
static SCIP_RETCODE resolvePropagation(SCIP *scip, SCIP_CONS *cons, SCIP_VAR *infervar, INFERINFO inferinfo, SCIP_BOUNDTYPE boundtype, SCIP_BDCHGIDX *bdchgidx, SCIP_RESULT *result)
static SCIP_Bool isRangedRow(SCIP *scip, SCIP_Real lhs, SCIP_Real rhs)
#define DEFAULT_DETECTLOWERBOUND
static SCIP_RETCODE checkPartialObjective(SCIP *scip, SCIP_CONS *cons, SCIP_CONSHDLRDATA *conshdlrdata)
#define CONSHDLR_DELAYPROP
static SCIP_Bool canTightenBounds(SCIP_CONS *cons)
#define DEFAULT_SEPARATEALL
static void findOperators(const char *str, char **firstoperator, char **secondoperator, SCIP_Bool *success)
static void getMinActivity(SCIP *scip, SCIP_CONSDATA *consdata, int posinf, int neginf, int poshuge, int neghuge, SCIP_Real delta, SCIP_Bool global, SCIP_Bool goodrelax, SCIP_Real *minactivity, SCIP_Bool *isrelax, SCIP_Bool *issettoinfinity)
static SCIP_RETCODE fullDualPresolve(SCIP *scip, SCIP_CONS **conss, int nconss, SCIP_Bool *cutoff, int *nchgbds)
static INFERINFO getInferInfo(PROPRULE proprule, int pos)
static void consdataGetGlbActivityResiduals(SCIP *scip, SCIP_CONSDATA *consdata, SCIP_VAR *var, SCIP_Real val, SCIP_Bool goodrelax, SCIP_Real *minresactivity, SCIP_Real *maxresactivity, SCIP_Bool *minisrelax, SCIP_Bool *maxisrelax, SCIP_Bool *isminsettoinfinity, SCIP_Bool *ismaxsettoinfinity)
Constraint handler for linear constraints in their most general form, .
constraint handler for nonlinear constraints specified by algebraic expressions
defines macros for basic operations in double-double arithmetic giving roughly twice the precision of...
#define SCIPquadprecSumQD(r, a, b)
#define QUAD_ASSIGN(a, constant)
#define QUAD_ASSIGN_Q(a, b)
#define SCIPdebugGetSolVal(scip, var, val)
#define SCIPdebugAddSolVal(scip, var, val)
#define SCIP_MAXTREEDEPTH
#define SCIP_CALL_ABORT(x)
#define SCIP_LONGINT_FORMAT
SCIP_Real SCIPgetDualsolLinear(SCIP *scip, SCIP_CONS *cons)
SCIP_RETCODE SCIPincludeLinconsUpgrade(SCIP *scip, SCIP_DECL_LINCONSUPGD((*linconsupgd)), int priority, const char *conshdlrname)
#define SCIP_DECL_NONLINCONSUPGD(x)
SCIP_Real SCIPgetRhsLinear(SCIP *scip, SCIP_CONS *cons)
SCIP_RETCODE SCIPupgradeConsLinear(SCIP *scip, SCIP_CONS *cons, SCIP_CONS **upgdcons)
SCIP_VAR ** SCIPgetVarsLinear(SCIP *scip, SCIP_CONS *cons)
SCIP_RETCODE SCIPchgRhsLinear(SCIP *scip, SCIP_CONS *cons, SCIP_Real rhs)
SCIP_RETCODE SCIPincludeConsUpgradeNonlinear(SCIP *scip, SCIP_DECL_NONLINCONSUPGD((*nlconsupgd)), int priority, SCIP_Bool active, const char *conshdlrname)
SCIP_RETCODE SCIPaddCoefLinear(SCIP *scip, SCIP_CONS *cons, SCIP_VAR *var, SCIP_Real val)
SCIP_Real SCIPgetLhsLinear(SCIP *scip, SCIP_CONS *cons)
int SCIPgetNVarsLinear(SCIP *scip, SCIP_CONS *cons)
SCIP_Real * SCIPgetValsLinear(SCIP *scip, SCIP_CONS *cons)
SCIP_ROW * SCIPgetRowLinear(SCIP *scip, SCIP_CONS *cons)
SCIP_RETCODE SCIPcreateConsBasicLinear(SCIP *scip, SCIP_CONS **cons, const char *name, int nvars, SCIP_VAR **vars, SCIP_Real *vals, SCIP_Real lhs, SCIP_Real rhs)
SCIP_EXPR * SCIPgetExprNonlinear(SCIP_CONS *cons)
SCIP_RETCODE SCIPseparateRelaxedKnapsack(SCIP *scip, SCIP_CONS *cons, SCIP_SEPA *sepa, int nknapvars, SCIP_VAR **knapvars, SCIP_Real *knapvals, SCIP_Real valscale, SCIP_Real rhs, SCIP_SOL *sol, SCIP_Bool *cutoff, int *ncuts)
SCIP_Real SCIPgetRhsNonlinear(SCIP_CONS *cons)
SCIP_Real SCIPgetDualfarkasLinear(SCIP *scip, SCIP_CONS *cons)
#define SCIP_DECL_LINCONSUPGD(x)
SCIP_RETCODE SCIPcopyConsLinear(SCIP *scip, SCIP_CONS **cons, SCIP *sourcescip, const char *name, int nvars, SCIP_VAR **sourcevars, SCIP_Real *sourcecoefs, SCIP_Real lhs, SCIP_Real rhs, SCIP_HASHMAP *varmap, SCIP_HASHMAP *consmap, SCIP_Bool initial, SCIP_Bool separate, SCIP_Bool enforce, SCIP_Bool check, SCIP_Bool propagate, SCIP_Bool local, SCIP_Bool modifiable, SCIP_Bool dynamic, SCIP_Bool removable, SCIP_Bool stickingatnode, SCIP_Bool global, SCIP_Bool *valid)
SCIP_RETCODE SCIPcleanupConssLinear(SCIP *scip, SCIP_Bool onlychecked, SCIP_Bool *infeasible)
SCIP_RETCODE SCIPcreateConsLinear(SCIP *scip, SCIP_CONS **cons, const char *name, int nvars, SCIP_VAR **vars, SCIP_Real *vals, SCIP_Real lhs, SCIP_Real rhs, SCIP_Bool initial, SCIP_Bool separate, SCIP_Bool enforce, SCIP_Bool check, SCIP_Bool propagate, SCIP_Bool local, SCIP_Bool modifiable, SCIP_Bool dynamic, SCIP_Bool removable, SCIP_Bool stickingatnode)
SCIP_Real SCIPgetActivityLinear(SCIP *scip, SCIP_CONS *cons, SCIP_SOL *sol)
SCIP_Real SCIPgetFeasibilityLinear(SCIP *scip, SCIP_CONS *cons, SCIP_SOL *sol)
SCIP_RETCODE SCIPclassifyConstraintTypesLinear(SCIP *scip, SCIP_LINCONSSTATS *linconsstats)
SCIP_RETCODE SCIPchgLhsLinear(SCIP *scip, SCIP_CONS *cons, SCIP_Real lhs)
SCIP_Real SCIPgetLhsNonlinear(SCIP_CONS *cons)
SCIP_RETCODE SCIPchgCoefLinear(SCIP *scip, SCIP_CONS *cons, SCIP_VAR *var, SCIP_Real val)
SCIP_RETCODE SCIPdelCoefLinear(SCIP *scip, SCIP_CONS *cons, SCIP_VAR *var)
SCIP_RETCODE SCIPincludeConshdlrLinear(SCIP *scip)
SCIP_RETCODE SCIPconvertCutsToConss(SCIP *scip, SCIP_HASHMAP *varmap, SCIP_HASHMAP *consmap, SCIP_Bool global, int *ncutsadded)
SCIP_Bool SCIPisConsCompressionEnabled(SCIP *scip)
SCIP_RETCODE SCIPgetVarCopy(SCIP *sourcescip, SCIP *targetscip, SCIP_VAR *sourcevar, SCIP_VAR **targetvar, SCIP_HASHMAP *varmap, SCIP_HASHMAP *consmap, SCIP_Bool global, SCIP_Bool *success)
SCIP_Bool SCIPisTransformed(SCIP *scip)
SCIP_Bool SCIPisPresolveFinished(SCIP *scip)
SCIP_Bool SCIPisStopped(SCIP *scip)
SCIP_STAGE SCIPgetStage(SCIP *scip)
int SCIPgetNObjVars(SCIP *scip)
SCIP_RETCODE SCIPaddVar(SCIP *scip, SCIP_VAR *var)
int SCIPgetNContVars(SCIP *scip)
SCIP_CONS ** SCIPgetConss(SCIP *scip)
SCIP_RETCODE SCIPaddObjoffset(SCIP *scip, SCIP_Real addval)
int SCIPgetNVars(SCIP *scip)
SCIP_RETCODE SCIPaddCons(SCIP *scip, SCIP_CONS *cons)
SCIP_RETCODE SCIPdelCons(SCIP *scip, SCIP_CONS *cons)
int SCIPgetNConss(SCIP *scip)
SCIP_VAR ** SCIPgetVars(SCIP *scip)
int SCIPgetNBinVars(SCIP *scip)
void SCIPhashtableFree(SCIP_HASHTABLE **hashtable)
SCIP_RETCODE SCIPhashtableSafeInsert(SCIP_HASHTABLE *hashtable, void *element)
SCIP_RETCODE SCIPhashtableCreate(SCIP_HASHTABLE **hashtable, BMS_BLKMEM *blkmem, int tablesize, SCIP_DECL_HASHGETKEY((*hashgetkey)), SCIP_DECL_HASHKEYEQ((*hashkeyeq)), SCIP_DECL_HASHKEYVAL((*hashkeyval)), void *userptr)
void * SCIPhashtableRetrieve(SCIP_HASHTABLE *hashtable, void *key)
#define SCIPhashSeven(a, b, c, d, e, f, g)
void SCIPhashtablePrintStatistics(SCIP_HASHTABLE *hashtable, SCIP_MESSAGEHDLR *messagehdlr)
static INLINE uint32_t SCIPrealHashCode(double x)
SCIP_RETCODE SCIPhashtableRemove(SCIP_HASHTABLE *hashtable, void *element)
SCIP_RETCODE SCIPhashtableInsert(SCIP_HASHTABLE *hashtable, void *element)
#define SCIPhashSignature64(a)
SCIP_RETCODE SCIPupdateLocalLowerbound(SCIP *scip, SCIP_Real newbound)
SCIP_RETCODE SCIPdelConsLocal(SCIP *scip, SCIP_CONS *cons)
SCIP_Real SCIPgetLocalLowerbound(SCIP *scip)
SCIP_RETCODE SCIPaddConflict(SCIP *scip, SCIP_NODE *node, SCIP_CONS *cons, SCIP_NODE *validnode, SCIP_CONFTYPE conftype, SCIP_Bool iscutoffinvolved)
SCIP_RETCODE SCIPaddConsLocal(SCIP *scip, SCIP_CONS *cons, SCIP_NODE *validnode)
void SCIPinfoMessage(SCIP *scip, FILE *file, const char *formatstr,...)
void SCIPverbMessage(SCIP *scip, SCIP_VERBLEVEL msgverblevel, FILE *file, const char *formatstr,...)
#define SCIPdebugMsgPrint
SCIP_MESSAGEHDLR * SCIPgetMessagehdlr(SCIP *scip)
void SCIPwarningMessage(SCIP *scip, const char *formatstr,...)
SCIP_Longint SCIPcalcGreComDiv(SCIP_Longint val1, SCIP_Longint val2)
SCIP_Longint SCIPcalcSmaComMul(SCIP_Longint val1, SCIP_Longint val2)
SCIP_Bool SCIPrealToRational(SCIP_Real val, SCIP_Real mindelta, SCIP_Real maxdelta, SCIP_Longint maxdnom, SCIP_Longint *nominator, SCIP_Longint *denominator)
SCIP_Real SCIPselectSimpleValue(SCIP_Real lb, SCIP_Real ub, SCIP_Longint maxdnom)
SCIP_Real SCIPrelDiff(SCIP_Real val1, SCIP_Real val2)
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_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_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)
SCIP_RETCODE SCIPgetIntParam(SCIP *scip, const char *name, int *value)
int SCIPgetNLPBranchCands(SCIP *scip)
SCIP_RETCODE SCIPaddConflictLb(SCIP *scip, SCIP_VAR *var, SCIP_BDCHGIDX *bdchgidx)
SCIP_RETCODE SCIPinitConflictAnalysis(SCIP *scip, SCIP_CONFTYPE conftype, SCIP_Bool iscutoffinvolved)
SCIP_RETCODE SCIPaddConflictUb(SCIP *scip, SCIP_VAR *var, SCIP_BDCHGIDX *bdchgidx)
const char * SCIPconflicthdlrGetName(SCIP_CONFLICTHDLR *conflicthdlr)
SCIP_Bool SCIPisConflictAnalysisApplicable(SCIP *scip)
SCIP_RETCODE SCIPanalyzeConflictCons(SCIP *scip, SCIP_CONS *cons, SCIP_Bool *success)
SCIP_RETCODE SCIPincludeConflicthdlrBasic(SCIP *scip, SCIP_CONFLICTHDLR **conflicthdlrptr, const char *name, const char *desc, int priority, SCIP_DECL_CONFLICTEXEC((*conflictexec)), SCIP_CONFLICTHDLRDATA *conflicthdlrdata)
int SCIPconshdlrGetNCheckConss(SCIP_CONSHDLR *conshdlr)
void SCIPconshdlrSetData(SCIP_CONSHDLR *conshdlr, SCIP_CONSHDLRDATA *conshdlrdata)
SCIP_RETCODE SCIPsetConshdlrFree(SCIP *scip, SCIP_CONSHDLR *conshdlr,)
SCIP_RETCODE SCIPsetConshdlrActive(SCIP *scip, SCIP_CONSHDLR *conshdlr,)
SCIP_CONS ** SCIPconshdlrGetCheckConss(SCIP_CONSHDLR *conshdlr)
SCIP_RETCODE SCIPsetConshdlrPresol(SCIP *scip, SCIP_CONSHDLR *conshdlr, SCIP_DECL_CONSPRESOL((*conspresol)), int maxprerounds, SCIP_PRESOLTIMING presoltiming)
SCIP_RETCODE SCIPsetConshdlrSepa(SCIP *scip, SCIP_CONSHDLR *conshdlr, SCIP_DECL_CONSSEPALP((*conssepalp)), SCIP_DECL_CONSSEPASOL((*conssepasol)), int sepafreq, int sepapriority, SCIP_Bool delaysepa)
SCIP_RETCODE SCIPsetConshdlrProp(SCIP *scip, SCIP_CONSHDLR *conshdlr, SCIP_DECL_CONSPROP((*consprop)), int propfreq, SCIP_Bool delayprop, SCIP_PROPTIMING proptiming)
SCIP_RETCODE SCIPsetConshdlrEnforelax(SCIP *scip, SCIP_CONSHDLR *conshdlr,)
SCIP_RETCODE SCIPincludeConshdlrBasic(SCIP *scip, SCIP_CONSHDLR **conshdlrptr, const char *name, const char *desc, int enfopriority, int chckpriority, int eagerfreq, SCIP_Bool needscons, SCIP_DECL_CONSENFOLP((*consenfolp)), SCIP_DECL_CONSENFOPS((*consenfops)), SCIP_DECL_CONSCHECK((*conscheck)), SCIP_DECL_CONSLOCK((*conslock)), SCIP_CONSHDLRDATA *conshdlrdata)
SCIP_RETCODE SCIPsetConshdlrParse(SCIP *scip, SCIP_CONSHDLR *conshdlr,)
SCIP_RETCODE SCIPsetConshdlrGetVars(SCIP *scip, SCIP_CONSHDLR *conshdlr,)
SCIP_RETCODE SCIPsetConshdlrPrint(SCIP *scip, SCIP_CONSHDLR *conshdlr,)
int SCIPconshdlrGetPropFreq(SCIP_CONSHDLR *conshdlr)
SCIP_RETCODE SCIPsetConshdlrGetSignedPermsymGraph(SCIP *scip, SCIP_CONSHDLR *conshdlr,)
int SCIPconshdlrGetNConss(SCIP_CONSHDLR *conshdlr)
const char * SCIPconshdlrGetName(SCIP_CONSHDLR *conshdlr)
SCIP_RETCODE SCIPsetConshdlrCopy(SCIP *scip, SCIP_CONSHDLR *conshdlr, SCIP_DECL_CONSHDLRCOPY((*conshdlrcopy)),)
SCIP_CONSHDLR * SCIPfindConshdlr(SCIP *scip, const char *name)
SCIP_RETCODE SCIPsetConshdlrInit(SCIP *scip, SCIP_CONSHDLR *conshdlr,)
SCIP_RETCODE SCIPsetConshdlrGetPermsymGraph(SCIP *scip, SCIP_CONSHDLR *conshdlr,)
SCIP_RETCODE SCIPsetConshdlrDelete(SCIP *scip, SCIP_CONSHDLR *conshdlr,)
SCIP_RETCODE SCIPsetConshdlrInitsol(SCIP *scip, SCIP_CONSHDLR *conshdlr,)
SCIP_RETCODE SCIPsetConshdlrDeactive(SCIP *scip, SCIP_CONSHDLR *conshdlr,)
SCIP_CONSHDLRDATA * SCIPconshdlrGetData(SCIP_CONSHDLR *conshdlr)
int SCIPconshdlrGetNActiveConss(SCIP_CONSHDLR *conshdlr)
SCIP_RETCODE SCIPsetConshdlrTrans(SCIP *scip, SCIP_CONSHDLR *conshdlr,)
SCIP_RETCODE SCIPsetConshdlrResprop(SCIP *scip, SCIP_CONSHDLR *conshdlr,)
SCIP_RETCODE SCIPsetConshdlrExitpre(SCIP *scip, SCIP_CONSHDLR *conshdlr,)
SCIP_RETCODE SCIPsetConshdlrExitsol(SCIP *scip, SCIP_CONSHDLR *conshdlr,)
SCIP_CONS ** SCIPconshdlrGetConss(SCIP_CONSHDLR *conshdlr)
SCIP_RETCODE SCIPsetConshdlrDelvars(SCIP *scip, SCIP_CONSHDLR *conshdlr,)
SCIP_RETCODE SCIPsetConshdlrExit(SCIP *scip, SCIP_CONSHDLR *conshdlr,)
SCIP_RETCODE SCIPsetConshdlrInitlp(SCIP *scip, SCIP_CONSHDLR *conshdlr,)
SCIP_RETCODE SCIPsetConshdlrGetNVars(SCIP *scip, SCIP_CONSHDLR *conshdlr,)
SCIP_CONSDATA * SCIPconsGetData(SCIP_CONS *cons)
int SCIPconsGetPos(SCIP_CONS *cons)
SCIP_Bool SCIPconsIsDynamic(SCIP_CONS *cons)
SCIP_CONSHDLR * SCIPconsGetHdlr(SCIP_CONS *cons)
SCIP_Bool SCIPconsIsInitial(SCIP_CONS *cons)
SCIP_RETCODE SCIPprintCons(SCIP *scip, SCIP_CONS *cons, FILE *file)
int SCIPconsGetNUpgradeLocks(SCIP_CONS *cons)
SCIP_RETCODE SCIPsetConsSeparated(SCIP *scip, SCIP_CONS *cons, SCIP_Bool separate)
SCIP_Bool SCIPconsIsMarkedPropagate(SCIP_CONS *cons)
SCIP_Bool SCIPconsIsOriginal(SCIP_CONS *cons)
SCIP_Bool SCIPconsIsChecked(SCIP_CONS *cons)
SCIP_Bool SCIPconsIsDeleted(SCIP_CONS *cons)
SCIP_Bool SCIPconsIsTransformed(SCIP_CONS *cons)
int SCIPconsGetNLocksPos(SCIP_CONS *cons)
SCIP_RETCODE SCIPsetConsInitial(SCIP *scip, SCIP_CONS *cons, SCIP_Bool initial)
SCIP_RETCODE SCIPsetConsEnforced(SCIP *scip, SCIP_CONS *cons, SCIP_Bool enforce)
SCIP_Bool SCIPconsIsLockedType(SCIP_CONS *cons, SCIP_LOCKTYPE locktype)
SCIP_Bool SCIPconsIsEnforced(SCIP_CONS *cons)
SCIP_RETCODE SCIPunmarkConsPropagate(SCIP *scip, SCIP_CONS *cons)
SCIP_Bool SCIPconsIsActive(SCIP_CONS *cons)
SCIP_RETCODE SCIPcreateCons(SCIP *scip, SCIP_CONS **cons, const char *name, SCIP_CONSHDLR *conshdlr, SCIP_CONSDATA *consdata, SCIP_Bool initial, SCIP_Bool separate, SCIP_Bool enforce, SCIP_Bool check, SCIP_Bool propagate, SCIP_Bool local, SCIP_Bool modifiable, SCIP_Bool dynamic, SCIP_Bool removable, SCIP_Bool stickingatnode)
SCIP_Bool SCIPconsIsPropagated(SCIP_CONS *cons)
SCIP_Bool SCIPconsIsLocal(SCIP_CONS *cons)
int SCIPconsGetNLocksNeg(SCIP_CONS *cons)
const char * SCIPconsGetName(SCIP_CONS *cons)
SCIP_Bool SCIPconsIsLocked(SCIP_CONS *cons)
SCIP_RETCODE SCIPresetConsAge(SCIP *scip, SCIP_CONS *cons)
SCIP_RETCODE SCIPmarkConsPropagate(SCIP *scip, SCIP_CONS *cons)
SCIP_Bool SCIPconsIsModifiable(SCIP_CONS *cons)
SCIP_RETCODE SCIPupdateConsFlags(SCIP *scip, SCIP_CONS *cons0, SCIP_CONS *cons1)
SCIP_Bool SCIPconsIsStickingAtNode(SCIP_CONS *cons)
SCIP_RETCODE SCIPreleaseCons(SCIP *scip, SCIP_CONS **cons)
SCIP_RETCODE SCIPsetConsPropagated(SCIP *scip, SCIP_CONS *cons, SCIP_Bool propagate)
SCIP_RETCODE SCIPsetConsChecked(SCIP *scip, SCIP_CONS *cons, SCIP_Bool check)
SCIP_Bool SCIPconsIsSeparated(SCIP_CONS *cons)
SCIP_RETCODE SCIPincConsAge(SCIP *scip, SCIP_CONS *cons)
SCIP_Bool SCIPconsIsRemovable(SCIP_CONS *cons)
SCIP_RETCODE SCIPaddRow(SCIP *scip, SCIP_ROW *row, SCIP_Bool forcecut, SCIP_Bool *infeasible)
SCIP_RETCODE SCIPincludeEventhdlrBasic(SCIP *scip, SCIP_EVENTHDLR **eventhdlrptr, const char *name, const char *desc, SCIP_DECL_EVENTEXEC((*eventexec)), SCIP_EVENTHDLRDATA *eventhdlrdata)
const char * SCIPeventhdlrGetName(SCIP_EVENTHDLR *eventhdlr)
SCIP_EVENTTYPE SCIPeventGetType(SCIP_EVENT *event)
SCIP_VARTYPE SCIPeventGetNewtype(SCIP_EVENT *event)
SCIP_RETCODE SCIPcatchVarEvent(SCIP *scip, SCIP_VAR *var, SCIP_EVENTTYPE eventtype, SCIP_EVENTHDLR *eventhdlr, SCIP_EVENTDATA *eventdata, int *filterpos)
SCIP_RETCODE SCIPdropVarEvent(SCIP *scip, SCIP_VAR *var, SCIP_EVENTTYPE eventtype, SCIP_EVENTHDLR *eventhdlr, SCIP_EVENTDATA *eventdata, int filterpos)
SCIP_Real SCIPeventGetOldbound(SCIP_EVENT *event)
SCIP_VAR * SCIPeventGetVar(SCIP_EVENT *event)
SCIP_Real SCIPeventGetNewbound(SCIP_EVENT *event)
SCIP_VARTYPE SCIPeventGetOldtype(SCIP_EVENT *event)
int SCIPexprGetNChildren(SCIP_EXPR *expr)
SCIP_Bool SCIPisExprSum(SCIP *scip, SCIP_EXPR *expr)
SCIP_Real * SCIPgetCoefsExprSum(SCIP_EXPR *expr)
SCIP_Bool SCIPisExprVar(SCIP *scip, SCIP_EXPR *expr)
SCIP_EXPR ** SCIPexprGetChildren(SCIP_EXPR *expr)
SCIP_Real SCIPgetConstantExprSum(SCIP_EXPR *expr)
SCIP_VAR * SCIPgetVarExprVar(SCIP_EXPR *expr)
SCIP_Bool SCIPhasCurrentNodeLP(SCIP *scip)
#define SCIPfreeBlockMemoryArray(scip, ptr, num)
int SCIPcalcMemGrowSize(SCIP *scip, int num)
#define SCIPallocBufferArray(scip, ptr, num)
#define SCIPreallocBufferArray(scip, ptr, num)
#define SCIPfreeBufferArray(scip, ptr)
#define SCIPduplicateBufferArray(scip, ptr, source, num)
#define SCIPallocBlockMemoryArray(scip, ptr, num)
#define SCIPreallocBlockMemoryArray(scip, ptr, oldnum, newnum)
#define SCIPfreeBlockMemory(scip, ptr)
#define SCIPfreeBlockMemoryArrayNull(scip, ptr, num)
#define SCIPallocBlockMemory(scip, ptr)
#define SCIPduplicateBlockMemoryArray(scip, ptr, source, num)
SCIP_RETCODE SCIPdelNlRow(SCIP *scip, SCIP_NLROW *nlrow)
SCIP_RETCODE SCIPaddNlRow(SCIP *scip, SCIP_NLROW *nlrow)
SCIP_Bool SCIPisNLPConstructed(SCIP *scip)
SCIP_RETCODE SCIPreleaseNlRow(SCIP *scip, SCIP_NLROW **nlrow)
SCIP_Bool SCIPnlrowIsInNLP(SCIP_NLROW *nlrow)
SCIP_RETCODE SCIPcreateNlRow(SCIP *scip, SCIP_NLROW **nlrow, const char *name, SCIP_Real constant, int nlinvars, SCIP_VAR **linvars, SCIP_Real *lincoefs, SCIP_EXPR *expr, SCIP_Real lhs, SCIP_Real rhs, SCIP_EXPRCURV curvature)
SCIP_Bool SCIPinProbing(SCIP *scip)
void SCIPlinConsStatsIncTypeCount(SCIP_LINCONSSTATS *linconsstats, SCIP_LINCONSTYPE linconstype, int increment)
void SCIPlinConsStatsReset(SCIP_LINCONSSTATS *linconsstats)
SCIP_Bool SCIProwIsModifiable(SCIP_ROW *row)
SCIP_RETCODE SCIPchgRowLhs(SCIP *scip, SCIP_ROW *row, SCIP_Real lhs)
SCIP_RETCODE SCIPcreateEmptyRowCons(SCIP *scip, SCIP_ROW **row, SCIP_CONS *cons, const char *name, SCIP_Real lhs, SCIP_Real rhs, SCIP_Bool local, SCIP_Bool modifiable, SCIP_Bool removable)
SCIP_RETCODE SCIPaddVarToRow(SCIP *scip, SCIP_ROW *row, SCIP_VAR *var, SCIP_Real val)
SCIP_RETCODE SCIPprintRow(SCIP *scip, SCIP_ROW *row, FILE *file)
SCIP_Real SCIPgetRowSolFeasibility(SCIP *scip, SCIP_ROW *row, SCIP_SOL *sol)
SCIP_RETCODE SCIPreleaseRow(SCIP *scip, SCIP_ROW **row)
SCIP_Real SCIProwGetDualfarkas(SCIP_ROW *row)
SCIP_RETCODE SCIPchgRowRhs(SCIP *scip, SCIP_ROW *row, SCIP_Real rhs)
SCIP_Bool SCIProwIsInLP(SCIP_ROW *row)
SCIP_RETCODE SCIPaddVarsToRow(SCIP *scip, SCIP_ROW *row, int nvars, SCIP_VAR **vars, SCIP_Real *vals)
SCIP_Real SCIProwGetDualsol(SCIP_ROW *row)
SCIP_Real SCIPgetRowSolActivity(SCIP *scip, SCIP_ROW *row, SCIP_SOL *sol)
SCIP_Real SCIPgetSolVal(SCIP *scip, SCIP_SOL *sol, SCIP_VAR *var)
void SCIPupdateSolLPConsViolation(SCIP *scip, SCIP_SOL *sol, SCIP_Real absviol, SCIP_Real relviol)
SCIP_RETCODE SCIPupdateCutoffbound(SCIP *scip, SCIP_Real cutoffbound)
int SCIPgetNSepaRounds(SCIP *scip)
SCIP_Real SCIPgetLowerbound(SCIP *scip)
int SCIPgetNRuns(SCIP *scip)
SCIP_Real SCIPgetCutoffbound(SCIP *scip)
SCIP_Longint SCIPgetNConflictConssApplied(SCIP *scip)
SCIP_RETCODE SCIPgetSymActiveVariables(SCIP *scip, SYM_SYMTYPE symtype, SCIP_VAR ***vars, SCIP_Real **scalars, int *nvars, SCIP_Real *constant, SCIP_Bool transformed)
SCIP_RETCODE SCIPextendPermsymDetectionGraphLinear(SCIP *scip, SYM_GRAPH *graph, SCIP_VAR **vars, SCIP_Real *vals, int nvars, SCIP_CONS *cons, SCIP_Real lhs, SCIP_Real rhs, SCIP_Bool *success)
SCIP_Bool SCIPisUbBetter(SCIP *scip, SCIP_Real newub, SCIP_Real oldlb, SCIP_Real oldub)
SCIP_Bool SCIPisFeasGE(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_Real SCIPinfinity(SCIP *scip)
SCIP_Bool SCIPisGE(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_Bool SCIPisIntegral(SCIP *scip, SCIP_Real val)
SCIP_Bool SCIPisSumRelLE(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_Bool SCIPisSumRelEQ(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_Bool SCIPisFeasEQ(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_Bool SCIPisPositive(SCIP *scip, SCIP_Real val)
SCIP_Bool SCIPisLbBetter(SCIP *scip, SCIP_Real newlb, SCIP_Real oldlb, SCIP_Real oldub)
SCIP_Real SCIPfeasCeil(SCIP *scip, SCIP_Real val)
SCIP_Bool SCIPisLE(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_Bool SCIPisFeasZero(SCIP *scip, SCIP_Real val)
SCIP_Real SCIPfloor(SCIP *scip, SCIP_Real val)
SCIP_Bool SCIPisHugeValue(SCIP *scip, SCIP_Real val)
SCIP_Real SCIPfeasFloor(SCIP *scip, SCIP_Real val)
SCIP_Bool SCIPisInfinity(SCIP *scip, SCIP_Real val)
SCIP_Bool SCIPisFeasLT(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_Bool SCIPisFeasNegative(SCIP *scip, SCIP_Real val)
SCIP_Bool SCIPisFeasLE(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_Bool SCIPisFeasIntegral(SCIP *scip, SCIP_Real val)
SCIP_Real SCIPfeastol(SCIP *scip)
SCIP_Real SCIPgetHugeValue(SCIP *scip)
SCIP_Bool SCIPisGT(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_Bool SCIPisNegative(SCIP *scip, SCIP_Real val)
SCIP_Real SCIPceil(SCIP *scip, SCIP_Real val)
SCIP_Bool SCIPisSumRelGE(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_Bool SCIPisScalingIntegral(SCIP *scip, SCIP_Real val, SCIP_Real scalar)
SCIP_Bool SCIPisFeasGT(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_Bool SCIPisEQ(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_Real SCIPcutoffbounddelta(SCIP *scip)
SCIP_Bool SCIPisUpdateUnreliable(SCIP *scip, SCIP_Real newvalue, SCIP_Real oldvalue)
SCIP_Bool SCIPisZero(SCIP *scip, SCIP_Real val)
SCIP_Real SCIPepsilon(SCIP *scip)
SCIP_Bool SCIPisLT(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_Bool SCIPisSumGT(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_Bool SCIPisFeasPositive(SCIP *scip, SCIP_Real val)
SCIP_Bool SCIPparseReal(SCIP *scip, const char *str, SCIP_Real *value, char **endptr)
SCIP_Bool SCIPinRepropagation(SCIP *scip)
int SCIPgetDepth(SCIP *scip)
SCIP_Bool SCIPvarIsInitial(SCIP_VAR *var)
SCIP_RETCODE SCIPgetProbvarLinearSum(SCIP *scip, SCIP_VAR **vars, SCIP_Real *scalars, int *nvars, int varssize, SCIP_Real *constant, int *requiredsize, SCIP_Bool mergemultiples)
SCIP_RETCODE SCIPtightenVarLb(SCIP *scip, SCIP_VAR *var, SCIP_Real newbound, SCIP_Bool force, SCIP_Bool *infeasible, SCIP_Bool *tightened)
SCIP_RETCODE SCIPvarGetOrigvarSum(SCIP_VAR **var, SCIP_Real *scalar, SCIP_Real *constant)
SCIP_Bool SCIPvarIsDeleted(SCIP_VAR *var)
SCIP_Real SCIPvarGetNegationConstant(SCIP_VAR *var)
SCIP_RETCODE SCIPlockVarCons(SCIP *scip, SCIP_VAR *var, SCIP_CONS *cons, SCIP_Bool lockdown, SCIP_Bool lockup)
SCIP_Real SCIPvarGetMultaggrConstant(SCIP_VAR *var)
SCIP_BOUNDTYPE SCIPvarGetBestBoundType(SCIP_VAR *var)
SCIP_VAR * SCIPvarGetNegatedVar(SCIP_VAR *var)
SCIP_Bool SCIPvarIsActive(SCIP_VAR *var)
SCIP_Bool SCIPvarIsBinary(SCIP_VAR *var)
SCIP_RETCODE SCIPaddClique(SCIP *scip, SCIP_VAR **vars, SCIP_Bool *values, int nvars, SCIP_Bool isequation, SCIP_Bool *infeasible, int *nbdchgs)
SCIP_RETCODE SCIPgetTransformedVars(SCIP *scip, int nvars, SCIP_VAR **vars, SCIP_VAR **transvars)
SCIP_VARSTATUS SCIPvarGetStatus(SCIP_VAR *var)
int SCIPvarGetNLocksUpType(SCIP_VAR *var, SCIP_LOCKTYPE locktype)
SCIP_Real SCIPvarGetAggrConstant(SCIP_VAR *var)
SCIP_Bool SCIPdoNotAggr(SCIP *scip)
SCIP_Real SCIPvarGetUbLocal(SCIP_VAR *var)
SCIP_Bool SCIPdoNotMultaggrVar(SCIP *scip, SCIP_VAR *var)
SCIP_Bool SCIPvarIsTransformed(SCIP_VAR *var)
SCIP_RETCODE SCIPaggregateVars(SCIP *scip, SCIP_VAR *varx, SCIP_VAR *vary, SCIP_Real scalarx, SCIP_Real scalary, SCIP_Real rhs, SCIP_Bool *infeasible, SCIP_Bool *redundant, SCIP_Bool *aggregated)
SCIP_RETCODE SCIPinferVarUbCons(SCIP *scip, SCIP_VAR *var, SCIP_Real newbound, SCIP_CONS *infercons, int inferinfo, SCIP_Bool force, SCIP_Bool *infeasible, SCIP_Bool *tightened)
SCIP_Real SCIPvarGetObj(SCIP_VAR *var)
SCIP_Real SCIPvarGetAggrScalar(SCIP_VAR *var)
SCIP_RETCODE SCIPtightenVarUb(SCIP *scip, SCIP_VAR *var, SCIP_Real newbound, SCIP_Bool force, SCIP_Bool *infeasible, SCIP_Bool *tightened)
SCIP_VARTYPE SCIPvarGetType(SCIP_VAR *var)
SCIP_RETCODE SCIPgetProbvarSum(SCIP *scip, SCIP_VAR **var, SCIP_Real *scalar, SCIP_Real *constant)
SCIP_Real SCIPvarGetUbGlobal(SCIP_VAR *var)
int SCIPvarGetIndex(SCIP_VAR *var)
SCIP_RETCODE SCIPaddVarLocksType(SCIP *scip, SCIP_VAR *var, SCIP_LOCKTYPE locktype, int nlocksdown, int nlocksup)
SCIP_RETCODE SCIPunlockVarCons(SCIP *scip, SCIP_VAR *var, SCIP_CONS *cons, SCIP_Bool lockdown, SCIP_Bool lockup)
SCIP_Real SCIPgetVarUbAtIndex(SCIP *scip, SCIP_VAR *var, SCIP_BDCHGIDX *bdchgidx, SCIP_Bool after)
int SCIPvarGetProbindex(SCIP_VAR *var)
const char * SCIPvarGetName(SCIP_VAR *var)
SCIP_RETCODE SCIPmultiaggregateVar(SCIP *scip, SCIP_VAR *var, int naggvars, SCIP_VAR **aggvars, SCIP_Real *scalars, SCIP_Real constant, SCIP_Bool *infeasible, SCIP_Bool *aggregated)
SCIP_VAR * SCIPbdchginfoGetVar(SCIP_BDCHGINFO *bdchginfo)
SCIP_RETCODE SCIPreleaseVar(SCIP *scip, SCIP_VAR **var)
SCIP_Real SCIPadjustedVarUb(SCIP *scip, SCIP_VAR *var, SCIP_Real ub)
SCIP_RETCODE SCIPparseVarsLinearsum(SCIP *scip, const char *str, SCIP_VAR **vars, SCIP_Real *vals, int *nvars, int varssize, int *requiredsize, char **endptr, SCIP_Bool *success)
SCIP_Real SCIPadjustedVarLb(SCIP *scip, SCIP_VAR *var, SCIP_Real lb)
SCIP_Bool SCIPvarIsIntegral(SCIP_VAR *var)
SCIP_RETCODE SCIPchgVarType(SCIP *scip, SCIP_VAR *var, SCIP_VARTYPE vartype, SCIP_Bool *infeasible)
SCIP_RETCODE SCIPflattenVarAggregationGraph(SCIP *scip, SCIP_VAR *var)
SCIP_VAR ** SCIPvarGetMultaggrVars(SCIP_VAR *var)
int SCIPvarGetMultaggrNVars(SCIP_VAR *var)
SCIP_RETCODE SCIPaddVarImplication(SCIP *scip, SCIP_VAR *var, SCIP_Bool varfixing, SCIP_VAR *implvar, SCIP_BOUNDTYPE impltype, SCIP_Real implbound, SCIP_Bool *infeasible, int *nbdchgs)
SCIP_Bool SCIPvarIsRemovable(SCIP_VAR *var)
SCIP_Real SCIPvarGetLbLocal(SCIP_VAR *var)
SCIP_Bool SCIPvarIsNegated(SCIP_VAR *var)
SCIP_Bool SCIPvarIsRelaxationOnly(SCIP_VAR *var)
SCIP_VAR * SCIPvarGetNegationVar(SCIP_VAR *var)
SCIP_RETCODE SCIPcreateVar(SCIP *scip, SCIP_VAR **var, const char *name, SCIP_Real lb, SCIP_Real ub, SCIP_Real obj, SCIP_VARTYPE vartype, SCIP_Bool initial, SCIP_Bool removable, SCIP_DECL_VARDELORIG((*vardelorig)), SCIP_DECL_VARTRANS((*vartrans)), SCIP_DECL_VARDELTRANS((*vardeltrans)), SCIP_DECL_VARCOPY((*varcopy)), SCIP_VARDATA *vardata)
SCIP_Bool SCIPvarIsOriginal(SCIP_VAR *var)
SCIP_Real SCIPvarGetLbGlobal(SCIP_VAR *var)
SCIP_RETCODE SCIPfixVar(SCIP *scip, SCIP_VAR *var, SCIP_Real fixedval, SCIP_Bool *infeasible, SCIP_Bool *fixed)
SCIP_RETCODE SCIPinferVarLbCons(SCIP *scip, SCIP_VAR *var, SCIP_Real newbound, SCIP_CONS *infercons, int inferinfo, SCIP_Bool force, SCIP_Bool *infeasible, SCIP_Bool *tightened)
SCIP_Real SCIPgetVarLbAtIndex(SCIP *scip, SCIP_VAR *var, SCIP_BDCHGIDX *bdchgidx, SCIP_Bool after)
int SCIPvarCompare(SCIP_VAR *var1, SCIP_VAR *var2)
SCIP_RETCODE SCIPwriteVarName(SCIP *scip, FILE *file, SCIP_VAR *var, SCIP_Bool type)
SCIP_RETCODE SCIPchgVarObj(SCIP *scip, SCIP_VAR *var, SCIP_Real newobj)
SCIP_RETCODE SCIPwriteVarsLinearsum(SCIP *scip, FILE *file, SCIP_VAR **vars, SCIP_Real *vals, int nvars, SCIP_Bool type)
SCIP_Real SCIPbdchginfoGetNewbound(SCIP_BDCHGINFO *bdchginfo)
int SCIPvarGetNLocksDownType(SCIP_VAR *var, SCIP_LOCKTYPE locktype)
SCIP_RETCODE SCIPgetTransformedVar(SCIP *scip, SCIP_VAR *var, SCIP_VAR **transvar)
SCIP_RETCODE SCIPcaptureVar(SCIP *scip, SCIP_VAR *var)
SCIP_Bool SCIPallowStrongDualReds(SCIP *scip)
SCIP_RETCODE SCIPinferVarFixCons(SCIP *scip, SCIP_VAR *var, SCIP_Real fixedval, SCIP_CONS *infercons, int inferinfo, SCIP_Bool force, SCIP_Bool *infeasible, SCIP_Bool *tightened)
SCIP_Real * SCIPvarGetMultaggrScalars(SCIP_VAR *var)
SCIP_VAR * SCIPvarGetAggrVar(SCIP_VAR *var)
void SCIPsortDownRealPtr(SCIP_Real *realarray, void **ptrarray, int len)
void SCIPsortRealInt(SCIP_Real *realarray, int *intarray, int len)
void SCIPsort(int *perm, SCIP_DECL_SORTINDCOMP((*indcomp)), void *dataptr, int len)
int SCIPsnprintf(char *t, int len, const char *s,...)
SCIP_RETCODE SCIPskipSpace(char **s)
assert(minobj< SCIPgetCutoffbound(scip))
static SCIP_Bool propagate
static const SCIP_Real scalars[]
static const char * paramname[]
memory allocation routines
#define BMScopyMemoryArray(ptr, source, num)
#define BMSclearMemoryArray(ptr, num)
struct BMS_BlkMem BMS_BLKMEM
void SCIPmessageFPrintInfo(SCIP_MESSAGEHDLR *messagehdlr, FILE *file, const char *formatstr,...)
BMS_BLKMEM * SCIPblkmem(SCIP *scip)
public methods for conflict analysis handlers
public methods for managing constraints
public methods for managing events
public functions to work with algebraic expressions
public methods for LP management
public methods for message output
#define SCIPstatisticMessage
#define SCIPdebugPrintCons(x, y, z)
public data structures and miscellaneous methods
methods for sorting joint arrays of various types
public methods for problem variables
public methods for branching rule plugins and branching
public methods for conflict handler plugins and conflict analysis
public methods for constraint handler plugins and constraints
public methods for problem copies
public methods for cuts and aggregation rows
public methods for event handler plugins and event handlers
public methods for the LP relaxation, rows and columns
public methods for memory management
public methods for message handling
public methods for numerical tolerances
public methods for SCIP parameter handling
public methods for global and local (sub)problems
public methods for the probing mode
public methods for solutions
public methods for querying solving statistics
public methods for the branch-and-bound tree
public methods for SCIP variables
SCIP_DECL_LINCONSUPGD((*linconsupgd))
structs for symmetry computations
methods for dealing with symmetry detection graphs
#define SCIP_DECL_CONFLICTEXEC(x)
@ SCIP_CONFTYPE_PROPAGATION
#define SCIP_DECL_CONSGETSIGNEDPERMSYMGRAPH(x)
#define SCIP_DECL_CONSGETPERMSYMGRAPH(x)
#define SCIP_DECL_CONSENFOLP(x)
#define SCIP_DECL_CONSDELETE(x)
#define SCIP_DECL_CONSEXIT(x)
#define SCIP_DECL_CONSGETVARS(x)
#define SCIP_DECL_CONSINITSOL(x)
#define SCIP_DECL_CONSPRINT(x)
struct SCIP_ConshdlrData SCIP_CONSHDLRDATA
#define SCIP_DECL_CONSSEPALP(x)
#define SCIP_DECL_CONSENFORELAX(x)
#define SCIP_DECL_CONSPROP(x)
#define SCIP_DECL_CONSGETNVARS(x)
#define SCIP_DECL_CONSRESPROP(x)
@ SCIP_LINCONSTYPE_BINPACKING
@ SCIP_LINCONSTYPE_VARBOUND
@ SCIP_LINCONSTYPE_INVKNAPSACK
@ SCIP_LINCONSTYPE_PRECEDENCE
@ SCIP_LINCONSTYPE_AGGREGATION
@ SCIP_LINCONSTYPE_MIXEDBINARY
@ SCIP_LINCONSTYPE_SINGLETON
@ SCIP_LINCONSTYPE_SETCOVERING
@ SCIP_LINCONSTYPE_EQKNAPSACK
@ SCIP_LINCONSTYPE_KNAPSACK
@ SCIP_LINCONSTYPE_SETPARTITION
@ SCIP_LINCONSTYPE_INTKNAPSACK
@ SCIP_LINCONSTYPE_SETPACKING
@ SCIP_LINCONSTYPE_GENERAL
@ SCIP_LINCONSTYPE_CARDINALITY
#define SCIP_DECL_CONSACTIVE(x)
#define SCIP_DECL_CONSENFOPS(x)
#define SCIP_DECL_CONSPARSE(x)
#define SCIP_DECL_CONSTRANS(x)
#define SCIP_DECL_CONSDEACTIVE(x)
#define SCIP_DECL_CONSPRESOL(x)
#define SCIP_DECL_CONSINITLP(x)
#define SCIP_DECL_CONSEXITPRE(x)
#define SCIP_DECL_CONSLOCK(x)
#define SCIP_DECL_CONSCOPY(x)
#define SCIP_DECL_CONSINIT(x)
struct SCIP_ConsData SCIP_CONSDATA
#define SCIP_DECL_CONSCHECK(x)
#define SCIP_DECL_CONSHDLRCOPY(x)
#define SCIP_DECL_CONSEXITSOL(x)
#define SCIP_DECL_CONSFREE(x)
#define SCIP_DECL_CONSSEPASOL(x)
enum SCIP_LinConstype SCIP_LINCONSTYPE
#define SCIP_DECL_CONSDELVARS(x)
#define SCIP_EVENTTYPE_BOUNDCHANGED
#define SCIP_EVENTTYPE_VARUNLOCKED
#define SCIP_EVENTTYPE_TYPECHANGED
#define SCIP_EVENTTYPE_GUBCHANGED
#define SCIP_EVENTTYPE_GBDCHANGED
struct SCIP_EventData SCIP_EVENTDATA
#define SCIP_EVENTTYPE_UBTIGHTENED
#define SCIP_EVENTTYPE_VARFIXED
#define SCIP_EVENTTYPE_VARDELETED
#define SCIP_DECL_EVENTEXEC(x)
#define SCIP_EVENTTYPE_FORMAT
#define SCIP_EVENTTYPE_GLBCHANGED
#define SCIP_EVENTTYPE_BOUNDRELAXED
#define SCIP_EVENTTYPE_LBCHANGED
#define SCIP_EVENTTYPE_UBCHANGED
#define SCIP_EVENTTYPE_BOUNDTIGHTENED
#define SCIP_EVENTTYPE_LBTIGHTENED
enum SCIP_BoundType SCIP_BOUNDTYPE
#define SCIP_DECL_HASHKEYEQ(x)
#define SCIP_DECL_SORTINDCOMP(x)
#define SCIP_DECL_HASHGETKEY(x)
#define SCIP_DECL_HASHKEYVAL(x)
enum SCIP_Result SCIP_RESULT
enum SCIP_Retcode SCIP_RETCODE
@ SCIP_STAGE_EXITPRESOLVE
@ SCIP_STAGE_TRANSFORMING
enum SYM_Symtype SYM_SYMTYPE
#define SCIP_PRESOLTIMING_EXHAUSTIVE
@ SCIP_VARTYPE_CONTINUOUS
@ SCIP_VARSTATUS_ORIGINAL
@ SCIP_VARSTATUS_MULTAGGR
@ SCIP_VARSTATUS_AGGREGATED
enum SCIP_LockType SCIP_LOCKTYPE
enum SCIP_Vartype SCIP_VARTYPE
enum SCIP_Varstatus SCIP_VARSTATUS