| ||||||||||||||||||||||||

tlp::TreeTest Class Reference Class for testing if the graph is a tree. More...
Inheritance diagram for tlp::TreeTest:
Collaboration diagram for tlp::TreeTest:
## Static Public Member Functions- static bool isTree (Graph *graph)
- static bool isFreeTree (Graph *graph)
- static void makeRootedTree (Graph *freeTree, node root)
- static void makeDirectedTree (Graph *freeTree, node root)
- static Graph * computeTree (Graph *graph, PluginProgress *pluginProgress=NULL)
- static void cleanComputedTree (Graph *graph, Graph *tree)
## Detailed DescriptionClass for testing if the graph is a tree. ## Member Function DocumentationClean the graph from a tree previously computed with the computeTree method
Computes a rooted tree from the graph. The algorithm is the following : - if the graph is a rooted tree, returns the graph
- if the graph is a free tree, returns a rooted clone subgraph
- if the graph is connected, makes a clone subgraph and returns a rooted spanning tree of that clone
- if the graph is not connected, makes a clone subgraph, computes a tree for each of its connected components, adds a simple source and returns the clone.
Returns true if the graph is a topological tree (i.e. if the graph was undirected, there would be no cycle), false otherwise.
Returns true if the graph is a rooted tree (i.e. a graph with one node designated as the root), false otherwise. Synonymous of the makeRootedTree method. |

Tulip Software by LaBRI Visualization Team 2001 - 2012 |