COIN-OR::LEMON - Graph Library

Changeset 2509:a8081c9cd96a in lemon-0.x for lemon/network_simplex.h


Ignore:
Timestamp:
11/14/07 07:28:08 (16 years ago)
Author:
Peter Kovacs
Branch:
default
Phase:
public
Convert:
svn:c9d7d8f5-90d6-0310-b91f-818b3a526b0e/lemon/trunk@3374
Message:

Small changes in the min. cost flow classes.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • lemon/network_simplex.h

    r2471 r2509  
    2727
    2828#include <limits>
     29#include <lemon/graph_adaptor.h>
     30#include <lemon/graph_utils.h>
    2931#include <lemon/smart_graph.h>
    30 #include <lemon/graph_utils.h>
    3132
    3233/// \brief The pivot rule used in the algorithm.
     
    8687  /// - Edge capacities and costs should be nonnegative integers.
    8788  ///   However \c CostMap::Value should be signed type.
    88   /// - Supply values should be integers.
     89  /// - Supply values should be signed integers.
    8990  /// - \c LowerMap::Value must be convertible to
    9091  ///   \c CapacityMap::Value and \c CapacityMap::Value must be
     
    149150    public:
    150151
    151       typedef typename MapBase<Edge, Cost>::Value Value;
    152       typedef typename MapBase<Edge, Cost>::Key Key;
    153 
    154152      ReducedCostMap( const SGraph &_gr,
    155153                      const SCostMap &_cm,
     
    157155        gr(_gr), cost_map(_cm), pot_map(_pm) {}
    158156
    159       Value operator[](const Key &e) const {
     157      Cost operator[](const Edge &e) const {
    160158        return cost_map[e] - pot_map[gr.source(e)] + pot_map[gr.target(e)];
    161159      }
Note: See TracChangeset for help on using the changeset viewer.