COIN-OR::LEMON - Graph Library

source: lemon-tutorial/tools.dox @ 51:e335f323a929

Last change on this file since 51:e335f323a929 was 46:58557724a139, checked in by Peter Kovacs <kpeter@…>, 15 years ago

Add new sekeleton pages and complete the TOC

File size: 2.7 KB
Line 
1/* -*- mode: C++; indent-tabs-mode: nil; -*-
2 *
3 * This file is a part of LEMON, a generic C++ optimization library.
4 *
5 * Copyright (C) 2003-2010
6 * Egervary Jeno Kombinatorikus Optimalizalasi Kutatocsoport
7 * (Egervary Research Group on Combinatorial Optimization, EGRES).
8 *
9 * Permission to use, modify and distribute this software is granted
10 * provided that this copyright notice appears in all copies. For
11 * precise terms see the accompanying LICENSE file.
12 *
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
15 * purpose.
16 *
17 */
18
19namespace lemon {
20/**
21[PAGE]sec_tools[PAGE] Tools
22
23\todo This page is under construction.
24
25[SEC]sec_aux_structures[SEC] Auxiliary Data Structures
26Graph algorithms depend on various auxiliary data structures and algorithms.
27For example, heaps play an important role in Dijkstra and Prim
28algorithms, both the theoretical and practical performance of them
29are determined by the applied heap implementation.
30
31LEMON implements various such auxiliary tools. For instance,
32several data structures are available for maintaining \e disjoint \e sets.
33\ref UnionFind is the classical union-find data structure, which is
34used to implement the \ref Kruskal algorithm.
35The \ref UnionFindEnum and \ref HeapUnionFind classes are used in
36matching algorithms, the first one supports the enumeration of the
37items stored in the sets, while the second one also assigns priorities to the
38elements and an item having minimum priority can be retrieved set-wise.
39
40
41[SEC]sec_graph_to_eps[SEC] Postscript Exporting
42
43Another nice feature of the library is \ref graphToEps(), a highly
44configurable graph displaying tool (using EPS output format).
45Originally, it was developed to evaluate the flexibility and scalability
46of LEMON's approach to implement named parameters. Later it
47has been evolved into a versatile tool featuring above 35 named
48parameters. The following code demonstrates its typical use.
49
50\code
51  graphToEps(g, "graph.eps")
52    .coords(coords)
53    .title("Sample EPS figure")
54    .copyright("(c) 2003-2010 LEMON Project")
55    .absoluteNodeSizes().absoluteArcWidths()
56    .nodeScale(2).nodeSizes(sizes)
57    .nodeShapes(shapes)
58    .nodeColors(composeMap(palette, colors))
59    .arcColors(composeMap(palette, acolors))
60    .arcWidthScale(.4).arcWidths(widths)
61    .nodeTexts(id).nodeTextSize(3)
62    .run();
63\endcode
64
65Using this feature, various nice images can be generated from graphs,
66like this one.
67
68\image html graph_to_eps.png
69
70
71[SEC]sec_time_count[SEC] Time Measuring and Counting
72
73See \ref timecount.
74
75
76[SEC]sec_random[SEC] Random Number Generation
77
78See \ref Random.
79
80
81[SEC]sec_arg_parser[SEC] Argument Parser
82
83See \ref ArgParser.
84
85[TRAILER]
86*/
87}
Note: See TracBrowser for help on using the repository browser.