xRoute transit through Warsaw

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
szymon
Posts: 6
Joined: Wed Apr 20, 2022 6:34 am

xRoute transit through Warsaw

Post by szymon »

Hi,
I use xRoute to calculate the route in Poland. The route is then displayed using the map. In some situations, the calculated route runs through roads where transit is prohibited, for example Warsaw (see attachment).

Current regulations say that entry to Warsaw is possible only for vehicles that make deliveries in Warsaw. Other vehicles must use different routes.
What should be done to take this scenario into account?
Below is an example query:

Code: Select all

{"waypoints":[{"$type":"OnRoadWaypoint","location":{"coordinate":{"x":21.184751,"y":51.989141}}},{"$type":"OnRoadWaypoint","location":{"coordinate":{"x":21.184751,"y":51.989141}}},{"$type":"OnRoadWaypoint","location":{"coordinate":{"x":19.763054,"y":52.736877}}},{"$type":"OnRoadWaypoint","location":{"coordinate":{"x":19.474281,"y":52.429691}}},{"$type":"OnRoadWaypoint","location":{"coordinate":{"x":19.474281,"y":52.429691}}},{"$type":"OnRoadWaypoint","location":{"coordinate":{"x":19.37035,"y":52.438217}}},{"$type":"OnRoadWaypoint","location":{"coordinate":{"x":19.934122,"y":52.09812}}},{"$type":"OnRoadWaypoint","location":{"coordinate":{"x":21.184751,"y":51.989141}}},{"$type":"OnRoadWaypoint","location":{"coordinate":{"x":21.184751,"y":51.989141}}},{"$type":"OnRoadWaypoint","location":{"coordinate":{"x":21.184751,"y":51.989141}}}],"resultFields":{"polyline":true},"routeOptions":{"polylineOptions":{"elevations":true}},"requestProfile":{"routingProfile":{"searchSpace":{"heuristicAggressiveness":0},"course":{"violations":{"enabled":false}}},"featureLayerProfile":{"themes":[{"enabled":true,"id":"PTV_TruckAttributes"}]},"vehicleProfile":{"weight":{"emptyWeight":36000,"loadWeight":0,"totalPermittedWeight":36000},"legalCondition":{"isDelivery":false,"isEmergency":false},"dimensions":{"height":400,"length":1875,"width":254.99999999999997},"load":{"loadType":"GOODS"},"axle":{"numberOfAxles":"4"},"engine":{"emissionStandardEU":"EURO_5","engineType":"COMBUSTION","fuelType":"DIESEL"}}}}
Thanks in advance,
Szymon
Attachments
untitled.png
User avatar
Bernd Welter
Site Admin
Posts: 2695
Joined: Mon Apr 14, 2014 10:28 am
Contact:

Re: xRoute transit through Warsaw

Post by Bernd Welter »

Hello Szymon,

your request triggers the following topics in my mind:
  • VehicleProfile.LegalCondition.IsDelivery: your sample request disabled this flag. By enabling this your vehicle is declared to be allowed to use segments with delivery restrictions.
    isDelivery=true  :  successful routing
    isDelivery=true : successful routing
    A side effect: by setting this value to true the vehicle is allowed to drive through ANY isDeliveryOnly area as there's no distinct ID that separates two different areas from each other. This mechanism may therefore cause issues when you are not allowed to drive through area B but did set "isDelivery=true" to pass through area A.

    Code: Select all

    {
      "$type": "RouteResponse",
      "distance": 426660,
      "travelTime": 34458.593,
      "trafficDelay": 0,
      "polyline": {
        "plain": {
          "$type": "Polyline",
          "polyline": [..
          ]
        }
      },
      "violated": false
    }
  • isDelivery=false: may cause issues (errors) if an involved waypoint is located in a delivery only area.
  • com.ptvgroup.xserver.routingprofile.Violations.enabled=true : this will allow the router to use segments which are violating constraints (TruckAttributes, RestrictionZones...). Any constrain, not only delivery. If a waypoint is located in a critical area it might be necessary to allow violations to reach it at all.
    violations.enabled = true
    violations.enabled = true

    Code: Select all

    {
      "$type": "RouteResponse",
      "distance": 426424,
      "travelTime": 34399.657,
      "trafficDelay": 0,
      "polyline": {
        "plain": {
          "$type": "Polyline",
          "polyline": [..
          ]
        }
      },
      "violated": true
    }
    
  • com.ptvgroup.xserver.routingprofile.Violations.enabled=false: this may sometimes cause the engine to desperately try to find a valid path to the waypoint. And when I say desperately this means "poor performance may occur". This happens often with the metropolitan areas which are more and more covered with isDelivery flags.
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:
szymon
Posts: 6
Joined: Wed Apr 20, 2022 6:34 am

Re: xRoute transit through Warsaw

Post by szymon »

Changing options in any combination does not produce different results. I get the same wrong result every time.
map1.png
How can I get a result like the one you presented in your map screenshot?
User avatar
Bernd Welter
Site Admin
Posts: 2695
Joined: Mon Apr 14, 2014 10:28 am
Contact:

Re: xRoute transit through Warsaw

Post by Bernd Welter »

Hello Szymon,

are you using another map provider?
My screenshots were based on your sample request and I only changed the two attributes I mentioned.

If needed let's schedule a 1:1 session,

Bernd
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:
szymon
Posts: 6
Joined: Wed Apr 20, 2022 6:34 am

Re: xRoute transit through Warsaw

Post by szymon »

I am using server defaults.
map2.png
map2.png (11.42 KiB) Viewed 2590 times
map3.png
map3.png (7.66 KiB) Viewed 2590 times
User avatar
Bernd Welter
Site Admin
Posts: 2695
Joined: Mon Apr 14, 2014 10:28 am
Contact:

Re: xRoute transit through Warsaw

Post by Bernd Welter »

And I use HERE data.

As mentioned : Please schedule a session with me ;-)
Attachments
poland.png
poland.png (3 KiB) Viewed 2578 times
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:
User avatar
Bernd Welter
Site Admin
Posts: 2695
Joined: Mon Apr 14, 2014 10:28 am
Contact:

Re: xRoute transit through Warsaw

Post by Bernd Welter »

Sidenote:
We identified at least the missing TimeConsideration as a cause for the issues: there are many, many time based truck attributes in the area

Play with this showcase to evaluate the coverage of such data!
Attachments
Warszawa and it's many time dependent truck attributes
Warszawa and it's many time dependent truck attributes
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