
www.Usenet.com
| <-- __Chronological__ --> | <-- __Thread__ --> |
Siddharth S Malu <[EMAIL PROTECTED]> wrote in message news:<[EMAIL PROTECTED]>...
> I have seen algorithms for listing all spanning trees of a network,
> which is also exponential. It might be helpful in some cases, where the
> each tree is evaluated on different scores.
> Something similar might apply for paths. Comments from OP?
Lots(Network net, Path start, Node fini)
{
if(fini in start) emit(start)
else {
foreach Node n, a successor of start.end() {
if(n not in start) Lots(net, start + n, fini);
}
}
}
In the intial call, pass a path consisting of the source node.
This still won't get all paths.
Paths with cycles will be eliminated.
If there is one, there is an infinity of them.
| <-- __Chronological__ --> | <-- __Thread__ --> |