Liquid sorting

Post pictures and videos of your factories.
If possible, please post also the blueprints/maps of your creations!
For art/design etc. you can go to Fan Art.

Post Reply
Festmester
Inserter
Inserter
Posts: 22
Joined: Sat Oct 22, 2016 5:08 am
Contact:

Liquid sorting

Post by Festmester »

Hey guys. I don't know if it has any practical use in all your super factories, since I quickly get lost in the delicate details of the game :p

But it seems I found a way to sort liquids. First experiment was a success, I ran 3 liquids through the same pipe that didn't clog up even once. The liquids would only be funneled one at a time until there would be no more. That means there must be only little storage at the start, and large storage in the end for each liquid type. It might be possible to effectively run a main pipe with more than 3 liquid types, or 2 main pipes with each 3. Sorry for the many large pictures. My eyes hurt and just want to write this down :)
1.jpg
1.jpg (119.49 KiB) Viewed 7936 times
In the picture above, I marked what kind of material was already in the different pumps. I mark them on the pic because I filled them each with a liquid to the individual pump, then turned it so I could do the same with the next one without mixing them, and so on. Ready to connect pipes! Orange is heavy, yellow is light, and gray is petroleum.
2.jpg
2.jpg (127.46 KiB) Viewed 7936 times
After connecting the main pipe, all liquids ready to go!
3.jpg
3.jpg (230.44 KiB) Viewed 7936 times
I missed a screenshot before this. First I let the heavy oil drain into the pump and tank primed for heavy oil. The above screenshot shows how the light oil passes through when the heavy is depleted, while heavy still remains in the up-facing pump, as a form of filter. Down-facing pump also still has petroleum.
4.jpg
4.jpg (194.48 KiB) Viewed 7936 times
After light oil has depleted, petroleum is next up in the queue. Look at picture 2 (and other screens) to see how they are actually queued up and reserve the main pipe in turn.
5.jpg
5.jpg (234.77 KiB) Viewed 7936 times
Petroleum passes through, while light and heavy naturally remain in other pumps to keep the 'filters' active.
6.jpg
6.jpg (69.19 KiB) Viewed 7936 times
7.jpg
7.jpg (89.52 KiB) Viewed 7936 times
8.jpg
8.jpg (90.38 KiB) Viewed 7936 times
Last 3 pics is just checking it actually works over time. And it does. Three liquids in a single pipe! Of course you can control the flow in many ways, connecting the tanks and pumps to both circuit and logistics network.

Enjoy this weird finding (provided someone else already didn't, that is!)

Edit: petroleum has entered my heavy pipe. But the idea was good :(

User avatar
DaveMcW
Smart Inserter
Smart Inserter
Posts: 3699
Joined: Tue May 13, 2014 11:06 am
Contact:

Re: Liquid sorting

Post by DaveMcW »

I tried (and failed) the same thing. It seems impossible to do a stable 3-way sort.

There is a way to do 2-way sort for some liquids:

Image

Festmester
Inserter
Inserter
Posts: 22
Joined: Sat Oct 22, 2016 5:08 am
Contact:

Re: Liquid sorting

Post by Festmester »

I think the main problem is that units of fluid under 1, like 0,1 or 0.9 is not registered in the circuit network. Too small to pump around, too small to do anything with. It's just stuck.

The coming fluid update should open possibilities. Then it can be sorted straight out of a fluid tank I think :)

User avatar
hansinator
Fast Inserter
Fast Inserter
Posts: 160
Joined: Sat Sep 10, 2016 10:42 pm
Contact:

Re: Liquid sorting

Post by hansinator »

I got it to work with 3 liquids and it didn't fail for ~1 hour.

Image

I use two storage tanks at the beginning and end of the shared pipes as a sensor. The pumps are necessary to make sure no pipe stalls with a liquid level of 0.0. Sadly it has a low throughput as you can't use parallel pumps - they will get stuck. When the liquid level sum of both tanks is below 5 there are 3 pumps that will pump down the "receiving" parts of the sorter and dump it into a steam engine. The nixies + combinator are just for debugging and not part of the setup. It works, but there's something strange to it...

Sometimes there's this happening:
Image

Seems like a bug to me, but it is what makes it work without combinators. To avoid this one would need to add a hysteresis (like XKnight's version that works with 1 combinator + constants) that starts to pump down when the liquid level drops below 2 and only stops when it has risen above, say, ~50. That would ensure that the pipes are pumped down without wasting too much liquid.

Edit: You must prime the storage tanks and the corresponding pumps first.

Here's the blueprint where I've stripped the creative mode liquid sources and sinks:
Blueprint

User avatar
hansinator
Fast Inserter
Fast Inserter
Posts: 160
Joined: Sat Sep 10, 2016 10:42 pm
Contact:

Re: Liquid sorting

Post by hansinator »

Festmester wrote:I think the main problem is that units of fluid under 1, like 0,1 or 0.9 is not registered in the circuit network. Too small to pump around, too small to do anything with. It's just stuck.

The coming fluid update should open possibilities. Then it can be sorted straight out of a fluid tank I think :)
That is not the main problem, at least not for my setup. The main problem is that sometimes the pumps will get stuck and stay filled with a liquid of level 0.0 even if the pipes in front and behind them are free. This somehow makes it impossible to use one pump for different liquids (which I count on to suck empty the sensor tanks) :-/

Festmester
Inserter
Inserter
Posts: 22
Joined: Sat Oct 22, 2016 5:08 am
Contact:

Re: Liquid sorting

Post by Festmester »

Interesting setups! I'll check them in detail when I have time! :D

I made it this far after trying 4 other possible setups:
liquids.jpg
liquids.jpg (349.75 KiB) Viewed 7831 times
The only problem I have is keeping fluids inside the first pumps at the 'sorter intersection'. Else I believe it works perfectly, except the circulation part in the picture is just stupid, but hey gotta test it all!
So don't mind that one, just one attempt at creating a buffer that won't stall the throughput. Terrible option by the way!

So: How does one have the pump running without draining it completely?

It's paradoxical that the pump can't run when the tank is below a threshold in order to not drain, but then the tank can't be fed and the circuit stops. I want to both stop it and start it below a certain level. Maybe run it in a really narrow range but even that causes flushing and other liquid invades the wrong pipe.

It seems so simple and impossible at the same time! I believe the intersection solution is perfect to solve any clutter of 0.0 fluids, but pumps draining to 0 and changing type is what breaks this one. And I can't figure it out :(

User avatar
hansinator
Fast Inserter
Fast Inserter
Posts: 160
Joined: Sat Sep 10, 2016 10:42 pm
Contact:

Re: Liquid sorting

Post by hansinator »

Festmester wrote: It seems so simple and impossible at the same time! I believe the intersection solution is perfect to solve any clutter of 0.0 fluids, but pumps draining to 0 and changing type is what breaks this one. And I can't figure it out :(
I came to the same conclusion. It seems like it may be possible to get this done with combinators, but you'll probably need a lot. It's no better than using parallel pipes in the first place. What a pitty..

Your circulation approach is interesting. I tried it once but then focused on using steam engines. What exactly are the problems with it?

Festmester
Inserter
Inserter
Posts: 22
Joined: Sat Oct 22, 2016 5:08 am
Contact:

Re: Liquid sorting

Post by Festmester »

hansinator wrote:
Festmester wrote: It seems so simple and impossible at the same time! I believe the intersection solution is perfect to solve any clutter of 0.0 fluids, but pumps draining to 0 and changing type is what breaks this one. And I can't figure it out :(
I came to the same conclusion. It seems like it may be possible to get this done with combinators, but you'll probably need a lot. It's no better than using parallel pipes in the first place. What a pitty..

Your circulation approach is interesting. I tried it once but then focused on using steam engines. What exactly are the problems with it?

The circulation blocks incoming fluid from the entry pump. Also a paradox :P I want an 'injection' of fluid to be the buffer, but it ends up circulating (creating buffer for the pump) but blocks the flow so much the throughput is minimal :)

User avatar
hansinator
Fast Inserter
Fast Inserter
Posts: 160
Joined: Sat Sep 10, 2016 10:42 pm
Contact:

Re: Liquid sorting

Post by hansinator »

I tried different variations with loops and found a setup that works. Look closely at the pump arrangement. The key is to not use a pump between the input/loop intersection and the storange tank like in your setup.

Image

Festmester
Inserter
Inserter
Posts: 22
Joined: Sat Oct 22, 2016 5:08 am
Contact:

Re: Liquid sorting

Post by Festmester »

hansinator wrote:I tried different variations with loops and found a setup that works. Look closely at the pump arrangement. The key is to not use a pump between the input/loop intersection and the storange tank like in your setup.
Nice stuff! Did you wire the pumps at all or are they just doing their thing?

Edit:

I tried it and it absolutely looks like working effectively. I was so close too :D Thanks for helping figuring out the mystery!

roy7
Filter Inserter
Filter Inserter
Posts: 337
Joined: Fri Dec 12, 2014 4:24 pm
Contact:

Re: Liquid sorting

Post by roy7 »

Would the pumps outputting directly into a tank get the same result? So you wouldn't even need pipe from the center point to the tanks, just have the pumps go right to the tanks and not draw from the tank unless it has over some minimum amount to be sure it never runs empty (and gets wrong fluid). Assuming you prime the tanks with the right fluids at first manually, anyway.

Post Reply

Return to “Show your Creations”