Control over Plastic/Solid Fuel process

Clever and beautiful constructions, bigger than two chunks
- Defense: killing biters as an art
- Castles, Throne Rooms, Decorations (comfortable living in the Factorio World)
- Main Bus Concepts
- Modular Systems, Factory Streets, show how all works together
- Megabases
Please provide us with blueprints or saves, if that makes sense of course.
Forum rules
Clever and beautiful constructions, bigger than two chunks
User avatar
MBas
Fast Inserter
Fast Inserter
Posts: 112
Joined: Fri Jan 06, 2017 12:57 pm
Contact:

Control over Plastic/Solid Fuel process

Post by MBas »

control.png
control.png (3.05 MiB) Viewed 3534 times
Hello!

Introduction
This is my rafinery for plastic/solid fuels as main product. It has potential to be fully focused into SF/plastic production. Whole process has plastic production and LO into SF production generally turned on and i measure flows into both processes. If the ratio between production speeds (flows) and amounts of order are not same, the factory will try to manage LO and PG production via turning on/off of cracking LO-PG process or burning PG into SF. You can see all important values at green network illustrated on the picture. First two signals are amounts of order. The following one indicates flow into inividual processes (note that crude oil symbol is used for PG->SF production). Unit system is equal to LIQUID FLOW / 4 sec (so value 37 means 9.25 fluids per one second).

Why this approach? Hanging one simple order is not so important. Much mure interesting is how to handle some continous trend of plastic or solid fuel consumption. Keeping speed of plastic/solid fuel production proporational to missing content is wise setup for rafinarey in my point of wiev.

Stats

Maximum speed of plastic production = 1482 plastic / minute
Maximum speed of solid fuels production = 1845 SF / minute
Efficient production (no LO cracking & no PG burning) = 830 plastic / minute + 1222 SF / minute
Crude oil consumption = 1572 crude oil / minute

Some theory
The idea has two points.
1. Prepare the order at maximum speed in most efficient way
2. Use an arbitrariness at previous point for cracking LO->PG or burning PG into SF to keep speeds of processing proporotional to order amount

Note: Whole mechanism will not keep optimal ratio all the time. Its not a bug. If you have some left content of fluids in the tanks after previous process, the rafinery just use it to produce platic or SF (but it never overflow your order anyway). In that case the production will be even larger than mentioned efficient due to supply consumption.

I made a "control function" to satisfy this rules. Its definition is little bit complicated, but no so :)

C = 5*( (6*LO + 3*CO) * PL - 4 * PG * SF ) / sqrt ((SF+10)*(PL+10))

SF = remain of solid fuel order
PL = remain of plastic order
LO = speed of LO flow into SF production
CO = speed of PG flow into SF production
PG = speed of PG flow into platic production

And value C is set into rest of rafinery to control other processes:

C < -100: PG->SF is on
C < -500: PG->SF even steal some PG from plastic production
C > 100: 2/10 of cracking LO->PG is on
C > 200: 4/10 of cracking LO->PG is on
C > 300: 6/10 of cracking LO->PG is on
C > 400: 8/10 of cracking LO->PG is on
C > 500: 10/10 of cracking LO->PG is on

I know that "C" function is quite complicatated, however each parts has its puprpose. First of all, ideal value to keep second rule (keeping ratios) is when C is equal to zero. So all processes like LO->PG cracking or PG->SF burning try to keep this value nearby 0. There must be some clearence to avoid oscilate behavior (since both of processes are irreversible). And there is also normalization (with usinq square root) but it must be smart which meens it must be proportional into amounts of order and it should be oriented into lesser value in order (thats the reason why i used a gemetric mean calculated by square root).

Flow measurement
The idea is simple. Following image shows how it works. Just keep some value of your fluid in upper tank by bottom pump. You must satisfy all the setup (connections of tanks, connections of pumps into tanks). And the difference between tanks will be proportional to flow. Difference about 120-125 should be equal to 30 fluid/sec flow. You can use two pumps at each tank if you need to measure flow up to 60 fluids/sec.
flow.png
flow.png (735.34 KiB) Viewed 3534 times
Management of order
I use a simple memory cell https://wiki.factorio.com/Combinator_Tu ... mory_Cells to keep order in memory. Following picture is an example how to add content from the belt into memory. I just multiply the signal from the belt by -1 in my rafinery to substract order by any piece of plastic/SF which left the rafinery. Constatnt combinator is used for setting your order manually. If you set R signal into any value different from 0, it will reset the memory. Any change of any content in constant combinator will pass into memory cell. Following combinators are:

1. each *(-1) -> each
2. each + 0 -> each

So it just add value multiplied by -1 to each signal which simply turns each signal into 0. However the multiplication is delayed by 1 tick so you obtain a value of change during a tick and store it into memory.
memory.png
memory.png (399.82 KiB) Viewed 3534 times
Blueprint
Here is a blueprint of whole project. Just be careful on electricity wires connection, espetially between switches. All wires must follow the first picture.

Code: Select all

H4sIAAAAAAAA/91dW2/jOLL+K4M87tp9ROpmYTYLzC6wzzM7j4uDwLGVRBjHNnzpn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ZHk
Al9iBu84qwj8FuO/cJEnMyuUJD91ediU+S1NUdbo+RzmsDQ/ktnRTIih2t/VbZqrvFgUn+uRLxpxSjEaGyvntR72s7tV+DeDdiwQuMl1ymE1fWDaVkOisTxr
9Wo8HZG0LWSpqWnE4dBoJIO9ZFzuviwPN63/KSVukbsg/sFom8OHoQWhXf09D2W5Qg34pawRFXftIAkLF3Jjg/A9R+QKeOB6CaNkw4WC+ABEMWQkB9U4ao2s
mTBG2K8btRfLYCMIK4DAT1pjS0PjEWNsSszVJIbiRd1eZlbppeNFHR4vmneewQpCKhVKsu0TnqU6sn+jw8Iyr+k55hzRPx/ZPxvZvxjZfzayf7sFjBkgGjuA
DlD11uGOqF+tbMXzltzvE0k0MU2WxfdtuWF5mJqTl02Ujr10a5P/RJPE3yQVrF7bVsfBONrP/FgJpo/Hqmy7443Qvth21f4tU2gijczyELMaUY+tXZgxwMuk
WjQbJJPGY+DiL29ZTi8vP+/Kw3G3/unu53K9/C8hbpBZ0t8AAA==
Aeternus
Filter Inserter
Filter Inserter
Posts: 835
Joined: Wed Mar 29, 2017 2:10 am
Contact:

Re: Control over Plastic/Solid Fuel process

Post by Aeternus »

Alternate option for shutting cracking off: Instead of cutting power to the chemplants, use an electric pump as a control valve. Works just as well and you don't have to fiddle around with specific wiring to the power poles. I used to do it the same way as you but found it to be too much of a hassle, especially if you economize on spacing.
Frightning
Filter Inserter
Filter Inserter
Posts: 814
Joined: Fri Apr 29, 2016 5:27 pm
Contact:

Re: Control over Plastic/Solid Fuel process

Post by Frightning »

Aeternus wrote:Alternate option for shutting cracking off: Instead of cutting power to the chemplants, use an electric pump as a control valve. Works just as well and you don't have to fiddle around with specific wiring to the power poles. I used to do it the same way as you but found it to be too much of a hassle, especially if you economize on spacing.
This is how I do it as well. In fact, this method lends itself nicely to extensible rows of Chemical plants, which in turn, can become Beacon friendly layouts with some careful planning. The trick is to put the Electric pump right before the input for the used oil product, and then daisy-chain wire them together. You can then have the control signal (determined by whatever circuit logic you desire) be spread to all pumps in the row easily.
Post Reply

Return to “Medium/Big/Gigantic Sized Structures”