Differences between revisions 48 and 57 (spanning 9 versions)
Revision 48 as of 2006-10-07 22:59:41
Size: 29486
Editor: anonymous
Comment:
Revision 57 as of 2006-10-08 20:23:30
Size: 29794
Editor: anonymous
Comment:
Deletions are marked like this. Additions are marked like this.
Line 1: Line 1:
[[TableOfContents]]
Line 5: Line 7:
The main people working on this project are Emily Kirkman and Robert Miller.  The main people working on this project are Emily Kirkman and Robert Miller.
Line 9: Line 11:
   A. Software included with SAGE
      I. GAP
      I. Maxima
      I. Singular
      I. PARI, MWRANK, NTL
      I. Matplotlib
      I. GSL, Numeric

   A. Software SAGE interfaces with (but does not include)

      I. [http://magma.maths.usyd.edu.au/magma/htmlhelp/text1452.htm Magma]
=== Software included with SAGE ===
==== GAP ====
==== Maxima ====
==== Singular ====
==== PARI, MWRANK, NTL ====
==== Matplotlib ====
==== GSL, Numeric ====

=== Software included with SAGE as optional ===
==== GRAPE ====
===== Nauty =====
       [http://cs.anu.edu.au/~bdm/nauty/ Link]
         a. Benchmark program
         a. Source posted, but no public license - should contact Brendan !McKay
         a. Written in portable subset of C, python wrapper already in existence (see pynauty)
         a. Both MAGMA and GRAPE (GAP package) use nauty
            1. '''Construction'''
               includes gtools - quick generators for non-isomorphic graphs, also generates bipartite graphs and digraphs
            1. '''Invariants'''
               canonical labelling
            1. '''Morphisms/Group Actions'''
               Computing automorphism groups of graphs and digraphs, isomorphism testing

=== Software SAGE interfaces with (but does not include) ===

==== Magma ====
      [http://magma.maths.usyd.edu.au/magma/htmlhelp/text1452.htm Link]
Line 33: Line 51:
          . has k-clique, clique number, all cliques, maximum clique ([http://magma.maths.usyd.edu.au/magma/htmlhelp/text1473.htm "When comparing both algorithms in the situation where the problem is to find a maximum clique one observes that in general BranchAndBound does better. However Dynamic outperforms BranchAndBound when the graphs under consideration are large (more then 400 vertices) random graphs with high density (larger than 0.5%). So far, it can only be said that the comparative behaviour of both algorithms is highly dependent on the structure of the graphs."]), independent sets and number,            . has k-clique, clique number, all cliques, maximum clique ([http://magma.maths.usyd.edu.au/magma/htmlhelp/text1473.htm "When comparing both algorithms in the situation where the problem is to find a maximum clique one observes that in general BranchAndBound does better. However Dynamic outperforms BranchAndBound when the graphs under consideration are large (more then 400 vertices) random graphs with high density (larger than 0.5%). So far, it can only be said that the comparative behaviour of both algorithms is highly dependent on the structure of the graphs."]), independent sets and number,
Line 45: Line 63:
          . Max flow min cut (2 algorithms: [http://magma.maths.usyd.edu.au/magma/htmlhelp/text1499.htm#15274 Dinic & push-relabel]), maximum matching for bipartite,            . Max flow min cut (2 algorithms: [http://magma.maths.usyd.edu.au/magma/htmlhelp/text1499.htm#15274 Dinic & push-relabel]), maximum matching for bipartite,
Line 61: Line 79:
      I. Maple: '''networks''' package, which includes: ==== Maple ====
Contains the '''networks''' package, which includes:
Line 65: Line 84:
          . new (0 verts), void (n verts, 0 edges), incremental construction, complement, complete, contraction, hypercubes, cycle, petersen, cube, icosahedron, dodecahedron, octahedron, tetrahedron, simplify a multigraph, union, subgraphs,            . new (0 verts), void (n verts, 0 edges), incremental construction, complement, complete, contraction, hypercubes, cycle, petersen, cube, icosahedron, dodecahedron, octahedron, tetrahedron, simplify a multigraph, union, subgraphs,
Line 71: Line 90:
          . in-nbrs(arrivals), out-nbrs(departures), degree sequence, endpoints, graphical ("tests whether intlist is the degree sequence of a simple graph"), edge-nbrs, vert-nbrs, in-degree, out-degree, max & min degree, edge span & span polynomial ("The span polynomial in variable p gives the probability that G is spanning when each edge operates with probability p.", "When G is connected, this is the all-terminal reliability polynomial of G, and gives the probability that G is connected when each edge operates independently with probability p."), 
         1. '''Connectivity'''
          . components, edge-connectivity, 2-components, count minimal cutsets, rank ("The rank of an edgeset e is the number of vertices of G minus the number of components of the subgraph induced by e."), Whitney rank polynomial ("The rank polynomial is a sum over all subgraphs H of G of $x^{(rank(G) - rank(H))} y^{corank(H)}$."), 
         1. '''Paths, etc.'''
          . diameter, fundcyc ("Given a subset e of edges forming a unicyclic subgraph of a graph G, the edges forming the unique cycle are returned as a set. It is assumed that only one cycle is present."), girth, find path from a to b, 
          . in-nbrs(arrivals), out-nbrs(departures), degree sequence, endpoints, graphical ("tests whether intlist is the degree sequence of a simple graph"), edge-nbrs, vert-nbrs, in-degree, out-degree, max & min degree, edge span & span polynomial ("The span polynomial in variable p gives the probability that G is spanning when each edge operates with probability p.", "When G is connected, this is the all-terminal reliability polynomial of G, and gives the probability that G is connected when each edge operates independently with probability p."),
         1. '''Connectivity'''
          . components, edge-connectivity, 2-components, count minimal cutsets, rank ("The rank of an edgeset e is the number of vertices of G minus the number of components of the subgraph induced by e."), Whitney rank polynomial ("The rank polynomial is a sum over all subgraphs H of G of $x^{(rank(G) - rank(H))} y^{corank(H)}$."),
         1. '''Paths, etc.'''
          . diameter, fundcyc ("Given a subset e of edges forming a unicyclic subgraph of a graph G, the edges forming the unique cycle are returned as a set. It is assumed that only one cycle is present."), girth, find path from a to b,
Line 79: Line 98:
          . chromatic polynomial, 
         1. '''Optimization'''
          . maximum flow (flow), Dinic algorithm for max flow (see Magma), flow polynomial ("The flow polynomial in variable h gives the number of nowhere-zero flows on G with edge labels chosen from integers modulo h."), minimum cut, 
          . chromatic polynomial,
         1. '''Optimization'''
          . maximum flow (flow), Dinic algorithm for max flow (see Magma), flow polynomial ("The flow polynomial in variable h gives the number of nowhere-zero flows on G with edge labels chosen from integers modulo h."), minimum cut,
Line 83: Line 102:
          . isplanar,            . isplanar,
Line 85: Line 104:
          . acycpoly ("The acyclicity polynomial in variable p gives the probability that G is acyclic when each edge operates with probability p."), adjacency matrix, distance table (allpairs- optional table gives shortest path trees, rooted at each vertex), incidence matrix,            . acycpoly ("The acyclicity polynomial in variable p gives the probability that G is acyclic when each edge operates with probability p."), adjacency matrix, distance table (allpairs- optional table gives shortest path trees, rooted at each vertex), incidence matrix,
Line 93: Line 112:
      I. Mathematica: [http://documents.wolfram.com/mathematica/Built-inFunctions/AdvancedDocumentation/DiscreteMath/GraphPlot/ GraphPlot] ([http://documents.wolfram.com/mathematica/Built-inFunctions/AdvancedDocumentation/DiscreteMath/GraphPlot/AdvancedDocumentationGraphPlotReferences.html biblio]) is built-in: also a few functions for "applications" (?); designed to work well with large graphs; also supports graphs from ''Combinatorica'' ==== Mathematica ====
      [http://documents
.wolfram.com/mathematica/Built-inFunctions/AdvancedDocumentation/DiscreteMath/GraphPlot/ GraphPlot]([http://documents.wolfram.com/mathematica/Built-inFunctions/AdvancedDocumentation/DiscreteMath/GraphPlot/AdvancedDocumentationGraphPlotReferences.html biblio]) is built-in: also a few functions for "applications" (?); designed to work well with large graphs; also supports graphs from ''Combinatorica''
Line 101: Line 121:
          . maximal independent vertex sets and edge sets, 
         1. '''Connectivity'''
          . list strongly connected components, 
          . maximal independent vertex sets and edge sets,
         1. '''Connectivity'''
          . list strongly connected components,
Line 107: Line 127:
          . [http://documents.wolfram.com/mathematica/Built-inFunctions/AdvancedDocumentation/DiscreteMath/GraphPlot/AdvancedDocumentationGraphPlotTreePlot.html TreePlot] uses the layered drawing algorithm, implements more control:            . [http://documents.wolfram.com/mathematica/Built-inFunctions/AdvancedDocumentation/DiscreteMath/GraphPlot/AdvancedDocumentationGraphPlotTreePlot.html TreePlot] uses the layered drawing algorithm, implements more control:
Line 113: Line 133:
   A. Extensions of software that SAGE interfaces with
      I. Magma
      I. Maple
=== Extensions of software that SAGE interfaces with ===
==== Magma ====
==== Maple ====
Line 124: Line 144:
             . discrete laplacian matrix (this function may fight with the built-in laplacian in 'linalg'), compute its eigenvalues given a measure,               . discrete laplacian matrix (this function may fight with the built-in laplacian in 'linalg'), compute its eigenvalues given a measure,
Line 128: Line 148:
      I. Mathematica ==== Mathematica ====
Line 131: Line 151:
   A. Software that SAGE can now include as is (not as an optional package...)
      I. [http://gato.sourceforge.net/ Gato], a tool that animates algorithms, perhaps SAGE cannot actually include right now as is, but license is LGPL, and it requires Python and Tcl/Tk: would be good for educational purposes
=== Software that SAGE can now include as is (not as an optional package...) ===
==== Gato ====
     
[http://gato.sourceforge.net/ Link]
      A
tool that animates algorithms, perhaps SAGE cannot actually include right now as is, but license is LGPL, and it requires Python and Tcl/Tk: would be good for educational purposes
Line 134: Line 156:
      I. [https://networkx.lanl.gov/ NetworkX], seems pretty comprehensive, released under "GNU Lesser General Public License", works on Python $\geq$ 2.3, interfaces with Matplotlib, Pygraphviz, Graphviz, Pydot, numpy or Numeric, Ipython, !SciPy, PyGSL, sAsync, PyYAML: EXCELLENT documentation with links to source code from each function descriptor (TODO: make sense of networkx.utils, networkx.threshold, networkx.generators.small, networkx.me, networkx.mixing, networkx.search_class, networkx.tests, ) ==== NetworkX ====
     
[https://networkx.lanl.gov/ Link]
      S
eems pretty comprehensive, released under "GNU Lesser General Public License", works on Python $\geq$ 2.3, interfaces with Matplotlib, Pygraphviz, Graphviz, Pydot, numpy or Numeric, Ipython, !SciPy, PyGSL, sAsync, PyYAML: EXCELLENT documentation with links to source code from each function descriptor (TODO: make sense of networkx.utils, networkx.threshold, networkx.generators.small, networkx.me, networkx.mixing, networkx.search_class, networkx.tests, )
Line 139: Line 163:
          . 'convert' module converts NetworkX graphs to and from other formats: python dict of lists, python dict of dicts, numpy matrices, scipy sparse matrices, pygraphviz; works with python pickling; Import and export networkx networks to dot format using pydot or pygraphviz,            . 'convert' module converts NetworkX graphs to and from other formats: python dict of lists, python dict of dicts, numpy matrices, scipy sparse matrices, pygraphviz; works with python pickling; Import and export networkx networks to dot format using pydot or pygraphviz,
Line 143: Line 167:
          . density,            . density,
Line 145: Line 169:
          . standard predicates, directed acyclic,            . standard predicates, directed acyclic,
Line 149: Line 173:
          . neighbors, degree, valid degree sequence?, create degree sequence, double edge swap, 
         1. '''Connectivity'''
          . find k-cores of a graph, is (k,l) connected, (number) components, 
         1. '''Paths, etc.'''
          . eccentricity, diameter, periphery, radius, center, shortest path (length & many variants, including Dijkstra, Floyd-Warshall), dictionary of all shortest path lengths, list of vertices in topological sort order, predecessors, 
          . neighbors, degree, valid degree sequence?, create degree sequence, double edge swap,
         1. '''Connectivity'''
          . find k-cores of a graph, is (k,l) connected, (number) components,
         1. '''Paths, etc.'''
          . eccentricity, diameter, periphery, radius, center, shortest path (length & many variants, including Dijkstra, Floyd-Warshall), dictionary of all shortest path lengths, list of vertices in topological sort order, predecessors,
Line 157: Line 181:
          . clustering: number of triangles for given nodes, clustering coefficients (fraction of triads, which is edge vertex edge, that are triangles), transitivity (3*triangles/triads); breadth-first and depth-first search, Helper queues for use in graph searching; LIFO: Last in first out queue (stack), FIFO: First in first out queue, Priority(fcn): Priority queue with items are sorted by fcn, Random: Random queue, q.append(item) -- add an item to the queue, q.extend(items) -- equivalent to: for item in items: q.append(item), q.pop() -- return the top item from the queue, len(q) -- number of items in q (also q.__len());            . clustering: number of triangles for given nodes, clustering coefficients (fraction of triads, which is edge vertex edge, that are triangles), transitivity (3*triangles/triads); breadth-first and depth-first search, Helper queues for use in graph searching; LIFO: Last in first out queue (stack), FIFO: First in first out queue, Priority(fcn): Priority queue with items are sorted by fcn, Random: Random queue, q.append(item) -- add an item to the queue, q.extend(items) -- equivalent to: for item in items: q.append(item), q.pop() -- return the top item from the queue, len(q) -- number of items in q (also q.__len());
Line 159: Line 183:
          . adjacency matrix, (normalized) Laplacian,            . adjacency matrix, (normalized) Laplacian,
Line 165: Line 189:
          . random bipartite graph from two degree sequences (four versions: including regular, 'reverse' and alternating Havel-Hakimi style), bipartite preferential attachment, bipartite with fixed degree, projection of bipartite onto selected nodes, random pseudograph with given degree sequence, random graph with expected degree given, Havel-Hakimi for simple graphs, tree with given degree sequence, generate a graph with given degree sequence maximizing s-metric, s-metric (the sum of the product $deg(u)*deg(v)$ for every edge u-v in G (Reference unpublished li-2005, author Lun Li and David Alderson and John C.)), digraphs: growing network, growing network with redirection or copying; random geometric graph in the unit cube, $G_{n,p}$ Erdös-Rényi (two versions, normal and fast), Newman-Watts-Strogatz small world graph ("First create a ring over n nodes. Then each node in the ring is connected with its k nearest neighbors. Then shortcuts are created by adding new edges as follows: for each edge u-v in the underlying "n-ring with k nearest neighbors"; with probability p add a new edge u-w with randomly-chosen existing node w. In contrast with watts_strogatz_graph(), no edges are removed."), Watts-Strogatz small world graph ("First create a ring over n nodes. Then each node in the ring is connected with its k nearest neighbors. Then shortcuts are created by rewiring existing edges as follows: for each edge u-v in the underlying "n-ring with k nearest neighbors"; with probability p replace u-v with a new edge u-w with randomly-chosen existing node w. In contrast with newman_watts_strogatz_graph(), the random rewiring does not increase the number of edges."), $G_{n,d}$ ("Return a random regular graph of n nodes each with degree d... n*d must be even"), Barabási-Albert preferential attachment ("A graph of n nodes is grown by attaching new nodes each with m edges that are preferentially attached to existing nodes with high degree."), "Holme and Kim algorithm for growing graphs with powerlaw degree distribution and approximate average clustering" (see P. Holme and B. J. Kim, "Growing scale-free networks with tunable clustering", Phys. Rev. E 2002 vol 65 #2), random lobster ("A caterpillar is a tree that reduces to a path graph when pruning all leaf nodes (p2=0). A lobster is a tree that reduces to a caterpillar when pruning all leaf nodes."), random shell graph (see networkx.generators.random_graphs), tree with given powerlaw distribution ("A trial powerlaw degree sequence is chosen and then elements are swapped with new elements from a powerlaw distribution until the sequence makes a tree (#edges=#nodes-1).") or its degree sequence,            . random bipartite graph from two degree sequences (four versions: including regular, 'reverse' and alternating Havel-Hakimi style), bipartite preferential attachment, bipartite with fixed degree, projection of bipartite onto selected nodes, random pseudograph with given degree sequence, random graph with expected degree given, Havel-Hakimi for simple graphs, tree with given degree sequence, generate a graph with given degree sequence maximizing s-metric, s-metric (the sum of the product $deg(u)*deg(v)$ for every edge u-v in G (Reference unpublished li-2005, author Lun Li and David Alderson and John C.)), digraphs: growing network, growing network with redirection or copying; random geometric graph in the unit cube, $G_{n,p}$ Erdös-Rényi (two versions, normal and fast), Newman-Watts-Strogatz small world graph ("First create a ring over n nodes. Then each node in the ring is connected with its k nearest neighbors. Then shortcuts are created by adding new edges as follows: for each edge u-v in the underlying "n-ring with k nearest neighbors"; with probability p add a new edge u-w with randomly-chosen existing node w. In contrast with watts_strogatz_graph(), no edges are removed."), Watts-Strogatz small world graph ("First create a ring over n nodes. Then each node in the ring is connected with its k nearest neighbors. Then shortcuts are created by rewiring existing edges as follows: for each edge u-v in the underlying "n-ring with k nearest neighbors"; with probability p replace u-v with a new edge u-w with randomly-chosen existing node w. In contrast with newman_watts_strogatz_graph(), the random rewiring does not increase the number of edges."), $G_{n,d}$ ("Return a random regular graph of n nodes each with degree d... n*d must be even"), Barabási-Albert preferential attachment ("A graph of n nodes is grown by attaching new nodes each with m edges that are preferentially attached to existing nodes with high degree."), "Holme and Kim algorithm for growing graphs with powerlaw degree distribution and approximate average clustering" (see P. Holme and B. J. Kim, "Growing scale-free networks with tunable clustering", Phys. Rev. E 2002 vol 65 #2), random lobster ("A caterpillar is a tree that reduces to a path graph when pruning all leaf nodes (p2=0). A lobster is a tree that reduces to a caterpillar when pruning all leaf nodes."), random shell graph (see networkx.generators.random_graphs), tree with given powerlaw distribution ("A trial powerlaw degree sequence is chosen and then elements are swapped with new elements from a powerlaw distribution until the sequence makes a tree (#edges=#nodes-1).") or its degree sequence,
Line 174: Line 198:
   A. Software that SAGE should include (or maybe interface with, or include as optional), pending stuff (e.g. licensing)
      I. [http://cs.anu.edu.au/~bdm/nauty/ Nauty]
         a. Benchmark program
         a. Source posted, but no public license - should contact Brendan !McKay
         a. Written in portable subset of C, python wrapper already in existence (see pynauty)
         a. Nauty interfaces with MAGMA and GRAPE (GAP package)
            1. '''Construction'''
               includes gtools - quick generators for non-isomorphic graphs, also generates bipartite graphs and digraphs
            1. '''Invariants'''
               canonical labelling
            1. '''Morphisms/Group Actions'''
               Computing automorphism groups of graphs and digraphs, isomorphism testing
      I. [http://keithbriggs.info/very_nauty.html Very_nauty]
=== Software that SAGE can now include as optional ===
      (or maybe interface with)
==== Very_nauty ====
       [http://keithbriggs.info/very_nauty.html Link]
Line 188: Line 203:
         a. C library  
         1. '''Subgraphs and Subsets'''
            cliques in G(n,p), # of graphs on n nodes with chromatic number k, # of graphs on n nodes with clique number k, new data on chromatic number and cliqe number, Lambert's w function  
      I. [http://www.graphviz.org GraphViz]
         a. C library
         1. '''Subgraphs and Subsets'''
            cliques in G(n,p), # of graphs on n nodes with chromatic number k, # of graphs on n nodes with clique number k, new data on chromatic number and cliqe number, Lambert's w function
==== GraphViz ====
      
[http://www.graphviz.org Link]
Line 198: Line 214:
      I. [http://cs.anu.edu.au/people/bdm/plantri/ plantri and fullgen] written in C, tested mainly on UNIX, weird license ('free for all purposes other than sale for profit. However, they remain subject to our copyright and are not "public domain".'): interesting note, co-authored by Brendan !McKay, of ''nauty'' ==== plantri/fullgen ====
     
[http://cs.anu.edu.au/people/bdm/plantri/ Link] written in C, tested mainly on UNIX, weird license ('free for all purposes other than sale for profit. However, they remain subject to our copyright and are not "public domain".'): interesting note, co-authored by Brendan !McKay, of ''nauty''
Line 204: Line 221:
   A. Software that is incompatible with SAGE but still useful (e.g. web-based applets)
      I. [http://www.geocities.com/pechv_ru/ GRIN]
=== Software that is incompatible with SAGE but still useful ===
      
(e.g. web-based applets)
==== GRIN ====
   [http://www.geocities.com/pechv_ru/ Link]
Line 207: Line 226:
    a. not open-source, but free download 
       1. '''Connectivity''' 
    a. not open-source, but free download
       1. '''Connectivity'''
Line 211: Line 230:
          Paths and Cycles (Eulerian and Hamiltonian), Shortest Paths, Max Capacity Path, K Shortest paths, Critical path            Paths and Cycles (Eulerian and Hamiltonian), Shortest Paths, Max Capacity Path, K Shortest paths, Critical path
Line 213: Line 232:
          Minimal spanning tree            Minimal spanning tree
Line 215: Line 234:
          Max Flow  
       1. '''Morphisms/Group Actions''' 
          Max Flow
       1. '''Morphisms/Group Actions'''
Line 219: Line 238:
          Metrics of the graph Density, Undensity and so on...)               Metrics of the graph Density, Undensity and so on...)
Line 221: Line 240:
               2d only, Clipboard edit, decomposition of edges, resize  
      I. [http://prolland.free.fr/works/research/dsatphp/dsat.html DSATUR], a program for computing graph colorings, algorithm [http://prolland.free.fr/works/research/dsat/index.html#anchor38034 documentation] in French, input in [http://mat.gsia.cmu.edu/COLOR/general/ccformat.ps DIMACS] format, [http://prolland.free.fr/works/research/dsatphp/dsat.txt source code]
      I. [http://www.alogorithmic-solutions.com LEDA]
               2d only, Clipboard edit, decomposition of edges, resize
==== DSATUR ====
      [http://prolland.free.fr/works/research/dsatphp/dsat.html Link
], a program for computing graph colorings, algorithm [http://prolland.free.fr/works/research/dsat/index.html#anchor38034 documentation] in French, input in [http://mat.gsia.cmu.edu/COLOR/general/ccformat.ps DIMACS] format, [http://prolland.free.fr/works/research/dsatphp/dsat.txt source code]
==== LEDA ====
      I. [http://www.alogorithmic-solutions.com Link
]
Line 227: Line 248:
      I. [http://dimacs.rutgers.edu/~berryj/LINK.html LINK] ==== LINK ====
I. [http://dimacs.rutgers.edu/~berryj/LINK.html (hyper)link]
Line 229: Line 251:
         a. C++ libraries
      I. [http://www.informatik.uni-koeln.de/abacus/ ABACUS, (A Branch-And-!CUt System)]
         a. open source, GNU Lesser GPL v2.1
Line 233: Line 252:
==== ABACUS (A Branch-And-!CUt System) ====
      [http://www.informatik.uni-koeln.de/abacus/ Link]
         a. open source, GNU Lesser GPL v2.1
         a. C++ libraries
Line 236: Line 259:
   A. Algorithm descriptions for specific problems
 I. [http://rtm.science.unitn.it/intertools/ InterTools]
=== Algorithm descriptions for specific problems ===
==== InterTools ====
     
[http://rtm.science.unitn.it/intertools/ InterTools]
Line 241: Line 265:
      I. [http://www.cs.sunysb.edu/~algorith/implement/graphbase/implement.shtml Standford !Graphbase] ==== !Graphbase ====
[http://www.cs.sunysb.edu/~algorith/implement/graphbase/implement.shtml Standford Link]
Line 243: Line 268:
            a. Generating Graphs              a. Generating Graphs
Line 261: Line 286:
      I. [http://www.paddle.mb.ca/G&G/G&G.html Groups & Graphs] ==== Groups & Graphs ====
[http://www.paddle.mb.ca/G&G/G&G.html Link]
Line 273: Line 299:
   A. Apparently useless / and/or misc. / and/or etc.
        I. [http://www.npac.syr.edu/NPAC1/PUB/ranka/part/part.html Scalable Libraries for Graph Partitioning], no software yet, but good references on page: "Efficient methods for graph partitioning and incremental graph partitioning are important for parallelization of a large number of unstructured and/or adaptive applications."
=== Apparently useless / and/or misc. / and/or etc. ===
==== Scalable Libraries for Graph Partitioning ====
        
[http://www.npac.syr.edu/NPAC1/PUB/ranka/part/part.html Link], no software yet, but good references on page: "Efficient methods for graph partitioning and incremental graph partitioning are important for parallelization of a large number of unstructured and/or adaptive applications."

TableOfContents

Introduction

The SAGE Graph Theory Project aims to implement Graph objects and algorithms in ["SAGE"].

The main people working on this project are Emily Kirkman and Robert Miller.

Survey of existing Graph Theory software

Software included with SAGE

GAP

Maxima

Singular

PARI, MWRANK, NTL

Matplotlib

GSL, Numeric

Software included with SAGE as optional

GRAPE

Nauty
  • [http://cs.anu.edu.au/~bdm/nauty/ Link]

    1. Benchmark program
    2. Source posted, but no public license - should contact Brendan McKay

    3. Written in portable subset of C, python wrapper already in existence (see pynauty)
    4. Both MAGMA and GRAPE (GAP package) use nauty
      1. Construction

        • includes gtools - quick generators for non-isomorphic graphs, also generates bipartite graphs and digraphs
      2. Invariants

        • canonical labelling
      3. Morphisms/Group Actions

        • Computing automorphism groups of graphs and digraphs, isomorphism testing

Software SAGE interfaces with (but does not include)

Magma

  • [http://magma.maths.usyd.edu.au/magma/htmlhelp/text1452.htm Link]

    1. Representation

      • Sparse support; function computes memory requirement for graph with n verts and m edges; consists of graph itself, vertex set, and edge set
    2. Storage/Pipes

    3. Construction

      • From matrix; from edge tuples; from vertex neighbors; from edges of other graphs; subgraphs; quotient graphs; incremental construction; complement; contraction; breaking edges; line graph; switch nbrs for non-nbrs of a vertex; disjoint unions, edge unions; complete unions; cartesian, lexicographic and tensor products; n-th power (same vert set, incident iff dist \leq n); graph \leftrightarrow digraph; Cayley graph constructor; Schreier graph constructor; Orbital graph constructor; Closure graph constructor (given G, add edges to make G invariant under a given permutation group); Paley graphs and tournaments; graphs from incidence structures; converse(reverse digraph); n-th odd graph; n-th triangular graph; n-th square lattice graph; Clebsch, Shrikhande, Gewirtz and Chang graphs;

    4. Decorations (Coloring, Weight, Flow, etc.)

      • Vertices have labels only; Edges have labels, capacity(non-negative integers, loops=0) and weights(totally ordered ring);
    5. Invariants

      • #verts, #edges; characteristic polynomial; spectrum
    6. Predicates

      • 2 verts incident, 2 edges incident, 1 vertex and 1 edge incident, subgraph, bipartite, complete, Eulerian, tree, forest, empty, null, path, polygon, regular
    7. Subgraphs and Subsets

      • has k-clique, clique number, all cliques, maximum clique ([http://magma.maths.usyd.edu.au/magma/htmlhelp/text1473.htm "When comparing both algorithms in the situation where the problem is to find a maximum clique one observes that in general BranchAndBound does better. However Dynamic outperforms BranchAndBound when the graphs under consideration are large (more then 400 vertices) random graphs with high density (larger than 0.5%). So far, it can only be said that the comparative behaviour of both algorithms is highly dependent on the structure of the graphs."]), independent sets and number,

    8. Adjacency, etc.

      • (in- & out-) degree, degree vector, valence (if regular), vertex nbrs, edge nbrs, bipartition, dominating sets

    9. Connectivity

      • (strongly) connected, components, separable, 2-connected, 2-components, triconnectivity ([http://magma.maths.usyd.edu.au/magma/htmlhelp/text1466.htm "The linear-time triconnectivity algorithm by Hopcroft and Tarjan (HT73) has been implemented with corrections of our own and from C. Gutwenger and P. Mutzel (GM01). This algorithm requires that the graph has a sparse representation."]), k-vertex connectivity, vertex separator, k-edge connectivity, edge separator

    10. Paths, etc.

      • distance and geodesic, diameter and corr. path, ball and sphere, distance partition, equitable partition, girth and corr. cycle
    11. Trees, etc.

      • spanning tree, breadth first and depth first searches, rooted, root, parent, vertex paths
    12. Colorings(see also Decorations)

      • chromatic number and index, optimal vertex and edge colorings, chromatic polynomial
    13. Optimization

    14. Embedding (Planar graphs, etc.)

      • planarity, Kuratowski subgraphs, faces of a planar graph, embedding info as orientation of edges from a vertex
    15. Algebra

      • adjacency matrix, distance matrix, incidence matrix, intersection matrix
    16. Morphisms/Group Actions

      • interfaces nauty

    17. Symmetry

      • vertex, edge and distance transitivity; orbit partitions; primitivity; symmetric; distance regularity and intersection array
    18. Geometry

      • Go back and forth between incidence and coset geometries and their graphs; finite planes;
    19. Generation/Random Graphs

      • interfaces nauty

    20. Database

      • database interface, strongly regular graph DB, random graph from DB, slick implementation of for loops ("for G in D do ... end for;")

Maple

  • Contains the networks package, which includes:

    1. Representation

      • ?
    2. Construction

      • new (0 verts), void (n verts, 0 edges), incremental construction, complement, complete, contraction, hypercubes, cycle, petersen, cube, icosahedron, dodecahedron, octahedron, tetrahedron, simplify a multigraph, union, subgraphs,
    3. Decorations (Coloring, Weight, Flow, etc.)

      • vertex weights default to 0, edge weights default to 1 (can be any valid maple expression)
    4. Invariants

      • characteristic polynomial
    5. Adjacency, etc.

      • in-nbrs(arrivals), out-nbrs(departures), degree sequence, endpoints, graphical ("tests whether intlist is the degree sequence of a simple graph"), edge-nbrs, vert-nbrs, in-degree, out-degree, max & min degree, edge span & span polynomial ("The span polynomial in variable p gives the probability that G is spanning when each edge operates with probability p.", "When G is connected, this is the all-terminal reliability polynomial of G, and gives the probability that G is connected when each edge operates independently with probability p."),

    6. Connectivity

      • components, edge-connectivity, 2-components, count minimal cutsets, rank ("The rank of an edgeset e is the number of vertices of G minus the number of components of the subgraph induced by e."), Whitney rank polynomial ("The rank polynomial is a sum over all subgraphs H of G of x^{(rank(G) - rank(H))} y^{corank(H)}."),

    7. Paths, etc.

      • diameter, fundcyc ("Given a subset e of edges forming a unicyclic subgraph of a graph G, the edges forming the unique cycle are returned as a set. It is assumed that only one cycle is present."), girth, find path from a to b,
    8. Trees, etc.

      • ancestor, daughter, count spanning trees (Kirchoff Matrix-Tree theorem), cycle base ("A spanning tree is found, and fundcyc() is then used to find all fundamental cycles with respect to this tree. They are returned as a set of cycles with each cycle being represented by a set of edges."), edge disjoint spanning tree, shortest path spanning tree, min weight spanning tree, Tutte polynomial ("The Tutte polynomial is a sum over all maximal forests H of G of t^{ia(H)} z^{ea(H)} where ia(H) is the internal activity of H and ea(H) is the external activity of H.")

    9. Colorings

      • chromatic polynomial,
    10. Optimization

      • maximum flow (flow), Dinic algorithm for max flow (see Magma), flow polynomial ("The flow polynomial in variable h gives the number of nowhere-zero flows on G with edge labels chosen from integers modulo h."), minimum cut,
    11. Embedding (Planar graphs, etc.)

      • isplanar,
    12. Algebra

      • acycpoly ("The acyclicity polynomial in variable p gives the probability that G is acyclic when each edge operates with probability p."), adjacency matrix, distance table (allpairs- optional table gives shortest path trees, rooted at each vertex), incidence matrix,
    13. Generation/Random Graphs

      • random graphs- specify #verts and prob of edge occuring, or #verts and #edges
    14. Database

      • show command shows a table of known information about a network
    15. Visualization

      • plots graphs either in lines (Linear) or in concentric circles (Concentric), ability to give specific graphs specific plotting procedures, 3d plots ("The location of the vertices of the graph is determined as follows. Let A be the adjacency matrix of G and let u, v and w be three eigenvectors of A with corresponding second, third, and fourth largest eigenvalue in absolute value. Then the (x,y,z) coordinates of the ith vertex of G is (u[i],v[i],w[i])."; "Sometimes other symmetries in the graph can be seen by using other eigenvectors. If the optional argument eigenvectors = [e1, e2, e3] is specified, where e1, e2, and e3 are vertex numbers (integers from 1 through the number of vertices), the eigenvectors corresponding to the eigenvalues of these relative magnitudes are used.")

Mathematica

Extensions of software that SAGE interfaces with

Magma

Maple

  1. [http://www.math.uga.edu/~mbaker/REU/maple/laplacian-guide.html 'laplacian.mpl']; [http://www.fmf.uni-lj.si/~mohar/Papers/Spec.pdf here] is a paper on the Laplacian Spectrum

    1. Storage/Pipes

      • creation of certain spreadsheets, such as known eigenvalues and eigenvalues of increasing subdivisions of the graph
    2. Construction

      • banana graphs, star graphs, bouquets and flowers, hypercubes, supercirc (see docs), subdivide edges into n edges, contract, assign directions (apparently in a random way)
    3. Decorations (Coloring, Weight, Flow, etc.)

      • normalilze (so sum of weights = 1)
    4. Algebra

      • discrete laplacian matrix (this function may fight with the built-in laplacian in 'linalg'), compute its eigenvalues given a measure,
    5. Topology

  2. [http://www.cecm.sfu.ca/CAG/papers/GTpaper.pdf GraphTheory] and [http://www.cecm.sfu.ca/CAG/papers/GT2006.pdf Part II] of the paper (haven't yet found the actual package...)

Mathematica

  1. [http://www.combinatorica.com/ Combinatorica] - for a list of functions, see [http://www.cs.sunysb.edu/~skiena/combinatorica/help.pdf help.pdf], page 13-14, 18, 21, 23, 25 - for a [http://www.amazon.com/exec/obidos/ASIN/0521806860/ref=nosim/thealgorithmrepo/ book]

Software that SAGE can now include as is (not as an optional package...)

Gato

  • [http://gato.sourceforge.net/ Link] A tool that animates algorithms, perhaps SAGE cannot actually include right now as is, but license is LGPL, and it requires Python and Tcl/Tk: would be good for educational purposes

    • seems that you can write your algorithm in one window and watch it go, supports 3d

NetworkX

  • [https://networkx.lanl.gov/ Link] Seems pretty comprehensive, released under "GNU Lesser General Public License", works on Python \geq 2.3, interfaces with Matplotlib, Pygraphviz, Graphviz, Pydot, numpy or Numeric, Ipython, SciPy, PyGSL, sAsync, PyYAML: EXCELLENT documentation with links to source code from each function descriptor (TODO: make sense of networkx.utils, networkx.threshold, networkx.generators.small, networkx.me, networkx.mixing, networkx.search_class, networkx.tests, )

    1. Representation

      • in Graph and DiGraph, "data structures based on an adjacency list implemented as a node-centric dictionary of dictionaries. The dictionary contains keys corresponding to the nodes and the values are dictionaries of neighboring node keys with the value None (the Python None type). This allows fast addition, deletion and lookup of nodes and neighbors in large graphs"

      • "The XGraph and XDiGraph classes are extensions of the Graph and DiGraph classes... The key difference is that an XGraph edge is a 3-tuple e=(n1,n2,x), representing an undirected edge between nodes n1 and n2 that is decorated with the object x. Here n1 and n2 are (hashable) node objects and x is a (not necessarily hashable) edge object. Since the edge is undirected, edge (n1,n2,x) is equivalent to edge (n2,n1,x). An XDiGraph edge is a similar 3-tuple e=(n1,n2,x), with the additional property of directedness. I.e. e=(n1,n2,x) is a directed edge from n1 to n2 decorated with the object x, and is not equivalent to the edge (n2,n1,x). Whether a graph or digraph allow self-loops or multiple edges is determined at the time of object instantiation via specifying the parameters selfloops=True/False and multiedges=True/False."

    2. Storage/Pipes (see networkx.io)

      • 'convert' module converts NetworkX graphs to and from other formats: python dict of lists, python dict of dicts, numpy matrices, scipy sparse matrices, pygraphviz; works with python pickling; Import and export networkx networks to dot format using pydot or pygraphviz,
    3. Construction

      • add path, add cycle, incremental construction, subgraphs, copy, directed \leftrightarrow undirected, balanced r-tree of height h, barbell graph, complete graph, complete bipartite, circular ladder graph, cycle, hierarchically constructed Dorogovtsev-Goltsev-Mendes graph, empty graph, grid graph, n-dim grid graph, hypercube, ladder graph, lollipop graph (K_n \# P_m), null graph (#verts = 0), path graph (P_n), star graph, trivial graph (#verts = 1), wheel graph, (disjoint) union, cartesian product, composition, complement, empty-copy, relabel nodes by mapping or functions, convert labels to integers

    4. Invariants

      • density,
    5. Predicates

      • standard predicates, directed acyclic,
    6. Subgraphs and Subsets

      • find cliques (Bron & Kerbosch), maximal and bipartite clique graph constructor, project bipartite onto one part (connected if they share a common Top/Bottom Node), clique number and number of maximal cliques, find cliques containing specified node, maximum locally (k,l) connected subgraph

    7. Adjacency, etc.

      • neighbors, degree, valid degree sequence?, create degree sequence, double edge swap,
    8. Connectivity

      • find k-cores of a graph, is (k,l) connected, (number) components,
    9. Paths, etc.

      • eccentricity, diameter, periphery, radius, center, shortest path (length & many variants, including Dijkstra, Floyd-Warshall), dictionary of all shortest path lengths, list of vertices in topological sort order, predecessors,

    10. Trees, etc.

      • tree class, rooted/directed/forests (experimental classes)
    11. Optimization

      • clustering: number of triangles for given nodes, clustering coefficients (fraction of triads, which is edge vertex edge, that are triangles), transitivity (3*triangles/triads); breadth-first and depth-first search, Helper queues for use in graph searching; LIFO: Last in first out queue (stack), FIFO: First in first out queue, Priority(fcn): Priority queue with items are sorted by fcn, Random: Random queue, q.append(item) -- add an item to the queue, q.extend(items) -- equivalent to: for item in items: q.append(item), q.pop() -- return the top item from the queue, len(q) -- number of items in q (also q.len());

    12. Algebra

      • adjacency matrix, (normalized) Laplacian,
    13. Morphisms/Group Actions

      • non-isomorphic checker (does not check isomorphism; only conclusive in the not-isomorphic direction), three versions: fast, faster and fastest
    14. Symmetry

      • betweenness, edge, degree, and closeness centrality
    15. Generation/Random Graphs

      • random bipartite graph from two degree sequences (four versions: including regular, 'reverse' and alternating Havel-Hakimi style), bipartite preferential attachment, bipartite with fixed degree, projection of bipartite onto selected nodes, random pseudograph with given degree sequence, random graph with expected degree given, Havel-Hakimi for simple graphs, tree with given degree sequence, generate a graph with given degree sequence maximizing s-metric, s-metric (the sum of the product deg(u)*deg(v) for every edge u-v in G (Reference unpublished li-2005, author Lun Li and David Alderson and John C.)), digraphs: growing network, growing network with redirection or copying; random geometric graph in the unit cube, G_{n,p} Erdös-Rényi (two versions, normal and fast), Newman-Watts-Strogatz small world graph ("First create a ring over n nodes. Then each node in the ring is connected with its k nearest neighbors. Then shortcuts are created by adding new edges as follows: for each edge u-v in the underlying "n-ring with k nearest neighbors"; with probability p add a new edge u-w with randomly-chosen existing node w. In contrast with watts_strogatz_graph(), no edges are removed."), Watts-Strogatz small world graph ("First create a ring over n nodes. Then each node in the ring is connected with its k nearest neighbors. Then shortcuts are created by rewiring existing edges as follows: for each edge u-v in the underlying "n-ring with k nearest neighbors"; with probability p replace u-v with a new edge u-w with randomly-chosen existing node w. In contrast with newman_watts_strogatz_graph(), the random rewiring does not increase the number of edges."), G_{n,d} ("Return a random regular graph of n nodes each with degree d... n*d must be even"), Barabási-Albert preferential attachment ("A graph of n nodes is grown by attaching new nodes each with m edges that are preferentially attached to existing nodes with high degree."), "Holme and Kim algorithm for growing graphs with powerlaw degree distribution and approximate average clustering" (see P. Holme and B. J. Kim, "Growing scale-free networks with tunable clustering", Phys. Rev. E 2002 vol 65 #2), random lobster ("A caterpillar is a tree that reduces to a path graph when pruning all leaf nodes (p2=0). A lobster is a tree that reduces to a caterpillar when pruning all leaf nodes."), random shell graph (see networkx.generators.random_graphs), tree with given powerlaw distribution ("A trial powerlaw degree sequence is chosen and then elements are swapped with new elements from a powerlaw distribution until the sequence makes a tree (#edges=#nodes-1).") or its degree sequence,

    16. Database

      • atlas function returns all graphs on up to 7 vertices (see "An Atlas of Graphs" by Ronald C. Read and Robin J. Wilson, Oxford University Press, 1998.)
    17. Visualization

      • layout: circular, shell, random, spring model, spectral layout, Power Iteration method to find smallest eigenvectors of Laplacian(G)
      • intervace to pygraphviz
      • Draw networks with matplotlib (pylab)
      • Draw networks in 3d with [http://www.vtk.org/ vtk]

Software that SAGE can now include as optional

  • (or maybe interface with)

Very_nauty

  • [http://keithbriggs.info/very_nauty.html Link]

    1. designed to be compatible with nauty
    2. C library
    3. Subgraphs and Subsets

      • cliques in G(n,p), # of graphs on n nodes with chromatic number k, # of graphs on n nodes with clique number k, new data on chromatic number and cliqe number, Lambert's w function

GraphViz

  • [http://www.graphviz.org Link]

    1. open source, Common Public License Version 1.0
    2. poorly documented, at least on the web
      1. Visualization

        • DOT makes "hierarchical" drawings of directed graphs. Algorithm aims edges in same direction and attempts to not cross edges and reduce length. NEATO uses spring method, via the Kamada-Kawai algorithm (statistical multi-dimensional scaling) fdp also uses the spring model, via the Fruchterman-Reingold heuristic (handles larger graphs and undirected, clustered graphs)

plantri/fullgen

  • [http://cs.anu.edu.au/people/bdm/plantri/ Link] written in C, tested mainly on UNIX, weird license ('free for all purposes other than sale for profit. However, they remain subject to our copyright and are not "public domain".'): interesting note, co-authored by Brendan McKay, of nauty

    1. Generation/Random Graphs

      • plantri: "exactly one member of each isomorphism class is output without the need for storing them. The speed of generation is more than 100,000 graphs per second in most cases, so extremely large classes of graph can be exhaustively listed.", classes include planar triangulations, quadrangulations, simple graphs, triangulations of a disc, planar cubic and quartic graphs
      • fullgen generates fullerenes
      • see also [http://hep.physics.indiana.edu/~tsulanke/graphs/surftri/ surftri], which generates triangulations of surfaces of higher genus

Software that is incompatible with SAGE but still useful

  • (e.g. web-based applets)

GRIN

  • [http://www.geocities.com/pechv_ru/ Link]

    1. for windows only
    2. not open-source, but free download
      1. Connectivity

        • bridges and cutpoints
      2. Paths, etc.

        • Paths and Cycles (Eulerian and Hamiltonian), Shortest Paths, Max Capacity Path, K Shortest paths, Critical path
      3. Trees, etc.

        • Minimal spanning tree
      4. Optimization

        • Max Flow
      5. Morphisms/Group Actions

        • Automorphism group
      1. Topology

        • Metrics of the graph Density, Undensity and so on...)
      2. Visualization

        • 2d only, Clipboard edit, decomposition of edges, resize

DSATUR

LEDA

  1. [http://www.alogorithmic-solutions.com Link]

    1. Commercial, but supposedly fast
    2. Morphisms / Group Actions

      • Module graph and subgraph isomorphisms

  1. [http://dimacs.rutgers.edu/~berryj/LINK.html (hyper)link]

    1. Free, but not open source
    2. C++ libraries

ABACUS (A Branch-And-!CUt System)

  • [http://www.informatik.uni-koeln.de/abacus/ Link]

    1. open source, GNU Lesser GPL v2.1
    2. C++ libraries
    3. Optimization

      • Branch-and-Bound algorithm, linear programming relaxations allow for dynamic generation of cutting planes or columns)

Algorithm descriptions for specific problems

InterTools

!Graphbase

  • [http://www.cs.sunysb.edu/~algorith/implement/graphbase/implement.shtml Standford Link]

    1. Generations/Random Graphs

      1. Generating Graphs
      2. Random Number Generation
    2. Database

      1. Graph Data Structures
    3. Trees, etc.

      1. Minimum Spanning Tree
    4. Paths, etc.

      1. Hamiltonian Cycle
    5. Optimization

      1. Matching
      2. Shortest Path
    6. Connectivity

      1. Edge and Vertex Connectivity
      2. Connected Components
    7. Topology

      1. Topological Sorting
    8. Morphisms/Group Actions

      1. Generating Permutations

Groups & Graphs

  • [http://www.paddle.mb.ca/G&G/G&G.html Link]

    1. free download, but no mention of source or license
    2. no internet doc's
    3. links out to papers on algorithms (references Brendan McKay's Practical Graph Isomorphism paper)

    4. Algorithms:
      1. Morphisms/Group Actions

        1. Graph Isomorphism
        2. Permutations Groups
      2. Paths, etc.

        1. Hamilton Cycles
      3. Visualization

        1. Draw Symmetric

Apparently useless / and/or misc. / and/or etc.

Scalable Libraries for Graph Partitioning

  • [http://www.npac.syr.edu/NPAC1/PUB/ranka/part/part.html Link], no software yet, but good references on page: "Efficient methods for graph partitioning and incremental graph partitioning are important for parallelization of a large number of unstructured and/or adaptive applications."

Functionality categories

  1. Representation

  2. Storage/Pipes

  3. Construction

  4. Decorations (Coloring, Weight, Flow, etc.)

  5. Invariants

  6. Predicates

  7. Subgraphs and Subsets

  8. Adjacency, etc.

  9. Connectivity

  10. Paths, etc.

  11. Trees, etc.

  12. Colorings

  13. Optimization

  14. Embedding (Planar graphs, etc.)

  15. Algebra

  16. Morphisms/Group Actions

  17. Symmetry

  18. Geometry

  19. Topology

  20. Generation/Random Graphs

  21. Database

  22. Visualization

graph (last edited 2009-11-29 06:48:46 by newacct)