#include <CbcTree.hpp>
Inheritance diagram for CbcTree:
Public Member Functions | |
CbcTree () | |
CbcTree (const CbcTree &rhs) | |
CbcTree & | operator= (const CbcTree &rhs) |
virtual | ~CbcTree () |
virtual CbcTree * | clone () const |
Clone. | |
Heap access and maintenance methods | |
void | setComparison (CbcCompareBase &compare) |
Set comparison function and resort heap. | |
virtual CbcNode * | top () |
Return the top node of the heap. | |
virtual void | push (CbcNode *x) |
Add a node to the heap. | |
virtual void | pop () |
Remove the top node from the heap. | |
virtual CbcNode * | bestNode (double cutoff) |
Gets best node and takes off heap. | |
vector methods | |
virtual bool | empty () |
Test if empty *** note may be overridden. | |
int | size () const |
Return size. | |
CbcNode * | operator[] (int i) const |
[] operator | |
CbcNode * | nodePointer (int i) const |
Return a node pointer. | |
Search tree maintenance | |
void | cleanTree (CbcModel *model, double cutoff, double &bestPossibleObjective) |
Prune the tree using an objective function cutoff. | |
CbcNode * | bestAlternate () |
Get best on list using alternate method. | |
virtual void | endSearch () |
We may have got an intelligent tree so give it one more chance. | |
Protected Attributes | |
std::vector< CbcNode * > | nodes_ |
CbcCompare | comparison_ |
Definition at line 16 of file CbcTree.hpp.
CbcTree::CbcTree | ( | ) |
CbcTree::CbcTree | ( | const CbcTree & | rhs | ) |
virtual CbcTree::~CbcTree | ( | ) | [virtual] |
virtual CbcTree* CbcTree::clone | ( | ) | const [virtual] |
void CbcTree::setComparison | ( | CbcCompareBase & | compare | ) |
Set comparison function and resort heap.
virtual CbcNode* CbcTree::top | ( | ) | [virtual] |
virtual void CbcTree::push | ( | CbcNode * | x | ) | [virtual] |
virtual void CbcTree::pop | ( | ) | [virtual] |
virtual CbcNode* CbcTree::bestNode | ( | double | cutoff | ) | [virtual] |
Gets best node and takes off heap.
virtual bool CbcTree::empty | ( | ) | [virtual] |
int CbcTree::size | ( | ) | const [inline] |
CbcNode* CbcTree::operator[] | ( | int | i | ) | const [inline] |
CbcNode* CbcTree::nodePointer | ( | int | i | ) | const [inline] |
void CbcTree::cleanTree | ( | CbcModel * | model, | |
double | cutoff, | |||
double & | bestPossibleObjective | |||
) |
Prune the tree using an objective function cutoff.
This routine removes all nodes with objective worst than the specified cutoff value. It also sets bestPossibleObjective to best of all on tree before deleting.
CbcNode* CbcTree::bestAlternate | ( | ) |
Get best on list using alternate method.
virtual void CbcTree::endSearch | ( | ) | [inline, virtual] |
We may have got an intelligent tree so give it one more chance.
Reimplemented in CbcTreeLocal.
Definition at line 88 of file CbcTree.hpp.
std::vector<CbcNode *> CbcTree::nodes_ [protected] |
CbcCompare CbcTree::comparison_ [protected] |
Definition at line 92 of file CbcTree.hpp.