NAUTY format
[Input-Output]


Detailed Description

Tool to read graphs from Nauty format data


Files

file  nauty_reader.h
 Nauty file reader.

Functions

template<typename UGraph >
std::istream & readNauty (std::istream &is, UGraph &ugraph)
 Nauty file reader.

Function Documentation

std::istream& lemon::readNauty ( std::istream &  is,
UGraph ugraph 
) [inline]

The geng program is in the gtools suite of the nauty package. This tool can generate all non-isomorphic undirected graphs with given node number from several classes (for example, general, connected, biconnected, triangle-free, 4-cycle-free, bipartite and graphs with given edge number and degree constraints). This function reads a nauty graph6 format line from the given stream and builds it in the given graph.

The site of nauty package: http://cs.anu.edu.au/~bdm/nauty/

For example, the number of all non-isomorphic connected graphs can be computed with next code:

      int num = 0;
      SmartUGraph ugraph;
      while(readNauty(std::cin, ugraph)) {
        PlanarityChecking<SmartUGraph> pc(ugraph);
        if (pc.run()) ++num;
      }
      std::cout << "Number of planar graphs: " << num << std::endl;

The nauty files are quite huge, therefore instead of the direct file generation the pipelining is recommended. The execution of this program:

      ./geng -c 10 | ./num_of_pg 


Generated on Thu Jun 4 04:03:13 2009 for LEMON by  doxygen 1.5.9