help-gplusplus
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Programming a graph


From: Faheem Mitha
Subject: Re: Programming a graph
Date: Tue, 3 May 2005 05:54:15 +0000 (UTC)
User-agent: slrn/0.9.8.1 (Debian)

On Tue, 03 May 2005 00:38:27 +0200, Christian Christmann
<plfriko@yahoo.de> wrote:

> Hi,
>
> I need to write a graph which provides at least the
> following functions:
>
> 1) stores nodes and edges (both store further information which
>     can be of any type)
> 2) manipulations on nodes and edges like delete, add ...
> 3) provides a list of all successors/predecessors for a given node
> 4) provides a list of all nodes that can be reached from a given
>     node on an existing path (sequence of edges)
> 5) provides a list of all nodes that can reach n on a given path
> 6) check whether the graph is cyclic
>
> The code should be based on Standard Template Libraries (STL).
>
> How would you realize this task e.g. which structures would you 
> use? 
>
> Are there any STL graph classes which already provides the aforementioned
> functions?
>
> If you have or know any self-written graph code and would like to share
> just let me know ;) 

Have you checked out the Boost Graph library? I have not used it
myself, but might do what you want.

                                                             Faheem.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]