Boost logo

Boost Users :

From: Heiko Bauke (Heiko.Bauke_at_[hidden])
Date: 2004-03-05 03:37:31


Hello,

since some weeks I'm using the BGL. It's really a great library. But
I'm a bit confused about the documentation for the template class
adjacency_matrix.

According to the BGL-book and also the online documentation there
should be three constructors for adjacency_matrix:

adjacency_matrix(vertices_size_type n,
                 const GraphProperty& p = GraphProperty())

template <typename EdgeIterator>
adjacency_matrix(EdgeIterator first,
                 EdgeIterator last,
                 vertices_size_type n,
                 const GraphProperty& p = GraphProperty())

and

template <typename EdgeIterator, typename EdgePropertyIterator>
adjacency_matrix(EdgeIterator first, EdgeIterator last,
                 EdgePropertyIterator ep_iter,
                 vertices_size_type n,
                 const GraphProperty& p = GraphProperty())

but actually in boost/graph/adjacency_matrix.hpp is only the
constructor

adjacency_matrix(vertices_size_type n_vertices)

is defined. So it's not possible to construct an adjacency_matrix
from a pair of iterators (as it is possible for adjacency_list).

Has this constructor been removed or never been implemented? Such a
constructor would be very useful for me.

Another point that confuses me is that the template parameter
GraphProperty for

  template <typename Directed = directedS,
            typename VertexProperty = no_property,
            typename EdgeProperty = no_property,
            typename GraphProperty = no_property,
            typename Allocator = std::allocator<bool> >
  class adjacency_matrix;

seams never been used for the implementation of this class.

         regards,

         Heiko

P.S. I'm using boost 1.30.0.

-- 
-- Gute Sitten haben für die Gesellschaft mehr Wert als alle 
-- Berechnungen Newtons. (Friedrich II., der Große, 1712-1786)
-- Supercomputing in Magdeburg @ http://tina.nat.uni-magdeburg.de
--                 Heiko Bauke @ http://www.uni-magdeburg.de/bauke

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