FullBpGraph is a simple and fast implmenetation of undirected full bipartite graphs. It contains an edge between every red-blue pairs of nodes, therefore the number of edges is nr*nb
. This class is completely static and it needs constant memory space. Thus you can neither add nor delete nodes or edges, however the structure can be resized using resize().
This type fully conforms to the BpGraph concept. Most of its member functions and nested classes are documented only in the concept class.
This class provides constant time counting for nodes, edges and arcs.
- See Also
- FullGraph
Inherits BpGraphExtender< Base >.
|
| FullBpGraph () |
| Default constructor.
|
|
| FullBpGraph (int redNum, int blueNum) |
| Constructor.
|
|
void | resize (int redNum, int blueNum) |
| Resizes the graph.
|
|
RedNode | redNode (int index) const |
| Returns the red node with the given index.
|
|
int | index (RedNode node) const |
| Returns the index of the given red node.
|
|
BlueNode | blueNode (int index) const |
| Returns the blue node with the given index.
|
|
int | index (BlueNode node) const |
| Returns the index of the given blue node.
|
|
Edge | edge (const Node &u, const Node &v) const |
|
Arc | arc (const Node &u, const Node &v) const |
|
int | nodeNum () const |
| Number of nodes.
|
|
int | redNum () const |
| Number of red nodes.
|
|
int | blueNum () const |
| Number of blue nodes.
|
|
int | arcNum () const |
| Number of arcs.
|
|
int | edgeNum () const |
| Number of edges.
|
|