Scippy

GCG

Branch-and-Price & Column Generation for Everyone

cons_masterbranch.h File Reference

Detailed Description

constraint handler for storing the branching decisions at each node of the tree

Author
Gerald Gamrath
Martin Bergner
Christian Puchert
Marcel Schmickerath

Definition in file cons_masterbranch.h.

#include "scip/scip.h"
#include "type_branchgcg.h"

Go to the source code of this file.

Functions

SCIP_RETCODE SCIPincludeConshdlrMasterbranch (SCIP *scip)
 
SCIP_RETCODE GCGcreateConsMasterbranch (SCIP *scip, SCIP_CONS **cons, const char *name, SCIP_NODE *node, SCIP_CONS *parentcons, SCIP_BRANCHRULE *branchrule, GCG_BRANCHDATA *branchdata, SCIP_CONS **origbranchconss, int norigbranchconss, int maxorigbranchconss)
 
char * GCGconsMasterbranchGetName (SCIP_CONS *cons)
 
SCIP_NODE * GCGconsMasterbranchGetNode (SCIP_CONS *cons)
 
SCIP_CONS * GCGconsMasterbranchGetParentcons (SCIP_CONS *cons)
 
int GCGconsMasterbranchGetNChildconss (SCIP_CONS *cons)
 
SCIP_CONS * GCGconsMasterbranchGetChildcons (SCIP_CONS *cons, int childnr)
 
SCIP_CONS * GCGconsMasterbranchGetOrigcons (SCIP_CONS *cons)
 
void GCGconsMasterbranchSetOrigcons (SCIP_CONS *cons, SCIP_CONS *origcons)
 
GCG_BRANCHDATAGCGconsMasterbranchGetBranchdata (SCIP_CONS *cons)
 
SCIP_BRANCHRULE * GCGconsMasterbranchGetBranchrule (SCIP_CONS *cons)
 
SCIP_RETCODE GCGconsMasterbranchAddCopiedVarBndchg (SCIP *scip, SCIP_CONS *cons, SCIP_VAR *var, GCG_BOUNDTYPE boundtype, SCIP_Real newbound)
 
SCIP_CONS ** GCGconsMasterbranchGetOrigbranchConss (SCIP_CONS *cons)
 
int GCGconsMasterbranchGetNOrigbranchConss (SCIP_CONS *cons)
 
SCIP_RETCODE GCGconsMasterbranchReleaseOrigbranchConss (SCIP *masterscip, SCIP *origscip, SCIP_CONS *cons)
 
SCIP_CONS * GCGconsMasterbranchGetActiveCons (SCIP *scip)
 
void GCGconsMasterbranchGetStack (SCIP *scip, SCIP_CONS ***stack, int *nstackelements)
 
int GCGconsMasterbranchGetNStackelements (SCIP *scip)
 
SCIP_RETCODE GCGconsMasterbranchAddRootCons (SCIP *scip)
 
SCIP_Bool GCGcurrentNodeIsGeneric (SCIP *scip)
 
void GCGconsMasterbranchCheckConsistency (SCIP *scip)
 

Function Documentation

◆ SCIPincludeConshdlrMasterbranch()

SCIP_RETCODE SCIPincludeConshdlrMasterbranch ( SCIP *  scip)

◆ GCGcreateConsMasterbranch()

SCIP_RETCODE GCGcreateConsMasterbranch ( SCIP *  scip,
SCIP_CONS **  cons,
const char *  name,
SCIP_NODE *  node,
SCIP_CONS *  parentcons,
SCIP_BRANCHRULE *  branchrule,
GCG_BRANCHDATA branchdata,
SCIP_CONS **  origbranchconss,
int  norigbranchconss,
int  maxorigbranchconss 
)

◆ GCGconsMasterbranchGetName()

char* GCGconsMasterbranchGetName ( SCIP_CONS *  cons)

returns the name of the constraint

Definition at line 2391 of file cons_masterbranch.c.

Referenced by createOrigbranchConstraint().

◆ GCGconsMasterbranchGetNode()

SCIP_NODE* GCGconsMasterbranchGetNode ( SCIP_CONS *  cons)

returns the node in the B&B tree at which the given masterbranch constraint is sticking

Definition at line 2404 of file cons_masterbranch.c.

Referenced by createBranchNodesInOrigprob(), GCGcurrentNodeIsGeneric(), and SCIP_DECL_NODESELSELECT().

◆ GCGconsMasterbranchGetParentcons()

SCIP_CONS* GCGconsMasterbranchGetParentcons ( SCIP_CONS *  cons)

returns the masterbranch constraint of the B&B father of the node at which the given masterbranch constraint is sticking

Definition at line 2419 of file cons_masterbranch.c.

Referenced by GCGbranchGenericInitbranch(), pruneChildNodeByDominanceGeneric(), and SCIP_DECL_EVENTEXEC().

◆ GCGconsMasterbranchGetNChildconss()

int GCGconsMasterbranchGetNChildconss ( SCIP_CONS *  cons)

returns the number of masterbranch constraints of the children of the node at which the given masterbranch constraint is sticking

Definition at line 2434 of file cons_masterbranch.c.

Referenced by checkchildconsS(), and createBranchNodesInOrigprob().

◆ GCGconsMasterbranchGetChildcons()

SCIP_CONS* GCGconsMasterbranchGetChildcons ( SCIP_CONS *  cons,
int  childnr 
)

returns a masterbranch constraint of a child of the node at which the given masterbranch constraint is sticking

Definition at line 2449 of file cons_masterbranch.c.

Referenced by checkchildconsS(), and createBranchNodesInOrigprob().

◆ GCGconsMasterbranchGetOrigcons()

SCIP_CONS* GCGconsMasterbranchGetOrigcons ( SCIP_CONS *  cons)

returns the origbranch constraint of the node in the original program corresponding to the node which the given masterbranch constraint is sticking

returns the origbranch constraint of the node in the original program corresponding to the node at which the given masterbranch constraint is sticking

Definition at line 2468 of file cons_masterbranch.c.

Referenced by GCGconsOrigbranchCheckConsistency(), and SCIP_DECL_CONSDELETE().

◆ GCGconsMasterbranchSetOrigcons()

void GCGconsMasterbranchSetOrigcons ( SCIP_CONS *  cons,
SCIP_CONS *  origcons 
)

sets the origbranch constraint of the node in the master program corresponding to the node at which the given masterbranchbranch constraint is sticking

Definition at line 2483 of file cons_masterbranch.c.

Referenced by createOrigbranchConstraint(), and SCIP_DECL_CONSDELETE().

◆ GCGconsMasterbranchGetBranchdata()

GCG_BRANCHDATA* GCGconsMasterbranchGetBranchdata ( SCIP_CONS *  cons)

returns the branching data for a given masterbranch constraint

Definition at line 2498 of file cons_masterbranch.c.

Referenced by applyOriginalBranching(), checkchildconsS(), createOrigbranchConstraint(), GCGbranchGenericInitbranch(), pruneChildNodeByDominanceGeneric(), and SCIP_DECL_EVENTEXEC().

◆ GCGconsMasterbranchGetBranchrule()

SCIP_BRANCHRULE* GCGconsMasterbranchGetBranchrule ( SCIP_CONS *  cons)

◆ GCGconsMasterbranchAddCopiedVarBndchg()

SCIP_RETCODE GCGconsMasterbranchAddCopiedVarBndchg ( SCIP *  scip,
SCIP_CONS *  cons,
SCIP_VAR *  var,
GCG_BOUNDTYPE  boundtype,
SCIP_Real  newbound 
)

adds a bound change on an original variable that was directly copied to the master problem

Definition at line 2524 of file cons_masterbranch.c.

References GCGisMaster().

Referenced by applyOriginalBranching().

◆ GCGconsMasterbranchGetOrigbranchConss()

SCIP_CONS** GCGconsMasterbranchGetOrigbranchConss ( SCIP_CONS *  cons)

returns the constraints in the original problem that enforce the branching decision

Definition at line 2568 of file cons_masterbranch.c.

Referenced by createOrigbranchConstraint().

◆ GCGconsMasterbranchGetNOrigbranchConss()

int GCGconsMasterbranchGetNOrigbranchConss ( SCIP_CONS *  cons)

returns the number of constraints in the original problem that enforce the branching decision

Definition at line 2581 of file cons_masterbranch.c.

Referenced by createOrigbranchConstraint().

◆ GCGconsMasterbranchReleaseOrigbranchConss()

SCIP_RETCODE GCGconsMasterbranchReleaseOrigbranchConss ( SCIP *  masterscip,
SCIP *  origscip,
SCIP_CONS *  cons 
)

releases the constraints in the original problem that enforce the branching decision and frees the array holding the constraints

Definition at line 2596 of file cons_masterbranch.c.

References GCGisMaster(), and GCGisOriginal().

Referenced by createOrigbranchConstraint(), and SCIP_DECL_CONSDELETE().

◆ GCGconsMasterbranchGetActiveCons()

◆ GCGconsMasterbranchGetStack()

void GCGconsMasterbranchGetStack ( SCIP *  scip,
SCIP_CONS ***  stack,
int *  nstackelements 
)

returns the stack and the number of elements on it

Definition at line 2655 of file cons_masterbranch.c.

References CONSHDLR_NAME.

◆ GCGconsMasterbranchGetNStackelements()

int GCGconsMasterbranchGetNStackelements ( SCIP *  scip)

returns the number of elements on the stack

Definition at line 2677 of file cons_masterbranch.c.

References CONSHDLR_NAME.

◆ GCGconsMasterbranchAddRootCons()

SCIP_RETCODE GCGconsMasterbranchAddRootCons ( SCIP *  scip)

adds initial constraint to root node

Definition at line 2696 of file cons_masterbranch.c.

References CONSHDLR_NAME.

Referenced by SCIP_DECL_PRICERFARKAS(), and SCIP_DECL_PRICERREDCOST().

◆ GCGcurrentNodeIsGeneric()

SCIP_Bool GCGcurrentNodeIsGeneric ( SCIP *  scip)

◆ GCGconsMasterbranchCheckConsistency()

void GCGconsMasterbranchCheckConsistency ( SCIP *  scip)

checks the consistency of the masterbranch constraints in the problem

Definition at line 2747 of file cons_masterbranch.c.

References CONSHDLR_NAME, GCGconsOrigbranchGetMastercons(), and GCGconsOrigbranchGetParentcons().

Referenced by SCIP_DECL_NODESELSELECT().