, __FILE__, __LINE__); \
146stage = SCIPgetStage(scip); \
147if( stage == SCIP_STAGE_INIT ) \
149SCIPverbMessage(scip, lvl, NULL, "Init : "); \
151else if( stage == SCIP_STAGE_FREE ) \
153SCIPverbMessage(scip, lvl, NULL, "Free : "); \
155else if( SCIPinProbing(scip) ) \
157SCIPverbMessage(scip, lvl, NULL, "%*sDepth %i: ", \
1582 * SCIPgetProbingDepth(scip), "", SCIPgetProbingDepth(scip)); \
162SCIPverbMessage(scip, lvl, NULL, "Base : "); \
164SCIPverbMessage(scip, lvl, NULL, __VA_ARGS__); \
169#define LABdebugMessagePrint(scip,lvl,...) do \ 171 SCIPverbMessage(scip, lvl, NULL, __VA_ARGS__); \ 175#define LABdebugMessage(scip,lvl,...) 201assert(warmstartinfo !=
NULL);
205(*warmstartinfo)->lpistate =
NULL;
206(*warmstartinfo)->lpinorms =
NULL;
207(*warmstartinfo)->primalfeas =
FALSE;
208(*warmstartinfo)->dualfeas =
FALSE;
233assert(warmstartinfo !=
NULL);
238 if( (*warmstartinfo)->lpistate !=
NULL)
243 if( (*warmstartinfo)->lpinorms !=
NULL)
271assert(candidate !=
NULL);
275(*candidate)->downwarmstartinfo =
NULL;
276(*candidate)->upwarmstartinfo =
NULL;
277(*candidate)->branchvar =
NULL;
290assert(candidate !=
NULL);
317assert(candidate !=
NULL);
321(*candidate)->upwarmstartinfo !=
NULL, (*candidate)->downwarmstartinfo !=
NULL);
343assert(candidate !=
NULL);
385assert(candidate !=
NULL);
402assert(candidate !=
NULL);
457assert(decision !=
NULL);
484assert(decision !=
NULL);
506assert(sourcedecision !=
NULL);
507assert(targetdecision !=
NULL);
513targetdecision->
updb= sourcedecision->
updb;
516targetdecision->
score= sourcedecision->
score;
532assert(decision !=
NULL);
546assert(decision !=
NULL);
569assert(decision !=
NULL);
571 if( (*decision)->boundssize != 0 )
573assert((*decision)->downlowerbounds !=
NULL);
574assert((*decision)->downupperbounds !=
NULL);
575assert((*decision)->uplowerbounds !=
NULL);
576assert((*decision)->upupperbounds !=
NULL);
614assert(resultdata !=
NULL);
629assert(resultdata !=
NULL);
651assert(sourcedata !=
NULL);
652assert(targetdata !=
NULL);
675assert(resultdata !=
NULL);
718assert(data !=
NULL);
719assert(result !=
NULL);
756assert(result !=
NULL);
761 "level 2 result: <%s> %s %g + <%s> %s %g: lpval: %.9g, inf: %d, valid: %d\n",
767#define level2resultPrint(scip,result) 778assert(result !=
NULL);
817assert(data !=
NULL);
821(*data)->level2results =
NULL;
824(*data)->nlevel2results = 0;
825(*data)->level2resultssize = 0;
826(*data)->branchvar1 = 0;
827(*data)->branchvar2 = 0;
828(*data)->branchdir1 = 0;
829(*data)->branchdir2 = 0;
842assert(data !=
NULL);
844 while( (*data)->nlevel2results > 0 )
846--(*data)->nlevel2results;
849assert((*data)->nlevel2results == 0);
851 if( (*data)->level2results !=
NULL)
867assert(data !=
NULL);
891assert(data !=
NULL);
892assert(result !=
NULL);
935assert(data !=
NULL);
936assert(duplicate !=
NULL);
953result->
valid= valid;
1048#if defined(SCIP_DEBUG) || defined(SCIP_STATISTIC) 1049#define MAXRESULT SCIP_DELAYNODE 1053const char* getStatusString(
1057assert(result >= 1);
1058assert(result <= 18);
1063 return "SCIP_DIDNOTRUN";
1065 return "SCIP_DELAYED";
1067 return "SCIP_DIDNOTFIND";
1069 return "SCIP_FEASIBLE";
1071 return "SCIP_INFEASIBLE";
1073 return "SCIP_UNBOUNDED";
1075 return "SCIP_CUTOFF";
1077 return "SCIP_SEPARATED";
1079 return "SCIP_NEWROUND";
1081 return "SCIP_REDUCEDDOM";
1083 return "SCIP_CONSADDED";
1085 return "SCIP_CONSCHANGED";
1087 return "SCIP_BRANCHED";
1089 return "SCIP_SOLVELP";
1091 return "SCIP_FOUNDSOL";
1093 return "SCIP_SUSPENDED";
1095 return "SCIP_SUCCESS";
1097 return "SCIP_DELAYNODE";
1099 SCIPerrorMessage(
"result code %d not treated in lookahead branching rule\n", result);
1106#ifdef SCIP_STATISTIC 1113 int* nsinglecutoffs;
1116 int* nlpssolvedfsb;
1117 int* nduplicatelps;
1123 int* noldbranchused;
1125 int* noldbranchusedfsb;
1127 int* chosenfsbcand;
1131 int* cutoffafterfsb;
1133 int* domredafterfsb;
1135 intnsinglecandidate;
1136 intnsingleafterfilter;
1152 intncutoffproofnodes;
1153 intndomredproofnodes;
1163STATISTICS* statistics
1168assert(statistics !=
NULL);
1169assert(statistics->recursiondepth > 0);
1171statistics->nsinglecandidate = 0;
1172statistics->nsingleafterfilter = 0;
1173statistics->noldcandidate = 0;
1174statistics->nlperrorcalls = 0;
1175statistics->nlimitcalls = 0;
1176statistics->ntotalresults = 0;
1177statistics->nbinconst = 0;
1178statistics->nbinconstvio = 0;
1179statistics->ndomredvio = 0;
1180statistics->ndepthreached = 0;
1181statistics->ndomred = 0;
1182statistics->ndomredcons = 0;
1183statistics->ncutoffproofnodes = 0;
1184statistics->ndomredproofnodes = 0;
1185statistics->ncliquesadded = 0;
1187 for( i = 0; i <= MAXRESULT; i++)
1189statistics->nresults[i] = 0;
1192 for( i = 0; i < statistics->recursiondepth; i++ )
1194statistics->noldbranchused[i] = 0;
1195statistics->noldbranchusedfsb[i] = 0;
1196statistics->npropdomred[i] = 0;
1197statistics->nfullcutoffs[i] = 0;
1198statistics->nlpssolved[i] = 0;
1199statistics->nlpssolvedfsb[i] = 0;
1200statistics->nduplicatelps[i] = 0;
1201statistics->nlpiterations[i] = 0;
1202statistics->nlpiterationsfsb[i] = 0;
1203statistics->nsinglecutoffs[i] = 0;
1204statistics->stopafterfsb[i] = 0;
1205statistics->cutoffafterfsb[i] = 0;
1206statistics->domredafterfsb[i] = 0;
1209 for( i = 0; i < statistics->maxnbestcands; i++ )
1211statistics->chosenfsbcand[i] = 0;
1217voidstatisticsPrint(
1219STATISTICS* statistics
1223assert(statistics !=
NULL);
1224assert(statistics->recursiondepth > 0);
1227 if( statistics->ntotalresults > 0 )
1233 for( i = 1; i <= MAXRESULT; i++ )
1238statistics->nresults[i]);
1241 for( i = 0; i < statistics->maxnbestcands; i++ )
1243 if( statistics->chosenfsbcand[i] > 0 )
1246i+1, statistics->chosenfsbcand[i]);
1250 for( i = 0; i < statistics->recursiondepth; i++ )
1253i, statistics->stopafterfsb[i], statistics->cutoffafterfsb[i], statistics->domredafterfsb[i]);
1255i, statistics->nfullcutoffs[i], statistics->nsinglecutoffs[i]);
1257i, statistics->nlpssolved[i], statistics->nlpssolvedfsb[i], statistics->nduplicatelps[i]);
1259 SCIP_LONGINT_FORMAT "> of them to calculate the FSB score.\n", i, statistics->nlpiterations[i],
1260statistics->nlpiterationsfsb[i]);
1262 " propagation.\n", i, statistics->npropdomred[i]);
1264i, statistics->noldbranchused[i], statistics->noldbranchusedfsb[i]);
1268statistics->nsinglecandidate, statistics->nsingleafterfilter);
1270statistics->noldcandidate);
1272statistics->nlperrorcalls);
1274statistics->nlimitcalls);
1277statistics->ndomredcons);
1279statistics->nbinconst, statistics->nbinconstvio);
1281statistics->ndomred, statistics->ndomredvio);
1283statistics->ncliquesadded);
1285statistics->ncutoffproofnodes);
1287statistics->ndomredproofnodes);
1294 intncutoffproofnodes;
1301LOCALSTATISTICS** localstats
1305assert(localstats !=
NULL);
1309(*localstats)->ncutoffproofnodes = 0;
1316voidlocalStatisticsFree(
1318LOCALSTATISTICS** localstats
1322assert(localstats !=
NULL);
1329structSCIP_BranchruleData
1334#ifdef SCIP_STATISTIC 1335STATISTICS* statistics;
1360assert(conslist !=
NULL);
1361assert(startsize > 0);
1369(*conslist)->nelements = 0;
1370(*conslist)->memorysize = startsize;
1371(*conslist)->nviolatedcons = 0;
1387assert(list !=
NULL);
1388assert(consvars !=
NULL);
1389assert(nconsvars > 0);
1421assert(conslist !=
NULL);
1423 for( i = 0; i < (*conslist)->nelements; i++ )
1457assert(list !=
NULL);
1458assert(startsize > 0);
1464(*list)->nbinaryvars = 0;
1465(*list)->memorysize = startsize;
1479assert(list !=
NULL);
1480assert(vartoadd !=
NULL);
1495assert(list !=
NULL);
1511assert(list !=
NULL);
1534assert(consdata !=
NULL);
1535assert(maxdepth > 0);
1536assert(nstartcons > 0);
1553assert(consdata !=
NULL);
1578assert(candidatelist !=
NULL);
1579assert(ncandidates >= 0);
1583 if( ncandidates > 0 )
1588(*candidatelist)->candidates =
NULL;
1590(*candidatelist)->ncandidates = ncandidates;
1609assert(candidatelist !=
NULL);
1614assert(lpcands !=
NULL);
1615assert(lpcandssol !=
NULL);
1616assert(lpcandsfrac !=
NULL);
1620 for( i = 0; i < nlpcands; i++ )
1625assert(candidate !=
NULL);
1629candidate->
fracval= lpcandsfrac[i];
1631(*candidatelist)->candidates[i] = candidate;
1650assert(candidatelist !=
NULL);
1651assert((*candidatelist)->ncandidates > 0 || (*candidatelist)->candidates ==
NULL);
1653 if( (*candidatelist)->candidates !=
NULL)
1655 for( i = (*candidatelist)->ncandidates - 1; i >= 0; i-- )
1657 CANDIDATE* cand = (*candidatelist)->candidates[i];
1682assert(candidatelist !=
NULL);
1683assert(0 < nindices);
1684assert(nindices <= candidatelist->ncandidates);
1687 for( i = nindices; i < candidatelist->
ncandidates; i++ )
1712#ifdef SCIP_STATISTIC 1713 int* lowerboundnproofs;
1714 int* upperboundnproofs;
1730assert(domreds !=
NULL);
1741#ifdef SCIP_STATISTIC 1746 for( v = 0; v < ntotalvars; ++v )
1753(*domreds)->nviolatedvars = 0;
1754(*domreds)->nchangedvars = 0;
1755(*domreds)->nsimplebounds = 0;
1768assert(domreds !=
NULL);
1770#ifdef SCIP_STATISTIC 1802assert(status !=
NULL);
1806(*status)->addedbinconss =
FALSE;
1807(*status)->depthtoosmall =
FALSE;
1808(*status)->lperror =
FALSE;
1809(*status)->cutoff =
FALSE;
1810(*status)->domred =
FALSE;
1811(*status)->domredcutoff =
FALSE;
1812(*status)->limitreached =
FALSE;
1813(*status)->maxnconsreached =
FALSE;
1826assert(status !=
NULL);
1848assert(scorecontainer !=
NULL);
1866assert(scorecontainer !=
NULL);
1867assert(config !=
NULL);
1881(*scorecontainer)->nbestsortedcands = ncands;
1882(*scorecontainer)->scoresum = 0.0;
1883(*scorecontainer)->nsetscores = 0;
1888 for( i = 0; i < ntotalvars; i++ )
1890(*scorecontainer)->scores[i] = -1.0;
1891(*scorecontainer)->downgains[i] = -1.0;
1892(*scorecontainer)->upgains[i] = -1.0;
1913 intright = ncandidates - 1;
1916assert(scorecontainer !=
NULL);
1917assert(candidates !=
NULL);
1918assert(ncandidates >= 0);
1920 while( left <= right )
1922 intmid = left + ((right - left) / 2);
1926 if( midcand !=
NULL)
1933midscore = scorecontainer->
scores[midindex];
1957assert(scorecontainer !=
NULL);
1958assert(candidate !=
NULL);
1959assert(insertpoint >= 0);
1987assert(scorecontainer !=
NULL);
1988assert(cand !=
NULL);
1992assert(probindex >= 0);
1994 if( scorecontainer->
scores[probindex] < -0.5 )
1997scorecontainer->
scoresum+= score;
2001scorecontainer->
scoresum+= (score - scorecontainer->
scores[probindex]);
2004scorecontainer->
scores[probindex] = score;
2005scorecontainer->
downgains[probindex] = downgain;
2006scorecontainer->
upgains[probindex] = upgain;
2018 if( droppedcandidate !=
NULL)
2036assert(scorecontainer !=
NULL);
2070 int* ndeepestcutoffs,
2075#ifdef SCIP_STATISTIC
2076,STATISTICS* statistics
2077,LOCALSTATISTICS* localstats
2093#ifdef SCIP_STATISTIC
2103assert(var !=
NULL);
2104assert(baselpsol !=
NULL);
2105assert(domainreductions !=
NULL);
2106#ifdef SCIP_STATISTIC 2107assert(nproofnodes >= 0);
2115 if(
SCIPisLT(
scip, domainreductions->lowerbounds[varindex], lowerbound) )
2119domainreductions->lowerbounds[varindex] = lowerbound;
2120domainreductions->nchangedvars++;
2122domainreductions->nsimplebounds++;
2123#ifdef SCIP_STATISTIC 2124domainreductions->lowerboundnproofs[varindex] = nproofnodes;
2129 if(
SCIPisEQ(
scip, domainreductions->lowerbounds[varindex], lowerbound) &&
2130(force || domainreductions->lowerboundnproofs[varindex] > nproofnodes) )
2131domainreductions->lowerboundnproofs[varindex] = nproofnodes;
2140 if(
SCIPisFeasGT(
scip, domainreductions->lowerbounds[varindex], basesolutionval)
2141&& !domainreductions->baselpviolated[varindex] )
2143domainreductions->baselpviolated[varindex] =
TRUE;
2144domainreductions->nviolatedvars++;
2158#ifdef SCIP_STATISTIC
2168assert(var !=
NULL);
2169assert(baselpsol !=
NULL);
2170assert(domainreductions !=
NULL);
2171#ifdef SCIP_STATISTIC 2172assert(nproofnodes >= 0);
2180 if(
SCIPisLE(
scip, domainreductions->upperbounds[varindex], upperbound) )
2182#ifdef SCIP_STATISTIC 2184 if(
SCIPisEQ(
scip, domainreductions->upperbounds[varindex], upperbound) &&
2185(force || domainreductions->upperboundnproofs[varindex] > nproofnodes) )
2186domainreductions->upperboundnproofs[varindex] = nproofnodes;
2193domainreductions->upperbounds[varindex] = upperbound;
2194domainreductions->nchangedvars++;
2196domainreductions->nsimplebounds++;
2197#ifdef SCIP_STATISTIC 2198domainreductions->upperboundnproofs[varindex] = nproofnodes;
2207 if(
SCIPisFeasLT(
scip, domainreductions->upperbounds[varindex], basesolutionval)
2208&& !domainreductions->baselpviolated[varindex] )
2210domainreductions->baselpviolated[varindex] =
TRUE;
2211domainreductions->nviolatedvars++;
2223 intmaxstoredomreds,
2233assert(baselpsol !=
NULL);
2234assert(targetdomreds !=
NULL);
2235assert(domreds !=
NULL);
2241assert(vars !=
NULL);
2244 for( i = 0; i < nvars; i++ )
2249#ifdef SCIP_STATISTIC 2252domreds->lowerboundnproofs[i],
FALSE);
2260#ifdef SCIP_STATISTIC 2262domreds->upperboundnproofs[i],
FALSE);
2277 intmaxstoredomreds,
2288assert(baselpsol !=
NULL);
2289assert(targetdomreds !=
NULL);
2290assert(downdomreds !=
NULL);
2291assert(updomreds !=
NULL);
2297assert(vars !=
NULL);
2309 for( i = 0; i < nvars; i++ )
2314assert(vars[i] !=
NULL);
2323#ifdef SCIP_STATISTIC 2325 MIN(4, downdomreds->lowerboundnproofs[i] + updomreds->lowerboundnproofs[i] + 2),
FALSE);
2337#ifdef SCIP_STATISTIC 2339 MIN(4, downdomreds->upperboundnproofs[i] + updomreds->upperboundnproofs[i] + 2),
FALSE);
2359#ifdef SCIP_STATISTIC
2360,STATISTICS* statistics
2367#if defined(SCIP_DEBUG) || defined(SCIP_STATISTIC) 2368 intnboundsadded = 0;
2369 intnboundsaddedvio = 0;
2373assert(baselpsol !=
NULL);
2374assert(domreds !=
NULL);
2375assert(domredcutoff !=
NULL);
2376assert(domred !=
NULL);
2377#ifdef SCIP_STATISTIC 2378assert(statistics !=
NULL);
2382*domredcutoff =
FALSE;
2388assert(probvars !=
NULL);
2389assert(nprobvars > 0);
2394 for( i = 0; i < nprobvars && !(*domredcutoff); i++ )
2407assert(var !=
NULL);
2425#if defined(SCIP_DEBUG) || defined(SCIP_STATISTIC) 2433*domredcutoff =
TRUE;
2437 else if( tightened )
2441#if defined(SCIP_DEBUG) || defined(SCIP_STATISTIC) 2444#ifdef SCIP_STATISTIC 2447statistics->ndomredproofnodes += domreds->lowerboundnproofs[i];
2450#if defined(SCIP_DEBUG) || defined(SCIP_STATISTIC) 2476#if defined(SCIP_DEBUG) || defined(SCIP_STATISTIC) 2484*domredcutoff =
TRUE;
2488 else if( tightened )
2492#if defined(SCIP_DEBUG) || defined(SCIP_STATISTIC) 2495#ifdef SCIP_STATISTIC 2498statistics->ndomredproofnodes += domreds->upperboundnproofs[i];
2501#if defined(SCIP_DEBUG) || defined(SCIP_STATISTIC) 2514#ifdef SCIP_STATISTIC 2515statistics->ndomred += nboundsadded;
2516statistics->ndomredvio += nboundsaddedvio;
2520 "base lp.\n", nboundsadded, nboundsaddedvio);
2532assert(lpsol !=
NULL);
2557assert(decision !=
NULL);
2558assert(config !=
NULL);
2562assert(bestvar !=
NULL);
2579assert(downchild !=
NULL);
2580assert(upchild !=
NULL);
2612 for( i = 0; i < nvars; i++ )
2619assert(var !=
NULL);
2636 if(
SCIPisLT(
scip, newub, currentub) && var != bestvar )
2650 if(
SCIPisGT(
scip, newlb, currentlb) && var != bestvar)
2688assert(iterations !=
NULL);
2722assert(candidate !=
NULL);
2723assert(resultdata !=
NULL);
2724assert(status !=
NULL);
2725assert(config !=
NULL);
2726assert(status !=
NULL);
2731assert(branchvar !=
NULL);
2734 if( downbranching )
2749 if( downbranching )
2752 "old bounds=[<%g>..<%g>], new bounds=[<%g>..<%g>]\n",
SCIPvarGetName(branchvar), newbound, oldlowerbound,
2753oldupperbound, oldlowerbound, newbound);
2758 "old bounds=[<%g>..<%g>], new bounds=[<%g>..<%g>]\n",
SCIPvarGetName(branchvar), newbound, oldlowerbound,
2759oldupperbound, newbound, oldupperbound);
2763 if( (downbranching && newbound < oldlowerbound - 0.5)
2764|| (!downbranching && newbound > oldupperbound + 0.5) )
2772assert(!resultdata->
cutoff);
2776 if( downbranching )
2815 if( ndomredsfound > 0 )
2820 if( domreds !=
NULL)
2826assert(problemvars !=
NULL);
2830 for( i = 0; i < nproblemvars; i++ )
2835assert(var !=
NULL);
2839#ifdef SCIP_STATISTIC 2851 if( !resultdata->
cutoff)
2870 if( resultdata->
cutoff)
2907 char* constraintname,
2924assert(config !=
NULL);
2925assert(constraint !=
NULL);
2926assert(constraintname !=
NULL);
2927assert(consvars !=
NULL);
2928assert(nconsvars > 0);
2938check, propagate, local, modifiable, dynamic, removable, stickingatnode) );
2949 char* constraintname
2954assert(binaryvars !=
NULL);
2955assert(nbinaryvars > 0);
2956assert(constraintname !=
NULL);
2957assert(binaryvars[0] !=
NULL);
2961 for( i = 1; i < nbinaryvars; i++ )
2965assert(var !=
NULL);
2967oldlen = strlen(constraintname);
2984#ifdef SCIP_STATISTIC
2985,STATISTICS* statistics
2990assert(config !=
NULL);
2991assert(binconsdata !=
NULL);
2992assert(baselpsol !=
NULL);
3012assert(var !=
NULL);
3019violated = (lhssum < 1);
3036#ifdef SCIP_STATISTIC 3039assert(statistics !=
NULL);
3040statistics->ndomredcons++;
3058#ifdef SCIP_STATISTIC
3059,STATISTICS* statistics
3065#ifdef SCIP_STATISTIC 3066 intnvioconsadded = 0;
3068assert(statistics !=
NULL);
3070assert(basenode !=
NULL);
3071assert(conslist !=
NULL);
3072assert(config !=
NULL);
3073assert(consadded !=
NULL);
3074assert(cutoff !=
NULL);
3075assert(boundchange !=
NULL);
3082 for( i = 0; i < conslist->
nelements; i++ )
3087#ifdef SCIP_STATISTIC 3091assert(vars !=
NULL);
3093 for( v = 0; v < nvars; ++v )
3095assert(vars[v] !=
NULL);
3123#ifdef SCIP_STATISTIC 3146#ifdef SCIP_STATISTIC 3147statistics->ncliquesadded++;
3154*boundchange =
TRUE;
3163 if( nconsadded > 0 )
3167#ifdef SCIP_STATISTIC 3168statistics->nbinconst += nconsadded;
3169statistics->nbinconstvio += nvioconsadded;
3186assert(var !=
NULL);
3203assert(status !=
NULL);
3219assert(status !=
NULL);
3220assert(loopcounter !=
NULL);
3224 if( !branchfurther )
3227 returnbranchfurther;
3240assert(config !=
NULL);
3241assert(branchvar !=
NULL);
3269assert(persistent !=
NULL);
3270assert(branchvar !=
NULL);
3271assert(downbranchingresult !=
NULL);
3272assert(upbranchingresult !=
NULL);
3273assert(oldlpobjval !=
NULL);
3296downgain =
MAX(downbranchingresult->
dualbound- *oldlpobjval, 0);
3297upgain =
MAX(upbranchingresult->
dualbound- *oldlpobjval, 0);
3323assert(persistent !=
NULL);
3324assert(branchvar !=
NULL);
3325assert(downbranchingresult !=
NULL);
3326assert(upbranchingresult !=
NULL);
3365#ifdef SCIP_STATISTIC
3366,STATISTICS* statistics
3367,LOCALSTATISTICS* localstats
3372assert(config !=
NULL);
3373assert(candidatelist !=
NULL);
3374assert(status !=
NULL);
3375assert(scorecontainer !=
NULL);
3382#ifdef SCIP_STATISTIC 3384binconsdata, candidatelist, decision, scorecontainer, level2data, 1,
3386statistics, localstats,
NULL,
NULL) );
3389binconsdata, candidatelist, decision, scorecontainer, level2data, 1,
3402voidprintCandidates(
3412assert(candidatelist !=
NULL);
3416LABdebugMessagePrint(
scip, lvl,
"[");
3418 for( i = 0; i < ncands; i++ )
3422assert(cand !=
NULL);
3428LABdebugMessagePrint(
scip, lvl,
", ");
3431LABdebugMessagePrint(
scip, lvl,
"]\n");
3450assert(branchvar !=
NULL);
3451assert(downbranchingresult !=
NULL);
3452assert(upbranchingresult !=
NULL);
3457 if( !downbranchingresult->
cutoff)
3458downgain =
MAX(downgain, downbranchingresult->
dualbound- lpobjval);
3459 if( !upbranchingresult->
cutoff)
3460upgain =
MAX(upgain, upbranchingresult->
dualbound- lpobjval);
3462downgain = 100.0 * downgain;
3463upgain = 100.0 * upgain;
3469 if( downbranchingresult->
cutoff)
3470downgain = 2 * upgain;
3471 if( upbranchingresult->
cutoff)
3472upgain = 2 * downgain;
3496assert(branchvar !=
NULL);
3497assert(downbranchingresult !=
NULL);
3498assert(upbranchingresult !=
NULL);
3503 if( !downbranchingresult->
cutoff)
3504downgain =
MAX(downgain, downbranchingresult->
objval- lpobjval);
3505 if( !upbranchingresult->
cutoff)
3506upgain =
MAX(upgain, upbranchingresult->
objval- lpobjval);
3508downgain = 100.0 * downgain;
3509upgain = 100.0 * upgain;
3515 if( downbranchingresult->
cutoff)
3516downgain = 2 * upgain;
3517 if( upbranchingresult->
cutoff)
3518upgain = 2 * downgain;
3525 if( !downbranchingresult->
cutoff)
3527 if( !upbranchingresult->
cutoff)
3530downgain = 100.0 * downgain;
3531upgain = 100.0 * upgain;
3537 if( downbranchingresult->
cutoff)
3538downgain = 2 * upgain;
3539 if( upbranchingresult->
cutoff)
3540upgain = 2 * downgain;
3563assert(branchvar !=
NULL);
3564assert(downbranchingresult !=
NULL);
3565assert(upbranchingresult !=
NULL);
3570downscore = sqrt(downbranchingresult->
deeperscore);
3576 if( downbranchingresult->
cutoff)
3577downscore = 2 * upscore;
3578 if( upbranchingresult->
cutoff)
3579upscore = 2 * downscore;
3601 intntotaldowngains;
3605assert(branchvar !=
NULL);
3606assert(downbranchingresult !=
NULL);
3607assert(upbranchingresult !=
NULL);
3613totaldowngains = downbranchingresult->
totalgains;
3614totalupgains = upbranchingresult->
totalgains;
3618downscore = sqrt(downbranchingresult->
deeperscore);
3624 if( downbranchingresult->
cutoff)
3625downscore = 2 * upscore;
3626 if( upbranchingresult->
cutoff)
3627upscore = 2 * downscore;
3631downscore = sqrt(totaldowngains/ntotaldowngains);
3632upscore = sqrt(totalupgains/ntotalupgains);
3655assert(config !=
NULL);
3656assert(downbranchingresult !=
NULL);
3657assert(upbranchingresult !=
NULL);
3662 if( !downbranchingresult->
cutoff)
3663downgain =
MAX(0, downbranchingresult->
dualbound- lpobjval);
3664 if( !upbranchingresult->
cutoff)
3665upgain =
MAX(0, upbranchingresult->
dualbound- lpobjval);
3669 if( downbranchingresult->
cutoff)
3671 if( upbranchingresult->
cutoff)
3680 if( downbranchingresult->
cutoff)
3682 if( upbranchingresult->
cutoff)
3703 intnlowestlevelcutoffs;
3704 intntotaldowngains;
3707assert(downbranchingresult !=
NULL);
3708assert(upbranchingresult !=
NULL);
3711bestdowngain = downbranchingresult->
bestgain;
3712bestupgain = upbranchingresult->
bestgain;
3713totaldowngains = downbranchingresult->
totalgains;
3714totalupgains = upbranchingresult->
totalgains;
3718 returnbestdowngain + bestupgain + (totaldowngains/ntotaldowngains + totalupgains/ntotalupgains)*nlowestlevelcutoffs;
3737 intntotaldowngains;
3740assert(downbranchingresult !=
NULL);
3741assert(upbranchingresult !=
NULL);
3744bestdowngain = downbranchingresult->
bestgain;
3745bestupgain = upbranchingresult->
bestgain;
3746totaldowngains = downbranchingresult->
totalgains;
3747totalupgains = upbranchingresult->
totalgains;
3751 returnconfig->
minweight*
MIN(bestdowngain, bestupgain) + (1.0 - config->
minweight)*
MAX(bestdowngain, bestupgain) + (totaldowngains/ntotaldowngains + totalupgains/ntotalupgains)*nlowestlevelcutoffs;
3767 intnlowestlevelcutoffs;
3769assert(downbranchingresult !=
NULL);
3770assert(upbranchingresult !=
NULL);
3772nlowestlevelcutoffs = 0;
3777 if( !downbranchingresult->
cutoff)
3780downgain =
MAX(downgain, downbranchingresult->
dualbound- lpobjval);
3782 if( !upbranchingresult->
cutoff)
3785upgain =
MAX(upgain, upbranchingresult->
dualbound- lpobjval);
3792 if( downbranchingresult->
cutoff)
3795downgain = 2 * upgain;
3797 if( upbranchingresult->
cutoff)
3800upgain = 2 * downgain;
3805downgain = downgain/gap;
3806upgain = upgain/gap;
3829assert(downbranchingresult !=
NULL);
3830assert(upbranchingresult !=
NULL);
3839factor = factor * factor;
3844 if( !downbranchingresult->
cutoff)
3846downgain =
MAX(downgain, downbranchingresult->
dualbound- lpobjval);
3848 if( !upbranchingresult->
cutoff)
3850upgain =
MAX(upgain, upbranchingresult->
dualbound- lpobjval);
3857 if( downbranchingresult->
cutoff)
3859downgain = 2 * upgain;
3861 if( upbranchingresult->
cutoff)
3863upgain = 2 * downgain;
3868downgain = downgain/gap;
3869upgain = upgain/gap;
3889 charscoringfunction;
3892assert(config !=
NULL);
3893assert(branchvar !=
NULL);
3894assert(downbranchingresult !=
NULL);
3895assert(upbranchingresult !=
NULL);
3904 switch( scoringfunction )
3934assert(scoringfunction ==
'd');
3953assert(lpcand !=
NULL);
3966voidprintCandidateList(
3975assert(candidatelist !=
NULL);
3976assert(scorecontainer !=
NULL);
3978 for( i = 0; i < candidatelist->
ncandidates; i++ )
3983assert(var !=
NULL);
4002assert(candidatelist !=
NULL);
4003assert(scorecontainer !=
NULL);
4005assert(nbestcandidates <= candidatelist->ncandidates);
4007 for( i = 1; i < candidatelist->
ncandidates; i++ )
4014assert(movecand !=
NULL);
4017movescore = scorecontainer->
scores[moveprobindex];
4020nsorted =
MIN(i, nbestcandidates);
4024assert(insertionindex <= nsorted);
4029 if( insertionindex != i && insertionindex < nsorted )
4035 for( j = insertionindex; j < nsorted; j++ )
4038assert(oldcand !=
NULL);
4040candidatelist->
candidates[j] = reordercand;
4041reordercand = oldcand;
4044candidatelist->
candidates[i] = reordercand;
4050 "\n", candidatelist->
ncandidates, nbestcandidates);
4051printCandidateList(
scip, candidatelist, scorecontainer);
4068assert(branchvar !=
NULL);
4072size =
MIN(downsize, upsize);
4074 returnsize >= reliable;
4103#ifdef SCIP_STATISTIC
4104,STATISTICS* statistics
4105,LOCALSTATISTICS* localstats
4110 intnunscoredcandidates = 0;
4111 int* candidateunscored;
4114assert(config !=
NULL);
4115assert(status !=
NULL);
4116assert(allcandidates !=
NULL);
4117assert(scorecontainer !=
NULL);
4125 for( i = 0; i < allcandidates->
ncandidates; i++ )
4132assert(lpcand !=
NULL);
4133assert(branchvar !=
NULL);
4157candidateunscored[nunscoredcandidates] = i;
4158nunscoredcandidates++;
4163 if( nunscoredcandidates > 0 )
4171 for( i = 0; i < nunscoredcandidates; i++ )
4173 intcandindex = candidateunscored[i];
4182allcandidates->
ncandidates, nunscoredcandidates);
4189#ifdef SCIP_STATISTIC 4190 SCIP_CALL(
getFSBResult(
scip, status, persistent, config, baselpsol, domainreductions, binconsdata, unscoredcandidates,
4191decision, scorecontainer, level2data, lpobjval, statistics, localstats) );
4193 SCIP_CALL(
getFSBResult(
scip, status, persistent, config, baselpsol, domainreductions, binconsdata, unscoredcandidates,
4194decision, scorecontainer, level2data, lpobjval) );
4198 for( i = 0; i < nunscoredcandidates; i++ )
4200assert(allcandidates->
candidates[candidateunscored[i]] == unscoredcandidates->
candidates[i]);
4235#ifdef SCIP_STATISTIC
4236,STATISTICS* statistics
4237,LOCALSTATISTICS* localstats
4242assert(config !=
NULL);
4243assert(status !=
NULL);
4244assert(candidatelist !=
NULL);
4250assert(scorecontainer !=
NULL);
4259#ifdef SCIP_STATISTIC 4261decision, scorecontainer, level2data, lpobjval, statistics, localstats) );
4264decision, scorecontainer, level2data, lpobjval) );
4287 for( i = 1; i < nusedcands; ++i )
4302 if( bestmaxgain == 0.0 )
4306 for( i = nusedcands - 1; i >= 1; --i )
4315 if( i < nusedcands )
4319candidatelist->
candidates[nusedcands] = tmp;
4328 for( i = 1; i < nusedcands; ++i )
4373#ifdef SCIP_STATISTIC
4374,STATISTICS* statistics
4375,LOCALSTATISTICS* localstats
4387assert(status !=
NULL);
4388assert(config !=
NULL);
4389assert(candidate !=
NULL);
4390assert(branchingresult !=
NULL);
4393branchvalfrac = candidate->
fracval;
4396assert(branchvar !=
NULL);
4401 if( binconsdata !=
NULL&& varisbinary )
4403 if( downbranching )
4415assert(negbranchvar !=
NULL);
4431 if( level2data !=
NULL)
4456 if( result !=
NULL)
4459#ifdef SCIP_STATISTIC 4460statistics->nduplicatelps[probingdepth]++;
4473 "Use old %s branching result on var <%s> with 'val > %g' and bounds [<%g>..<%g>]: objval <%.9g>, cutoff <%d> " 4474 "(the parent objval was <%.9g>)\n",
4496#ifdef SCIP_STATISTIC 4497statistics->nlpssolved[probingdepth]++;
4498statistics->nlpiterations[probingdepth] += branchingresult->
niterations;
4502statistics->nlpssolvedfsb[probingdepth]++;
4503statistics->nlpiterationsfsb[probingdepth] += branchingresult->
niterations;
4514 else if( branchingresult->
cutoff)
4521 "<%.9g>)\n", branchingresult->
objval, localbaselpsolval);
4530localgain =
MAX(0, branchingresult->
objval- localbaselpsolval);
4533 if( downbranching )
4554 if( recursiondepth > 1 && !config->
inscoring)
4559assert(candidatelist !=
NULL);
4570#ifdef SCIP_STATISTIC 4571LOCALSTATISTICS* deeperlocalstats;
4573 SCIP_CALL( localStatisticsAllocate(
scip, &deeperlocalstats) );
4579#ifdef SCIP_STATISTIC 4581deeperdecision, scorecontainer, level2data, deeperlpobjval,
4582statistics, localstats) );
4585deeperdecision, scorecontainer, level2data, deeperlpobjval) );
4592 if( deeperstatus->
cutoff)
4603#ifdef SCIP_STATISTIC 4604deeperlocalstats->ncutoffproofnodes = 0;
4606binconsdata, candidatelist, deeperdecision, scorecontainer, level2data, recursiondepth - 1,
4610statistics, deeperlocalstats,
NULL,
NULL) );
4613binconsdata, candidatelist, deeperdecision, scorecontainer, level2data, recursiondepth - 1,
4631#ifdef SCIP_STATISTIC 4636statistics->stopafterfsb[probingdepth+1]++;
4638 if( deeperstatus->
cutoff)
4640statistics->cutoffafterfsb[probingdepth+1]++;
4642 else if( deeperstatus->
domred)
4644statistics->domredafterfsb[probingdepth+1]++;
4649 if( deeperstatus->
cutoff)
4652#ifdef SCIP_STATISTIC 4653localstats->ncutoffproofnodes += deeperlocalstats->ncutoffproofnodes;
4656 "cutoff\n", downbranching ?
"down":
"up");
4661#ifdef SCIP_STATISTIC 4662localStatisticsFree(
scip, &deeperlocalstats);
4673 if( recursiondepth == 1 && !config->
inscoring)
4677 if( branchingresult->
cutoff)
4683 if( binconsdata !=
NULL&& varisbinary )
4689#ifdef SCIP_STATISTIC 4723 int* ndeepestcutoffs,
4730#ifdef SCIP_STATISTIC
4731,STATISTICS* statistics
4732,LOCALSTATISTICS* localstats
4755assert(status !=
NULL);
4756assert(config !=
NULL);
4758assert(candidatelist !=
NULL);
4760assert(decision !=
NULL);
4761assert(recursiondepth >= 1);
4762#ifdef SCIP_STATISTIC 4763assert(statistics !=
NULL);
4765 if( firstscoreptr !=
NULL)
4766*firstscoreptr = -1.0;
4767 if( bestscoreptr !=
NULL)
4768*bestscoreptr = -1.0;
4773assert(probingdepth >= 0 && probingdepth < config->recursiondepth);
4781decision->
downdb= lpobjval;
4783decision->
updb= lpobjval;
4786decision->
score= 0.0;
4797assert(downbranchingresult !=
NULL);
4798assert(upbranchingresult !=
NULL);
4803stopafterinfeasible = !stopafterinfeasible;
4827 for( i = 0, c = start;
4844assert(candidate !=
NULL);
4849assert(branchvar !=
NULL);
4860#ifdef SCIP_STATISTIC 4861statistics->npropdomred[probingdepth]++;
4870#ifdef SCIP_STATISTIC 4874localstats->ncutoffproofnodes = 0;
4885useoldbranching =
TRUE;
4886#ifdef SCIP_STATISTIC 4888statistics->noldbranchusedfsb[probingdepth]++;
4890statistics->noldbranchused[probingdepth]++;
4911 for( k = 0; k < 2; ++k )
4917localdomainreductions = down ? downdomainreductions : updomainreductions;
4918localbranchingresult = down ? downbranchingresult : upbranchingresult;
4919otherbranchingresult = down ? upbranchingresult : downbranchingresult;
4921#ifdef SCIP_STATISTIC 4923recursiondepth, localdomainreductions, binconsdata, level2data, localbranchingresult, scorecontainer,
4924down, statistics, localstats) );
4928recursiondepth, localdomainreductions, binconsdata, level2data, localbranchingresult, scorecontainer,
4939 "The %s branching changed the cutoffbound and rendered the %s branching result infeasible.\n",
4940down ?
"down":
"up", down ?
"up":
"down");
4943 if( stopafterinfeasible && k == 0 && localbranchingresult->
cutoff)
4951 "(gain=%.9g, valid=%u, inf=%u)\n", downbranchingresult->
dualbound,
4956 if( niterations !=
NULL)
4960 if( persistent !=
NULL&& !upbranchingresult->
cutoff&& !downbranchingresult->
cutoff&& (config->
inscoring|| probingdepth == 0) )
4963upbranchingresult, lpobjval) );
4967 if( ndeepestcutoffs !=
NULL)
4970 if( ndeepestnodes !=
NULL)
4975 SCIP_Realscoringlpobjval = useoldbranching ? oldlpobjval : lpobjval;
4977scoringlpobjval, baselpobjval);
4979#ifdef SCIP_STATISTIC 4980 if( i == 0 && firstscoreptr !=
NULL)
4981*firstscoreptr = score;
4986assert(totalgains !=
NULL);
4987assert(ntotalgains !=
NULL);
4989*bestgain =
MAX(*bestgain, score);
4991 if( !downbranchingresult->
cutoff&& !upbranchingresult->
cutoff)
4993(*totalgains) += score;
5006#ifdef SCIP_STATISTIC 5007statistics->nfullcutoffs[probingdepth]++;
5008localstats->ncutoffproofnodes += 2;
5022#ifdef SCIP_STATISTIC 5023assert(localstats->ncutoffproofnodes == 0 || localstats->ncutoffproofnodes == 2);
50252 + localstats->ncutoffproofnodes,
TRUE);
5037#ifdef SCIP_STATISTIC 5038statistics->nsinglecutoffs[probingdepth]++;
5052#ifdef SCIP_STATISTIC 5053assert(localstats->ncutoffproofnodes == 0 || localstats->ncutoffproofnodes == 2);
50552 + localstats->ncutoffproofnodes,
TRUE);
5067#ifdef SCIP_STATISTIC 5068statistics->nsinglecutoffs[probingdepth]++;
5087 intmaxstoredomreds = INT_MAX;
5089assert(downdomainreductions !=
NULL);
5096updomainreductions);
5097 else if( upbranchingresult->
cutoff&& !downbranchingresult->
cutoff)
5099 else if( downbranchingresult->
cutoff&& !upbranchingresult->
cutoff)
5113bestscoringlpobjval, baselpobjval);
5115 if( newscore > bestscore )
5117bestscore = newscore;
5119#ifdef SCIP_STATISTIC 5120 if( bestscoreptr !=
NULL)
5121*bestscoreptr = newscore;
5123decision->
score= newscore;
5139#ifdef SCIP_STATISTIC 5140 if( bestscoreptr !=
NULL)
5141*bestscoreptr = score;
5149decision->
score= score;
5157assert(downdomainreductions !=
NULL);
5172bestscorelowerbound = branchlb;
5173bestscoreupperbound = branchub;
5174bestscoringlpobjval = scoringlpobjval;
5175assert(!
SCIPisEQ(
scip, bestscorelowerbound, bestscoreupperbound));
5183 " score=%.9g) -- best: <%s> (%.9g)\n", c, nlpcands,
SCIPvarGetName(branchvar), branchval,
5184 MAX(downbranchingresult->
objval- scoringlpobjval, 0),
MAX(downbranchingresult->
dualbound- scoringlpobjval, 0),
5185 MAX(upbranchingresult->
objval- scoringlpobjval, 0),
MAX(upbranchingresult->
dualbound- scoringlpobjval, 0),
5191assert(scorecontainer !=
NULL);
5197downbranchingresult->
dualbound- scoringlpobjval, upbranchingresult->
dualbound- scoringlpobjval) );
5200 if( probingdepth == 0 && (binconsdata !=
NULL|| domainreductions !=
NULL) && !useoldbranching
5206 if( binconsdata !=
NULL)
5208assert(binconsdata !=
NULL);
5221 if( domainreductions !=
NULL)
5223assert(domainreductions !=
NULL);
5254#ifdef SCIP_STATISTIC 5255statistics->npropdomred[probingdepth]++;
5262 if( updomainreductions !=
NULL)
5264assert(downdomainreductions !=
NULL);
5296assert(config !=
NULL);
5324#ifdef SCIP_STATISTIC
5325,STATISTICS* statistics
5326,LOCALSTATISTICS* localstats
5336#ifdef SCIP_STATISTIC 5339 intchosencandnr = -1;
5344assert(config !=
NULL);
5345assert(status !=
NULL);
5346assert(decision !=
NULL);
5347assert(candidatelist !=
NULL);
5348#ifdef SCIP_STATISTIC 5349assert(statistics !=
NULL);
5355assert(recursiondepth > 0);
5363#ifdef SCIP_STATISTIC 5364statistics->ndepthreached++;
5375decision->
downdb= lpobjval;
5377decision->
updb= lpobjval;
5384#ifdef SCIP_STATISTIC 5385statistics->nsinglecandidate++;
5417#ifdef SCIP_STATISTIC 5419decision, scorecontainer, level2data, lpobjval,
5420statistics, localstats) );
5423decision, scorecontainer, level2data, lpobjval) );
5430decision->
downdb= lpobjval;
5432decision->
updb= lpobjval;
5439#ifdef SCIP_STATISTIC 5440statistics->nsingleafterfilter++;
5459#ifdef SCIP_STATISTIC 5461decision, scorecontainer, level2data, recursiondepth, lpobjval, lpobjval,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
5462statistics, localstats, &firstscore, &bestscore) );
5465decision, scorecontainer, level2data, recursiondepth, lpobjval, lpobjval,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL) );
5468 if( level2data !=
NULL)
5487#ifdef SCIP_STATISTIC 5493assert(candidatelist->
ncandidates<= statistics->maxnbestcands);
5496 for( chosencandnr = 0; chosencandnr < candidatelist->
ncandidates; ++chosencandnr )
5503assert(chosencandnr < candidatelist->ncandidates);
5509 intprobingdepth = 0;
5512statistics->stopafterfsb[probingdepth]++;
5516statistics->cutoffafterfsb[probingdepth]++;
5520statistics->domredafterfsb[probingdepth]++;
5532 if( domainreductions !=
NULL)
5539#ifdef SCIP_STATISTIC 5541&status->
domred, statistics) );
5551 if( binconsdata !=
NULL)
5561#ifdef SCIP_STATISTIC 5577#if defined(SCIP_DEBUG) || defined(SCIP_STATISTIC) 5584#ifdef SCIP_STATISTIC 5586statistics->nsingleafterfilter--;
5593#ifdef SCIP_STATISTIC 5595statistics->nsingleafterfilter--;
5598 else if( status->
cutoff)
5609#ifdef SCIP_STATISTIC 5610 if( chosencandnr >= 0 )
5612++statistics->chosenfsbcand[chosencandnr];
5618bestscore, firstscore);
5621assert(!performedlab);
5636 if( baselpsol !=
NULL)
5659assert(branchruledata !=
NULL);
5661persistent = branchruledata->persistent;
5662assert(persistent !=
NULL);
5665 "nodes=%lld (old=%lld), iterations=%lld (old=%lld), lps=%lld (old=%lld)\n",
5694assert(branchruledata !=
NULL);
5695assert(result !=
NULL);
5696assert(branchruledata->config !=
NULL);
5697assert(branchruledata->persistent !=
NULL);
5698assert(branchruledata->persistent->olddecision !=
NULL);
5707 SCIPvarGetName(branchruledata->persistent->olddecision->branchvar));
5710branchruledata->persistent->olddecision->branchvar =
NULL;
5727assert(branchruledata !=
NULL);
5729persistent = branchruledata->persistent;
5730assert(persistent !=
NULL);
5732nvars = persistent->
nvars;
5734 for( i = nvars - 1; i >= 0; i--)
5757branchruledata->isinitialized =
FALSE;
5773assert(branchruledata !=
NULL);
5776 if( branchruledata->isinitialized &&
5780 if( branchruledata->isinitialized )
5797branchruledata->persistent->nvars = nvars;
5798branchruledata->persistent->oldntotalnodes = -1;
5799branchruledata->persistent->oldnnodelpiterations = -1;
5800branchruledata->persistent->oldnnodelps = -1;
5805 for( i = 0; i < nvars; i++ )
5807branchruledata->persistent->lastbranchid[i] = -1;
5808branchruledata->persistent->lastbranchnlps[i] = 0;
5814branchruledata->isinitialized =
TRUE;
5830assert(branchrule !=
NULL);
5846assert(branchruledata !=
NULL);
5847assert(branchruledata->config !=
NULL);
5848assert(branchruledata->persistent !=
NULL);
5865assert(branchrule !=
NULL);
5870assert(branchruledata !=
NULL);
5871assert(branchruledata->persistent !=
NULL);
5873branchruledata->persistent->restartindex = 0;
5875#ifdef SCIP_STATISTIC 5882recursiondepth = branchruledata->config->recursiondepth;
5883maxncands = branchruledata->config->maxncands;
5904branchruledata->statistics->recursiondepth = recursiondepth;
5905branchruledata->statistics->maxnbestcands = maxncands;
5907statisticsInit(branchruledata->statistics);
5921#ifdef SCIP_STATISTIC 5923STATISTICS* statistics;
5926assert(branchruledata !=
NULL);
5928statistics = branchruledata->statistics;
5929assert(statistics !=
NULL);
5931statisticsPrint(
scip, statistics);
5961assert(branchruledata !=
NULL);
5963 if( branchruledata->isinitialized )
5979assert(branchrule !=
NULL);
5982assert(result !=
NULL);
5987assert(branchruledata !=
NULL);
5989config = branchruledata->config;
6004#ifdef SCIP_STATISTIC 6005branchruledata->statistics->noldcandidate++;
6014#ifdef SCIP_STATISTIC 6015LOCALSTATISTICS* localstats;
6035#ifdef SCIP_STATISTIC 6039scorecontainer, candidatelist, branchruledata->statistics, localstats) );
6042scorecontainer, candidatelist) );
6048#ifdef SCIP_STATISTIC 6049branchruledata->statistics->ncutoffproofnodes += localstats->ncutoffproofnodes;
6058 else if( status->
domred)
6064#ifdef SCIP_STATISTIC 6065++branchruledata->statistics->nlperrorcalls;
6083#ifdef SCIP_STATISTIC 6086++branchruledata->statistics->nlimitcalls;
6131 "problem is infeasible.\n");
6140 "lookahead branching.\n");
6148#ifdef SCIP_STATISTIC 6149localStatisticsFree(
scip, &localstats);
6154 if( scorecontainer !=
NULL)
6162#ifdef SCIP_STATISTIC 6163assert(*result >= 1);
6164assert(*result <= MAXRESULT);
6165branchruledata->statistics->ntotalresults++;
6166branchruledata->statistics->nresults[*result]++;
6173sum = branchruledata->statistics->nsinglecandidate + branchruledata->statistics->nsingleafterfilter
6174+ branchruledata->statistics->noldcandidate + branchruledata->statistics->nlperrorcalls
6175+ branchruledata->statistics->nlimitcalls;
6177 for( i = 0; i < branchruledata->statistics->maxnbestcands; i++ )
6179sum += branchruledata->statistics->chosenfsbcand[i];
6181 if( sum != branchruledata->statistics->nresults[
SCIP_BRANCHED] )
6183printf(
"branched = %d != sum = %d (%d/%d/%d/%d/%d)\n",
6185branchruledata->statistics->nsinglecandidate, branchruledata->statistics->nsingleafterfilter,
6186branchruledata->statistics->noldcandidate,
6187branchruledata->statistics->nlperrorcalls, branchruledata->statistics->nlimitcalls);
6190assert(sum == branchruledata->statistics->nresults[
SCIP_BRANCHED]);
6194branchruledata->statistics->ncutoffproofnodes, branchruledata->statistics->ndomredproofnodes);
6219branchruledata->persistent->restartindex = 0;
6220branchruledata->isinitialized =
FALSE;
6221branchruledata->config->inscoring =
FALSE;
6227assert(branchrule !=
NULL);
6239 "branching/lookahead/useimpliedbincons",
6240 "should binary constraints be collected and applied?",
6243 "branching/lookahead/addbinconsrow",
6244 "should binary constraints be added as rows to the base LP? (0: no, 1: separate, 2: as initial rows)",
6247 "how many constraints that are violated by the base lp solution should be gathered until the rule is stopped and "\
6248 "they are added? [0 for unrestricted]",
6251 "how many binary constraints that are violated by the base lp solution should be gathered until the rule is "\
6252 "stopped and they are added? [0 for unrestricted]",
6255 "how many domain reductions that are violated by the base lp solution should be gathered until the rule is "\
6256 "stopped and they are added? [0 for unrestricted]",
6259 "branching/lookahead/reevalage",
6260 "max number of LPs solved after which a previous prob branching results are recalculated",
6263 "branching/lookahead/reevalagefsb",
6264 "max number of LPs solved after which a previous FSB scoring results are recalculated",
6267 "the max depth of LAB.",
6270 "branching/lookahead/usedomainreduction",
6271 "should domain reductions be collected and applied?",
6274 "branching/lookahead/mergedomainreductions",
6275 "should domain reductions of feasible siblings should be merged?",
6278 "branching/lookahead/prefersimplebounds",
6279 "should domain reductions only be applied if there are simple bound changes?",
6282 "branching/lookahead/onlyvioldomreds",
6283 "should only domain reductions that violate the LP solution be applied?",
6286 "branching/lookahead/addnonviocons",
6287 "should binary constraints, that are not violated by the base LP, be collected and added?",
6290 "branching/lookahead/abbreviated",
6291 "toggles the abbreviated LAB.",
6294 "if abbreviated: The max number of candidates to consider at the node.",
6297 "if abbreviated: The max number of candidates to consider per deeper node.",
6300 "branching/lookahead/reusebasis",
6301 "if abbreviated: Should the information gathered to obtain the best candidates be reused?",
6304 "branching/lookahead/storeunviolatedsol",
6305 "if only non violating constraints are added, should the branching decision be stored till the next call?",
6308 "branching/lookahead/abbrevpseudo",
6309 "if abbreviated: Use pseudo costs to estimate the score of a candidate.",
6312 "branching/lookahead/level2avgscore",
6313 "should the average score be used for uninitialized scores in level 2?",
6316 "branching/lookahead/level2zeroscore",
6317 "should uninitialized scores in level 2 be set to 0?",
6320 "branching/lookahead/addclique",
6321 "add binary constraints with two variables found at the root node also as a clique",
6324 "branching/lookahead/propagate",
6325 "should domain propagation be executed before each temporary node is solved?",
6328 "branching/lookahead/uselevel2data",
6329 "should branching data generated at depth level 2 be stored for re-using it?",
6332 "branching/lookahead/applychildbounds",
6333 "should bounds known for child nodes be applied?",
6336 "branching/lookahead/enforcemaxdomreds",
6337 "should the maximum number of domain reductions maxnviolateddomreds be enforced?",
6340 "branching/lookahead/updatebranchingresults",
6341 "should branching results (and scores) be updated w.r.t. proven dual bounds?",
6344 "branching/lookahead/maxproprounds",
6345 "maximum number of propagation rounds to perform at each temporary node (-1: unlimited, 0: SCIP default)",
6348 "branching/lookahead/scoringfunction",
6349 "scoring function to be used at the base level",
6352 "branching/lookahead/deeperscoringfunction",
6353 "scoring function to be used at deeper levels",
6356 "branching/lookahead/scoringscoringfunction",
6357 "scoring function to be used during FSB scoring",
6360 "branching/lookahead/minweight",
6361 "if scoringfunction is 's', this value is used to weight the min of the gains of two child problems in the convex combination",
6364 "branching/lookahead/worsefactor",
6365 "if the FSB score is of a candidate is worse than the best by this factor, skip this candidate (-1: disable)",
6368 "branching/lookahead/filterbymaxgain",
6369 "should lookahead branching only be applied if the max gain in level 1 is not uniquely that of the best candidate?",
static SCIP_RETCODE selectVarStart(SCIP *scip, CONFIGURATION *config, PERSISTENTDATA *persistent, STATUS *status, BRANCHINGDECISION *decision, SCORECONTAINER *scorecontainer, CANDIDATELIST *candidatelist)
static SCIP_Bool isCandidateReliable(SCIP *scip, SCIP_VAR *branchvar)
static SCIP_DECL_BRANCHFREE(branchFreeLookahead)
static SCIP_Bool warmStartInfoIsAvailable(WARMSTARTINFO *warmstartinfo)
static void domainReductionsFree(SCIP *scip, DOMAINREDUCTIONS **domreds)
#define DEFAULT_USEBINARYCONSTRAINTS
static SCIP_RETCODE branchingDecisionEnsureBoundArraysSize(SCIP *scip, BRANCHINGDECISION *decision, int nvars)
static void binConsDataFree(SCIP *scip, BINCONSDATA **consdata)
static void level2resultFree(SCIP *scip, LEVEL2RESULT **result)
static SCIP_RETCODE getOldBranching(SCIP *scip, PERSISTENTDATA *persistent, CONFIGURATION *config, SCIP_VAR *branchvar, BRANCHINGRESULTDATA *downbranchingresult, BRANCHINGRESULTDATA *upbranchingresult, SCIP_Real *oldlpobjval)
#define DEFAULT_UPDATEBRANCHINGRESULTS
#define BRANCHRULE_PRIORITY
static SCIP_RETCODE scoreContainerCreate(SCIP *scip, SCORECONTAINER **scorecontainer, CONFIGURATION *config)
static SCIP_RETCODE applyDomainReductions(SCIP *scip, CONFIGURATION *config, SCIP_SOL *baselpsol, DOMAINREDUCTIONS *domreds, SCIP_Bool *domredcutoff, SCIP_Bool *domred)
#define DEFAULT_PROPAGATE
static SCIP_Real calculateScaledCutoffScore(BRANCHINGRESULTDATA *downbranchingresult, BRANCHINGRESULTDATA *upbranchingresult)
static SCIP_DECL_BRANCHINIT(branchInitLookahead)
static SCIP_RETCODE level2dataEnsureSize(SCIP *scip, LEVEL2DATA *data)
#define DEFAULT_DEEPERSCORINGFUNCTION
static SCIP_RETCODE executeBranching(SCIP *scip, CONFIGURATION *config, SCIP_Bool downbranching, CANDIDATE *candidate, BRANCHINGRESULTDATA *resultdata, SCIP_SOL *baselpsol, DOMAINREDUCTIONS *domreds, STATUS *status)
static SCIP_RETCODE statusCreate(SCIP *scip, STATUS **status)
static void addLowerBound(SCIP *scip, SCIP_VAR *var, SCIP_Real lowerbound, SCIP_SOL *baselpsol, SCIP_Bool simplechange, DOMAINREDUCTIONS *domainreductions)
static SCIP_Real calculateScoreFromPseudocosts(SCIP *scip, CANDIDATE *lpcand)
#define DEFAULT_SCORINGFUNCTION
static void createBinaryConstraintName(SCIP_VAR **binaryvars, int nbinaryvars, char *constraintname)
static SCIP_RETCODE executeBranchingRecursive(SCIP *scip, STATUS *status, CONFIGURATION *config, SCIP_SOL *baselpsol, CANDIDATE *candidate, SCIP_Real localbaselpsolval, SCIP_Real baselpobjval, int recursiondepth, DOMAINREDUCTIONS *domainreductions, BINCONSDATA *binconsdata, LEVEL2DATA *level2data, BRANCHINGRESULTDATA *branchingresult, SCORECONTAINER *scorecontainer, SCIP_Bool downbranching)
static void binaryVarListDrop(BINARYVARLIST *list)
#define DEFAULT_USELEVEL2DATA
static SCIP_Bool areBoundsChanged(SCIP *scip, SCIP_VAR *var, SCIP_Real lowerbound, SCIP_Real upperbound)
static SCIP_Bool isBranchFurther(STATUS *status, SCIP_Bool checkdomreds)
#define DEFAULT_ENFORCEMAXDOMREDS
static SCIP_RETCODE branchingResultDataCreate(SCIP *scip, BRANCHINGRESULTDATA **resultdata)
static SCIP_RETCODE domainReductionsCreate(SCIP *scip, DOMAINREDUCTIONS **domreds)
static SCIP_RETCODE copyCurrentSolution(SCIP *scip, SCIP_SOL **lpsol)
static SCIP_DECL_BRANCHEXIT(branchExitLookahead)
#define DEFAULT_ABBREVIATED
static SCIP_RETCODE warmStartInfoFree(SCIP *scip, WARMSTARTINFO **warmstartinfo)
#define DEFAULT_MERGEDOMAINREDUCTIONS
static void branchingResultDataCopy(BRANCHINGRESULTDATA *sourcedata, BRANCHINGRESULTDATA *targetdata)
static SCIP_RETCODE applyBinaryConstraints(SCIP *scip, SCIP_NODE *basenode, CONSTRAINTLIST *conslist, CONFIGURATION *config, SCIP_Bool *consadded, SCIP_Bool *cutoff, SCIP_Bool *boundchange)
static SCIP_RETCODE scoreContainerFree(SCIP *scip, SCORECONTAINER **scorecontainer)
#define DEFAULT_ADDCLIQUE
#define DEFAULT_REEVALAGE
#define DEFAULT_REEVALAGEFSB
static SCIP_RETCODE constraintListCreate(SCIP *scip, CONSTRAINTLIST **conslist, int startsize)
static SCIP_Real calculateScoreFromDeeperscoreAndCutoffs(SCIP *scip, SCIP_VAR *branchvar, BRANCHINGRESULTDATA *downbranchingresult, BRANCHINGRESULTDATA *upbranchingresult)
static void scoreContainterResetBestSortedCands(SCORECONTAINER *scorecontainer)
static SCIP_Bool isUsePreviousResult(SCIP *scip, SCIP_BRANCHRULEDATA *branchruledata)
static SCIP_DECL_BRANCHEXECLP(branchExeclpLookahead)
static SCIP_RETCODE ensureScoresPresent(SCIP *scip, STATUS *status, PERSISTENTDATA *persistent, CONFIGURATION *config, SCIP_SOL *baselpsol, DOMAINREDUCTIONS *domainreductions, BINCONSDATA *binconsdata, CANDIDATELIST *allcandidates, BRANCHINGDECISION *decision, SCORECONTAINER *scorecontainer, LEVEL2DATA *level2data, SCIP_Real lpobjval)
static SCIP_RETCODE candidateCreate(SCIP *scip, CANDIDATE **candidate)
#define DEFAULT_MAXNDEEPERCANDS
static SCIP_RETCODE candidateListCreate(SCIP *scip, CANDIDATELIST **candidatelist, int ncandidates)
static SCIP_Bool isBranchFurtherLoopDecrement(STATUS *status, int *loopcounter)
static void binaryVarListAppend(SCIP *scip, BINARYVARLIST *list, SCIP_VAR *vartoadd)
#define level2resultPrint(scip, result)
static SCIP_Bool level2resultEqual(LEVEL2RESULT *result1, LEVEL2RESULT *result2)
static SCIP_Real calculateScore(SCIP *scip, CONFIGURATION *config, SCIP_VAR *branchvar, BRANCHINGRESULTDATA *downbranchingresult, BRANCHINGRESULTDATA *upbranchingresult, SCIP_Real lpobjval, SCIP_Real baselpobjval)
static SCIP_DECL_BRANCHCOPY(branchCopyLookahead)
static SCIP_RETCODE usePreviousResult(SCIP *scip, SCIP_BRANCHRULEDATA *branchruledata, SCIP_RESULT *result)
static SCIP_RETCODE level2resultCreateFromData(SCIP *scip, LEVEL2DATA *data, LEVEL2RESULT **result)
static SCIP_RETCODE candidateListKeep(SCIP *scip, CANDIDATELIST *candidatelist, int nindices)
static SCIP_RETCODE filterCandidates(SCIP *scip, STATUS *status, PERSISTENTDATA *persistent, CONFIGURATION *config, SCIP_SOL *baselpsol, DOMAINREDUCTIONS *domainreductions, BINCONSDATA *binconsdata, CANDIDATELIST *candidatelist, BRANCHINGDECISION *decision, SCORECONTAINER *scorecontainer, LEVEL2DATA *level2data, SCIP_Real lpobjval)
#define DEFAULT_APPLYCHILDBOUNDS
static SCIP_Real calculateScoreFromResult2(SCIP *scip, SCIP_VAR *branchvar, BRANCHINGRESULTDATA *downbranchingresult, BRANCHINGRESULTDATA *upbranchingresult, SCIP_Real lpobjval)
static SCIP_RETCODE initBranchruleData(SCIP *scip, SCIP_BRANCHRULEDATA *branchruledata)
#define DEFAULT_MINWEIGHT
static int findInsertionPoint(SCIP *scip, SCORECONTAINER *scorecontainer, SCIP_Real scoretoinsert, CANDIDATE **candidates, int ncandidates)
static SCIP_RETCODE candidateFree(SCIP *scip, CANDIDATE **candidate)
static SCIP_RETCODE candidateListGetAllFractionalCandidates(SCIP *scip, CANDIDATELIST **candidatelist)
#define DEFAULT_ADDBINCONSROW
static SCIP_RETCODE selectVarRecursive(SCIP *scip, STATUS *status, PERSISTENTDATA *persistent, CONFIGURATION *config, SCIP_SOL *baselpsol, DOMAINREDUCTIONS *domainreductions, BINCONSDATA *binconsdata, CANDIDATELIST *candidatelist, BRANCHINGDECISION *decision, SCORECONTAINER *scorecontainer, LEVEL2DATA *level2data, int recursiondepth, SCIP_Real lpobjval, SCIP_Real baselpobjval, SCIP_Longint *niterations, int *ndeepestcutoffs, SCIP_Real *bestgain, SCIP_Real *totalgains, int *ntotalgains, int *ndeepestnodes)
static void binaryVarListFree(SCIP *scip, BINARYVARLIST **list)
static SCIP_RETCODE getNIterationsLastLP(SCIP *scip, SCIP_Longint *iterations)
static SCIP_RETCODE binConsDataCreate(SCIP *scip, BINCONSDATA **consdata, int maxdepth, int nstartcons)
static SCIP_RETCODE candidateStoreWarmStartInfo(SCIP *scip, CANDIDATE *candidate, SCIP_Bool down)
#define DEFAULT_LEVEL2AVGSCORE
static SCIP_RETCODE branchOnVar(SCIP *scip, CONFIGURATION *config, BRANCHINGDECISION *decision)
static void statusFree(SCIP *scip, STATUS **status)
static SCIP_RETCODE level2dataCreate(SCIP *scip, LEVEL2DATA **data)
static void applyDeeperDomainReductions(SCIP *scip, SCIP_SOL *baselpsol, int maxstoredomreds, DOMAINREDUCTIONS *targetdomreds, DOMAINREDUCTIONS *downdomreds, DOMAINREDUCTIONS *updomreds)
static void level2dataFree(SCIP *scip, LEVEL2DATA **data)
static SCIP_Bool isUseOldBranching(SCIP *scip, PERSISTENTDATA *persistent, CONFIGURATION *config, SCIP_VAR *branchvar)
static SCIP_DECL_BRANCHEXITSOL(branchExitSolLookahead)
static void addUpperBound(SCIP *scip, SCIP_VAR *var, SCIP_Real upperbound, SCIP_SOL *baselpsol, SCIP_Bool simplechange, DOMAINREDUCTIONS *domainreductions)
static SCIP_RETCODE freePersistent(SCIP *scip, SCIP_BRANCHRULEDATA *branchruledata)
static void branchingDecisionFree(SCIP *scip, BRANCHINGDECISION **decision)
static SCIP_RETCODE level2dataGetResult(SCIP *scip, LEVEL2DATA *data, LEVEL2RESULT **result)
static SCIP_RETCODE candidateFreeWarmStartInfo(SCIP *scip, CANDIDATE *candidate)
static SCIP_Real calculateScoreFromDeeperscore(SCIP *scip, SCIP_VAR *branchvar, BRANCHINGRESULTDATA *downbranchingresult, BRANCHINGRESULTDATA *upbranchingresult)
static void branchingDecisionCopy(BRANCHINGDECISION *sourcedecision, BRANCHINGDECISION *targetdecision)
SCIP_RETCODE SCIPincludeBranchruleLookahead(SCIP *scip)
static SCIP_RETCODE scoreContainerSetScore(SCIP *scip, SCORECONTAINER *scorecontainer, CANDIDATE *cand, SCIP_Real score, SCIP_Real downgain, SCIP_Real upgain)
#define DEFAULT_REUSEBASIS
static void constraintListFree(SCIP *scip, CONSTRAINTLIST **conslist)
static SCIP_RETCODE addBinaryConstraint(SCIP *scip, CONFIGURATION *config, BINCONSDATA *binconsdata, SCIP_SOL *baselpsol)
#define DEFAULT_RECURSIONDEPTH
static SCIP_RETCODE candidateListFree(SCIP *scip, CANDIDATELIST **candidatelist)
static SCIP_Real calculateWeightedCutoffScore(CONFIGURATION *config, BRANCHINGRESULTDATA *downbranchingresult, BRANCHINGRESULTDATA *upbranchingresult)
#define DEFAULT_USEDOMAINREDUCTION
static SCIP_RETCODE warmStartInfoCreate(SCIP *scip, WARMSTARTINFO **warmstartinfo)
static SCIP_Bool isStoreDecision(CONFIGURATION *config, BINCONSDATA *binconsdata, DOMAINREDUCTIONS *domainreductions)
#define DEFAULT_MAXNVIOLATEDCONS
static void applySingleDeeperDomainReductions(SCIP *scip, SCIP_SOL *baselpsol, int maxstoredomreds, DOMAINREDUCTIONS *targetdomreds, DOMAINREDUCTIONS *domreds)
static CANDIDATE * scoreContainerUpdateSortOrder(SCORECONTAINER *scorecontainer, CANDIDATE *candidate, int insertpoint)
static SCIP_RETCODE constraintListAppend(SCIP *scip, CONSTRAINTLIST *list, SCIP_VAR **consvars, int nconsvars, SCIP_Bool violated)
static SCIP_RETCODE binaryVarListCreate(SCIP *scip, BINARYVARLIST **list, int startsize)
static SCIP_RETCODE createBinaryConstraint(SCIP *scip, CONFIGURATION *config, SCIP_CONS **constraint, char *constraintname, SCIP_VAR **consvars, int nconsvars)
static SCIP_Bool candidateHasWarmStartInfo(CANDIDATE *candidate, SCIP_Bool down)
#define DEFAULT_SCORINGSCORINGFUNCTION
static void branchingResultDataFree(SCIP *scip, BRANCHINGRESULTDATA **resultdata)
#define LABdebugMessage(scip, lvl,...)
static SCIP_RETCODE updateOldBranching(SCIP *scip, PERSISTENTDATA *persistent, CONFIGURATION *config, SCIP_VAR *branchvar, SCIP_Real branchval, BRANCHINGRESULTDATA *downbranchingresult, BRANCHINGRESULTDATA *upbranchingresult, SCIP_Real lpobjval)
#define DEFAULT_STOREUNVIOLATEDSOL
static SCIP_Bool isCurrentNodeCutoff(SCIP *scip)
#define DEFAULT_WORSEFACTOR
#define DEFAULT_MAXNVIOLATEDBINCONS
static SCIP_RETCODE level2dataStoreResult(SCIP *scip, LEVEL2DATA *data, SCIP_Real lpobjval, SCIP_Bool cutoff, SCIP_Bool valid, SCIP_Bool *duplicate)
#define DEFAULT_ABBREVPSEUDO
#define DEFAULT_PREFERSIMPLEBOUNDS
static SCIP_Real calculateWeightedGain(SCIP *scip, CONFIGURATION *config, BRANCHINGRESULTDATA *downbranchingresult, BRANCHINGRESULTDATA *upbranchingresult, SCIP_Real lpobjval)
#define DEFAULT_FILTERBYMAXGAIN
#define DEFAULT_MAXPROPROUNDS
static void branchingResultDataInit(SCIP *scip, BRANCHINGRESULTDATA *resultdata)
static SCIP_Real calculateRelCutoffScore(SCIP *scip, SCIP_VAR *branchvar, BRANCHINGRESULTDATA *downbranchingresult, BRANCHINGRESULTDATA *upbranchingresult, SCIP_Real lpobjval)
static SCIP_Real calculateCutoffScore(SCIP *scip, SCIP_VAR *branchvar, BRANCHINGRESULTDATA *downbranchingresult, BRANCHINGRESULTDATA *upbranchingresult, SCIP_Real lpobjval)
static void sortFirstCandidatesByScore(SCIP *scip, CANDIDATELIST *candidatelist, SCORECONTAINER *scorecontainer, int nbestcandidates)
#define BRANCHRULE_MAXDEPTH
#define DEFAULT_ONLYVIOLDOMREDS
static SCIP_RETCODE branchingDecisionCreate(SCIP *scip, BRANCHINGDECISION **decision)
static SCIP_Real calculateScoreFromResult(SCIP *scip, SCIP_VAR *branchvar, BRANCHINGRESULTDATA *downbranchingresult, BRANCHINGRESULTDATA *upbranchingresult, SCIP_Real lpobjval)
static SCIP_RETCODE getFSBResult(SCIP *scip, STATUS *status, PERSISTENTDATA *persistent, CONFIGURATION *config, SCIP_SOL *baselpsol, DOMAINREDUCTIONS *domainreductions, BINCONSDATA *binconsdata, CANDIDATELIST *candidatelist, BRANCHINGDECISION *decision, SCORECONTAINER *scorecontainer, LEVEL2DATA *level2data, SCIP_Real lpobjval)
#define DEFAULT_ADDNONVIOCONS
static SCIP_Bool branchingDecisionIsValid(BRANCHINGDECISION *decision)
#define BRANCHRULE_MAXBOUNDDIST
static void branchingDecisionInit(SCIP *scip, BRANCHINGDECISION *decision)
static SCIP_RETCODE candidateLoadWarmStartInfo(SCIP *scip, CANDIDATE *candidate, SCIP_Bool down)
#define DEFAULT_MAXNVIOLATEDDOMREDS
#define DEFAULT_LEVEL2ZEROSCORE
#define DEFAULT_MAXNCANDS
lookahead LP branching rule
Constraint handler for logicor constraints (equivalent to set covering, but algorithms are suited fo...
#define SCIP_MAXTREEDEPTH
#define SCIP_LONGINT_FORMAT
SCIP_RETCODE SCIPcreateConsLogicor(SCIP *scip, SCIP_CONS **cons, const char *name, int nvars, SCIP_VAR **vars, 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 SCIPisStopped(SCIP *scip)
SCIP_Bool SCIPisExactSolve(SCIP *scip)
int SCIPgetNIntVars(SCIP *scip)
int SCIPgetNVars(SCIP *scip)
SCIP_VAR ** SCIPgetVars(SCIP *scip)
int SCIPgetNBinVars(SCIP *scip)
SCIP_RETCODE SCIPlpiFreeNorms(SCIP_LPI *lpi, BMS_BLKMEM *blkmem, SCIP_LPINORMS **lpinorms)
SCIP_Bool SCIPlpiIsPrimalFeasible(SCIP_LPI *lpi)
SCIP_Bool SCIPlpiIsDualFeasible(SCIP_LPI *lpi)
SCIP_RETCODE SCIPlpiGetNorms(SCIP_LPI *lpi, BMS_BLKMEM *blkmem, SCIP_LPINORMS **lpinorms)
SCIP_RETCODE SCIPlpiFreeState(SCIP_LPI *lpi, BMS_BLKMEM *blkmem, SCIP_LPISTATE **lpistate)
SCIP_RETCODE SCIPlpiGetIterations(SCIP_LPI *lpi, int *iterations)
SCIP_RETCODE SCIPlpiGetState(SCIP_LPI *lpi, BMS_BLKMEM *blkmem, SCIP_LPISTATE **lpistate)
SCIP_RETCODE SCIPupdateNodeLowerbound(SCIP *scip, SCIP_NODE *node, SCIP_Real newbound)
SCIP_RETCODE SCIPupdateLocalLowerbound(SCIP *scip, SCIP_Real newbound)
SCIP_RETCODE SCIPaddConsNode(SCIP *scip, SCIP_NODE *node, 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,...)
SCIP_RETCODE SCIPgetBoolParam(SCIP *scip, const char *name, SCIP_Bool *value)
SCIP_RETCODE SCIPaddLongintParam(SCIP *scip, const char *name, const char *desc, SCIP_Longint *valueptr, SCIP_Bool isadvanced, SCIP_Longint defaultvalue, SCIP_Longint minvalue, SCIP_Longint maxvalue, SCIP_DECL_PARAMCHGD((*paramchgd)), SCIP_PARAMDATA *paramdata)
SCIP_RETCODE SCIPaddCharParam(SCIP *scip, const char *name, const char *desc, char *valueptr, SCIP_Bool isadvanced, char defaultvalue, const char *allowedvalues, SCIP_DECL_PARAMCHGD((*paramchgd)), SCIP_PARAMDATA *paramdata)
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 SCIPsetBranchruleExit(SCIP *scip, SCIP_BRANCHRULE *branchrule, SCIP_DECL_BRANCHEXIT((*branchexit)))
SCIP_RETCODE SCIPsetBranchruleExecLp(SCIP *scip, SCIP_BRANCHRULE *branchrule, SCIP_DECL_BRANCHEXECLP((*branchexeclp)))
SCIP_RETCODE SCIPsetBranchruleCopy(SCIP *scip, SCIP_BRANCHRULE *branchrule, SCIP_DECL_BRANCHCOPY((*branchcopy)))
SCIP_RETCODE SCIPincludeBranchruleBasic(SCIP *scip, SCIP_BRANCHRULE **branchruleptr, const char *name, const char *desc, int priority, int maxdepth, SCIP_Real maxbounddist, SCIP_BRANCHRULEDATA *branchruledata)
const char * SCIPbranchruleGetName(SCIP_BRANCHRULE *branchrule)
SCIP_BRANCHRULEDATA * SCIPbranchruleGetData(SCIP_BRANCHRULE *branchrule)
SCIP_RETCODE SCIPsetBranchruleFree(SCIP *scip, SCIP_BRANCHRULE *branchrule, SCIP_DECL_BRANCHFREE((*branchfree)))
SCIP_RETCODE SCIPsetBranchruleExitsol(SCIP *scip, SCIP_BRANCHRULE *branchrule, SCIP_DECL_BRANCHEXITSOL((*branchexitsol)))
SCIP_RETCODE SCIPsetBranchruleInit(SCIP *scip, SCIP_BRANCHRULE *branchrule, SCIP_DECL_BRANCHINIT((*branchinit)))
void SCIPbranchruleSetData(SCIP_BRANCHRULE *branchrule, SCIP_BRANCHRULEDATA *branchruledata)
SCIP_RETCODE SCIPbranchVarVal(SCIP *scip, SCIP_VAR *var, SCIP_Real val, SCIP_NODE **downchild, SCIP_NODE **eqchild, SCIP_NODE **upchild)
SCIP_RETCODE SCIPgetLPBranchCands(SCIP *scip, SCIP_VAR ***lpcands, SCIP_Real **lpcandssol, SCIP_Real **lpcandsfrac, int *nlpcands, int *npriolpcands, int *nfracimplvars)
SCIP_Real SCIPgetBranchScore(SCIP *scip, SCIP_VAR *var, SCIP_Real downgain, SCIP_Real upgain)
int SCIPgetNPseudoBranchCands(SCIP *scip)
SCIP_RETCODE SCIPprintCons(SCIP *scip, SCIP_CONS *cons, FILE *file)
SCIP_RETCODE SCIPreleaseCons(SCIP *scip, SCIP_CONS **cons)
int SCIPgetNLPRows(SCIP *scip)
SCIP_RETCODE SCIPgetLPI(SCIP *scip, SCIP_LPI **lpi)
SCIP_LPSOLSTAT SCIPgetLPSolstat(SCIP *scip)
SCIP_Bool SCIPallColsInLP(SCIP *scip)
SCIP_Real SCIPgetLPObjval(SCIP *scip)
#define SCIPfreeBuffer(scip, ptr)
#define SCIPfreeBlockMemoryArray(scip, ptr, num)
#define SCIPallocMemoryArray(scip, ptr, num)
#define SCIPallocClearBufferArray(scip, ptr, num)
int SCIPcalcMemGrowSize(SCIP *scip, int num)
#define SCIPallocBufferArray(scip, ptr, num)
#define SCIPallocMemory(scip, ptr)
#define SCIPfreeBufferArray(scip, ptr)
#define SCIPfreeMemoryArray(scip, ptr)
#define SCIPfreeMemory(scip, ptr)
#define SCIPallocBlockMemoryArray(scip, ptr, num)
#define SCIPallocBuffer(scip, ptr)
#define SCIPreallocBlockMemoryArray(scip, ptr, oldnum, newnum)
#define SCIPfreeBlockMemory(scip, ptr)
#define SCIPallocBlockMemory(scip, ptr)
#define SCIPduplicateBlockMemoryArray(scip, ptr, source, num)
SCIP_Real SCIPnodeGetLowerbound(SCIP_NODE *node)
SCIP_Longint SCIPnodeGetNumber(SCIP_NODE *node)
SCIP_Real SCIPnodeGetEstimate(SCIP_NODE *node)
int SCIPgetProbingDepth(SCIP *scip)
SCIP_RETCODE SCIPchgVarUbProbing(SCIP *scip, SCIP_VAR *var, SCIP_Real newbound)
SCIP_RETCODE SCIPsetProbingLPState(SCIP *scip, SCIP_LPISTATE **lpistate, SCIP_LPINORMS **lpinorms, SCIP_Bool primalfeas, SCIP_Bool dualfeas)
SCIP_RETCODE SCIPchgVarLbProbing(SCIP *scip, SCIP_VAR *var, SCIP_Real newbound)
SCIP_RETCODE SCIPpropagateProbing(SCIP *scip, int maxproprounds, SCIP_Bool *cutoff, SCIP_Longint *ndomredsfound)
SCIP_RETCODE SCIPbacktrackProbing(SCIP *scip, int probingdepth)
SCIP_Bool SCIPinProbing(SCIP *scip)
SCIP_RETCODE SCIPnewProbingNode(SCIP *scip)
SCIP_RETCODE SCIPsolveProbingLP(SCIP *scip, int itlim, SCIP_Bool *lperror, SCIP_Bool *cutoff)
SCIP_RETCODE SCIPfreeSol(SCIP *scip, SCIP_SOL **sol)
SCIP_RETCODE SCIPcreateLPSol(SCIP *scip, SCIP_SOL **sol, SCIP_HEUR *heur)
SCIP_RETCODE SCIPunlinkSol(SCIP *scip, SCIP_SOL *sol)
SCIP_Real SCIPgetSolVal(SCIP *scip, SCIP_SOL *sol, SCIP_VAR *var)
SCIP_Longint SCIPgetNNodeZeroIterationLPs(SCIP *scip)
SCIP_Longint SCIPgetNNodes(SCIP *scip)
SCIP_Longint SCIPgetNTotalNodes(SCIP *scip)
SCIP_Longint SCIPgetNNodeLPIterations(SCIP *scip)
SCIP_Longint SCIPgetNLPs(SCIP *scip)
SCIP_Real SCIPgetCutoffbound(SCIP *scip)
SCIP_Longint SCIPgetNNodeLPs(SCIP *scip)
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 SCIPisRelGT(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_Real SCIPfeasCeil(SCIP *scip, SCIP_Real val)
SCIP_Bool SCIPisLE(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_Real SCIPfeasFloor(SCIP *scip, SCIP_Real val)
SCIP_Bool SCIPisFeasLT(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_Bool SCIPisFeasIntegral(SCIP *scip, SCIP_Real val)
SCIP_Bool SCIPisGT(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_Real SCIPceil(SCIP *scip, SCIP_Real val)
SCIP_Bool SCIPisFeasGT(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_Bool SCIPisEQ(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_Real SCIPsumepsilon(SCIP *scip)
SCIP_Bool SCIPisLT(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_Bool SCIPisSumLE(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
int SCIPgetCutoffdepth(SCIP *scip)
int SCIPgetDepth(SCIP *scip)
SCIP_NODE * SCIPgetCurrentNode(SCIP *scip)
SCIP_RETCODE SCIPtightenVarLb(SCIP *scip, SCIP_VAR *var, SCIP_Real newbound, SCIP_Bool force, SCIP_Bool *infeasible, SCIP_Bool *tightened)
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_Real SCIPgetVarPseudocostCountCurrentRun(SCIP *scip, SCIP_VAR *var, SCIP_BRANCHDIR dir)
SCIP_RETCODE SCIPendStrongbranch(SCIP *scip)
SCIP_Real SCIPvarGetUbLocal(SCIP_VAR *var)
SCIP_RETCODE SCIPchgVarUbNode(SCIP *scip, SCIP_NODE *node, SCIP_VAR *var, SCIP_Real newbound)
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)
int SCIPvarGetProbindex(SCIP_VAR *var)
const char * SCIPvarGetName(SCIP_VAR *var)
SCIP_Longint SCIPgetVarStrongbranchNode(SCIP *scip, SCIP_VAR *var)
SCIP_Real SCIPadjustedVarUb(SCIP *scip, SCIP_VAR *var, SCIP_Real ub)
SCIP_Longint SCIPgetVarStrongbranchLPAge(SCIP *scip, SCIP_VAR *var)
SCIP_RETCODE SCIPsetVarStrongbranchData(SCIP *scip, SCIP_VAR *var, SCIP_Real lpobjval, SCIP_Real primsol, SCIP_Real down, SCIP_Real up, SCIP_Bool downvalid, SCIP_Bool upvalid, SCIP_Longint iter, int itlim)
SCIP_Real SCIPgetVarPseudocostVal(SCIP *scip, SCIP_VAR *var, SCIP_Real solvaldelta)
SCIP_Real SCIPadjustedVarLb(SCIP *scip, SCIP_VAR *var, SCIP_Real lb)
SCIP_RETCODE SCIPgetNegatedVar(SCIP *scip, SCIP_VAR *var, SCIP_VAR **negvar)
SCIP_Real SCIPvarGetLbLocal(SCIP_VAR *var)
SCIP_RETCODE SCIPupdateVarPseudocost(SCIP *scip, SCIP_VAR *var, SCIP_Real solvaldelta, SCIP_Real objdelta, SCIP_Real weight)
SCIP_RETCODE SCIPchgVarLbNode(SCIP *scip, SCIP_NODE *node, SCIP_VAR *var, SCIP_Real newbound)
SCIP_RETCODE SCIPtryStrongbranchLPSol(SCIP *scip, SCIP_Bool *foundsol, SCIP_Bool *cutoff)
SCIP_RETCODE SCIPgetVarStrongbranchLast(SCIP *scip, SCIP_VAR *var, SCIP_Real *down, SCIP_Real *up, SCIP_Bool *downvalid, SCIP_Bool *upvalid, SCIP_Real *solval, SCIP_Real *lpobjval)
SCIP_Bool SCIPisStrongbranchDownFirst(SCIP *scip, SCIP_VAR *var)
void SCIPenableVarHistory(SCIP *scip)
SCIP_RETCODE SCIPstartStrongbranch(SCIP *scip, SCIP_Bool enablepropagation)
int SCIPsnprintf(char *t, int len, const char *s,...)
interface methods for specific LP solvers
memory allocation routines
#define BMScopyMemoryArray(ptr, source, num)
#define BMSclearMemoryArray(ptr, num)
struct BMS_BlkMem BMS_BLKMEM
BMS_BLKMEM * SCIPblkmem(SCIP *scip)
public methods for branching rules
public methods for message output
public data structures and miscellaneous methods
public methods for branch and bound tree
public methods for problem variables
public methods for branching rule plugins and branching
public methods for constraint handler plugins and constraints
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
CONSTRAINTLIST * conslist
BINARYVARLIST * binaryvars
SCIP_Real * downlowerbounds
SCIP_Real * upupperbounds
SCIP_Real * uplowerbounds
SCIP_Real * downupperbounds
WARMSTARTINFO * downwarmstartinfo
WARMSTARTINFO * upwarmstartinfo
SCIP_Bool applychildbounds
SCIP_Bool usedomainreduction
SCIP_Bool storeunviolatedsol
SCIP_Longint reevalagefsb
SCIP_Bool mergedomainreductions
SCIP_Bool onlyvioldomreds
SCIP_Bool prefersimplebounds
char deeperscoringfunction
char scoringscoringfunction
SCIP_Bool enforcemaxdomreds
SCIP_Bool updatebranchingresults
SCIP_Bool level2zeroscore
SCIP_Bool filterbymaxgain
SCIP_Shortbool * baselpviolated
LEVEL2RESULT ** level2results
SCIP_Longint * lastbranchid
SCIP_Longint oldnnodelpiterations
SCIP_Longint * lastbranchnlps
BRANCHINGDECISION * olddecision
SCIP_Real * lastbranchlpobjval
SCIP_Longint oldntotalnodes
BRANCHINGRESULTDATA ** lastbranchdownres
BRANCHINGRESULTDATA ** lastbranchupres
CANDIDATE ** bestsortedcands
SCIP_Bool maxnconsreached
struct SCIP_BranchruleData SCIP_BRANCHRULEDATA
@ SCIP_BRANCHDIR_DOWNWARDS
enum SCIP_LPSolStat SCIP_LPSOLSTAT
@ SCIP_LPSOLSTAT_NOTSOLVED
@ SCIP_LPSOLSTAT_TIMELIMIT
@ SCIP_LPSOLSTAT_UNBOUNDEDRAY
@ SCIP_LPSOLSTAT_INFEASIBLE
@ SCIP_LPSOLSTAT_ITERLIMIT
enum SCIP_VerbLevel SCIP_VERBLEVEL
enum SCIP_Result SCIP_RESULT
enum SCIP_Retcode SCIP_RETCODE
@ SCIP_VARTYPE_CONTINUOUS
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4