Boost Users :
Subject: Re: [Boost-users] Bidirectional Graph and undirected graphs
From: Daniel Russel (drussel_at_[hidden])
Date: 2009-05-13 16:57:46
On Wed, May 13, 2009 at 1:38 PM, Andrew Sutton <andrew.n.sutton_at_[hidden]>wrote:
> The latter implies that undirected graphs have to have two copies of each
>> edge, one pointed each direction.
>> Which is correct? The former, I hope :-) Thanks.
> Undirected graphs store only one set of edges. The implementation of the
> just makes it seem like two different copies :)
I'm not sure I understand your response. I was being sloppy and using edge
and edge descriptor interchangeably (since there is no separate concept of
If the returned edge_descriptor (by out_edges) must have v at its source,
then there must be at least two edge descriptors per undirected edge.
Currently our graph uses a pointer to an edge object as an edge descriptor.
Getting the "source" using such an edge descriptor can't always return v
since it has no way of knowing where the edge descriptor came from. I can
change the edge descriptor to be a pair of vertices, which would solve the
problem, but don't want to if not needed. Thanks.
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net