[Lemon-user] Question regarding the MaxWeightedPerfectMatching class
Dragos Trinca
dnt04001 at engr.uconn.edu
Thu Jul 17 14:44:30 CEST 2008
Hi,
I have a question regarding the MaxWeightedPerfectMatching class.
The following code works well:
#include <iostream>
#include <lemon/list_graph.h>
#include <lemon/max_matching.h>
int main()
{
typedef lemon::ListGraph Graph;
typedef Graph::EdgeMap<int> LengthMap;
using lemon::INVALID;
Graph g;
LengthMap length(g);
typedef lemon::MaxWeightedPerfectMatching<Graph,LengthMap> MWPM;
// MWPM gg(g, length);
}
However, if I remove the comments from the last line, it gives me errors as follows:
/home/dnt04001/lemon-0.7/include/lemon/max_matching.h: In instantiation of âlemon::MaxWeightedPerfectMatching<lemon::ListGraph, lemon::GraphExtender<lemon::ListGraphBase>::EdgeMap<int> >â:
hello_lemon.cc:95: instantiated from here
/home/dnt04001/lemon-0.7/include/lemon/max_matching.h:2024: error: no type named âUEdgeâ in âclass lemon::ListGraphâ
/home/dnt04001/lemon-0.7/include/lemon/max_matching.h:2024: error: no type named âUEdgeItâ in âclass lemon::ListGraphâ
/home/dnt04001/lemon-0.7/include/lemon/max_matching.h:2024: error: no type named âIncEdgeItâ in âclass lemon::ListGraphâ
/home/dnt04001/lemon-0.7/include/lemon/max_matching.h: In instantiation of âlemon::MaxWeightedPerfectMatching<lemon::ListGraph, lemon::GraphExtender<lemon::ListGraphBase>::EdgeMap<int> >â:
hello_lemon.cc:95: instantiated from here
/home/dnt04001/lemon-0.7/include/lemon/max_matching.h:2055: error: no class template named âUEdgeMapâ in âclass lemon::ListGraphâ
/home/dnt04001/lemon-0.7/include/lemon/max_matching.h:2100: error: no class template named âUEdgeMapâ in âclass lemon::ListGraphâ
/home/dnt04001/lemon-0.7/include/lemon/max_matching.h:2101: error: no class template named âUEdgeMapâ in âclass lemon::ListGraphâ
/home/dnt04001/lemon-0.7/include/lemon/max_matching.h:2474: error: no type named âUEdgeâ in âclass lemon::ListGraphâ
/home/dnt04001/lemon-0.7/include/lemon/max_matching.h:2508: error: no type named âUEdgeâ in âclass lemon::ListGraphâ
/home/dnt04001/lemon-0.7/include/lemon/max_matching.h:2990: error: no type named âUEdgeâ in âclass lemon::ListGraphâ
/home/dnt04001/lemon-0.7/include/lemon/max_matching.h: In constructor âlemon::MaxWeightedPerfectMatching<_UGraph, _WeightMap>::MaxWeightedPerfectMatching(const _UGraph&, const _WeightMap&) [with _UGraph = lemon::ListGraph, _WeightMap = lemon::GraphExtender<lemon::ListGraphBase>::EdgeMap<int>]â:
hello_lemon.cc:95: instantiated from here
/home/dnt04001/lemon-0.7/include/lemon/max_matching.h:2825: error: using invalid field âlemon::MaxWeightedPerfectMatching<_UGraph, _WeightMap>::_delta3_indexâ
/home/dnt04001/lemon-0.7/include/lemon/max_matching.h:2825: error: using invalid field âlemon::MaxWeightedPerfectMatching<_UGraph, _WeightMap>::_delta3â
/home/dnt04001/lemon-0.7/include/lemon/max_matching.h: In member function âvoid lemon::MaxWeightedPerfectMatching<_UGraph, _WeightMap>::destroyStructures() [with _UGraph = lemon::ListGraph, _WeightMap = lemon::GraphExtender<lemon::ListGraphBase>::EdgeMap<int>]â:
/home/dnt04001/lemon-0.7/include/lemon/max_matching.h:2828: instantiated from âlemon::MaxWeightedPerfectMatching<_UGraph, _WeightMap>::~MaxWeightedPerfectMatching() [with _UGraph = lemon::ListGraph, _WeightMap = lemon::GraphExtender<lemon::ListGraphBase>::EdgeMap<int>]â
hello_lemon.cc:95: instantiated from here
/home/dnt04001/lemon-0.7/include/lemon/max_matching.h:2179: error: using invalid field âlemon::MaxWeightedPerfectMatching<_UGraph, _WeightMap>::_delta3â
/home/dnt04001/lemon-0.7/include/lemon/max_matching.h:2180: error: using invalid field âlemon::MaxWeightedPerfectMatching<_UGraph, _WeightMap>::_delta3_indexâ
/home/dnt04001/lemon-0.7/include/lemon/max_matching.h:2181: error: using invalid field âlemon::MaxWeightedPerfectMatching<_UGraph, _WeightMap>::_delta3â
Maybe somebody can tell me how to use the MaxWeightedPerfectMatching class.
Thanks,
Dragos
More information about the Lemon-user
mailing list