On Nov 20, 2007 12:30 PM, Vijay Kumar Adhikari <[EMAIL PROTECTED]> wrote: > > Perhaps if you told us what you need > > a tree for (because you almost never need a tree for itself) we could > > suggest a good high level module. > > I am trying to analyze BGP routing table available at RouteViews > routing archive. The data looks something like > > 1.0.0.0/8 1 2 3 4 5 6 > 7 4 5 6 > 8 9 6 > 2.0.0.0/8 1 2 10 11 > 7 4 11 > 3.0.0.0/8 1 12 13 > 7 14 > 8 12 13 > > For 1.0.0.0/8, the path make a tree rooted at 6 and 1, 7 and 8 > appearing as the leaves, for 2.0.0.0/8 the root is at 11 and 1 and 7 > are leaves. For 3.0.0.0/8 the structure is not a tree. We may thing of > the structure as two trees rooted at 13 and 14 respectively. There may > be many other cases possible. > > What I want to do is to see how many of the structures are trees? How > many are not? If not how many connected components are there? If the > structure is a tree what is the depth of the tree, what is the maximum > fanout etc. I want to see if the similarity of two structure tell me > some relationship between the prefixes. For instance, do two prefixes > owned by the same organization have the same structure. And things > like that. I am not specifically looking for something. I am trying to > study the structures to see if there is something interesting there. > > Maybe this time I am using trees just for trees :) > > -- > Vijay >
It looks to me like the Graph module is what you want then. -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/