Skip to content
Ed Scheinerman edited this page Sep 19, 2018 · 23 revisions

SimpleGraphs

The SimpleGraphs module defines two data types for working with graphs:

  • A robustly supported SimpleGraph type that represents undirected graphs without loops or multiple edges.
  • A modest SimpleDigraph type that represents directed graphs in which there may be at most one directed edge (u,v) from a vertex u to a vertex v. There may also be a directed edge in the opposite direction, (v,u). Loops are permitted.

At the time of this writing, this Wiki will focus exclusively on undirected graphs.

More Information

Function descriptions in this Wiki are terse. Use the Julia help function for more information. Type a ? and then the name of the function. For example:

help?> adjacency
search: adjacency

  adjacency(G) returns the adjacency matrix of G.

  Note: If the vertices can be sorted by sort, then the first row of the 
  adjacency matrix corresponds to the first vertex (in order) in G and so forth. 
  However, if the vertices are not sortable in this way, the mapping between 
  vertices and rows/columns of the matrix is unpredictable.

Associated Modules

Additional graph theory functionality are provided in the following modules (which require separate installation):

  • DrawSimpleGraphs: draw graphs on the screen using Plots.
  • SimpleGraphAlgorithms: additional graph algorithms that typically rely on [integer] linear programming.
  • SimpleGraphRepresentations: working with specialty classes of graphs such as permutation graphs, interval graphs, and so forth.

Note that the SimplePartitions module is automatically included via the REQUIRE mechanism.

Clone this wiki locally