modelRealGasJunction_L2_nPorts

Volume junction for real gases with n ports

Extends from TransiEnt.Basics.Icons.RealGasJunction_L2 (Icon for real gas junction).

Information

1. Purpose of model

This model represents a generalized junction for real gases with n ports. It is a modified version of the model TransiEnt.Components.Gas.VolumesValvesFittings.RealGasJunction_L2. The model is documented there and here only the changes are described: The three ports were replaced by one vector, summary, eye and fluid models at port were deleted. Linear pressure losses can be turned on by setting Delta_p_nom to a value unequal to zero for the desired port. You can choose a quasi-stationary or dynamic mass balance implementations. Additionally, the parameter variableCompositionEntries can be used in case that not all components are freely variable, e.g. when hydrogen is fed into natural gas.

2. Level of detail, physical effects considered, and physical insight

(no remarks)

3. Limits of validity

(no remarks)

4. Interfaces

gasPort[n_ports]: vector of inlets/outlets for gas

5. Nomenclature

(no elements)

6. Governing Equations

(no remarks)

7. Remarks for Usage

(no remarks)

8. Validation

(no remarks)

9. References

(no remarks)

10. Version History

Created by Carsten Bode (c.bode@tuhh.de), Mar 2019

Modified by Carsten Bode (c.bode@tuhh.de), May 2020 (added quasi-stationary equations and simplified equations for only dependent mass fractions)

Parameters

TypeNameDefaultDescription
Integer[:]dependentCompositionEntriesif variableCompositionEntries[1] == 0 then 1:medium.nc else TransiEnt.Basics.Functions.findSetDifference(1:medium.nc, variableCompositionEntries)Entries of medium vector which are supposed to be dependent on the variable entries
Initial Values
IntegerinitOption0Type of initialisation
BooleanuseHomotopysimCenter.useHomotopyTrue, if homotopy method is used during initialisation
ClaRa.Basics.Units.Pressurep_startsimCenter.p_amb_const + simCenter.p_eff_2Initial value for gas pressure
ClaRa.Basics.Units.EnthalpyMassSpecifich_startTILMedia.Internals.VLEFluidConfigurations.FullyMixtureCompatible.VLEFluidFunctions.specificEnthalpy_pTxi(medium, p_start, T_start, xi_start)Initial value for gas specific enthalpy
ClaRa.Basics.Units.MassFractionxi_startmedium.xi_defaultInitial value for mass fractions
ClaRa.Basics.Units.TemperatureT_startsimCenter.T_groundInitial value for gas temperature (used in calculation of h_start)
Fundamental Definitions
TILMedia.VLEFluidTypes.BaseVLEFluidmediumsimCenter.gasModel1
Integern_ports3
ClaRa.Basics.Units.Volumevolume0.1Volume of the junction
BooleanconstantCompositionsimCenter.useConstCompInGasCompUse simplified equation for constant composition (xi_nom will be used)
SI.MassFraction[medium.nc - 1]xi_nommedium.xi_defaultConstant composition
Integer[:]variableCompositionEntries{0}Entries of medium vector which are supposed to be completely variable
IntegermassBalance1Mass balance and species balance fomulation
BooleanshowHeatPortfalse
SI.Pressurep_min_assert0Minimum pressure in component below which the simulation terminates
SI.Pressurep_max_assert1000e5Maximum pressure in component above which the simulation terminates
Modelica.Units.SI.MassFlowRate[n_ports]m_flow_nomones(n_ports)*10Nominal mass flow rate
Modelica.Units.SI.PressureDifference[n_ports]Delta_p_nomzeros(n_ports)Nominal pressure loss at m_flow_nom

Connectors

TypeNameDefaultDescription
TransiEnt.Basics.Interfaces.Gas.RealGasPortIn[n_ports]gasPort
Modelica.Thermal.HeatTransfer.Interfaces.HeatPort_aheat

Components

TypeNameDefaultDescription
TransiEnt.SimCentersimCenter
TransiEnt.Components.Gas.VolumesValvesFittings.Base.Linear_inclZero[n_ports]pressureLoss
TILMedia.Internals.VLEFluidConfigurations.FullyMixtureCompatible.VLEFluid_pTgasBulk
ClaRa.Basics.Units.MassFraction[medium.nc - 1]xi
Modelica.Units.SI.MassFractionxi_end1 - sum(xi)Last entry of mass fraction
Modelica.Units.SI.SpecificEnthalpyhSpecific enthalpy
ClaRa.Basics.Units.Pressurep
ClaRa.Basics.Units.MassmassGas mass in control volume