DrawNetwork - Maple Help

GraphTheory

 DrawNetwork

 Calling Sequence DrawNetwork(G) DrawNetwork(G, st) DrawNetwork(G, S, T) DrawNetwork(G, S, T, st)

Parameters

 G - graph st - (optional) 'horizontal', 'vertical' S - (optional) vertex T - (optional) vertex

Description

 • DrawNetwork displays the vertices, arcs and vertex labels of a network. A network is a directed graph with at least one vertex with indegree 0 (the source) and at least one vertex with outdegree 0 (the sink).
 • If you specify S and T, the graph is displayed with S as the main source and T as the main sink.
 • The network can be displayed either horizontally or vertically.
 • Remaining options are passed on to the DrawGraph command.

Examples

 > $\mathrm{with}\left(\mathrm{GraphTheory}\right):$
 > $N≔\mathrm{Digraph}\left(\left\{\left[1,2\right],\left[1,3\right],\left[2,4\right],\left[3,4\right]\right\}\right)$
 ${N}{≔}{\mathrm{Graph 1: a directed unweighted graph with 4 vertices and 4 arc\left(s\right)}}$ (1)
 > $\mathrm{DrawNetwork}\left(N\right)$
 > $\mathrm{DrawNetwork}\left(N,'\mathrm{horizontal}'\right)$
 > $G≔\mathrm{Digraph}\left(\left\{\left[1,3\right],\left[2,3\right],\left[3,4\right],\left[3,5\right]\right\}\right):$
 > $\mathrm{IsNetwork}\left(G\right)$
 $\left\{{1}{,}{2}\right\}{,}\left\{{4}{,}{5}\right\}$ (2)
 > $\mathrm{DrawNetwork}\left(G,2,5\right)$