we invented a new experimental parameter in the routing of v2.36:
com.ptvgroup.xserver.routingprofile.SpecialAreas.borderCost
With this parameter you can "punish" or "prohibit" border crossing events by
- borderCost : The additional cost for crossing a border between different countries or subdivisions. If it is set to INFINITE border crossing is impossible. This field is experimental. Before using it, make sure you understand the implications of Experimental features.
- MathematicalCostWithInfinite: MathematicalCostWithInfinite
Defines the event-specific mathematical cost. The mathematical cost is an abstract value without a physical equivalent. Hence it can be used to model user-specific needs that symbolize a certain value, mostly in order to parameterize the objective function of an optimization algorithm.
Route calculation only: There are two ways to influence the cost of a route: absolute cost, which is added if an event occurs (defined by this type), and relative cost, which means increasing the cost of a segment by a percent value (Penalty type). The routing cost depends on many parameters and is an abstract value without a physical equivalent. As a rule of thumb the cost of x represents a detour of x [m] at a speed of 36 [km/h].
A mathematical cost specified by this type can be set also to INFINITE. Pattern: INFINITE|\d+. - Benefit: This parameter supports specific usecases such as garbage disposal (not allowed to bring garbage into other countires) or security transport (where the armed staff isn't allowed to cross borders).
- Good to know: If you had to deal with these requirements of "do stay inside the following country" and by creating individual profiles/request settings for each country in charge this new parameter could reduce the complexity of your settings or even the number of search graphs.
- Works with...:
- creation of HPRs
- creation of distance matrices
- calculating routes