]> git.proxmox.com Git - ceph.git/blame - ceph/src/boost/libs/graph/doc/tsp_tour_len_visitor.html
bump version to 12.2.2-pve1
[ceph.git] / ceph / src / boost / libs / graph / doc / tsp_tour_len_visitor.html
CommitLineData
7c673cae
FG
1<HTML>
2<!--
3 Copyright (c) Matyas Egyhazy 2008
4 Distributed under the Boost Software License, Version 1.0.
5 (See accompanying file LICENSE_1_0.txt or copy at
6 http://www.boost.org/LICENSE_1_0.txt)
7 -->
8<Head>
9<Title>Boost Graph Library: tsp_tour_len_visitor</Title>
10<BODY BGCOLOR="#ffffff" LINK="#0000ee" TEXT="#000000" VLINK="#551a8b"
11 ALINK="#ff0000">
12<IMG SRC="../../../boost.png"
13 ALT="C++ Boost" width="277" height="86">
14
15<BR Clear>
16
17<H1>
18<pre>
19tsp_tour_len_visitor&lt;Graph, WeightMap, OutputIterator, Length&gt;
20</pre>
21</H1>
22
23This type is a TSP tour visitor. It supplies the OutputIterator with the vertices of the tour and
24records the total length of the tour.
25
26<h3>Example</h3>
27
28<pre>
29double d(0.0);
30std::vector&lt;Vertex&gt; c;
31boost::metric_tsp_approx
32 (g, get(edge_weight, g),
33 make_tsp_tour_len_visitor(g, std::back_inserter(c), d, get(edge_weight, g)));
34</pre>
35
36
37<h3>Model of</h3>
38
39<a href="./TSPTourVisitor.html">TSP Tour Visitor</a>
40
41<H3>Template Parameters</H3>
42
43<P>
44<TABLE border>
45<TR>
46<th>Parameter</th><th>Description</th><th>Default</th>
47</tr>
48
49<TR><TD><TT>Graph</TT></TD>
50<TD>
51The graph type
52</TD>
53<TD>None</TD>
54</TR>
55
56<TR><TD><TT>WeightMap</TT></TD>
57<TD>
58The weight of each edge in the graph.
59The type <tt>WeightMap</tt> must be a model of
60<a href="../../property_map/doc/ReadablePropertyMap.html">Readable Property Map</a>.
61The edge descriptor type of the graph needs to be usable as the key type for the weight map.
62</TD>
63<TD>None</TD>
64</TR>
65
66<TR><TD><TT>OutputIterator</TT></TD>
67<TD>
68An OutputIterator
69</TD>
70<TD>None</TD>
71</TR>
72
73<TR><TD><TT>Length</TT></TD>
74<TD>
75A suitable container for the length of the tour. It must implement additive operators.
76</TD>
77<TD>None</TD>
78</TR>
79
80</table>
81
82<H3>Where Defined</H3>
83
84<P>
85<a href="../../../boost/graph/metric_tsp_approx.hpp">
86<TT>boost/graph/metric_tsp_approx.hpp</TT></a>
87
88<h3>Member Functions</h3>
89
90This class implements all of the member functions required by <a
91href="./TSPTourVisitor.html">TSPTourVisitor</a>.
92
93<h3>Non-Member Functions</h3>
94
95<table border>
96<tr>
97<th>Function</th><th>Description</th>
98</tr>
99
100<tr><td><tt>
101template &lt;typename Graph, typename WeightMap, typename OutputIterator, typename Length&gt;<br>
102tsp_tour_len_visitor&lt;OutputIterator&gt;<br>
103make_tsp_tour_len_visitor(Graph const& g, OutIter iter, Length& l, WeightMap map)
104</tt></td><td>
105Returns a tour_len_visitor that records the TSP tour in the OutputIterator parameter and the length of the tour in the Length parameter.
106</td></tr>
107
108</table>
109
110<h3>See Also</h3>
111
112None
113
114<br>
115<HR>
116<TABLE>
117<TR valign=top>
118<TD nowrap>Copyright &copy; 2008</TD><TD>
119Matyas Egyhazy
120</TD></TR></TABLE>
121
122</BODY>
123</HTML>