matsim-libs
matsim-libs copied to clipboard
Consider turn restrictions during routing
We want to consider turn restrictions in the network during routing.
Turn restrictions are list of subsequent links, which shall not be passed by vehicles of a given mode.
Currently, it is only possible to model turn restrictions using Lanes with a separate lane definition file.
Proposal
- Links can have a
disallowedNextLinks
attribute containing an object, which is basically a map of modes and a set of lists with forbidden next link ids. - Turn restrictions are only considered at the routing level. The QSim should just execute routes and not check turn restrictions again. This allows busses with fixed routes to follow it and cars get routed differently.
- An empty or missing attribute means that no next links are disallowed.
Example
- Link
1
has attributedisallowedNextLinks = {"car": {["2", "3"], ["6"]}, "bike": {["6"]}}
- This means that link sequences
[1, 2, 3]
and[1, 6]
are not allowed for car and link sequence[1, 6]
is not allowed for bike.
Todos
- [x] Implement the data structure and AttributeConverter
#2855 - [ ] Enable pt2matsim to create networks with turn restriction info
https://github.com/matsim-org/pt2matsim/pull/202 https://github.com/matsim-org/pt2matsim/issues/75 - [ ] Enable network transformation in router / enable routing with restrictions
https://github.com/matsim-org/matsim-libs/pull/3024 - [ ] Adjust NetworkCleaner & MultiModalNetworkCleaner
- [ ] [Optional] There should be some validation methods that check whether only existing & connected next links are actually referenced in the disallowed link lists.
- [ ] [Optional] Eventually, when reading a network, there should be warnings, if these kind of inconsistencies are detected.
- [ ] [Optional] Adjust NetworkSimplifier to deal with turn restriction data correctly
- [ ] [Optional] Ask Simunto to also consider/visualize turn restrictions in VIA