modelFlow1Dim_MD
Information
Model Flow1Dim_2ph describes the flow of fluid through a discretized one dimentional tube.
Enthalpy and pressure are selected as state variable
In the model the node variables are characterized by the following syntax: _node.
The model is discretized using the collocated grid method: the nodes variable are the state variables and the cell variable are deduced
.UpWind discretization is considered i.e. h_node[j+1] = h_node[j].
Numerical options
In this tab several options are available to make the model more robust:
The model is characterized by a SummaryClass that provide a quick access to the following variables once the model is simulated:
The model is based on:
Casella, F. Object-oriented modelling of two-phase fluid flows by the finite volume method. Proceedings 5th Mathmod Vienna, Austria, Sep 2006, p. 68.
Parameters
| Type | Name | Default | Description |
|---|---|---|---|
| Modelica.SIunits.SpecificEnthalpy | hzero | 1e-3 | Small value for deltah |
| Real | pi | Modelica.Constants.pi | pi-greco |
| Integer | N | 10 | Number of cells |
| Integer | Nt | 1 | Number of tubes in parallel |
| Modelica.SIunits.Area | A | 16.18 | Lateral surface of the tube: heat exchange area |
| Modelica.SIunits.Volume | V | 0.03781 | Volume of the tube |
| Modelica.SIunits.Volume | Vi | V/N | Volume of a single cell |
| Modelica.SIunits.Area | Ai | A/N | Lateral surface of a single cell |
| Modelica.SIunits.MassFlowRate | Mdotnom | 0.2588 | Nominal fluid flow rate |
| Modelica.SIunits.CoefficientOfHeatTransfer | U_nom | 100 | if HTtype = LiqVap : Heat transfer coefficient, liquid zone |
| Initialization | |||
| Modelica.SIunits.Pressure | pstart | Fluid pressure start value | |
| Medium.Temperature | Tstart_inlet | Inlet temperature start value | |
| Medium.Temperature | Tstart_outlet | Outlet temperature start value | |
| Medium.SpecificEnthalpy[N + 1] | hstart | linspace(Medium.specificEnthalpy_pT(pstart, Tstart_inlet), Medium.specificEnthalpy_pT(pstart, Tstart_outlet), N + 1) | Start value of enthalpy vector (initialized by default) |
| Numerical options | |||
| Boolean | Mdotconst | false | Set to yes to assume constant mass flow rate at each node (easier convergence) |
| Boolean | max_der | false | Set to yes to limit the density derivative during phase transitions |
| Boolean | filter_dMdt | false | Set to yes to filter dMdt with a first-order filter |
| Real | max_drhodt | 100 | Maximum value for the density derivative |
| Modelica.SIunits.Time | TT | 1 | Integration time of the first-order filter |
| Initialization › Intialization options | |||
| Boolean | steadystate | true | if true, sets the derivative of h (working fluids enthalpy in each cell) to zero during Initialization |
Connectors
| Type | Name | Default | Description |
|---|---|---|---|
| ThermoCycle.Interfaces.Fluid.FlangeA | InFlow | ||
| ThermoCycle.Interfaces.Fluid.FlangeB | OutFlow | ||
| ThermoCycle.Interfaces.HeatTransfer.ThermalPort | Wall_int |
Components
| Type | Name | Default | Description |
|---|---|---|---|
| Medium.SaturationProperties | sat | ||
| Modelica.SIunits.SpecificEnthalpy | h_l | saturated liquid enthalpy | |
| Modelica.SIunits.SpecificEnthalpy | h_v | saturated vapor enthalpy | |
| Medium.Density | rho_l | ||
| Medium.Density | rho_v | ||
| Modelica.SIunits.DerDensityByPressure | drldp | Bubble point density derivative with respect to pressure | |
| Modelica.SIunits.DerDensityByPressure | drvdp | Dew point density derivative with respect to pressure | |
| Modelica.SIunits.DerEnthalpyByPressure | dhldp | Bubble point enthalpy derivative with respect to pressure | |
| Modelica.SIunits.DerEnthalpyByPressure | dhvdp | Dew point enthalpy derivative with respect to pressure | |
| Medium.ThermodynamicState[N + 1] | fluidState | ||
| Medium.AbsolutePressure | p | ||
| Modelica.SIunits.MassFlowRate | M_dot_su | ||
| Medium.SpecificEnthalpy[N] | h | Fluid specific enthalpy at the center cells | |
| Modelica.SIunits.SpecificEnthalpy[N + 1] | h_node | Enthalpy state variables at each node | |
| Medium.Temperature[N] | T | ||
| Medium.Temperature[N + 1] | T_node | Fluid temperature at the nodes | |
| Modelica.SIunits.Temperature[N] | T_wall | Internal wall temperature | |
| Medium.Density[N] | rho | Fluid cell density at center cell | |
| Medium.Density[N + 1] | rho_node | Fluid cell density at the nodes | |
| Modelica.SIunits.DerDensityByEnthalpy[N + 1] | drdh_node | Derivative of density by enthalpy at each node | |
| Modelica.SIunits.DerDensityByEnthalpy[N] | drdh1 | Derivative of average density by left enthalpy | |
| Modelica.SIunits.DerDensityByEnthalpy[N] | drdh2 | Derivative of average density by right enthalpy | |
| Modelica.SIunits.DerDensityByPressure[N + 1] | drdp_node | Derivative of density by pressure at each node | |
| Modelica.SIunits.DerDensityByPressure[N] | drdp | Derivative of density by pressure at center cell | |
| Real[N] | dMdt | Time derivative of mass in each cell between two nodes | |
| Modelica.SIunits.HeatFlux[N] | qdot | heat flux in each cell between two nodes | |
| Modelica.SIunits.MassFlowRate[N + 1] | Mdot_node | ||
| Modelica.SIunits.MassFlowRate[N] | Mdot | ||
| Real[N + 1] | x_node | Vapor quality at each node | |
| Modelica.SIunits.Power | Q_tot | Total heat flux exchanged by the thermal port | |
| Modelica.SIunits.Mass | M_tot | Total mass of the fluid in the component | |
| Real | AA | Variable for the calculation of the mean density derivative | |
| Real | BB | Variable for the calculation of the mean density derivative | |
| SummaryClass | Summary |
Contents
| Name | Description |
|---|---|
| Medium | |
| SummaryClass |