Optimizing Dijkstra for dense graph?

Posted by Jason on Stack Overflow See other posts from Stack Overflow or by Jason
Published on 2009-09-12T00:31:53Z Indexed on 2010/06/05 15:02 UTC
Read the original article Hit count: 246

Filed under:
|
|
|

Is there another way to calculate the shortest path for a near complete graph other than Dijkstra? I have about 8,000 nodes and about 18 million edges. I've gone through the thread "a to b on map" and decided to use Dijkstra. I wrote my script in Perl using the Boost::Graph library. But the result isn't what I expected. It took about 10+ minutes to calculate one shortest path using the call $graph->dijkstra_shortest_path($start_node,$end_node);

I understand there are a lot of edges and it may be the reason behind the slow running time. Am I dead in the water? Is there any other way to speed this up?

© Stack Overflow or respective owner

Related posts about path

Related posts about graph