13#ifndef MINOTAURTREEMANAGER_H
14#define MINOTAURTREEMANAGER_H
137 void setUb(
double value);
162 double bestLowerBound_;
165 double bestUpperBound_;
192 std::ofstream vbcFile_;
195 bool shouldPrune_(
NodePtr node);
203 void insertCandidate_(
NodePtr node,
bool pop_now =
false);
212 void removeNodeAndUp_(
NodePtr node);
220 void removeNode_(
NodePtr node);
Declare the base class ActiveNodeStore for storing active nodes of the branch-and-bound tree.
Define the Environment class.
Declare important 'types' used in Minotaur.
Save and retrieve active nodes.
Definition: ActiveNodeStore.h:31
Definition: Environment.h:28
Base class for managing the branch-and-bound tree.
Definition: TreeManager.h:29
bool anyActiveNodesLeft()
Return true if any active nodes remain in the tree. False otherwise.
Definition: TreeManager.cpp:89
void insertRoot(NodePtr node)
Insert the root node into the tree.
Definition: TreeManager.cpp:254
double getUb()
Return the best known upper bound.
Definition: TreeManager.cpp:224
double getLb()
Return the value of the highest lower bound evaluated in the last update of he bound.
Definition: TreeManager.cpp:212
double updateLb()
Recalculate and return the lower bound of the tree.
Definition: TreeManager.cpp:388
void setCutOff(double value)
Set the cut off value for the objective function.
Definition: TreeManager.cpp:352
NodePtr branch(Branches branches, NodePtr node, WarmStartPtr ws)
Branch and create new nodes.
Definition: TreeManager.cpp:95
UInt getSize() const
Return the size of the tree, including both active and processed nodes.
Definition: TreeManager.cpp:218
double getPerGap()
Return the gap between the lower and upper bound as a percentage. It is calculated as .
Definition: TreeManager.cpp:191
~TreeManager()
Destroy.
Definition: TreeManager.cpp:78
double getCutOff()
Return the cut off value. It is INFINITY if it is not set.
Definition: TreeManager.cpp:185
UInt getActiveNodes() const
Return the number of active nodes, i.e. nodes that have been created, but not processed yet.
Definition: TreeManager.cpp:154
void removeActiveNode(NodePtr node)
Remove a given active node from storage.
Definition: TreeManager.cpp:278
bool shouldDive()
Return true if the tree-manager recommends diving. False otherwise.
Definition: TreeManager.cpp:367
TreeManager(EnvPtr env)
Constructor.
Definition: TreeManager.cpp:25
void setUb(double value)
Set the best known objective function value.
Definition: TreeManager.cpp:358
void pruneNode(NodePtr node)
Prune a given node from the tree.
Definition: TreeManager.cpp:271
NodePtr getCandidate()
Search for the best candidate that can be processed next.
Definition: TreeManager.cpp:160
Definition: WarmStart.h:45
Definition: ActiveNodeStore.h:20
unsigned int UInt
Unsigned integer.
Definition: Types.h:30
TreeSearchOrder
Order of tree search.
Definition: Types.h:237