Mixing Simulation in Petroleum Refining

       Mixing simulation in petroleum refining is used to combine multiple material flows into a single downstream flow in refinery process simulation models and digital twins. Petroleum Refining Library provides two components:
       MixerLight — combines exactly two incoming material flows.
       Mixer — combines any number of incoming material flows into a single output flow.
       Both components support proportional mixing and neutral mixing, dynamic changes in mixing coefficients, and flow constraints.They are commonly used in refinery process simulation to combine flows from parallel process units, storage tanks, tank farms, and alternative flow routes.
The key difference between the Petroleum Refining Library Mixer and the standard AnyLogic Fluid Merge component is the ability to guarantee that the entire flow can be received from a specific input.
Another difference is the ability of the Petroleum Refining Library Mixer to combine any number of incoming flows simultaneously, rather than being limited to two flows.

How Mixing Simulation in Petroleum Refining Works

       Mixer and MixerLight perform material flow mixing using mixing coefficients. In proportional mixing mode, the coefficients define the relative contribution of each input flow. For example, coefficients [1, 2, 3] produce the following mixing ratio:
Input 1: 1/6; Input 2: 2/6; Input 3: 3/6. The coefficients do not need to be specified as percentages. A coefficient of 0 closes the corresponding input, while all-zero coefficients block the resulting flow.
       Mixer and MixerLight also support neutral mixing. In this mode, no predefined mixing ratio is enforced, and the flow is determined by the available incoming flows. In proportional mixing mode, the specified mixing ratios are preserved. If one input cannot provide the required flow, the total refinery throughput is reduced rather than redistributing the missing flow among the other inputs.

Mass Balance and Flow Composition

       Mixer and MixerLight preserve mass balance according to the law of conservation of mass: tthe output mass flow equals the sum of all incoming mass flows. Incoming flows can represent different products. However, the base Mixer logic does not calculate their composition. It simply combines the incoming mass, while the output product is defined by the corresponding FluidEnter.

Dynamic Mixing

       Mixing coefficients can change dynamically during the simulation, allowing mixing proportions and material flow rates to be adjusted when operating conditions or operating modes change. New coefficient values take effect immediately without transition delays. Connections cannot be changed after they are established.Input flows can be connected at model startup or after the model starts, depending on the connectAfterStart parameter.

Applications in Refinery Simulation

       Mixer and MixerLight are used in refinery process simulation to combine material flows from multiple sources into a single downstream flow. Typical applications in refinery process simulation include:
  • combining flows from parallel process units;
  • combining flows from multiple storage tanks or tank farms;
  • combining flows from parallel production or processing lines;
  • supporting refinery logistics, operating modes, and production planning scenarios.
For example, gasoline produced by three parallel process units can be combined into one gasoline flow before further transportation, storage, or processing.

Conclusion

       Mixing simulation in petroleum refining provides a flexible way to combine multiple material flows into a single downstream stream in refinery simulation models and digital twins.MixerLight supports two inputs, while Mixer can combine any number of incoming flows. With proportional and neutral mixing, dynamic mixing coefficients, and flow constraints, these components can model flow consolidation across refinery process units, tank farms, storage systems, and refinery logistics.

FAQ

1. What is a Mixer in Petroleum Refining Library?
A Mixer is a component used to combine multiple incoming material flows into one output flow.

2. What is the difference between Mixer and MixerLight?
MixerLight — combines exactly two incoming material flows, while Mixer can combine any number of incoming flows.

3. How are incoming flows controlled in Mixer?
Incoming flows can be controlled using mixing coefficients and flow rates.

4. How do mixing coefficients work?
Mixing coefficients define the relative contribution of each incoming flow. For example, [1, 2, 3] produces a mixing ratio of 1/6 : 2/6 : 3/6.

5. What does a mixing coefficient of zero mean?
A coefficient of 0 closes the corresponding input. If all mixing coefficients are zero, the output flow is blocked.

6. What happens if one incoming flow is constrained?
In proportional mixing mode, the total throughput is reduced to preserve the specified mixing proportions. The missing flow is not automatically redistributed among the other inputs.

7. What is neutral mixing?
In neutral mixing mode, no predefined mixing ratio is enforced. The resulting flow depends on the available incoming flows.

8. Can Mixer connections be changed after the simulation starts?
Yes. Mixing coefficients can change dynamically, and new values take effect immediately without transition delays.

9. Can Mixer connections be changed during simulation?
Yes. Mixing coefficients can change dynamically, and new values take effect immediately without transition delays.

10. Do Mixer and MixerLight preserve mass balance?
Yes. The output mass flow equals the combined mass flow of the incoming streams, subject to flow availability and mixing constraints.

11. Can Mixer combine flows with different products?
Yes. However, the base Mixer logic does not calculate product composition. It combines mass flows, while the outgoing product is defined by the connected FluidEnter.

12. Where can Mixer be used in refinery simulation?
Mixer can combine flows from parallel process units, storage tanks, tank farms, and alternative material flow routes.