PotentialDifferenceMap< GR, POT > Class Template Reference
[Graph Maps]


Detailed Description

template<typename GR, typename POT>
class lemon::PotentialDifferenceMap< GR, POT >

PotentialDifferenceMap returns the difference between the potentials of the source and target nodes of each arc in a digraph, i.e. it returns
   potential[gr.target(arc)] - potential[gr.source(arc)].
Template Parameters:
GR The digraph type.
POT A node map storing the potentials.
#include <lemon/maps.h>

List of all members.

Public Types

typedef GR::Arc Key
 Key type.
typedef POT::Value Value
 Value type.

Public Member Functions

 PotentialDifferenceMap (const GR &gr, const POT &potential)
 Constructor.
Value operator[] (const Key &arc) const
 Returns the potential difference for the given arc.

Related Functions

(Note that these are not member functions.)

template<typename GR , typename POT >
PotentialDifferenceMap< GR, POT > potentialDifferenceMap (const GR &gr, const POT &potential)
 Returns a PotentialDifferenceMap.


Constructor & Destructor Documentation

PotentialDifferenceMap ( const GR &  gr,
const POT &  potential 
) [inline, explicit]

Contructor of the map.


Member Function Documentation

Value operator[] ( const Key arc  )  const [inline]

Returns the potential difference for the given arc, i.e.

   potential[gr.target(arc)] - potential[gr.source(arc)].


Generated on Wed May 13 09:53:08 2009 for LEMON by  doxygen 1.5.9