Bcps 0.95.1
|
This class contain the data for a BCPS search tree node. More...
#include <BcpsTreeNode.h>
Public Member Functions | |
BcpsTreeNode () | |
Default constructor. | |
virtual | ~BcpsTreeNode () |
Destructor. | |
virtual int | process (bool isRoot=false, bool rampUp=false) |
This methods performs the processing of the node. | |
virtual int | bound (BcpsModel *model)=0 |
Bounding procedure to estimate quality of this node. | |
virtual std::vector< CoinTriple< AlpsNodeDesc *, AlpsNodeStatus, double > > | branch ()=0 |
This method must be invoked on a pregnant node (which has all the information needed to create the children) and should create the children's decriptions. | |
const BcpsBranchObject * | branchObject () const |
Return the branching object. | |
void | setBranchObject (BcpsBranchObject *b) |
Set the branching object. | |
Protected Member Functions | |
virtual int | generateConstraints (BcpsModel *model, BcpsConstraintPool *conPool) |
Generate constraints. | |
virtual int | generateVariables (BcpsModel *model, BcpsVariablePool *varPool) |
Generate variables. | |
virtual int | chooseBranchingObject (BcpsModel *model)=0 |
Choose a branching object. | |
virtual int | installSubProblem (BcpsModel *model)=0 |
Extract node information (bounds, constraints, variables) from this node and load the information into the relaxation solver, such as linear programming solver. | |
virtual int | handleBoundingStatus (int status, bool &keepOn, bool &fathomed) |
Handle bounding status: | |
AlpsReturnStatus | encodeBcps (AlpsEncoded *encoded) const |
Pack Bcps portion of node into an encoded object. | |
Protected Attributes | |
BcpsBranchObject * | branchObject_ |
Branching object for this node, which has information of how to execute branching. | |
This class contain the data for a BCPS search tree node.
At this level, we consider a tree node to be simply a list of objects. The objects are organized by type. A differencing scheme is implemented here by looking for differences between the lists of each type in the current node and its parent.
Definition at line 47 of file BcpsTreeNode.h.
|
inline |
Default constructor.
Definition at line 100 of file BcpsTreeNode.h.
|
inlinevirtual |
Destructor.
Definition at line 103 of file BcpsTreeNode.h.
|
inlineprotectedvirtual |
Generate constraints.
The generated constraints are stored in constraint pool. The default implementation does nothing.
Definition at line 59 of file BcpsTreeNode.h.
|
inlineprotectedvirtual |
Generate variables.
The generated varaibles are stored in variable pool. The default implementation does nothing.
Definition at line 67 of file BcpsTreeNode.h.
|
protectedpure virtual |
Choose a branching object.
|
protectedpure virtual |
Extract node information (bounds, constraints, variables) from this node and load the information into the relaxation solver, such as linear programming solver.
|
inlineprotectedvirtual |
Handle bounding status:
staus | Input The solution status of bounding. |
keepOn | Output Whether to keep on bounding. |
fathomed | Output Whether this node is fathomed. |
Definition at line 92 of file BcpsTreeNode.h.
|
virtual |
This methods performs the processing of the node.
For branch and bound, this would mean performing the bounding operation. The minimum requirement for this method is that it change the status to either internal or fathomed so the tree manager can deal with it afterwards. The status of the node when it begins processing will be active.
|
pure virtual |
Bounding procedure to estimate quality of this node.
|
pure virtual |
This method must be invoked on a pregnant
node (which has all the information needed to create the children) and should create the children's decriptions.
The stati of the children can be any of the ones process()
can return.
|
inline |
Return the branching object.
Definition at line 124 of file BcpsTreeNode.h.
|
inline |
Set the branching object.
Definition at line 127 of file BcpsTreeNode.h.
|
inlineprotected |
Pack Bcps portion of node into an encoded object.
Definition at line 132 of file BcpsTreeNode.h.
|
protected |
Branching object for this node, which has information of how to execute branching.
Definition at line 53 of file BcpsTreeNode.h.