FRAMES NO FRAMES

Class IlcSearchNode

Definition file: ilsolver/search.h
Include file: <ilsolver/ilosolver.h>

Instances of this class represent nodes in the search tree of a parallel search. Most of its member functions access information of use to node evaluators. Node evaluators are documented in the class IlcNodeEvaluator.

The following figure illustrates a search tree consisting of its root node and choice points. Its maximum or-depth is three. It shows the number of discrepancies at the leaves. A discrepancy corresponds to the or-depth of that search node minus its left-depth.

See Also:

Constructor Summary
public IlcSearchNode()
public IlcSearchNode(IlcSearchNodeI * impl)
Method Summary
public IlcFloatgetBitsetValue(IlcInt start, IlcInt length) const
public IlcIntgetDepth() const
public IlcSearchNodeI *getImpl() const
public IlcIntgetLastDiscrepancyDepth(IlcInt offset) const
public IlcIntgetLeftDepth() const
public IlcIntgetRightDepth() const
public IloSolvergetSolver() const
public IloSolverI *getSolverI() const
public voidoperator=(const IlcSearchNode & h)
Constructor Detail

IlcSearchNode

public IlcSearchNode()

This constructor creates an empty handle. You must initialize it before you use it.


IlcSearchNode

public IlcSearchNode(IlcSearchNodeI * impl)

This constructor creates a handle object from a pointer to an implementation object.


Method Detail

getBitsetValue

public IlcFloat getBitsetValue(IlcInt start, IlcInt length) const

Node evaluators use this member function. It first converts the path from the root to the node into a bitset, where 0 (zero) is a left move and 1 (one) a right move. Then it extracts from this bitset a sub-bitset starting from the position indicated by the parameter start and extending. It then converts this extracted bitset into an integer, using the convention that the least significant bit is to the left (corresponding to the choice points closer to the root of the search tree). This member function then casts this integer into a IlcFloat value and returns it.


getDepth

public IlcInt getDepth() const

Node evaluators use this member function. It returns the or-depth of the invoking search node.


getImpl

public IlcSearchNodeI * getImpl() const
This constructor creates an object by copying another one.

This member function returns a pointer to the implementation object of the invoking handle.


getLastDiscrepancyDepth

public IlcInt getLastDiscrepancyDepth(IlcInt offset) const

Node evaluators use this member function. It returns the or-depth of a particular node in the search tree; that node is the one located at offset number of right moves along the path from the root of the search tree to the invoking node.


getLeftDepth

public IlcInt getLeftDepth() const

Node evaluators use this member function. It returns the number of left moves in the path starting from the root of the search tree to the position of the invoking node.


getRightDepth

public IlcInt getRightDepth() const

Node evaluators use this member function. It returns the number of right moves in the path starting from the root of the search tree to the position of the invoking node.


getSolver

public IloSolver getSolver() const

This member function returns the solver that the invoking node belongs to.


getSolverI

public IloSolverI * getSolverI() const

This member function returns the implementation of the solver that the invoking node belongs to.


operator=

public void operator=(const IlcSearchNode & h)

This operator assigns an address to the handle pointer of the invoking object. That address is the location of the implementation object of the provided argument.