Couenne::DepNode Class Reference

vertex of a dependence graph. More...

#include <CouenneDepGraph.hpp>

List of all members.

Public Types

 DEP_WHITE
 DEP_GRAY
 DEP_BLACK
enum  dep_color { DEP_WHITE, DEP_GRAY, DEP_BLACK }
 color used in DFS for checking cycles More...

Public Member Functions

 DepNode (int ind)
 fictitious constructor: only fill in index (such object is used in find() and then discarded)
 ~DepNode ()
 destructor
int Index () const
 return index of this variable
int Order () const
 return index of this variable
std::set< DepNode *, compNode > * DepList () const
 return all variables it depends on
bool depends (int xi, bool=false, std::set< DepNode *, compNode > *already_visited=NULL) const
 does this variable depend on variable with index xi?
void createOrder (DepGraph *)
 assign numbering to all nodes of graph
void print (int=0, bool descend=false) const
 debugging procedure
enum dep_colorcolor ()
 return or set color of a node
std::set< DepNode *, compNode > * depList ()
 index nodes on which this one depends (forward star in dependence graph)
void replaceIndex (DepNode *oldVarNode, DepNode *newVarNode)
 replace the index of a variable with another in the entire graph.

Protected Attributes

int index_
 index of variable associated with node
std::set< DepNode *, compNode > * depList_
 index nodes on which this one depends (forward star in dependence graph)
int order_
 order in which this variable should be updated, evaluated, etc.
enum dep_color color_
 color used in DFS for checking cycles


Detailed Description

vertex of a dependence graph.

Contains variable and its forward star (all variables it depends on)

Definition at line 33 of file CouenneDepGraph.hpp.


Member Enumeration Documentation

enum Couenne::DepNode::dep_color

color used in DFS for checking cycles

Enumerator:
DEP_WHITE 
DEP_GRAY 
DEP_BLACK 

Definition at line 38 of file CouenneDepGraph.hpp.


Constructor & Destructor Documentation

Couenne::DepNode::DepNode ( int  ind  )  [inline]

fictitious constructor: only fill in index (such object is used in find() and then discarded)

Definition at line 59 of file CouenneDepGraph.hpp.

Couenne::DepNode::~DepNode (  )  [inline]

destructor

Definition at line 66 of file CouenneDepGraph.hpp.

References depList_.


Member Function Documentation

int Couenne::DepNode::Index (  )  const [inline]

return index of this variable

Definition at line 70 of file CouenneDepGraph.hpp.

References index_.

int Couenne::DepNode::Order (  )  const [inline]

return index of this variable

Definition at line 74 of file CouenneDepGraph.hpp.

References order_.

std::set<DepNode *, compNode>* Couenne::DepNode::DepList (  )  const [inline]

return all variables it depends on

Definition at line 78 of file CouenneDepGraph.hpp.

References depList_.

bool Couenne::DepNode::depends ( int  xi,
bool  = false,
std::set< DepNode *, compNode > *  already_visited = NULL 
) const

does this variable depend on variable with index xi?

void Couenne::DepNode::createOrder ( DepGraph  ) 

assign numbering to all nodes of graph

void Couenne::DepNode::print ( int  = 0,
bool  descend = false 
) const

debugging procedure

enum dep_color& Couenne::DepNode::color (  )  [inline]

return or set color of a node

Definition at line 92 of file CouenneDepGraph.hpp.

References color_.

std::set<DepNode *, compNode>* Couenne::DepNode::depList (  )  [inline]

index nodes on which this one depends (forward star in dependence graph)

Definition at line 97 of file CouenneDepGraph.hpp.

References depList_.

void Couenne::DepNode::replaceIndex ( DepNode oldVarNode,
DepNode newVarNode 
)

replace the index of a variable with another in the entire graph.

Used when redundant constraints w := x are discovered


Member Data Documentation

int Couenne::DepNode::index_ [protected]

index of variable associated with node

Definition at line 43 of file CouenneDepGraph.hpp.

Referenced by Index().

std::set<DepNode *, compNode>* Couenne::DepNode::depList_ [protected]

index nodes on which this one depends (forward star in dependence graph)

Definition at line 47 of file CouenneDepGraph.hpp.

Referenced by depList(), DepList(), and ~DepNode().

int Couenne::DepNode::order_ [protected]

order in which this variable should be updated, evaluated, etc.

Definition at line 50 of file CouenneDepGraph.hpp.

Referenced by Order().

enum dep_color Couenne::DepNode::color_ [protected]

color used in DFS for checking cycles

Definition at line 53 of file CouenneDepGraph.hpp.

Referenced by color().


The documentation for this class was generated from the following file:
Generated on Mon Aug 8 03:07:02 2011 for Couenne by  doxygen 1.4.7