GraphTheory - Maple Programming Help

Online Help

All Products    Maple    MapleSim


Home : Support : Online Help : Mathematics : Discrete Mathematics : Graph Theory : GraphTheory Package : GraphTheory/TopologicSort

GraphTheory

  

TopologicSort

 

Calling Sequence

Parameters

Description

Examples

Calling Sequence

TopologicSort(G)

Parameters

G

-

acyclic directed graph

Description

• 

The TopologicSort command returns a linear ordering of vertices of an acyclic digraph that is consistent with the arcs of the digraph.  This means a vertex u precedes a vertex v if there is an arc from u to v. The output is a list.

Examples

withGraphTheory:

DGDigrapha,b,a,d,b,d,c,a,c,b,c,d:

IsAcyclicDG

true

(1)

TopologicSortDG

c,a,b,d

(2)

See Also

Digraph

IsAcyclic

TopologicalSort