Whoops ... the compiler must have been hallucinating :-)<div><br></div><div>I know I was; I can look up an edge, but can&#39;t remove one.�<br><div><br></div><div>I have tried it two ways:�</div><div><br></div><div>remove_edge(u,v,g);�</div>
<div>and�</div><div>remove_edge(e,g);�</div><div><br></div><div>with u,v being vertices and e being an edge of course.�</div><div><br></div><div>Possible I do not have a MutableGraph but really I am not sure. I do know an edge exists between vertices u and v.�</div>
<div><br></div><div>Eric<br><br><div class="gmail_quote">On Thu, Jun 10, 2010 at 12:46 AM, Cedric Laczny <span dir="ltr">&lt;<a href="mailto:cedric.laczny@gmx.de">cedric.laczny@gmx.de</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
Hi,<br>
<br>
when I look at the error, I see that it complains about remove_edge().<br>
However, I don&#39;t see any call of this in your example code. So I would suggest<br>
that you either post a complete and short &quot;working&quot; example, or more carefully<br>
select the lines that you post.<br>
<br>
Concerning the question in the title of your post, one way to check if there<br>
is an edge between two vertices could be to get the adjacent vertices of<br>
Vertex b and check if Vertex d is among them, or even to check if Vertex b has<br>
any adjacent vertices at all. I know, this is probably not the nicest solution<br>
but unless you don&#39;t use an AdjacencyMatrix graph, I don&#39;t know if this would<br>
even be possible in a nicer way, so to say in O(1).<br>
<br>
Best,<br>
<font color="#888888"><br>
Cedric<br>
</font><div><div></div><div class="h5"><br>
On Thursday, 10. June 2010 06:59:24 Eric Fowler wrote:<br>
&gt; This should be easy ....<br>
&gt;<br>
&gt; typedef adjacency_list&lt;vecS, vecS, undirectedS, POS&lt;position_type&gt;,<br>
&gt; LEN&lt;position_type&gt; &gt; DG;<br>
&gt; typedef graph_traits&lt;DG&gt;::vertex_descriptor Vertex;<br>
&gt; typedef graph_traits&lt;DG&gt;::edge_descriptor Edge;<br>
&gt;<br>
&gt; ...<br>
&gt; Vertex b, d;<br>
&gt; ...populate b and ....<br>
&gt;<br>
&gt; bool bRet;<br>
&gt; Edge e;<br>
&gt;<br>
&gt; tie(e,bRet) = edge(b,d,*this);<br>
&gt;<br>
&gt; This earns me a lengthy error message from g++ (following).<br>
&gt;<br>
&gt; I notice that there is no function described for looking up an edge on an<br>
&gt; IncidenceGraph or an AdjacencyGraph ... hmm .... this puzzles me.<br>
&gt;<br>
&gt; What am I missing?<br>
&gt;<br>
&gt; Eric<br>
&gt;<br>
&gt; ../shuttle/trunk/DelaunayGraph.h:273: error: no matching function for call<br>
&gt; to �DelaunayGraph&lt;int&gt;::remove_edge(Edge&amp;, DelaunayGraph&lt;int&gt;&amp;)�<br>
&gt; /usr/include/boost/graph/detail/adjacency_list.hpp:848: note: candidates<br>
&gt; are: void boost::undirected_graph_helper&lt;Config&gt;::remove_edge(typename<br>
&gt; Config::edge_descriptor) [with Config =<br>
&gt; boost::detail::adj_list_gen&lt;boost::adjacency_list&lt;boost::vecS, boost::vecS,<br>
&gt; boost::undirectedS, POS&lt;int&gt;, LEN&lt;int&gt;, boost::no_property, boost::listS&gt;,<br>
&gt; boost::vecS, boost::vecS, boost::undirectedS,<br>
&gt; boost::property&lt;boost::vertex_bundle_t, POS&lt;int&gt;, boost::no_property&gt;,<br>
&gt; boost::property&lt;boost::edge_bundle_t, LEN&lt;int&gt;, boost::no_property&gt;,<br>
&gt; boost::no_property, boost::listS&gt;::config]<br>
&gt; /usr/include/boost/graph/detail/adjacency_list.hpp:859: note:<br>
&gt; � void boost::undirected_graph_helper&lt;Config&gt;::remove_edge(typename<br>
&gt; Config::out_edge_iterator) [with Config =<br>
&gt; boost::detail::adj_list_gen&lt;boost::adjacency_list&lt;boost::vecS, boost::vecS,<br>
&gt; boost::undirectedS, POS&lt;int&gt;, LEN&lt;int&gt;, boost::no_property, boost::listS&gt;,<br>
&gt; boost::vecS, boost::vecS, boost::undirectedS,<br>
&gt; boost::property&lt;boost::vertex_bundle_t, POS&lt;int&gt;, boost::no_property&gt;,<br>
&gt; boost::property&lt;boost::edge_bundle_t, LEN&lt;int&gt;, boost::no_property&gt;,<br>
&gt; boost::no_property, boost::listS&gt;::config]<br>
&gt; make: *** [MyDialog.o] Error 1<br>
</div></div><div class="im">_______________________________________________<br>
Boost-users mailing list<br>
<a href="mailto:Boost-users@lists.boost.org">Boost-users@lists.boost.org</a><br>
</div><div><div></div><div class="h5"><a href="http://lists.boost.org/mailman/listinfo.cgi/boost-users" target="_blank">http://lists.boost.org/mailman/listinfo.cgi/boost-users</a></div></div></blockquote></div><br></div>
</div>