DirectedGraph

DirectedGraph[g]
gives a directed graph from the undirected graph g.

DirectedGraph[g,conv]
gives a directed graph using the conversion conv.

DirectedGraph[{vw,},]
uses rules vw to specify the graph g.

Details and OptionsDetails and Options

ExamplesExamplesopen allclose all

Basic Examples  (3)Basic Examples  (3)

Convert each undirected edge of the graph to both directions:

In[1]:=
Click for copyable input
Out[1]=

A random direction:

In[1]:=
Click for copyable input
Out[1]=

A direction according to the vertex order in the vertex list:

In[1]:=
Click for copyable input
Out[1]=
Introduced in 2010
(8.0)
| Updated in 2015
(10.3)
Translate this page: