Boost logo

Boost Users :

From: Carsten Scholtes (carsten.scholtes_at_[hidden])
Date: 2007-03-30 11:13:18


Hello!

I'm trying to use boost::graph's adjacency_list<listS, multisetS,...>.
The documentation ( boost_1_33_1/libs/graph/doc/adjacency_list.html )
states for the function edge_range():

> This function only works when the OutEdgeList for the adjacency_list
> is a container that sorts the out edges according to target vertex,
> and allows for parallel edges. The multisetS selector chooses
> such a container.

Attached you find a small program demonstrating a case where edges do
not seem to get sorted accordingly. The last comment in the program
contains a sample output.

* The line below "All edges" shows the sequence of all edges. It does
not seem to be sorted in the specified way. Probably as a consequnce
of this, edge_range() does not work as expected:

* The last line of the output is generated by using
edge_range(). It should output edges from node 1 to node 0. There is
only one such edge. Instead of that, edges (1,2) and (1,0) are returned.

Am I using the interface in a wrong way or is there an error in the
implementation of adjacency_list<>?

Thank you in advance for any comment or advice.

Carsten Scholtes




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