The PathChecker class provides functions to compute whether given graphs have paths of a defined length.
More...
#include <PathChecker.h>
|
static bool | hasPath (Hypergraph const &graph, unsigned int length) |
| Checks if the given graph has a path with at least the given length. More...
|
|
|
static bool | findPath (Hypergraph const &graph, unordered_set< IDType > &visited, IDType currentVertex, unsigned int currentPath, unsigned int maxPath) |
| Recursively searches for a path in the given graph which has the given maximal length. More...
|
|
The PathChecker class provides functions to compute whether given graphs have paths of a defined length.
- Author
- Jan Stückrath
bool findPath |
( |
Hypergraph const & |
graph, |
|
|
unordered_set< IDType > & |
visited, |
|
|
IDType |
currentVertex, |
|
|
unsigned int |
currentPath, |
|
|
unsigned int |
maxPath |
|
) |
| |
|
staticprotected |
Recursively searches for a path in the given graph which has the given maximal length.
The other parameters are used for the recursion.
- Parameters
-
graph | the graph to be checked |
visited | the set of all node and edge IDs of elements of the currently found path (initially only currentVertex) |
currentVertex | the vertex ID from which the currently found path will be extended (initially some vertex ID) |
currentPath | the length of the currently found path (initially zero) |
maxPath | the pathlength to be checked; terminates if reached return true, iff the given graph contains a path of length 'length' |
bool hasPath |
( |
Hypergraph const & |
graph, |
|
|
unsigned int |
length |
|
) |
| |
|
static |
Checks if the given graph has a path with at least the given length.
- Parameters
-
graph | the graph to be checked |
length | the length to be used in the check |
- Returns
- true, iff the given graph contains a path of length 'length'
The documentation for this class was generated from the following files:
- /home/stueckrath/eclipse_ws/Uncover/src/graphs/PathChecker.h
- /home/stueckrath/eclipse_ws/Uncover/src/graphs/PathChecker.cpp