|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.ObjectJaCoP.constraints.netflow.simplex.Node
public final class Node
A node (vertex) in the network.
| Field Summary | |
|---|---|
Arc[] |
adjacencyList
adjacency list (recorded when degree reaches 2) |
Arc |
artificial
connects this node to the root |
int |
balance
balance of the last feasible flow |
int |
degree
number of connected arcs |
int |
deltaBalance
change in balance for the next flow computation |
int |
depth
|
int |
initialBalance
for debug only |
java.lang.String |
name
a label, great for debugging |
Node |
parent
|
int |
potential
the potential (or dual variable) of the network simplex |
Node |
thread
|
Arc |
toParent
|
| Constructor Summary | |
|---|---|
Node(java.lang.String name,
int balance)
|
|
| Method Summary | |
|---|---|
Node |
lca(Node that)
Finds the root of the smallest subtree that contains both this node and that node. |
void |
markTree(boolean setMark)
Sets or clears a mark on a subtree rooted at this node |
Node |
predecessorOnThread()
Finds the predecessor of this node on the thread. |
Node |
rightMostLeaf()
Finds the last node on the thread that has a larger depth than this node. |
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public final int initialBalance
public final java.lang.String name
public int potential
public int balance
public int deltaBalance
public Arc artificial
public Arc toParent
public Node parent
public Node thread
public int depth
public int degree
public Arc[] adjacencyList
| Constructor Detail |
|---|
public Node(java.lang.String name,
int balance)
| Method Detail |
|---|
public Node lca(Node that)
that - another node
public Node rightMostLeaf()
public Node predecessorOnThread()
public void markTree(boolean setMark)
setMark - whether to set or clear the markpublic java.lang.String toString()
toString in class java.lang.Object
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||