xRoute (xServer2) - avoiding Switzerland?

This forum deals with any kind of routing computation whether it is simple A:B-routing, calculation of isochrones, simple matrix computation or nearest search.
Post Reply
ClaasB
Posts: 3
Joined: Wed Jul 08, 2020 1:21 pm

xRoute (xServer2) - avoiding Switzerland?

Post by ClaasB »

Dear all,

we are wondering how we can steer a route (e.g. from North Germany to Italy) avoiding driving throogh Switzerland due to custom checks and other restrictions. It's should always pass by Austria.

Best regards,
Claas
User avatar
Bernd Welter
Site Admin
Posts: 2574
Joined: Mon Apr 14, 2014 10:28 am
Contact:

Re: xRoute (xServer2) - avoiding Switzerland?

Post by Bernd Welter »

Hello Claas,

the easiest way to prevent the xRoute2 router from driving via Switzerland is probably a Geographic Restriction such as ForbiddenCountries=["CH"]. In this case you are also responsible for pre-evaluation of the countries being involved in the routing: how to deal with waypoints in switzerland?

Further thoughts:
If you want to use the brenner (enforce an object instead of avoiding a country) you may check whether a ManipulateWaypointat the Brenner does satisfy your need (once agin pre-evaluation is required).

Last but not least: You may also check whether the monetary cost options fullfill the job: in most cases the motivation for a detour is to avoid the swiss toll. As xRoute2 is able to consider these costs in the process of "routing" this could lead to a more generic solution. At least if the costs for the detour are really cheaper than the swiss route.

Best regards,
Bernd
Attachments
Route from Karlsruhe / Germany to Milano / Italy.<br />Green: forbiddenCountries=[&quot;CH&quot;], <br />Blue: no restrictions set
Route from Karlsruhe / Germany to Milano / Italy.
Green: forbiddenCountries=["CH"],
Blue: no restrictions set
Bernd Welter
Technical Partner Manager Developer Components
PTV Logistics - Germany

Bernd at... The Forum,LinkedIn, Youtube, StackOverflow
I like the smell of PTV Developer in the morning... :twisted:
Post Reply