13#ifndef MINOTAURTREEMANAGER_H
14#define MINOTAURTREEMANAGER_H
141 void setUb(
double value);
166 double bestLowerBound_;
169 double bestUpperBound_;
196 std::ofstream vbcFile_;
199 bool shouldPrune_(
NodePtr node);
207 void insertCandidate_(
NodePtr node,
bool pop_now =
false);
216 void removeNodeAndUp_(
NodePtr node);
224 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:119
void insertRoot(NodePtr node)
Insert the root node into the tree.
Definition: TreeManager.cpp:284
double getUb()
Return the best known upper bound.
Definition: TreeManager.cpp:254
double getLb()
Return the value of the highest lower bound evaluated in the last update of he bound.
Definition: TreeManager.cpp:242
double updateLb()
Recalculate and return the lower bound of the tree.
Definition: TreeManager.cpp:418
void setCutOff(double value)
Set the cut off value for the objective function.
Definition: TreeManager.cpp:382
NodePtr branch(Branches branches, NodePtr node, WarmStartPtr ws)
Branch and create new nodes.
Definition: TreeManager.cpp:125
UInt getSize() const
Return the size of the tree, including both active and processed nodes.
Definition: TreeManager.cpp:248
double getPerGap()
Return the gap between the lower and upper bound as a percentage. It is calculated as .
Definition: TreeManager.cpp:221
~TreeManager()
Destroy.
Definition: TreeManager.cpp:108
double getCutOff()
Return the cut off value. It is INFINITY if it is not set.
Definition: TreeManager.cpp:215
UInt getActiveNodes() const
Return the number of active nodes, i.e. nodes that have been created, but not processed yet.
Definition: TreeManager.cpp:184
void removeActiveNode(NodePtr node)
Remove a given active node from storage.
Definition: TreeManager.cpp:308
bool shouldDive()
Return true if the tree-manager recommends diving. False otherwise.
Definition: TreeManager.cpp:397
TreeManager(EnvPtr env)
Constructor.
Definition: TreeManager.cpp:25
void setSearchType(TreeSearchOrder newType)
Set the search type for the tree manager.
Definition: TreeManager.cpp:82
void setUb(double value)
Set the best known objective function value.
Definition: TreeManager.cpp:388
void pruneNode(NodePtr node)
Prune a given node from the tree.
Definition: TreeManager.cpp:301
NodePtr getCandidate()
Search for the best candidate that can be processed next.
Definition: TreeManager.cpp:190
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