COIN-OR::LEMON - Graph Library

Changeset 2081:94a7deb46c07 in lemon-0.x


Ignore:
Timestamp:
05/12/06 17:29:42 (18 years ago)
Author:
Balazs Dezso
Branch:
default
Phase:
public
Convert:
svn:c9d7d8f5-90d6-0310-b91f-818b3a526b0e/lemon/trunk@2744
Message:

New demo file for computing disjoint paths

Doc review

Correcting misformatting in adaptors
Adding header to demos

Files:
2 added
5 edited

Legend:

Unmodified
Added
Removed
  • demo/Makefile.am

    r1979 r2081  
    1919        grid_ugraph_demo \
    2020        topology_demo \
    21         simann_maxcut_demo
     21        simann_maxcut_demo \
     22        disjoint_paths_demo
    2223
    2324if HAVE_GLPK
     
    6768
    6869simann_maxcut_demo_SOURCES = simann_maxcut_demo.cc
     70
     71disjoint_paths_demo_SOURCES = disjoint_paths.cc
  • demo/descriptor_map_demo.cc

    r1956 r2081  
    1717 */
    1818
     19/// \ingroup demos
     20/// \file
     21/// \brief Using descriptor map and own special map types.
     22///
     23/// This demo shows how can be used the DescriptorMap class
     24/// which helps to use unique label for each node or edge.
     25/// And it gives an example how easy is creating own map types.
     26///
     27/// \include descriptor_map_demo.cc
     28
    1929#include <lemon/list_graph.h>
    2030#include <lemon/graph_utils.h>
     
    3141using namespace lemon;
    3242
    33 // Special map type
    34 // It gives back a position for each node. The position of the nodes
     43// Special xy<double> map type
     44//
     45// It gives back a position for each node. The position of the nodes
    3546// are on the circle with the given center and radius.
    3647//
    37 // Because we use the descriptor map it will hold the proprty described above
    38 // even if a node added or deleted.
     48// Because we use the descriptor map it will hold the proprty
     49// described above even if a node added or deleted.
    3950template <typename Graph>
    4051class CircleMap {
  • demo/dim_to_dot.cc

    r1956 r2081  
    1717 */
    1818
    19 // Use a DIMACS max flow file as stdin.
    20 // dim_to_dot < dimacs_max_flow_file > dot_output_file
    21 // This program makes a dot file from a dimacs max flow file.
    22 // This program can be an aid in making up to date visualized documantation
    23 // of demo programs.
    24 
    25 // For later documentation (if marci does not do it)
    26 // Az a graphviz csomag egy egyszeru formatuma, ami egy graphrajzolo csomag.
    27 // Az EdgeSubGraphAdaptor doksijaban szerepel egy kirajzolt graf. Azt nem
    28 // kezzel csinaltam, hanem a megfelelo dim file-bol ezzel a progival. A
    29 // doxygen ugyanis ilyet eszik, igy a juzer vizualisan is latja a grafot a
    30 // doksiban, es sajat maga is le tudja futtatni az algoritmust, mert ott van
    31 // a kezeben a dim file is. Es mivel ez egy generalt file, ezert ha vmit
    32 // valtoztatunk a dim-en, ezt is konnyu bemasolni. Uff.
    33 
     19///\file
     20///\brief Dim (Dimacs) to Dot (Graphviz) converter
     21///
     22/// This program can convert the dimacs format to graphviz dot format.
     23///
     24/// Use a DIMACS max flow file as stdin.
     25///
     26/// <tt>dim_to_dot < dimacs_max_flow_file > dot_output_file</tt>
     27///
     28/// This program makes a dot file from a dimacs max flow file.
     29/// This program can be an aid in making up to date visualized documantation
     30/// of demo programs.
     31///
     32/// \include dim_to_dot.cc
    3433
    3534#include <iostream>
  • demo/tight_edge_filter_map.h

    r2042 r2081  
    1717 */
    1818
    19 #ifndef LEMON_TIGHT_EDGE_FILTER_MAP_H
    20 #define LEMON_TIGHT_EDGE_FILTER_MAP_H
     19#ifndef DEMO_TIGHT_EDGE_FILTER_MAP_H
     20#define DEMO_TIGHT_EDGE_FILTER_MAP_H
    2121
    2222#include <lemon/maps.h>
    2323
    24 // /// \file
    25 // /// \brief Maximum flow algorithms.
    26 // /// \ingroup galgs
     24/// \file
     25/// \brief Tight edge filter map.
     26///
     27/// Tight edge filter map is bool map on the edges of the graph
     28/// which filters the edges which are not tight for a node-potential.
     29/// It is used in the \ref sub_graph_adaptor_demo.cc file.
     30///
     31/// \include tight_edge_filter_map.h
    2732
    2833namespace lemon {
    2934
    30   /*!
    31     \brief A map for filtering the edge-set to those edges
    32     which are tight w.r.t. a node-potential and
    33     edge-distance.
    34    
    35     Let \f$ G=(V,A) \f$ be a directed graph (graph for short) and
    36     let \f$ \mathbb{F} \f$ be a number type.
    37     Given a distance function
    38     \f$ d:E\to\mathbb{F} \f$,
    39     \f$ \pi:V\to\mathbb{F} \f$ is said to be a potetial
    40     w.r.t. \f$ d \f$
    41     if and only if
    42     \f$ \pi(v)\le d(uv)+\pi(u) \f$ holds for each edge \f$ uv\in E \f$
    43     (or the reverse inequality holds for each edge).
    44     An edge is said to be tight if this inequality holds with equality,
    45     and the map returns \c true exactly for those edges.
    46     To avoid rounding errors, it is recommended to use this class with exact
    47     number types, e.g. with \c int.
    48   */
     35  /// \brief A map for filtering the edge-set to those edges
     36  /// which are tight w.r.t. a node-potential and
     37  /// edge-distance.
     38  ///
     39  /// Let \f$ G=(V,A) \f$ be a directed graph (graph for short) and
     40  /// let \f$ \mathbb{F} \f$ be a number type.
     41  /// Given a distance function
     42  /// \f$ d:E\to\mathbb{F} \f$,
     43  /// \f$ \pi:V\to\mathbb{F} \f$ is said to be a potetial
     44  /// w.r.t. \f$ d \f$
     45  /// if and only if
     46  /// \f$ \pi(v)\le d(uv)+\pi(u) \f$ holds for each edge \f$ uv\in E \f$
     47  /// (or the reverse inequality holds for each edge).
     48  /// An edge is said to be tight if this inequality holds with equality,
     49  /// and the map returns \c true exactly for those edges.
     50  /// To avoid rounding errors, it is recommended to use this class with exact
     51  /// number types, e.g. with \c int.
    4952  template<typename Graph,
    5053           typename NodePotentialMap, typename EdgeDistanceMap>
     
    6770} //namespace lemon
    6871
    69 #endif //LEMON_TIGHT_EDGE_FILTER_MAP_H
     72#endif //DEMO_TIGHT_EDGE_FILTER_MAP_H
  • lemon/graph_adaptor.h

    r2079 r2081  
    4242
    4343  ///\brief Base type for the Graph Adaptors
    44   ///\ingroup graph_adaptors
    4544  ///
    4645  ///Base type for the Graph Adaptors
     
    193192  };
    194193
     194  ///\ingroup graph_adaptors
     195  ///
     196  ///\brief Trivial Graph Adaptor
     197  ///
     198  /// This class is an adaptor which does not change the adapted graph.
     199  /// It can be used only to test the graph adaptors.
    195200  template <typename _Graph>
    196201  class GraphAdaptor :
     
    246251   
    247252
     253  ///\ingroup graph_adaptors
     254  ///
    248255  ///\brief A graph adaptor which reverses the orientation of the edges.
    249   ///\ingroup graph_adaptors
    250256  ///
    251257  /// If \c g is defined as
     
    637643  };
    638644
     645  /// \ingroup graph_adaptors
     646  ///
    639647  /// \brief A graph adaptor for hiding nodes and edges from a graph.
    640   /// \ingroup graph_adaptors
    641648  ///
    642649  /// SubGraphAdaptor shows the graph with filtered node-set and
     
    756763
    757764
     765  ///\ingroup graph_adaptors
     766  ///
    758767  ///\brief An adaptor for hiding nodes from a graph.
    759   ///\ingroup graph_adaptors
    760768  ///
    761769  ///An adaptor for hiding nodes from a graph.
     
    810818  }
    811819
     820  ///\ingroup graph_adaptors
     821  ///
    812822  ///\brief An adaptor for hiding edges from a graph.
    813823  ///
     
    12281238
    12291239
     1240  ///\ingroup graph_adaptors
     1241  ///
    12301242  /// \brief An undirected graph is made from a directed graph by an adaptor
    1231   /// \ingroup graph_adaptors
    12321243  ///
    12331244  /// Undocumented, untested!!!
     
    13661377
    13671378 
     1379  ///\ingroup graph_adaptors
     1380  ///
    13681381  ///\brief An adaptor for composing the residual
    13691382  ///graph for directed flow and circulation problems.
    1370   ///
    1371   ///\ingroup graph_adaptors
    13721383  ///
    13731384  ///An adaptor for composing the residual graph for directed flow and
     
    15751586
    15761587
     1588  ///\ingroup graph_adaptors
     1589  ///
    15771590  ///\brief For blocking flows.
    1578   ///\ingroup graph_adaptors
    15791591  ///
    15801592  ///This graph adaptor is used for on-the-fly
     
    23202332  /// \ingroup graph_adaptors
    23212333  ///
    2322   /// \brief SplitGraphAdaptor class
     2334  /// \brief Split graph adaptor class
    23232335  ///
    23242336  /// This is an graph adaptor which splits all node into an in-node
     
    23762388  ///
    23772389  /// The second solution contains just 3 disjoint paths while the first 4.
     2390  /// The full code can be found in the \ref disjoint_paths.cc demo file.
    23782391  ///
    23792392  /// This graph adaptor is fully conform to the
Note: See TracChangeset for help on using the changeset viewer.