Last year I wrote a routine for a client that did "shortest path" in
MapBasic. It was based on Dijikstra's algorithm (see
http://www.orie.cornell.edu/~or115/handouts/handout3/handout3.html), and
it worked surprisingly well for a language as slow as MapBasic. It would
have performance problems applied to a large (many node) network, but
for finding the shortest path along fiber cables from city to city, it
worked fast enough.

As to detail in the roads, all you need is a way to uniquely identify
each segment (I used RowId), and all segments must at end nodes. In
other words, if you have a segment that joins another in a "T"
intersection, then the segment that crosses the T needs to be split at
that point so that all three segments terminate at a common node. Also,
you have to ensure that segments actually *meet*. I had a few that were
close, but didn't actually touch (even though they were supposed to.) So
your first problem will be to "clean" the network before you can index
it for shortest path.

But there are commercial apps to do this. I think there's one called
RouteView.

- Bill Thoen
------------------------------------------------------------ 
GISnet, 1401 Walnut St., Suite C, Boulder, CO  80302
tel: 303-786-9961, fax: 303-443-4856
mailto:[EMAIL PROTECTED], http://www.ctmap.com/gisnet
------------------------------------------------------------

"Lawley, Jane" wrote:
> 
> hi,
> 
> is mapinfo capable of shortest path analysis or is there an extension
> available for this kind of analysis? and what sort of detail do i need in
> the road file for this type of analysis?
> 
> thanks in advance for your help!
> 
> cheers, jane



_______________________________________________________________________
List hosting provided by Directions Magazine | www.directionsmag.com |
To unsubscribe, send e-mail to [EMAIL PROTECTED] and
put "unsubscribe MapInfo-L" in the message body.

Reply via email to