tsp_tour_visitor

Records the vertices of a TSP tour into an output iterator.

Defined in: <boost/graph/metric_tsp_approx.hpp>
Models: TSP Tour Visitor

Usage

std::vector<Vertex> tour;
metric_tsp_approx(g, get(edge_weight, g),
                  make_tsp_tour_visitor(std::back_inserter(tour)));

Synopsis

template <typename OutputIterator>
struct tsp_tour_visitor;

template <typename OutputIterator>
tsp_tour_visitor<OutputIterator>
make_tsp_tour_visitor(OutputIterator iter);

Parameters

Parameter Description

OutputIterator

Output iterator that receives vertex descriptors of the tour.