VirtualFCS.Fluid.Separator

A lumped fixed-volume gas/liquid separator

Model Description and References

This unit separates the phases of a condensable medium flow. It can operate at fixed temperature (heatPort=false), adiabatically (heatPort=true) or with heat dissipation models with appropriate units connected to the heat port.

Note that all ports have the same pressure, and to achieve physically meaningful results it will most often be necessary to connect them to a valve or other flow resistance unit before flushing to a constant-pressure reservoir.
Two output signals for level and pressure are provided, since these are the values that typically control the output flows.

In case of reverse flow, the feed port's (mid_port) height can be adjusted with feedHeight to set whether it will output liquid or gas depending on the liquid level in the separator.
If the separator runs out of liquid or overflows, the compositions and enthalpy of the liquid viz. the gas outlet will eventually change to the other phase; the transition interval depend on the pipeHeight parameter.

Governing Equations

V_gas = m*medium.beta/medium.d_gas;

V_liq = m*(1 - medium.beta)/medium.d_liq;

level = V_liq/V;

port_top.Xi_outflow = smoothStep(V_gas/V - pipeHeight, medium.X_gas[1:Medium.nXi], medium.X_liq[1:Medium.nXi], pipeHeight);

port_mid.Xi_outflow = smoothStep(V_liq/V - feedHeight, port_top.Xi_outflow, port_bottom.Xi_outflow, pipeHeight);

port_bottom.Xi_outflow = smoothStep(V_liq/V - pipeHeight, medium.X_liq[1:Medium.nXi], medium.X_gas[1:Medium.nXi], pipeHeight);

port_top.h_outflow = smoothStep(V_gas/V - pipeHeight, medium.h_gas, medium.h_liq, pipeHeight);

port_mid.h_outflow = smoothStep(V_liq/V - feedHeight, port_top.h_outflow, port_bottom.h_outflow, pipeHeight);

port_bottom.h_outflow = smoothStep(V_liq/V - pipeHeight, medium.h_liq, medium.h_gas, pipeHeight);

QuantityDescription
V_gasGas volume
V_liqLiquid volume
port_midTwo-phase inlet
port_topGas outlet at the top
port_bottomLiquid outlet at the bottom

Parameters

NameTypeUnitDefaultDescription
useHeatPortBoolean1false= true, if heatPort is enabled (inherited)
TModelica.Units.SI.TemperatureK293.15Fixed device temperature if useHeatPort = false (inherited)
energyDynamicsModelica.Fluid.Types.Dynamics-system.energyDynamicsFormulation of energy balance (inherited)
massDynamicsModelica.Fluid.Types.Dynamics-Modelica.Fluid.Types.Dynamics.FixedInitialFormulation of mass balance (inherited)
substanceDynamicsModelica.Fluid.Types.Dynamics-massDynamicsFormulation of substance balance (inherited)
traceDynamicsModelica.Fluid.Types.Dynamics-massDynamicsFormulation of trace substance balance (inherited)
p_startMedium.AbsolutePressurePasystem.p_startStart value of pressure (inherited)
use_T_startBoolean1true= true, use T_start, otherwise h_start (inherited)
T_startMedium.TemperatureKif use_T_start then system.T_start else Medium.temperature_phX(p_start, h_start, X_start)Start value of temperature (inherited)
h_startMedium.SpecificEnthalpyJ/kgif use_T_start then Medium.specificEnthalpy_pTX(p_start, T_start, X_start) else Medium.h_defaultStart value of specific enthalpy (inherited)
X_startMedium.MassFraction[Medium.nX]1Medium.X_defaultStart value of mass fractions m_i/m (inherited)
C_startMedium.ExtraProperty[Medium.nC]-Medium.C_defaultStart value of trace substances (inherited)
VModelica.Units.SI.Volumem31E-3Separator total volume
feedHeightReal10.5Relative vertical placement of feed, used for reverse flow
pipeHeightReal10.05Relative width of the inlet/outlet pipes compared to separator height

Interfaces and Connections

NameKindTypeUnitDescription
port_midConnectionModelica.Fluid.Interfaces.FluidPort_aPa; kg/s; J/kgTwo-phase inlet
levelOutput signalModelica.Blocks.Interfaces.RealOutput-
pOutput signalModelica.Blocks.Interfaces.RealOutput-
port_topConnectionModelica.Fluid.Interfaces.FluidPort_bPa; kg/s; J/kgGas outlet at the top
port_bottomConnectionModelica.Fluid.Interfaces.FluidPort_bPa; kg/s; J/kgLiquid outlet at the bottom
heatPortConnectionModelica.Thermal.HeatTransfer.Interfaces.HeatPort_aK; WConditional heat port
fluidVolumeInput signalModelica.Units.SI.Volumem3Volume