72 assert(num <= branchcand->lpcandssize);
95 assert(num <= branchcand->pseudocandssize);
120 assert(num <= branchcand->externcandssize);
136 assert(branchcand !=
NULL);
139 (*branchcand)->lpcands =
NULL;
140 (*branchcand)->lpcandssol =
NULL;
141 (*branchcand)->lpcandsfrac =
NULL;
142 (*branchcand)->externcands =
NULL;
143 (*branchcand)->externcandssol =
NULL;
144 (*branchcand)->externcandsscore =
NULL;
145 (*branchcand)->pseudocands =
NULL;
146 (*branchcand)->lpcandssize = 0;
147 (*branchcand)->nlpcands = 0;
148 (*branchcand)->nimpllpfracs = 0;
149 (*branchcand)->npriolpcands = 0;
150 (*branchcand)->npriolpbins = 0;
151 (*branchcand)->lpmaxpriority = INT_MIN;
152 (*branchcand)->externcandssize = 0;
153 (*branchcand)->nexterncands = 0;
154 (*branchcand)->nprioexterncands = 0;
155 (*branchcand)->nprioexternbins = 0;
156 (*branchcand)->nprioexternints = 0;
157 (*branchcand)->nprioexternimpls = 0;
158 (*branchcand)->externmaxpriority = INT_MIN;
159 (*branchcand)->pseudocandssize = 0;
160 (*branchcand)->npseudocands = 0;
161 (*branchcand)->npriopseudocands = 0;
162 (*branchcand)->npriopseudobins = 0;
163 (*branchcand)->npriopseudoints = 0;
164 (*branchcand)->pseudomaxpriority = INT_MIN;
176 assert(branchcand !=
NULL);
195 assert(branchcand !=
NULL);
209 assert(branchcand !=
NULL);
210 assert(stat !=
NULL);
216 SCIPsetDebugMsg(
set,
"calculating LP branching candidates: validlp=%" SCIP_LONGINT_FORMAT
", lpcount=%" SCIP_LONGINT_FORMAT
"\n",
259 for( c = 0; c < ncols; ++c )
263 assert(col->
lppos == c);
305 assert(insertpos < branchcand->lpcandssize);
308 branchpriority = INT_MIN;
367 branchcand->
lpcands[insertpos] = var;
377 SCIPsetDebugMsg(
set,
" -> candidate %d: var=<%s>, sol=%g, frac=%g, prio=%d (max: %d) -> pos %d\n",
420 if( lpcands !=
NULL )
421 *lpcands = branchcand->
lpcands;
422 if( lpcandssol !=
NULL )
424 if( lpcandsfrac !=
NULL )
426 if( nlpcands !=
NULL )
428 if( npriolpcands !=
NULL )
431 if( nfracimplvars !=
NULL )
444 int* nprioexterncands,
445 int* nprioexternbins,
446 int* nprioexternints,
447 int* nprioexternimpls
452 assert(branchcand !=
NULL);
455 if( externcands !=
NULL )
457 if( externcandssol !=
NULL )
459 if( externcandsscore !=
NULL )
461 if( nexterncands !=
NULL )
463 if( nprioexterncands !=
NULL )
465 if( nprioexternbins !=
NULL )
467 if( nprioexternints !=
NULL )
469 if( nprioexternimpls !=
NULL )
480 assert(branchcand !=
NULL);
490 assert(branchcand !=
NULL);
500 assert(branchcand !=
NULL);
510 assert(branchcand !=
NULL);
520 assert(branchcand !=
NULL);
530 assert(branchcand !=
NULL);
550 assert(branchcand !=
NULL);
564 SCIPsetDebugMsg(
set,
"inserting external candidate <%s> of type %d and priority %d into candidate set (maxprio: %d), score = %g, solval = %g\n",
672 assert(branchcand !=
NULL);
691 assert(branchcand !=
NULL);
743 i < branchcand->nprioexterncands; i++ )
750 assert(branchpriority < branchcand->externmaxpriority);
765 int* npriopseudocands
768 assert(branchcand !=
NULL);
777 assert(prob !=
NULL);
809 if( pseudocands !=
NULL )
811 if( npseudocands !=
NULL )
813 if( npriopseudocands !=
NULL )
825 assert(branchcand !=
NULL);
835 assert(branchcand !=
NULL);
845 assert(branchcand !=
NULL);
855 assert(branchcand !=
NULL);
865 assert(branchcand !=
NULL);
883 assert(branchcand !=
NULL);
885 assert(branchcand->
npriopseudocands <= insertpos && insertpos < branchcand->npseudocands);
891 SCIPdebugMessage(
"inserting pseudo candidate <%s> of type %d and priority %d into candidate set at position %d (maxprio: %d)\n",
971 assert(branchcand !=
NULL);
1005 assert(branchcand !=
NULL);
1006 assert(var !=
NULL);
1013 SCIPdebugMessage(
"removing pseudo candidate <%s> of type %d and priority %d at %d from candidate set (maxprio: %d)\n",
1021 assert(0 <= freepos && freepos < branchcand->npseudocands);
1023 if( freepos < branchcand->npriopseudobins )
1037 if( freepos < branchcand->npriopseudobins + branchcand->
npriopseudoints )
1051 if( freepos < branchcand->npriopseudocands )
1087 assert(var !=
NULL);
1105 assert(branchcand !=
NULL);
1106 assert(var !=
NULL);
1146 int oldbranchpriority;
1147 int pseudomaxpriority;
1149 assert(branchcand !=
NULL);
1153 if( oldbranchpriority == branchpriority )
1161 if( oldbranchpriority == pseudomaxpriority || branchpriority > pseudomaxpriority )
1203 assert(paramdata !=
NULL);
1217 assert(branchrule !=
NULL);
1218 assert(
set !=
NULL);
1219 assert(set->scip !=
NULL);
1221 if( branchrule->branchcopy !=
NULL )
1224 SCIP_CALL( branchrule->branchcopy(set->scip, branchrule) );
1258 assert(branchrule !=
NULL);
1259 assert(name !=
NULL);
1260 assert(desc !=
NULL);
1265 (*branchrule)->priority = priority;
1266 (*branchrule)->maxdepth = maxdepth;
1267 (*branchrule)->maxbounddist = maxbounddist;
1268 (*branchrule)->branchcopy = branchcopy;
1269 (*branchrule)->branchfree = branchfree;
1270 (*branchrule)->branchinit = branchinit;
1271 (*branchrule)->branchexit = branchexit;
1272 (*branchrule)->branchinitsol = branchinitsol;
1273 (*branchrule)->branchexitsol = branchexitsol;
1274 (*branchrule)->branchexeclp = branchexeclp;
1275 (*branchrule)->branchexecext = branchexecext;
1276 (*branchrule)->branchexecps = branchexecps;
1277 (*branchrule)->branchruledata = branchruledata;
1280 (*branchrule)->nlpcalls = 0;
1281 (*branchrule)->nexterncalls = 0;
1282 (*branchrule)->npseudocalls = 0;
1283 (*branchrule)->ncutoffs = 0;
1284 (*branchrule)->ncutsfound = 0;
1285 (*branchrule)->nconssfound = 0;
1286 (*branchrule)->ndomredsfound = 0;
1287 (*branchrule)->nchildren = 0;
1288 (*branchrule)->initialized =
FALSE;
1294 &(*branchrule)->priority,
FALSE, priority, INT_MIN/4, INT_MAX/4,
1297 (void)
SCIPsnprintf(paramdesc,
SCIP_MAXSTRLEN,
"maximal depth level, up to which branching rule <%s> should be used (-1 for no limit)", name);
1302 (void)
SCIPsnprintf(paramdesc,
SCIP_MAXSTRLEN,
"maximal relative distance from current node's dual bound to primal bound compared to best node's dual bound for applying branching rule (0.0: only on current best node, 1.0: on all nodes)");
1304 &(*branchrule)->maxbounddist,
FALSE, maxbounddist, 0.0, 1.0,
1316 assert(branchrule !=
NULL);
1317 assert(*branchrule !=
NULL);
1318 assert(!(*branchrule)->initialized);
1319 assert(
set !=
NULL);
1322 if( (*branchrule)->branchfree !=
NULL )
1324 SCIP_CALL( (*branchrule)->branchfree(set->scip, *branchrule) );
1342 assert(branchrule !=
NULL);
1343 assert(
set !=
NULL);
1351 if( set->misc_resetstat )
1365 if( branchrule->branchinit !=
NULL )
1370 SCIP_CALL( branchrule->branchinit(set->scip, branchrule) );
1386 assert(branchrule !=
NULL);
1387 assert(
set !=
NULL);
1395 if( branchrule->branchexit !=
NULL )
1400 SCIP_CALL( branchrule->branchexit(set->scip, branchrule) );
1416 assert(branchrule !=
NULL);
1417 assert(
set !=
NULL);
1420 if( branchrule->branchinitsol !=
NULL )
1425 SCIP_CALL( branchrule->branchinitsol(set->scip, branchrule) );
1440 assert(branchrule !=
NULL);
1441 assert(
set !=
NULL);
1444 if( branchrule->branchexitsol !=
NULL )
1449 SCIP_CALL( branchrule->branchexitsol(set->scip, branchrule) );
1470 assert(branchrule !=
NULL);
1471 assert(
set !=
NULL);
1472 assert(tree !=
NULL);
1475 assert(result !=
NULL);
1478 if( branchrule->branchexeclp !=
NULL 1494 runbranchrule =
SCIPsetIsLE(
set, loclowerbound - glblowerbound, branchrule->
maxbounddist * (cutoffbound - glblowerbound));
1502 int oldnactiveconss;
1515 SCIP_CALL( branchrule->branchexeclp(set->scip, branchrule, allowaddcons, result) );
1529 SCIPerrorMessage(
"branching rule <%s> returned invalid result code <%d> from LP solution branching\n",
1530 branchrule->
name, *result);
1535 SCIPerrorMessage(
"branching rule <%s> added a constraint in LP solution branching without permission\n",
1577 assert(branchrule !=
NULL);
1578 assert(
set !=
NULL);
1579 assert(tree !=
NULL);
1582 assert(result !=
NULL);
1585 if( branchrule->branchexecext !=
NULL 1602 runbranchrule =
SCIPsetIsLE(
set, loclowerbound - glblowerbound, branchrule->
maxbounddist * (cutoffbound - glblowerbound));
1610 int oldnactiveconss;
1612 SCIPsetDebugMsg(
set,
"executing external solution branching rule <%s>\n", branchrule->
name);
1623 SCIP_CALL( branchrule->branchexecext(set->scip, branchrule, allowaddcons, result) );
1637 SCIPerrorMessage(
"branching rule <%s> returned invalid result code <%d> from external solution branching\n",
1638 branchrule->
name, *result);
1643 SCIPerrorMessage(
"branching rule <%s> added a constraint in external solution branching without permission\n",
1683 assert(branchrule !=
NULL);
1684 assert(
set !=
NULL);
1685 assert(tree !=
NULL);
1687 assert(result !=
NULL);
1690 if( branchrule->branchexecps !=
NULL 1706 runbranchrule =
SCIPsetIsLE(
set, loclowerbound - glblowerbound, branchrule->
maxbounddist * (cutoffbound - glblowerbound));
1725 SCIP_CALL( branchrule->branchexecps(set->scip, branchrule, allowaddcons, result) );
1738 SCIPerrorMessage(
"branching rule <%s> returned invalid result code <%d> from pseudo solution branching\n",
1739 branchrule->
name, *result);
1744 SCIPerrorMessage(
"branching rule <%s> added a constraint in pseudo solution branching without permission\n",
1778 assert(branchrule !=
NULL);
1789 assert(branchrule !=
NULL);
1800 assert(branchrule !=
NULL);
1802 branchrule->branchcopy = branchcopy;
1811 assert(branchrule !=
NULL);
1813 branchrule->branchfree = branchfree;
1822 assert(branchrule !=
NULL);
1824 branchrule->branchinit = branchinit;
1833 assert(branchrule !=
NULL);
1835 branchrule->branchexit = branchexit;
1844 assert(branchrule !=
NULL);
1846 branchrule->branchinitsol = branchinitsol;
1855 assert(branchrule !=
NULL);
1857 branchrule->branchexitsol = branchexitsol;
1868 assert(branchrule !=
NULL);
1870 branchrule->branchexeclp = branchexeclp;
1879 assert(branchrule !=
NULL);
1881 branchrule->branchexecext = branchexecext;
1890 assert(branchrule !=
NULL);
1892 branchrule->branchexecps = branchexecps;
1900 assert(branchrule !=
NULL);
1902 return branchrule->
name;
1910 assert(branchrule !=
NULL);
1912 return branchrule->
desc;
1920 assert(branchrule !=
NULL);
1932 assert(branchrule !=
NULL);
1933 assert(
set !=
NULL);
1936 set->branchrulessorted =
FALSE;
1944 assert(branchrule !=
NULL);
1955 assert(branchrule !=
NULL);
1956 assert(maxdepth >= -1);
1966 assert(branchrule !=
NULL);
1977 assert(branchrule !=
NULL);
1978 assert(maxbounddist >= -1);
1989 assert(branchrule !=
NULL);
2000 assert(branchrule !=
NULL);
2010 assert(branchrule !=
NULL);
2020 assert(branchrule !=
NULL);
2030 assert(branchrule !=
NULL);
2040 assert(branchrule !=
NULL);
2050 assert(branchrule !=
NULL);
2060 assert(branchrule !=
NULL);
2072 assert(branchrule !=
NULL);
2082 assert(branchrule !=
NULL);
2092 assert(branchrule !=
NULL);
2102 assert(branchrule !=
NULL);
2125 assert(
set !=
NULL);
2129 if( set->branch_sumadjustscore )
2132 downgain = downgain + eps;
2133 upgain = upgain + eps;
2138 downgain =
MAX(downgain, eps);
2139 upgain =
MAX(upgain, eps);
2142 switch( set->branch_scorefunc )
2146 if( downgain > upgain )
2147 score =
set->branch_scorefac * downgain + (1.0-
set->branch_scorefac) * upgain;
2149 score =
set->branch_scorefac * upgain + (1.0-
set->branch_scorefac) * downgain;
2153 score = downgain * upgain;
2156 if( downgain > upgain )
2157 score = upgain * upgain / downgain;
2159 score = downgain * downgain / upgain;
2162 SCIPerrorMessage(
"invalid branching score function <%c>\n", set->branch_scorefunc);
2186 assert(nchildren == 0 || gains !=
NULL);
2191 for( c = 0; c < nchildren; ++c )
2193 if( gains[c] < min1 )
2198 else if( gains[c] < min2 )
2224 assert(
set !=
NULL);
2225 assert(var !=
NULL);
2238 branchpoint =
MAX(lb,
MIN(suggestion, ub));
2269 if(
REALABS(branchpoint) > 1e+12 )
2271 branchpoint =
MAX(lb,
MIN(branchpoint, ub));
2282 branchpoint = lb + 1000.0;
2293 branchpoint = ub - 1000.0;
2319 branchpoint = (lb+ub)/2.0;
2333 scale = MAX3(lbabs, ubabs, 1.0);
2339 minbrpoint = (1.0 -
set->branch_clamp) * lb + set->branch_clamp * ub;
2346 maxbrpoint =
set->branch_clamp * lb + (1.0 -
set->branch_clamp) * ub;
2350 branchpoint =
MAX(minbrpoint,
MIN(branchpoint, maxbrpoint));
2370 return branchpoint - 0.5;
2378 if( branchpoint <= lb + 0.5 )
2383 else if( branchpoint >= ub - 0.5 )
2395 return branchpoint - 0.5;
2429 assert(branchcand !=
NULL);
2430 assert(result !=
NULL);
2439 SCIPsetDebugMsg(
set,
"branching on LP solution with %d (+%d) fractional (+implicit fractional) variables (%d of maximal priority)\n",
2444 if( nalllpcands == 0 )
2452 SCIP_CALL(
SCIPbranchExecPseudo(blkmem,
set, stat, transprob, origprob, tree, reopt, lp, branchcand, eventqueue, cutoffbound,
2453 allowaddcons, result) );
2480 bestpriority = INT_MIN;
2482 for( i = 0; i < nalllpcands; ++i )
2486 if( priority > bestpriority || (priority == bestpriority && factor > bestfactor) )
2489 bestpriority = priority;
2490 bestfactor = factor;
2493 assert(0 <= bestcand && bestcand < nalllpcands);
2495 var = branchcand->
lpcands[bestcand];
2501 SCIP_CALL(
SCIPtreeBranchVar(tree, reopt, blkmem,
set, stat, transprob, origprob, lp, branchcand, eventqueue, var,
SCIP_INVALID,
2530 assert(branchcand !=
NULL);
2531 assert(result !=
NULL);
2537 SCIPsetDebugMsg(
set,
"branching on external solution with %d branching candidates (%d of maximal priority)\n",
2552 SCIP_CALL(
SCIPbranchExecPseudo(blkmem,
set, stat, transprob, origprob, tree, reopt, lp, branchcand, eventqueue, cutoffbound,
2553 allowaddcons, result) );
2583 bestpriority = INT_MIN;
2604 if( priority > bestpriority || (priority == bestpriority && factor > bestfactor) || (priority == bestpriority && factor == bestfactor && domain > bestdomain) )
2607 bestpriority = priority;
2608 bestfactor = factor;
2609 bestdomain = domain;
2612 assert(0 <= bestcand && bestcand < branchcand->nexterncands);
2622 SCIPsetDebugMsg(
set,
"no branching method succeeded; fallback selected to branch on variable <%s> with bounds [%g, %g] on value %g\n",
2625 SCIP_CALL(
SCIPtreeBranchVar(tree, reopt, blkmem,
set, stat, transprob, origprob, lp, branchcand, eventqueue, var, val,
2660 assert(branchcand !=
NULL);
2661 assert(result !=
NULL);
2693 bestpriority = INT_MIN;
2699 if( priority > bestpriority || (priority == bestpriority && factor > bestfactor) )
2702 bestpriority = priority;
2703 bestfactor = factor;
2706 assert(0 <= bestcand && bestcand < branchcand->npseudocands);
2712 SCIP_CALL(
SCIPtreeBranchVar(tree, reopt, blkmem,
set, stat, transprob, origprob, lp, branchcand, eventqueue, var,
SCIP_INVALID,
enum SCIP_Result SCIP_RESULT
int SCIPbranchcandGetNPrioExternBins(SCIP_BRANCHCAND *branchcand)
SCIP_RETCODE SCIPbranchruleCreate(SCIP_BRANCHRULE **branchrule, SCIP_SET *set, SCIP_MESSAGEHDLR *messagehdlr, BMS_BLKMEM *blkmem, const char *name, const char *desc, int priority, int maxdepth, SCIP_Real maxbounddist, SCIP_DECL_BRANCHCOPY((*branchcopy)), SCIP_DECL_BRANCHFREE((*branchfree)), SCIP_DECL_BRANCHINIT((*branchinit)), SCIP_DECL_BRANCHEXIT((*branchexit)), SCIP_DECL_BRANCHINITSOL((*branchinitsol)), SCIP_DECL_BRANCHEXITSOL((*branchexitsol)), SCIP_DECL_BRANCHEXECLP((*branchexeclp)), SCIP_DECL_BRANCHEXECEXT((*branchexecext)), SCIP_DECL_BRANCHEXECPS((*branchexecps)), SCIP_BRANCHRULEDATA *branchruledata)
SCIP_Bool SCIPsetIsInfinity(SCIP_SET *set, SCIP_Real val)
SCIP_BRANCHRULEDATA * SCIPbranchruleGetData(SCIP_BRANCHRULE *branchrule)
internal methods for managing events
SCIP_Bool SCIPbranchruleIsInitialized(SCIP_BRANCHRULE *branchrule)
SCIP_Bool SCIPsetIsLE(SCIP_SET *set, SCIP_Real val1, SCIP_Real val2)
SCIP_RETCODE SCIPtreeBranchVar(SCIP_TREE *tree, SCIP_REOPT *reopt, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_STAT *stat, SCIP_PROB *transprob, SCIP_PROB *origprob, SCIP_LP *lp, SCIP_BRANCHCAND *branchcand, SCIP_EVENTQUEUE *eventqueue, SCIP_VAR *var, SCIP_Real val, SCIP_NODE **downchild, SCIP_NODE **eqchild, SCIP_NODE **upchild)
SCIP_Bool SCIPsetIsFeasZero(SCIP_SET *set, SCIP_Real val)
SCIP_DECL_SORTPTRCOMP(SCIPbranchruleComp)
void SCIPbranchruleSetCopy(SCIP_BRANCHRULE *branchrule, SCIP_DECL_BRANCHCOPY((*branchcopy)))
#define BMSfreeMemoryArrayNull(ptr)
internal methods for branch and bound tree
SCIP_Real SCIPbranchruleGetMaxbounddist(SCIP_BRANCHRULE *branchrule)
SCIP_Real SCIPsetFeastol(SCIP_SET *set)
SCIP_Real SCIPvarGetBranchFactor(SCIP_VAR *var)
SCIP_Real SCIPsetFloor(SCIP_SET *set, SCIP_Real val)
SCIP_RETCODE SCIPbranchruleExitsol(SCIP_BRANCHRULE *branchrule, SCIP_SET *set)
SCIP_Real SCIPnodeGetLowerbound(SCIP_NODE *node)
SCIP_PARAMDATA * SCIPparamGetData(SCIP_PARAM *param)
SCIP_Longint SCIPbranchruleGetNChildren(SCIP_BRANCHRULE *branchrule)
#define SCIP_DECL_BRANCHEXECPS(x)
SCIP_Longint ndomredsfound
internal methods for clocks and timing issues
int SCIPbranchcandGetNPseudoCands(SCIP_BRANCHCAND *branchcand)
SCIP_BRANCHRULEDATA * branchruledata
SCIP_Bool SCIPsetIsPositive(SCIP_SET *set, SCIP_Real val)
struct SCIP_ParamData SCIP_PARAMDATA
void SCIPbranchruleSetFree(SCIP_BRANCHRULE *branchrule, SCIP_DECL_BRANCHFREE((*branchfree)))
SCIP_Real SCIPvarGetLbLocal(SCIP_VAR *var)
struct SCIP_BranchruleData SCIP_BRANCHRULEDATA
SCIP_RETCODE SCIPbranchcandCreate(SCIP_BRANCHCAND **branchcand)
SCIP_Real SCIPsetInfinity(SCIP_SET *set)
SCIP_Real SCIPvarGetSol(SCIP_VAR *var, SCIP_Bool getlpval)
int SCIPbranchcandGetNPrioExternCands(SCIP_BRANCHCAND *branchcand)
const char * SCIPbranchruleGetDesc(SCIP_BRANCHRULE *branchrule)
SCIP_Real SCIPbranchGetScore(SCIP_SET *set, SCIP_VAR *var, SCIP_Real downgain, SCIP_Real upgain)
#define SCIP_DECL_BRANCHFREE(x)
void SCIPclockStop(SCIP_CLOCK *clck, SCIP_SET *set)
SCIP_Longint SCIPbranchruleGetNDomredsFound(SCIP_BRANCHRULE *branchrule)
SCIP_Bool SCIPsetIsFeasIntegral(SCIP_SET *set, SCIP_Real val)
SCIP_Real SCIPrelDiff(SCIP_Real val1, SCIP_Real val2)
SCIP_RETCODE SCIPbranchExecPseudo(BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_STAT *stat, SCIP_PROB *transprob, SCIP_PROB *origprob, SCIP_TREE *tree, SCIP_REOPT *reopt, SCIP_LP *lp, SCIP_BRANCHCAND *branchcand, SCIP_EVENTQUEUE *eventqueue, SCIP_Real cutoffbound, SCIP_Bool allowaddcons, SCIP_RESULT *result)
void SCIPclockStart(SCIP_CLOCK *clck, SCIP_SET *set)
int SCIPbranchcandGetNPrioPseudoImpls(SCIP_BRANCHCAND *branchcand)
int SCIPsnprintf(char *t, int len, const char *s,...)
enum SCIP_Retcode SCIP_RETCODE
int SCIPtreeGetCurrentDepth(SCIP_TREE *tree)
SCIP_Longint SCIPbranchruleGetNCutoffs(SCIP_BRANCHRULE *branchrule)
internal methods for branching rules and branching candidate storage
void SCIPbranchcandClearExternCands(SCIP_BRANCHCAND *branchcand)
int SCIPsetCalcMemGrowSize(SCIP_SET *set, int num)
SCIP_Real SCIPsetRound(SCIP_SET *set, SCIP_Real val)
#define SCIP_DECL_BRANCHEXECEXT(x)
SCIP_RETCODE SCIPbranchruleInitsol(SCIP_BRANCHRULE *branchrule, SCIP_SET *set)
static SCIP_RETCODE ensureLpcandsSize(SCIP_BRANCHCAND *branchcand, SCIP_SET *set, int num)
SCIP_Longint SCIPbranchruleGetNExternCalls(SCIP_BRANCHRULE *branchrule)
internal methods for handling parameter settings
SCIP_Bool SCIPsetIsNegative(SCIP_SET *set, SCIP_Real val)
void SCIPclockEnableOrDisable(SCIP_CLOCK *clck, SCIP_Bool enable)
#define SCIP_DECL_BRANCHEXITSOL(x)
#define BMSfreeMemory(ptr)
static SCIP_RETCODE ensureExterncandsSize(SCIP_BRANCHCAND *branchcand, SCIP_SET *set, int num)
SCIP_RETCODE SCIPbranchruleExecLPSol(SCIP_BRANCHRULE *branchrule, SCIP_SET *set, SCIP_STAT *stat, SCIP_TREE *tree, SCIP_SEPASTORE *sepastore, SCIP_Real cutoffbound, SCIP_Bool allowaddcons, SCIP_RESULT *result)
int SCIPbranchcandGetNPrioExternInts(SCIP_BRANCHCAND *branchcand)
SCIP_LPSOLSTAT SCIPlpGetSolstat(SCIP_LP *lp)
SCIP_Real SCIPsetCeil(SCIP_SET *set, SCIP_Real val)
internal methods for LP management
SCIP_Bool SCIPsetIsFeasFracIntegral(SCIP_SET *set, SCIP_Real val)
int SCIPbranchcandGetNPrioPseudoCands(SCIP_BRANCHCAND *branchcand)
SCIP_RETCODE SCIPbranchruleExecPseudoSol(SCIP_BRANCHRULE *branchrule, SCIP_SET *set, SCIP_STAT *stat, SCIP_TREE *tree, SCIP_Real cutoffbound, SCIP_Bool allowaddcons, SCIP_RESULT *result)
int SCIPlpGetNCols(SCIP_LP *lp)
SCIP_Longint nexterncalls
SCIP_Bool SCIPsetIsGE(SCIP_SET *set, SCIP_Real val1, SCIP_Real val2)
SCIP_RETCODE SCIPbranchExecLP(BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_STAT *stat, SCIP_PROB *transprob, SCIP_PROB *origprob, SCIP_TREE *tree, SCIP_REOPT *reopt, SCIP_LP *lp, SCIP_SEPASTORE *sepastore, SCIP_BRANCHCAND *branchcand, SCIP_EVENTQUEUE *eventqueue, SCIP_Real cutoffbound, SCIP_Bool allowaddcons, SCIP_RESULT *result)
int SCIPbranchcandGetNExternCands(SCIP_BRANCHCAND *branchcand)
SCIP_Bool SCIPsetIsLT(SCIP_SET *set, SCIP_Real val1, SCIP_Real val2)
SCIP_RETCODE SCIPbranchcandAddExternCand(SCIP_BRANCHCAND *branchcand, SCIP_SET *set, SCIP_VAR *var, SCIP_Real score, SCIP_Real solval)
#define SCIP_DECL_BRANCHINIT(x)
SCIP_RETCODE SCIPvarChgBranchPriority(SCIP_VAR *var, int branchpriority)
SCIP_Real SCIPcolGetPrimsol(SCIP_COL *col)
#define SCIP_DECL_BRANCHCOPY(x)
SCIP_RETCODE SCIPbranchcandGetExternCands(SCIP_BRANCHCAND *branchcand, SCIP_VAR ***externcands, SCIP_Real **externcandssol, SCIP_Real **externcandsscore, int *nexterncands, int *nprioexterncands, int *nprioexternbins, int *nprioexternints, int *nprioexternimpls)
#define BMSfreeMemoryArray(ptr)
internal methods for storing and manipulating the main problem
SCIP_Real SCIPbranchruleGetSetupTime(SCIP_BRANCHRULE *branchrule)
SCIP_Real SCIPbranchGetBranchingPoint(SCIP_SET *set, SCIP_TREE *tree, SCIP_VAR *var, SCIP_Real suggestion)
void SCIPclockReset(SCIP_CLOCK *clck)
SCIP_COL ** SCIPlpGetCols(SCIP_LP *lp)
#define SCIP_DECL_BRANCHINITSOL(x)
SCIP_RETCODE SCIPbranchruleExit(SCIP_BRANCHRULE *branchrule, SCIP_SET *set)
int SCIPsepastoreGetNCuts(SCIP_SEPASTORE *sepastore)
#define SCIP_DECL_BRANCHEXECLP(x)
const char * SCIPvarGetName(SCIP_VAR *var)
SCIP_RETCODE SCIPbranchcandGetPseudoCands(SCIP_BRANCHCAND *branchcand, SCIP_SET *set, SCIP_PROB *prob, SCIP_VAR ***pseudocands, int *npseudocands, int *npriopseudocands)
SCIP_Real SCIPclockGetTime(SCIP_CLOCK *clck)
void SCIPbranchruleSetInit(SCIP_BRANCHRULE *branchrule, SCIP_DECL_BRANCHINIT((*branchinit)))
SCIP_Real * externcandsscore
SCIP_RETCODE SCIPbranchcandGetLPCands(SCIP_BRANCHCAND *branchcand, SCIP_SET *set, SCIP_STAT *stat, SCIP_LP *lp, SCIP_VAR ***lpcands, SCIP_Real **lpcandssol, SCIP_Real **lpcandsfrac, int *nlpcands, int *npriolpcands, int *nfracimplvars)
SCIP_Real * externcandssol
SCIP_Longint SCIPbranchruleGetNConssFound(SCIP_BRANCHRULE *branchrule)
SCIP_Bool SCIPsetIsRelGT(SCIP_SET *set, SCIP_Real val1, SCIP_Real val2)
SCIP_RETCODE SCIPsetBranchrulePriority(SCIP *scip, SCIP_BRANCHRULE *branchrule, int priority)
static SCIP_RETCODE branchcandCalcLPCands(SCIP_BRANCHCAND *branchcand, SCIP_SET *set, SCIP_STAT *stat, SCIP_LP *lp)
internal methods for global SCIP settings
SCIP_Longint SCIPbranchruleGetNLPCalls(SCIP_BRANCHRULE *branchrule)
SCIP_Bool SCIPsetIsFeasGE(SCIP_SET *set, SCIP_Real val1, SCIP_Real val2)
SCIP_Real SCIPbranchruleGetTime(SCIP_BRANCHRULE *branchrule)
SCIP_RETCODE SCIPsetAddIntParam(SCIP_SET *set, SCIP_MESSAGEHDLR *messagehdlr, BMS_BLKMEM *blkmem, 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_Bool SCIPsetIsEQ(SCIP_SET *set, SCIP_Real val1, SCIP_Real val2)
SCIP_Bool SCIPbranchcandContainsExternCand(SCIP_BRANCHCAND *branchcand, SCIP_VAR *var)
internal methods for storing separated cuts
SCIP_Bool SCIPsetIsFeasLE(SCIP_SET *set, SCIP_Real val1, SCIP_Real val2)
#define BMSduplicateMemoryArray(ptr, source, num)
SCIP_Longint nprobboundchgs
SCIP_RETCODE SCIPclockCreate(SCIP_CLOCK **clck, SCIP_CLOCKTYPE clocktype)
void SCIPbranchruleSetMaxdepth(SCIP_BRANCHRULE *branchrule, int maxdepth)
SCIP_Longint SCIPbranchruleGetNCutsFound(SCIP_BRANCHRULE *branchrule)
internal methods for problem variables
void SCIPbranchruleSetExecLp(SCIP_BRANCHRULE *branchrule, SCIP_DECL_BRANCHEXECLP((*branchexeclp)))
void SCIPbranchruleSetPriority(SCIP_BRANCHRULE *branchrule, SCIP_SET *set, int priority)
SCIP_Bool SCIPsetIsIntegral(SCIP_SET *set, SCIP_Real val)
SCIP_Longint npseudocalls
SCIP_Real SCIPsetSumepsilon(SCIP_SET *set)
int SCIPbranchcandGetNPrioExternConts(SCIP_BRANCHCAND *branchcand)
static const char * paramname[]
int SCIPvarGetBranchPriority(SCIP_VAR *var)
void SCIPclockFree(SCIP_CLOCK **clck)
void SCIPbranchruleSetData(SCIP_BRANCHRULE *branchrule, SCIP_BRANCHRULEDATA *branchruledata)
void SCIPbranchruleEnableOrDisableClocks(SCIP_BRANCHRULE *branchrule, SCIP_Bool enable)
SCIP_Bool SCIPsetIsRelLT(SCIP_SET *set, SCIP_Real val1, SCIP_Real val2)
static SCIP_DECL_PARAMCHGD(paramChgdBranchrulePriority)
SCIP_Bool SCIPtreeHasCurrentNodeLP(SCIP_TREE *tree)
SCIP_COL * SCIPvarGetCol(SCIP_VAR *var)
SCIP_Real SCIPbranchGetScoreMultiple(SCIP_SET *set, SCIP_VAR *var, int nchildren, SCIP_Real *gains)
SCIP_RETCODE SCIPbranchcandUpdateVar(SCIP_BRANCHCAND *branchcand, SCIP_SET *set, SCIP_VAR *var)
void SCIPbranchruleSetExecPs(SCIP_BRANCHRULE *branchrule, SCIP_DECL_BRANCHEXECPS((*branchexecps)))
SCIP_RETCODE SCIPbranchruleExecExternSol(SCIP_BRANCHRULE *branchrule, SCIP_SET *set, SCIP_STAT *stat, SCIP_TREE *tree, SCIP_SEPASTORE *sepastore, SCIP_Real cutoffbound, SCIP_Bool allowaddcons, SCIP_RESULT *result)
void SCIPbranchcandInvalidate(SCIP_BRANCHCAND *branchcand)
#define SCIP_MAXTREEDEPTH
SCIP_RETCODE SCIPbranchcandFree(SCIP_BRANCHCAND **branchcand)
void SCIPbranchruleSetInitsol(SCIP_BRANCHRULE *branchrule, SCIP_DECL_BRANCHINITSOL((*branchinitsol)))
int SCIPbranchruleGetMaxdepth(SCIP_BRANCHRULE *branchrule)
SCIP_Real SCIPsetFeasFrac(SCIP_SET *set, SCIP_Real val)
int SCIPparamGetInt(SCIP_PARAM *param)
void SCIPbranchruleSetExecExt(SCIP_BRANCHRULE *branchrule, SCIP_DECL_BRANCHEXECEXT((*branchexecext)))
void SCIPsetSortBranchrules(SCIP_SET *set)
SCIP_Longint SCIPbranchruleGetNPseudoCalls(SCIP_BRANCHRULE *branchrule)
void SCIPbranchruleSetExitsol(SCIP_BRANCHRULE *branchrule, SCIP_DECL_BRANCHEXITSOL((*branchexitsol)))
SCIP_RETCODE SCIPbranchruleInit(SCIP_BRANCHRULE *branchrule, SCIP_SET *set)
SCIP_RETCODE SCIPbranchruleCopyInclude(SCIP_BRANCHRULE *branchrule, SCIP_SET *set)
int SCIPbranchcandGetNPrioPseudoBins(SCIP_BRANCHCAND *branchcand)
SCIP_Longint validlpcandslp
SCIP_VARSTATUS SCIPvarGetStatus(SCIP_VAR *var)
static void branchcandSortPseudoCands(SCIP_BRANCHCAND *branchcand)
internal methods for problem statistics
const char * SCIPbranchruleGetName(SCIP_BRANCHRULE *branchrule)
datastructures for branching rules and branching candidate storage
SCIP_RETCODE SCIPbranchruleFree(SCIP_BRANCHRULE **branchrule, SCIP_SET *set)
SCIP_Bool SCIPsetIsFeasPositive(SCIP_SET *set, SCIP_Real val)
#define BMSallocMemory(ptr)
#define BMSreallocMemoryArray(ptr, num)
void SCIPbranchruleSetMaxbounddist(SCIP_BRANCHRULE *branchrule, SCIP_Real maxbounddist)
void SCIPbranchruleSetExit(SCIP_BRANCHRULE *branchrule, SCIP_DECL_BRANCHEXIT((*branchexit)))
static void branchcandRemovePseudoCand(SCIP_BRANCHCAND *branchcand, SCIP_VAR *var)
static void branchcandInsertPseudoCand(SCIP_BRANCHCAND *branchcand, SCIP_VAR *var, int insertpos)
SCIP_RETCODE SCIPbranchcandRemoveVar(SCIP_BRANCHCAND *branchcand, SCIP_VAR *var)
SCIP_VARTYPE SCIPvarGetType(SCIP_VAR *var)
SCIP_Real SCIPvarGetMultaggrUbLocal(SCIP_VAR *var, SCIP_SET *set)
SCIP_Real SCIPsetEpsilon(SCIP_SET *set)
int SCIPbranchcandGetNPrioPseudoInts(SCIP_BRANCHCAND *branchcand)
enum SCIP_Vartype SCIP_VARTYPE
SCIP_Real SCIPvarGetUbLocal(SCIP_VAR *var)
SCIP_Real SCIPtreeGetLowerbound(SCIP_TREE *tree, SCIP_SET *set)
common defines and data types used in all packages of SCIP
struct BMS_BlkMem BMS_BLKMEM
SCIP_RETCODE SCIPsetAddRealParam(SCIP_SET *set, SCIP_MESSAGEHDLR *messagehdlr, BMS_BLKMEM *blkmem, 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 SCIPbranchExecExtern(BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_STAT *stat, SCIP_PROB *transprob, SCIP_PROB *origprob, SCIP_TREE *tree, SCIP_REOPT *reopt, SCIP_LP *lp, SCIP_SEPASTORE *sepastore, SCIP_BRANCHCAND *branchcand, SCIP_EVENTQUEUE *eventqueue, SCIP_Real cutoffbound, SCIP_Bool allowaddcons, SCIP_RESULT *result)
SCIP_Longint nprobholechgs
SCIP_Real SCIPvarGetMultaggrLbLocal(SCIP_VAR *var, SCIP_SET *set)
#define SCIP_DECL_BRANCHEXIT(x)
SCIP_Bool SCIPsetIsFeasNegative(SCIP_SET *set, SCIP_Real val)
SCIP_RETCODE SCIPbranchcandUpdateVarBranchPriority(SCIP_BRANCHCAND *branchcand, SCIP_SET *set, SCIP_VAR *var, int branchpriority)
int SCIPbranchcandGetNPrioExternImpls(SCIP_BRANCHCAND *branchcand)
int SCIPbranchruleGetPriority(SCIP_BRANCHRULE *branchrule)
static SCIP_RETCODE ensurePseudocandsSize(SCIP_BRANCHCAND *branchcand, SCIP_SET *set, int num)
memory allocation routines