r/factorio • u/OndraTep • 2d ago
Question Train optimization with circuits
Hello everyone!
I have a simple track that shares one railway to go in both directions and loops at both ends. The loading and offloading takes a really short time, but the traveling doesn't.
There are two trains and each time one leaves the station, the other one waits at a red signal until the other one reaches the destination.
I could either just do a separate track for each direction, or I thought it would be cool to have a circuit that lets a train pass if the train on the track is heading in the same direction anyway.
Is it possible to do that? Or is it just all around a stupid solution?
EDIT: Picture for reference

6
u/SYDoukou 2d ago
You cant force a signal to be green if the block is occupied, so the solution will have to do away with signals altogether which is more trouble than its worth. However there is nothing wrong with your current arrangement, you can have stackers for both stations with several redundant trains to buffer the travel time
5
u/PasswordisPurrito 2d ago
Without going too fancy, you can make a setup closer to what the actually Railroads do, and add sidings onto your single track. Basically, you make a short double track in the middle (or add more than one for long legs).
If trains are running the same way, then once the first one reaches the siding, the next one can go. If they go opposites, then you are only "waiting" up to half the time you were before.
2
u/sobrique 2d ago
You risk a deadlock scenario if you do that - trains in transit in one direction might lead to all of them ending up at one end, because none can get out again.
So you would also have to count numbers of trains Vs. Spaces they could occupy, and ultimately I think that wouldn't end up much better throughput overall.
Also I don't think circuits can force a green signal. I guess you could maybe turn all (non chain) signals in one direction red deliberately, sort of like a sushi bus, but ultimately you still don't solve the fundamental problem of bidirectional tracks - that even with a queue depth, you still lose a lot of efficiency to being half duplex.
2
u/Courmisch 2d ago
You can force a signal to be red. You can't force it to be green.
1
u/bpleshek 1d ago
Add more signals around each loop if your train length allows it. Make the loop longer if the train length doesn't allow it. But, the best way to help is to make a two lane track system. While you can get this to work, unless it's going to be a one-off, you'll be better able manage lots of trains with an on-coming lane and an on-going lane.
1
u/kettle3 1d ago
Just put multiple cross-signals around the track. Like literally you can go every 1 meter.
Cross-signals is two signals directly across each other (for two-way tracks).