Re: Finding longest path between two vertices
- From: tchow@xxxxxxxxxxxxx
- Date: 18 Jun 2007 22:15:52 GMT
In article <1182197872.234378.227740@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>,
Googmeister <googmeister@xxxxxxxxx> wrote:
Right, Bellman-Ford works in directed graphs with no negative cycles.
Note that if the graph is acyclic, you can compute shortest/longest
path in linear time via topological sort.
Right.
On Jun 18, 3:36 pm, Jym <Jean-Yves.Moyen+n...@xxxxxxxxxxxx> wrote:
I agree that there is a problem for finding "longest simple path" (ie
without taking the same edge several times). The OP had not make it clear
if that's really what he meant by "longest path".
O.K., you could be right. However, usually "path" means that there are no
repeated vertices. "Hamiltonian path," "shortest path," etc., all mean no
repeated vertices in the literature. But, it's conceivable that the OP
meant to consider only acyclic directed graphs.
--
Tim Chow tchow-at-alum-dot-mit-dot-edu
The range of our projectiles---even ... the artillery---however great, will
never exceed four of those miles of which as many thousand separate us from
the center of the earth. ---Galileo, Dialogues Concerning Two New Sciences
.
- Follow-Ups:
- References:
- Finding longest path between two vertices
- From: Tim Frink
- Re: Finding longest path between two vertices
- From: tchow
- Re: Finding longest path between two vertices
- From: Jym
- Re: Finding longest path between two vertices
- From: Googmeister
- Finding longest path between two vertices
- Prev by Date: Re: Finding longest path between two vertices
- Next by Date: Re: Finding longest path between two vertices
- Previous by thread: Re: Finding longest path between two vertices
- Next by thread: Re: Finding longest path between two vertices
- Index(es):
Relevant Pages
|