Functions for testing if a graph represents a (free) tree or forest.
More...
|
| class | ogdf::LCA |
| | Implements the <O(n log n), O(1)>-time "sparse table" algorithm by Bender and Farach-Colton to compute lowest common ancestors (LCAs) in arborescences (not arbitrary directed acyclic graphs). More...
|
| |
Functions for testing if a graph represents a (free) tree or forest.
◆ isArborescence() [1/2]
| bool ogdf::isArborescence |
( |
const Graph & |
G, |
|
|
node & |
root |
|
) |
| |
Returns true iff G represents an arborescence.
- Parameters
-
| G | is the input graph. |
| root | is assigned the root node (if true is returned). |
- Returns
- true if
G represents an arborescence, false otherwise.
◆ isArborescence() [2/2]
| bool ogdf::isArborescence |
( |
const Graph & |
G | ) |
|
|
inline |
Returns true iff G represents an arborescence.
- Parameters
-
- Returns
- true if
G represents an arborescence, false otherwise.
Definition at line 986 of file simple_graph_alg.h.
◆ isArborescenceForest() [1/2]
| bool ogdf::isArborescenceForest |
( |
const Graph & |
G, |
|
|
List< node > & |
roots |
|
) |
| |
Returns true iff G is a forest consisting only of arborescences.
- Parameters
-
| G | is the input graph. |
| roots | is assigned the list of root nodes of the arborescences in the forest. If false is returned, roots is undefined. |
- Returns
- true if
G represents an arborescence forest, false otherwise.
◆ isArborescenceForest() [2/2]
| bool ogdf::isArborescenceForest |
( |
const Graph & |
G | ) |
|
|
inline |
Returns true iff G is a forest consisting only of arborescences.
- Parameters
-
- Returns
- true if
G represents an arborescence forest, false otherwise.
Definition at line 942 of file simple_graph_alg.h.
◆ isForest() [1/2]
Returns true iff G is a forest consisting only of arborescences.
- Deprecated:
- "isArborescenceForest() should be used instead."
- Parameters
-
| G | is the input graph. |
| roots | is assigned the list of root nodes of the arborescences in the forest. If false is returned, roots is undefined. |
- Returns
- true if
G represents an arborescence forest, false otherwise.
Definition at line 953 of file simple_graph_alg.h.
◆ isForest() [2/2]
| bool ogdf::isForest |
( |
const Graph & |
G | ) |
|
|
inline |
Returns true iff G is a forest consisting only of arborescences.
- Deprecated:
- "isArborescenceForest() should be used instead."
- Parameters
-
- Returns
- true if
G represents an arborescence forest, false otherwise.
Definition at line 963 of file simple_graph_alg.h.
◆ isFreeForest()
| bool ogdf::isFreeForest |
( |
const Graph & |
G | ) |
|
|
inline |
Returns true iff the undirected graph G is acyclic.
- Deprecated:
- "isAcyclicUndirected() should be used instead."
- Parameters
-
- Returns
- true if
G contains no undirected cycle, false otherwise.
Definition at line 905 of file simple_graph_alg.h.
◆ isTree()
| bool ogdf::isTree |
( |
const Graph & |
G | ) |
|
|
inline |
Returns true iff G is a tree, i.e. contains no undirected cycle and is connected.
- Parameters
-
- Returns
- true if
G is a tree, false otherwise.
Definition at line 917 of file simple_graph_alg.h.