[OSM-talk] conclusions from my postgres / postgis experiments

raphael Jacquot sxpert at sxpert.org
Thu Nov 23 11:29:47 GMT 2006


SteveC wrote:

>> * we need higher level ways, to group all linear ways that belong to a 
>> particular street
> 
> I'm not entirely sure why... I'm imagining a routing algorithim that
> will notice that its on a way with the same name as the one it was just
> driving on and that's it. Are there any use cases for super ways?

there are multiple issues here.

routing algorithms need a network composed of simple linear features 
that contain exactly one 'in' and one 'out', as trying to make sense of 
tree-like structures and loops and stuff is not only a waste of 
processing power, but also computationally challenging. also, they need 
the one way information, and that's about it.

here's a typical network :
                                          H
I                                        *
*-----<----.                             |
             \                            ^
A            \             D             |
*----->------*---*---*--*--*-------------* F
            B |             |             \
              |             |              `-----<------* G
              v             ^
              |             |
              |             |
              *------>------*
              C  train      E
	        station

(this is how it looks like in front of the train station here in grenoble.)

segments A-B, B-D, B-I, D-F  are on the same street, your routing 
algorithm needs to have access to those segments as separate ways
however, prior to doing the routing, you need to search for that 
street's name. it's simpler if you have to look up only one record for 
that street, even if it's composed of multiple segments.

so you look up the street name, get the list of ways that that street is 
composed of, then look up the one which contain say, the number you're 
looking for.

in the case of A->B, you'll have odd numbers, and B->I you'd have even 
numbers.




More information about the talk mailing list