Page 1 of 1

Route Violated in LegReport and other doubts

Posted: Tue May 21, 2024 7:01 am
by IAH
Hello,

I have doubts related to violations. When I receive a RouteViolation in LegReport (so, the leg is violated):
1) What is the reason of this violation? What is the meaning?
2) I would expect that in TourEvent-TourViolations a violation reason appear for the leg reported in the Leg but it is not like this

I attach response of this case above.

Besides I have other doubt related to input plan:
3) Can an input plan be set from scratch? I mean without taking it from a response of a TourResponse.

Thank you so much in advance!

Re: Route Violated in LegReport and other doubts

Posted: Tue May 21, 2024 7:39 am
by Joost
A route violation means that the route is not possible to be driven by the vehicle. The dima can't hold route violation details and therefor they are not available for xTour to give back. If you want to know the details you need to recalculate the violated leg with xRoute. Hint: route violation often happen nearby locations.

About the input plan, yes you can build it up from scratch. You can use this for letting a planner make some manually planning in advance for the big bulk. That being said: always verify a manually build input plan by doing an optimization with CalculationMode set to EVALUATE . If there are TourViolations in the input plan it will mean that each tour with violations will remain as is and that might not be what the planner is intending.

Re: Route Violated in LegReport and other doubts

Posted: Tue May 21, 2024 8:50 am
by IAH
Thank you for your quick answer.

You said "route cannot be given to the vehicle", but then how the times of the legs are calculated if the leg is violated (in the example also the flag of direct distance is false)?

Does it mean that there is an area where driver has to walk?

Thank you in advance

Re: Route Violated in LegReport and other doubts

Posted: Wed May 22, 2024 7:56 am
by Bernd Welter
Hi Ignacio,

a distance matrix can be seen as a storage of some KPIs of undeerlying AB-routes with equal routing options:
  • The primary key of the storage is the combination of the route locations of start and destination.
  • The stored data contains
    • traveltime
    • distance
    • violation state
    • direct distance state
    • toll (optional)
    Each row represents a relation and contains data about travelTimes, distance, estimatedByDirectDistance and violated.
    Each row represents a relation and contains data about travelTimes, distance, estimatedByDirectDistance and violated.
  • It does NOT contain details such as
    • Cause of a violation
    • Event lists
    • Toll details
That being said a tour optimization algorithm needs to read from a dima multiple (often millions of) times to assemble temporary structures which are then evaluated:
  • What is the complete time scheme? Does it violate opening times or operating times?
  • What distances apply? Does a vehicle's tour exceed maximum values?
  • With the routing there's also the option to define some "flexibility" when it comes to "are violations allowed"?
    • ignoreRouteViolations
    • ignoreReachabilityViolations
    So if you enforce newly built tours to be "clean" (without violations) then some locations which can't be reached without violations will remain unscheduled (orders flagged as unplannable)
What you should also consider is the potential combinations of the relation properties "violated" and "estimatedByDirectDistance" as not every combination can occur:
violatedestimatedByDirectDistancedescription, possible?
falsefalsebest routing based "condition"
truefalserouting based but kind of "suspicious"
falsetruesuccessful routing wasn't possible (e.g. because violations have been disabled), therefore workaround based on airline applies
truetrueimpossible

Re: Route Violated in LegReport and other doubts

Posted: Thu May 23, 2024 8:53 am
by IAH
Hi Bernd,

Thank you so much for your continuous support. You really brought light on all those doubts.

I'll keep bothering you in other posts ;)

Thank you!