Page 1 of 1

Are double-signals ever useful? Do they ever make sense?

Posted: Sun Dec 28, 2014 6:55 pm
by sillyfly
After recent (and also not-so-recent) discussions about train routing problems (https://forums.factorio.com/forum/vie ... f=6&t=7346 for example), I was thinking - Is there ever a case in which putting two signals on two sides of the same track useful? Is it ever not a recipe for disaster?

Here is what I mean - consider the following rail network (where = is rail, * is signal, > and < are trains going left and right respectively):

Code: Select all

        *
===>>=======<<===
        *
These trains are bound to cause a deadlock, as either one needs to go into the block the other is currently in. A much more sensible approach would be something like -

Code: Select all

        
        *
       /=====\
===>>==       ==<<===
       \=====/
            *
So the train coming from the left would take the lower path and the one coming from the right takes the upper part, thus neither block the other one.
The same approach could be used for end-circles -

Code: Select all

        
        *
       /===<<===\
===>>==          |
       \========/
        *     &*
Where "&" is a train stop. In this way, a train waiting to exit the loop would not block a train trying to enter the loop.

So, it appears to me having a signal on both sides of the same track is wrong and never useful. Or am I missing something?
Thanks!

Re: Are double-signals ever useful? Do they ever make sense?

Posted: Sun Dec 28, 2014 7:26 pm
by DaveMcW
No.

The Factorio signal system is very basic - too basic to support more than one train on a two-way track.

If you have two or more trains, you need two one-way tracks.

Re: Are double-signals ever useful? Do they ever make sense?

Posted: Sun Dec 28, 2014 7:30 pm
by sillyfly
DaveMcW wrote: If you have two or more trains, you need two one-way tracks.
That's not entirely true. As I have shown (I hope!) In the examples, it is possible to have such a system, as long as every one-track segment is a single block (not subdivided by signals on both sides at any point). Sure, you have to double up for loops or crossing spots, but it's not the same as having two way tracks all the way.

But I understand you agree those serve no purpose, and could only cause problems?
It that is the case - isn't it better if the option to make such signals is removed?

Re: Are double-signals ever useful? Do they ever make sense?

Posted: Sun Dec 28, 2014 7:33 pm
by DaveMcW
There is a difference between possible and sensible. :P

Re: Are double-signals ever useful? Do they ever make sense?

Posted: Sun Dec 28, 2014 8:03 pm
by Garm
Currently i am building a large rail network. main body of the network is one-way, however for construction purposes, as well as easy transportation I tend to build two-way dead ends with stations, for my 2-engine taxi.

Re: Are double-signals ever useful? Do they ever make sense?

Posted: Sun Dec 28, 2014 9:08 pm
by sillyfly
Ok, I understand what you say. But this means it is a station that will only ever have one train destined to go to it.
And if this is ever connected to the rest of the system, you will still need a way to signal your personal taxi which side to use.
So, what I understand you are doing now is -

Code: Select all

=====
     \   *
===========<<>>==
         *      &
where the "<<>>" is your double-headed taxi train, but wouldn't it be the same as having:

Code: Select all

   *
=====
     \   
===========<<>>==
   *            &
which will do the same, but also tell your taxi which track to use when going back on the one-way system?

Note that this design is also useful for one-way system in which train stops have no loops, but are rather two-way leaf nodes.

Re: Are double-signals ever useful? Do they ever make sense?

Posted: Mon Dec 29, 2014 12:57 am
by Garm
What i am using is more like your second example. Essentially my main rail network is fully segmented one-way system, but if need arises i simply branch both lines, merge them and use it as two way branch.

Is is possible to have multiple trains per two-way line, if you put down signals carefully, but not for a single station.
Here is small example from my current base

Re: Are double-signals ever useful? Do they ever make sense?

Posted: Mon Dec 29, 2014 1:06 am
by immibis
If there will only ever be one train on either side of the signal, the signal won't cause deadlocks. Only one side needs to meet this condition - the other side can be as busy as you want.

They are useful for connection single-track stations, which are only serviced by one train, to a single-track trunk line. (Yes, you can have a single-track trunk line. It's convenient for low-to-medium traffic).

Re: Are double-signals ever useful? Do they ever make sense?

Posted: Mon Dec 29, 2014 4:27 am
by sillyfly
immibis wrote:If there will only ever be one train on either side of the signal, the signal won't cause deadlocks. Only one side needs to meet this condition - the other side can be as busy as you want.
As I said, in theory this is correct, but with the current state of the train pathfinding you may have a train going where you have not expected it to go, thus causing a deadlock.
immibis wrote: They are useful for connection single-track stations, which are only serviced by one train, to a single-track trunk line. (Yes, you can have a single-track trunk line. It's convenient for low-to-medium traffic).
Indeed, it is very possible, as I have shown above! But, such systems do not rely on a double-signal, and indeed would benefit from not having double-signals.
I guess what I'm trying to say is - a double-signal is always a recipe for a deadlock (whether it will happen or not is debatable, but the opportunity exists), and I know of no configuration which explicitly relies on such signal placement.

@Garm: If I understand what you are talking about (the junction right below your character, on the rightmost track in the set?), it is technically like the first example, isn't it?
I suppose if all of your normal trains are single-headed no train could ever mis-route though there, but if you have another automated double-headed train, couldn't it theoretically mis-route through there?


I know at this stage this all seems like very theoretical extreme-case hypothesizing, but I really do want to understand if there is a case which explicitly requires putting two signals on both sides of the same track piece. I would even accept cases in which it is possible to avoid this configuration, but by avoiding it the end result is much more complex (provided that the double-signal solution actually works!)

Re: Are double-signals ever useful? Do they ever make sense?

Posted: Mon Dec 29, 2014 4:34 am
by spacesloth
Signals across from each other are useful on two-way tracks which have only one train planned to travel on them. Examples of this would be branches off of a main track to a loading zone.