[pgrouting-dev] selection of node types in dijkstra/TSP etc

Stephen Woodbridge woodbri at swoodbridge.com
Wed Apr 11 10:21:54 EDT 2012


Dave,

Do you have any articles/papers that discuss this kind of solver? I have 
not come across this or I'm not understanding your use case. As Daniel 
has mentioned the we typically control selection by modifying the costs. 
For example, I made a graph that used the angled between the segments as 
the cost and then created routes of minimum angle. This could be used 
for example to generate routes for tractor trailer trucks in low 
maneuverability.

-Steve

On 4/11/2012 4:22 AM, Dave Potts wrote:
> Hi Steve,
>
> Thats useful but its not quite what I am looking for.
>
> I can not make a preselection before I start routing, what I am actual
> after is a 'rule based selection'
>
> for example before selecting the next node to consider when selecting the
> shortest path,  I like to apply a set of rules.
>
>
> Whats the shortest path if I consider this dangerous node.
> Whats the shortest path if I consider what to go near this node etc
>
> There are many reasons why should you choose to go near nodes, some may be
> more danegrous that others.  I can just screen out all the nodes before I
> start out.
>
> Dave.
> Stephen Woodbridge wrote:
>> On 4/10/2012 7:22 AM, Dave Potts wrote:
>>>
>>>
>>> Hi
>>>
>>> Normally routing problems such as dijkstra/TSP always select the best
>>> route by the length of the route.
>>>
>>> Does anybody known a version that selects the route choosen by the node
>>> type as well as the distance covered?  The reason that I ask, in cases
>>> the
>>> select of the node type is important for example
>>>
>>> I am trying to get from node A to F,
>>>
>>> I have to possible routes A B C F  , A E to F or A D F.
>>>
>>> The route  A D E is the shortest one, but D is noted number of highway
>>> men/gunfighters living in town.
>>>
>>> I am a careful man and would prefer to travel the safest fast route.  Is
>>> there a generic solution to this type of problem other than removing D
>>> from the input list of nodes to compare?
>>>
>>> Can anybody suggest a different news group where this type of issue
>>> could
>>> be raised?
>>
>> In pgRouting it is trivial to do this by putting a filter on the edges
>> to remove edges or nodes of a particular class(es). Something like:
>>
>> select * from edges where etype != 'dangerous';
>>
>> select * from edges a, nodes b where a.source=b.id or a.target=b.id and
>> b.ntype not in ('dangerous', 'dirty');
>>
>> -Steve
>> _______________________________________________
>> pgrouting-dev mailing list
>> pgrouting-dev at lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/pgrouting-dev
>>
>
>



More information about the pgrouting-dev mailing list