• We have updated our Community Code of Conduct. Please read through the new rules for the forum that are an integral part of Paradox Interactive’s User Agreement.

PaulCa

Recruit
4 Badges
Nov 17, 2013
6
0
  • Cities in Motion 2
  • Ship Simulator Extremes
  • Cities: Skylines
  • Cities: Skylines Deluxe Edition
So I tried to make some fairly complex metro lines in sandbox and of course they dead locked as soon as traffic got higher. Sometimes they would even deadlock with light traffic and once dead locked they remained so for a long time. Useless.

Next after some browsing on the forums I reverted to simple loop lines with no junctions. No junctions, no dead locks. This got me far in the campaign etc. However it meant having horrible looking loop backs at the half way point, making interchange hubs look messy.

Finally I had an epiphany. Dead locks only occur when lines of different directions mix at junctions.

So following one simple rule; "Never cross tracks at a junction", I have been able to make very complex metro track layouts without being able to deadlock them (within reason), even when the entire track is covered in trains. Even including the 4 track sections for high speed, low speed bidirectional loops.

Another way to look at it is to treat metro tracks just like express ways. Avoid junctions by creating graded junctions etc. Never having a crossing intersection.

An example:
A standard railway Y junction at a depot. High level layout:
Screenshot_2013-11-30_14-46-51.png

You want Line A(left) and line B(right) both to reverse at the depot.

If you look closely, at the depot, line b's outline will cross line a's in line and vice versa. As soon as you have a train exiting onto line a at the same time as a train arriving on line b, it will dead lock.

The solution is to use single track. Connect the outer most lines directly and cross the directional track with a graded junction, like so:
Screenshot_2013-11-30_14-52-15.png


Now what if you want to be able to run trains direct from the left depot to the right depot? Well, you can create bypasses like this:
Screenshot_2013-11-30_14-56-28.png


Still deadlock free?

Lets see:
Screenshot_2013-11-30_15-05-42.png


It did eventually deadlock, but only because the track space AND depot space maxed out at the right hand depot. If the lines where realistically long, this would not have occured unless you a HUGE amount of trains.

One note... you are limited in the number of trains on any of the intersecting lines by the number of trains that will arrive at a deport concurrently. If you have a depot that can handle 10 trains and 11 arrive, the last one will need to wait outside. You can eventually dead lock it this way as the queue for the depot build up enough to block another depot, but this takes a huge amount of traffic and is easily fixed by lowering the traffic and deleting a few trains.

Sometimes junctions will get very complex and an easy way to handle them is the "roundabout" paradigm. Like this:
Screenshot_2013-11-30_15-07-11.png

Create an inner one way loop and branch into and out of that loop.

Now consider this:
Screenshot_2013-11-30_15-08-29.png


A one way depot sorting loop with two way branches connecting out to a 4 track outer express/all stop two way ring. Trains can route from any depot to any stop, in either direction and from any stop to any other stop, either express inner lines or all stop outer lines.

Inner sorting loop.
Screenshot_2013-11-30_15-09-45.png


It does require some interesting outer ring junctions:
Screenshot_2013-11-30_15-11-33.png

Both IN and OUT of the spoke can connect to/from fast or slow lines in both directions.

Now, one thing, if the devs are listening that would make certain junctions a lot simpler is if we could branch off the inner lines of a 4 track section. It seems we can only branch off the outer line, so to compensate we have to create a one way break out and graded pass like this:

Screenshot_2013-11-30_15-16-57.png

A 4 way express route merges onto a one way 2 track interchange.

It would be so much simpler if joining a 2 track one way section to a 4 track section, branched both inner and outer off.

Paul
 

Attachments

  • Screenshot_2013-11-30_15-09-45.png
    Screenshot_2013-11-30_15-09-45.png
    357,7 KB · Views: 92

Norfolk_Chris

Captain
5 Badges
May 2, 2013
385
7
  • Cities in Motion
  • Cities in Motion 2
  • Cities: Skylines Deluxe Edition
  • Cities: Skylines
  • Cities: Skylines - After Dark
You want to create the maximum capacity on your metro lines?

Simply follow the rule now being adopted by the Paris Metro (and other metro systems worldwide). Metro lines work most efficiently when they are simple point to point services without any junctions. I prefer to have a depot at each end, but a non-conflicting terminal loop works just as well! With this configuration you will be able to run your service on the minimum in-game headway of 5min all day. This way you will extract the maximum capacity from your (expensive) metro lines.
 

PaulCa

Recruit
4 Badges
Nov 17, 2013
6
0
  • Cities in Motion 2
  • Ship Simulator Extremes
  • Cities: Skylines
  • Cities: Skylines Deluxe Edition
Simply follow the rule now being adopted by the Paris Metro (and other metro systems worldwide). Metro lines work most efficiently when they are simple point to point services without any junctions. I prefer to have a depot at each end, but a non-conflicting terminal loop works just as well! With this configuration you will be able to run your service on the minimum in-game headway of 5min all day. This way you will extract the maximum capacity from your (expensive) metro lines.

Well, yes, that works too, as I said. The trouble is, you either have to have your passengers changing lines all the time or you have to have a large amount of physical tracks to meet different permutations.

Consider Central City. You might have a line from the South shore work district to the central city island. Then another line from the central city island to the north city island and another line from the north island out to the east suburb. Passengers need to change lines twice. With a cleverly routed and junctioned network you can create a service that runs direct along the same line as the other services. As long as you follow the "Never cross lines of differing directions at junctions" the worst congestion you will get is queueing.

Anyway, both work, I use both where appropriate and it just gives alternatives while avoiding deadly deadlock.

Out of interest (long shot) I am writing a train network simulation including cascading signals, speed limits, path allocation, scheduling, conflict resolution and exclusion zones. Certainly not of a calibre for inclusion into a game engine, but the amount of diagrams, doodles and research it has taken has given me a good view on the problems faced with automated rail systems. In relevance to CIM2, what is needed is an exclusion zone mechanism (multi-component spanning concurrency monitor in computing terms). The metro system needs to detect dead lock prone areas and create an exclusion zone through them, so that only one train may enter at a time, across multiple junctions. So if a train requests access to a junction complex, the system delays it until it can allocate the complete path through the whole junction complex to it's exit and only then does allow the train through. Allowing only one train is the simple approach, being able to allocate multiple non-conflicting paths through the complex is the harder version.
 

kensternation

First Lieutenant
1 Badges
Sep 28, 2011
232
2
  • Cities in Motion 2
... With this configuration you will be able to run your service on the minimum in-game headway of 5min all day...

Technically you can have 60 vehicles/hour on any line. if you set weekday, morning rush, evening rush, weekend and evening to all start at 00:00 and end at 23:55 and you check all the boxes so all 5 are running every day. I once set the population to maximum with the ruleset and had a HUGE bus line running up and down the entire right side of West City. I had a transfer point at one stop to bring the people from the left side over. To keep up with demand I had to run 60 buses the entire day and even then people complained about waiting on line and standing on the buses. I of course destroyed all long distance roads and turned them into bus only roads so the CIMs HAD to take mass transit. The line made money like crazy and it was kind of cool seeing all of those buses marching along.