I have undirected weighted labeled graph. What program i can use to generate and visualize tree graph, showing me all simple paths from vertice A to vertice B? //The vertices in each path should not be repeated.

1 Answer 1


The graph visualization software Graphviz may be used for that purpose. Graphs specified in the DOT language can be generated to common image formats. With the concentrate graph attribute you can specify that multiple edges are merged into one. The vertices (nodes in DOT terminology) are never repeated in the graphs. In case you have a tree graph all paths will be simple paths already.

Tree definition in Wikipedia:

Any two vertices in G can be connected by a unique simple path.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.