Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery
 
PerlMonks  

Re: Finding a Path

by Thelonius (Priest)
on Jan 24, 2007 at 14:27 UTC ( #596258=note: print w/ replies, xml ) Need Help??


in reply to Develop a Tree

There's a Graph module on CPAN. I haven't used it, but it looks like it's depth-first traversal would do for you.

Of course there's not usually just one path from a user's workstation to a server and the actual path depends on the state of each router's tables as the packet passes through them. But often--usually--the shortest path (in terms of # of edges or nodes) is the one taken.


Comment on Re: Finding a Path
Replies are listed 'Best First'.
Re^2: Finding a Path
by Herkum (Parson) on Jan 24, 2007 at 15:29 UTC

    I have taken a look at Graph before. The problem I have is that I cannot find any tutorials on how to use it. Most of what I seen in the way of examples, the programmer refers to everything in a way that imply you know what he is talking about.

    If you could point me at a tutorial for Graph I would certainly appreciate it.

      The tutorial for the Graph module is Mastering Algorithms with Perl by Jon Orwant, Jarkko Hietaniemi, and John Macdonald. I enjoyed this book very much and I use it as a reference for the Graph modules, which I use a lot.

      It should work perfectly the first time! - toma

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://596258]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (3)
As of 2015-07-30 04:04 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (269 votes), past polls