[pgrouting-dev] APSP Implementation

Jay Mahadeokar jai.mahadeokar at gmail.com
Fri Jan 28 07:04:33 EST 2011


Hi,

I have committed to https://github.com/jay-mahadeokar/pgrouting. Its just a
initial draft, will look into in again for optimising and making changes as
suggested by Anton. The current code should serve as the basic template for
apsp I guess.

I have modified the /core/src/CMakeLists.txt file such that it only compiles
dijekstra and apsp. Please look into it and change as it suits you before
compiling.

After installing, you may try and run queries like this:  SELECT * from
all_pairs_shortest_path('SELECT gid as
id,source::integer,target::integer,length::double precision as cost from
ways where source in (169,170,171,168)'::TEXT,false,false);

Note - I have set Debug ON. Put it to off for faster outputs.

TODO List -

1. How to deal with negative edge weights? I am finding negative values in
some output. I have still not yet looked into it thoroughly.
2. Changing the Distance Matrix type so that float8 is supported.
3. Commenting the code.


On Wed, Jan 26, 2011 at 9:00 AM, Anton Patrushev <
anton.patrushev at georepublic.de> wrote:

> Hi Jay,
>
> Sounds great already!
>
> As far as I remember, distance type in DistanceMatrix depends on the
> way you initialize DistanceMatrix type template - you need to set
> proper value type of your weight map.
>
> Anton.
> _______________________________________________
> pgrouting-dev mailing list
> pgrouting-dev at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/pgrouting-dev
>



-- 
Regards,
-Jay Mahadeokar
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/pgrouting-dev/attachments/20110128/ab52b9e8/attachment.html


More information about the pgrouting-dev mailing list