modelDelayFirstOrder

Delay element, approximated by a first order differential equation

Extends from IDEAS.Fluid.MixingVolumes.MixingVolume (Mixing volume with inlet and outlet ports (flow reversal is allowed)).

Information

This model approximates a transport delay using first order differential equations.

The model consists of a mixing volume with two ports. The size of the mixing volume is such that at the nominal mass flow rate m_flow_nominal, the time constant of the volume is equal to the parameter tau.

The heat flux connector is optional and need not be connnected.

Parameters

TypeNameDefaultDescription
BooleanprescribedHeatFlowRate (from PartialMixingVolume)falseSet to true if the model has a prescribed heat flow at its heatPort. If the heat flow rate at the heatPort is only based on temperature difference, then set to false
Booleansimplify_mWat_flow (from PartialMixingVolume)trueSet to true to cause port_a.m_flow + port_b.m_flow = 0 even if mWat_flow is non-zero
Modelica.Units.SI.VolumeV (from PartialMixingVolume)Volume
Dynamics › Conservation equations
Modelica.Fluid.Types.DynamicsenergyDynamics (from LumpedVolumeDeclarations)Modelica.Fluid.Types.Dynamics.DynamicFreeInitialType of energy balance: dynamic (3 initialization options) or steady state
Modelica.Fluid.Types.DynamicssubstanceDynamics (from LumpedVolumeDeclarations)energyDynamicsType of independent mass fraction balance: dynamic (3 initialization options) or steady state
Modelica.Fluid.Types.DynamicstraceDynamics (from LumpedVolumeDeclarations)energyDynamicsType of trace substance balance: dynamic (3 initialization options) or steady state
Advanced › Dynamics
Modelica.Fluid.Types.DynamicsmassDynamics (from LumpedVolumeDeclarations)energyDynamicsType of mass balance: dynamic (3 initialization options) or steady state, must be steady state if energyDynamics is steady state
Initialization
Medium.AbsolutePressurep_start (from LumpedVolumeDeclarations)Medium.p_defaultStart value of pressure
Medium.TemperatureT_start (from LumpedVolumeDeclarations)Medium.T_defaultStart value of temperature
Medium.MassFraction[Medium.nX]X_start (from LumpedVolumeDeclarations)Medium.X_defaultStart value of mass fractions m_i/m
Medium.ExtraProperty[Medium.nC]C_start (from LumpedVolumeDeclarations)fill(0, Medium.nC)Start value of trace substances
Medium.ExtraProperty[Medium.nC]C_nominal (from LumpedVolumeDeclarations)fill(1E-2, Medium.nC)Nominal value of trace substances. (Set to typical order of magnitude.)
Dynamics
RealmSenFac (from LumpedVolumeDeclarations)1Factor for scaling the sensible thermal mass of the volume
Advanced
Booleaninitialize_p (from PartialMixingVolume)not Medium.singleState= true to set up initial equations for pressure
Modelica.Units.SI.MassFlowRatem_flow_small (from PartialMixingVolume)1E-4*abs(m_flow_nominal)Small mass flow rate for regularization of zero flow
Booleanuse_C_flow (from MixingVolume)falseSet to true to enable input connector for trace substance
Nominal condition
Modelica.Units.SI.MassFlowRatem_flow_nominal (from PartialMixingVolume)Nominal mass flow rate
General › Ports
IntegernPorts (from PartialMixingVolume)0Number of ports
Assumptions
BooleanallowFlowReversal (from PartialMixingVolume)true= false to simplify equations, assuming, but not enforcing, no flow reversal. Used only if model has two ports.
Delay time
Modelica.Units.SI.Timetau60Time constant at nominal flow

Connectors

TypeNameDefaultDescription
Modelica.Fluid.Vessels.BaseClasses.VesselFluidPorts_b[nPorts]ports (from PartialMixingVolume)Fluid inlets and outlets
Modelica.Blocks.Interfaces.RealOutputU (from PartialMixingVolume)Internal energy of the component
Modelica.Blocks.Interfaces.RealOutputm (from PartialMixingVolume)Mass of the component
Modelica.Blocks.Interfaces.RealOutput[Medium.nXi]mXi (from PartialMixingVolume)Species mass of the component
Modelica.Blocks.Interfaces.RealOutput[Medium.nC]mC (from PartialMixingVolume)Trace substance mass of the component
Modelica.Thermal.HeatTransfer.Interfaces.HeatPort_aheatPort (from MixingVolume)Heat port for heat exchange with the control volume
Modelica.Blocks.Interfaces.RealInputC_flow (from MixingVolume)Trace substance mass flow rate added to the medium

Components

TypeNameDefaultDescription
Medium.TemperatureT (from PartialMixingVolume)Medium.temperature_phX(p = p, h = hOut_internal, X = if Medium.reducedX then cat(1, Xi, {1 - sum(Xi)}) else Xi)Temperature of the fluid
Modelica.Units.SI.Pressurep (from PartialMixingVolume)if nPorts > 0 then ports[1].p else p_startPressure of the fluid
Modelica.Units.SI.MassFraction[Medium.nXi]Xi (from PartialMixingVolume)XiOut_internalSpecies concentration of the fluid
Medium.ExtraProperty[Medium.nC]C (from PartialMixingVolume)COut_internalTrace substance mixture content

Revisions

  • July 12, 2024, by Michael Wetter:
    Moved parameter tau to the main parameter tab.
    This is for #1906.
  • March 7, 2022, by Michael Wetter:
    Set final massDynamics=energyDynamics.
    This is for #1542.
  • September 14, 2013, by Michael Wetter:
    Renamed V0 to V_nominal to use consistent notation.
  • September 24, 2008, by Michael Wetter:
    Changed base class from Modelica.Fluid to IDEAS library. This was done to track the auxiliary species flow mC_flow.
  • September 4, 2008, by Michael Wetter:
    Fixed bug in assignment of parameter sta0. The earlier implementation required temperature to be a state, which is not always the case.
  • March 17, 2008, by Michael Wetter:
    First implementation.