Routing options to use motorways and ferries

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
Uwe Schuster
Posts: 15
Joined: Wed Dec 08, 2021 11:25 am

Routing options to use motorways and ferries

Post by Uwe Schuster »

We are migrating from Mapserver to xServer 2 and routing with details like profiles, toll and emission does work. There are some remaining questions and one of them is regarding some routing profile options.
Our option (bool)Mapserver xServer 2
[x] Use motorway IRouteOptions2::put_RouteWithoutAutoroute(section, [true|false])

Mapserver SDK documentation:
"For the VARIANT_TRUE value the use of motorways is not permitted."
Use penaltiesByNetworkClass? NC0? Which penalty?
[x] Use residential roadsIDrivingOptions_5_4_0_0::put_ResidentsOnlyFactor(section, factor)

Mapserver SDK documentation:
"factor Modifier for streets that are restricted to residents"
"The values range from -99 (strong preference) to 0 (normal rating) to 2500 (strong avoidance). 2501 can be used to block streets that are restricted to residents completely. "


We do use the default value (0) when the option is checked and 2500 when the option is not checked.
Use penaltiesByNetworkClass? Which NC?
[x] Use ferriesIDrivingOptions_5_4_0_0::put_FerryFactor(section, factor)

Mapserver SDK documentation:
"Modifier for ferries."
"The values range from -99 (strong preference) to 0 (normal rating) to 2500 (strong avoidance). 2501 can be used to block ferries completely."


We do use 0 when the option is checked and 2500 when the option is not checked.
Use boatPenalty?
[x] Use motorway

Code: Select all

{
	"routingProfile": {
		"course": {
			"network": {
				"penaltiesByNetworkClass": {
					"penalties": [
						THIS_VALUE_HERE_QUESTIONMARK,
						10,
						15,
						35,
						40,
						90,
						100,
						100
					]
				}
			}
		}
	}
}
Is this correct to use routingProfile::course::network::penaltiesByNetworkClass::penalties?
"[x] Use motorway" = 0 for the first network class
"[ ] Use motorway" = 2500 for the first network class

[x] Use residential roads
Is this correct to use routingProfile::course::network::penaltiesByNetworkClass::penalties as well? What is the network class for this case?

[x] Use ferries

Code: Select all

{
	"routingProfile": {
		"course": {
			"combinedTransport": {
				"boatPenalty": "THIS_VALUE_HERE_QUESTIONMARK"
			}
		}
	}
}
Is this correct to use routingProfile::course::combinedTransport::boatPenalty?
"[x] Use ferries" = 0
"[ ] Use ferries" = 2500
Uwe Schuster
C-Informationssysteme GmbH
User avatar
Bernd Welter
Site Admin
Posts: 2695
Joined: Mon Apr 14, 2014 10:28 am
Contact:

Re: Routing options to use motorways and ferries

Post by Bernd Welter »

Hi Mr Schuster,

afaik Avoid_Highways refers to NC0 AND NC1.
Residentials is NC5.

I'll cross check this with DEV!

But I think you are on a proper path,

Bernd
Attachments
definition of network classes. Taken from xserver 1 documentation
definition of network classes. Taken from xserver 1 documentation
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:
Joost
Posts: 310
Joined: Fri Apr 25, 2014 1:46 pm

Re: Routing options to use motorways and ferries

Post by Joost »

About "IDrivingOptions_5_4_0_0::put_ResidentsOnlyFactor"

That is found at:
Routing / Course / BasicDataRules / SpecialAreas / @residentialMalus (xServer 1 profile)
RequestBase.requestProfile.routingProfile.crourse.apecialAreas.residentsOnlyPenalty (xServer 2 request)

It is not connected to a specific road type (== network class) but to a segment attribute. The attributes indicates that access to the road is only allowed for people who are resident.
Joost Claessen
Senior Technical Consultant
PTV Benelux
Uwe Schuster
Posts: 15
Joined: Wed Dec 08, 2021 11:25 am

Re: Routing options to use motorways and ferries

Post by Uwe Schuster »

Thanks Bernd and Joost!

For me "course::specialAreas::residentsOnlyPenalty" sounds more reasonable as equivalent for "IDrivingOptions_5_4_0_0::put_ResidentsOnlyFactor". I will try that (as soon as I remember a test case for that).
Uwe Schuster
C-Informationssysteme GmbH
Post Reply