tools/lgf-gen.cc
changeset 2491 b63ae56979ef
parent 2453 2800d9efb01d
child 2493 6231d9d3957b
equal deleted inserted replaced
7:50c79b6807e6 8:c5f619892f8b
    13  * This software is provided "AS IS" with no warranty of any kind,
    13  * This software is provided "AS IS" with no warranty of any kind,
    14  * express or implied, and with no claim as to its suitability for any
    14  * express or implied, and with no claim as to its suitability for any
    15  * purpose.
    15  * purpose.
    16  *
    16  *
    17  */
    17  */
       
    18 ///\ingroup tools
       
    19 ///\file
       
    20 ///\brief Special plane graph generator.
       
    21 ///
       
    22 ///Graph generator application for various types of plane graphs.
       
    23 ///
       
    24 ///\verbatim
       
    25 /// This program converts various DIMACS formats to the LEMON Graph Format
       
    26 /// (LGF).
       
    27 ///
       
    28 /// Usage:
       
    29 ///   ./tools/lgf-gen [-2con|-tree|-tsp|-tsp2|-dela] [-disc|-square|-gauss]
       
    30 ///      [-rand|-seed int] [--help|-h|-help] [-area num] [-cities int] [-dir]
       
    31 ///      [-eps] [-g int] [-n int] [prefix]
       
    32 /// Where:
       
    33 ///   [prefix]
       
    34 ///      Prefix of the output files. Default is 'lgf-gen-out'
       
    35 ///   --help|-h|-help
       
    36 ///      Print a short help message
       
    37 ///   -2con
       
    38 ///      Create a two connected planar graph
       
    39 ///   -area num
       
    40 ///      Full relative area of the cities (default is 1)
       
    41 ///   -cities int
       
    42 ///      Number of cities (default is 1)
       
    43 ///   -dela
       
    44 ///      Delaunay triangulation graph
       
    45 ///   -dir
       
    46 ///      Directed graph is generated (each edges are replaced by two directed ones)
       
    47 ///   -disc
       
    48 ///      Nodes are evenly distributed on a unit disc (default)
       
    49 ///   -eps
       
    50 ///      Also generate .eps output (prefix.eps)
       
    51 ///   -g int
       
    52 ///      Girth parameter (default is 10)
       
    53 ///   -gauss
       
    54 ///      Nodes are located according to a two-dim gauss distribution
       
    55 ///   -n int
       
    56 ///      Number of nodes (default is 100)
       
    57 ///   -rand
       
    58 ///      Use time seed for random number generator
       
    59 ///   -seed int
       
    60 ///      Random seed
       
    61 ///   -square
       
    62 ///      Nodes are evenly distributed on a unit square
       
    63 ///   -tree
       
    64 ///      Create a min. cost spanning tree
       
    65 ///   -tsp
       
    66 ///      Create a TSP tour
       
    67 ///   -tsp2
       
    68 ///      Create a TSP tour (tree based)
       
    69 ///\endverbatim
       
    70 /// \image html plane_tree.png
       
    71 /// \image latex plane_tree.eps "Eucledian spanning tree" width=\textwidth
       
    72 ///
       
    73 
    18 
    74 
    19 #include <lemon/list_graph.h>
    75 #include <lemon/list_graph.h>
    20 #include <lemon/graph_utils.h>
    76 #include <lemon/graph_utils.h>
    21 #include <lemon/random.h>
    77 #include <lemon/random.h>
    22 #include <lemon/dim2.h>
    78 #include <lemon/dim2.h>