modelSystem3

Third part of the system model with air supply and closed loop control

Extends from Modelica.Icons.Example (Icon for runnable examples).

Information

This part of the system model modifies Buildings.Examples.Tutorial.SpaceCooling.System2 to use the actual outside temperature for a summer day, and it adds closed loop control. The closed loop control measures the room temperature and switches the chilled water flow rate on or off.

Implementation

This section describes how we modified Buildings.Examples.Tutorial.SpaceCooling.System2 to build this model.

  1. The first step was to copy the model Buildings.Examples.Tutorial.SpaceCooling.System2.

  2. Next, we changed in weaDat the parameter that determines whether the outside dry bulb temperature is used from the weather data file or set to a constant value. This can be accomplished in the GUI of the weather data reader as follows:

    image

With this change to using real weather data, we also change the simulation time to be one day during the summer, where the start time is 4320 h (15552000 s) and the stop time is 4344 h (15638400 s).

If the model is now simulated, the following plot could be generated that shows that the room is cooled too much due to the open loop control:

image

To add closed loop control, we proceeded as follows.

  1. First, we made an instance of Buildings.Controls.OBC.CDL.Reals.Subtract and set its name to sub. It calculates the difference between the set point and the measured temperature.

  2. For the set point, we made the instance TRooSetPoi to feed a constant set point into the instance sub.

  3. The output of the instance sub was then fed as the input to con, which is an instance of Buildings.Controls.OBC.CDL.Reals.Hysteresis. For the instance con, we set the parameter for the lower limit to -0.5 and the upper limit to 0.5.

  4. The instance senTemRoo has been added to measure the room air temperature. Note that we decided to measure directly the room air temperature. If we would have used a temperature sensor in the return air stream, then its temperature would never change when the mass flow rate is zero, and hence it would not measure how the room temperature changes when the fan is off.

  5. Since the controller output is a boolean signal, but the instance souWat needs a real signal as an input for the water mass flow rate, we needed to add a conversion block. We therefore replaced the instance mWat_flow from a constant block to the block Buildings.Controls.OBC.CDL.Conversions.BooleanToReal. Because the cooling control has a reverse action, i.e., if the measured value exceeds the set point, the system should switch on instead of off, we configured the parameters of the conversion block as follow:

      realTrue=0
      realFalse=mW_flow_nominal
    

    This will output mW_flow_nominal when the room temperature is above the set point, and 0 otherwise.

This completes building the model shown in the figure on Buildings.Examples.Tutorial.SpaceCooling. When simulating the model, the response shown below should be seen.

image
image

Notes

To add a continuous controller for the coil water flow rate, we could have used the model Buildings.Controls.OBC.CDL.Reals.PID.

Parameters

TypeNameDefaultDescription
Modelica.Units.SI.VolumeV6*10*3Room volume
Realeps0.8Heat recovery effectiveness
Modelica.Units.SI.TemperatureTASup_nominal291.15Nominal air temperature supplied to room
Modelica.Units.SI.DimensionlessRatiowASup_nominal0.012Nominal air humidity ratio supplied to room [kg/kg] assuming 90% relative humidity
Modelica.Units.SI.TemperatureTRooSet297.15Nominal room air temperature
Modelica.Units.SI.TemperatureTOut_nominal303.15Design outlet air temperature
Modelica.Units.SI.TemperatureTHeaRecLvgTOut_nominal - eps*(TOut_nominal - TRooSet)Air temperature leaving the heat recovery
Modelica.Units.SI.DimensionlessRatiowHeaRecLvg0.0135Air humidity ratio leaving the heat recovery [kg/kg]
Modelica.Units.SI.HeatFlowRateQRooInt_flow1000Internal heat gains of the room
Modelica.Units.SI.HeatFlowRateQRooC_flow_nominal-QRooInt_flow - 10E3/30*(TOut_nominal - TRooSet)Nominal cooling load of the room
Modelica.Units.SI.MassFlowRatemA_flow_nominal1.3*QRooC_flow_nominal/1006/(TASup_nominal - TRooSet)Nominal air mass flow rate, increased by factor 1.3 to allow for recovery after temperature setback
Modelica.Units.SI.TemperatureDifferencedTFan2Estimated temperature raise across fan that needs to be made up by the cooling coil
Modelica.Units.SI.HeatFlowRateQCoiC_flow_nominalmA_flow_nominal*(TASup_nominal - THeaRecLvg - dTFan)*1006 + mA_flow_nominal*(wASup_nominal - wHeaRecLvg)*2458.3e3Cooling load of coil, taking into account outside air sensible and latent heat removal
Modelica.Units.SI.TemperatureTWSup_nominal285.15Water supply temperature
Modelica.Units.SI.TemperatureTWRet_nominal289.15Water return temperature
Modelica.Units.SI.MassFlowRatemW_flow_nominal-QCoiC_flow_nominal/(TWRet_nominal - TWSup_nominal)/4200Nominal water mass flow rate

Connectors

TypeNameDefaultDescription
BoundaryConditions.WeatherData.BusweaBus

Components

TypeNameDefaultDescription
Buildings.Fluid.MixingVolumes.MixingVolumevol
Modelica.Thermal.HeatTransfer.Components.ThermalConductortheConThermal conductance with the ambient
Modelica.Thermal.HeatTransfer.Sources.PrescribedTemperatureTOutOutside temperature
Modelica.Thermal.HeatTransfer.Sources.FixedHeatFlowpreHeaPrescribed heat flow
Buildings.Fluid.Movers.FlowControlled_m_flowfanSupply air fan
Buildings.Fluid.HeatExchangers.ConstantEffectivenesshexHeat recovery
Buildings.Fluid.HeatExchangers.WetCoilEffectivenessNTUcooCoiCooling coil
Buildings.Fluid.Sources.Outsideout
Buildings.Fluid.Sources.MassFlowSource_TsouWatSource for water flow rate
Buildings.Fluid.Sources.Boundary_pTsinWatSink for water circuit
BoundaryConditions.WeatherData.ReaderTMY3weaDatWeather data reader
Buildings.Controls.OBC.CDL.Reals.Sources.ConstantmAir_flowFan air flow rate
Buildings.Fluid.Sensors.TemperatureTwoPortsenTemHXOutTemperature sensor for heat recovery outlet on supply side
Buildings.Fluid.Sensors.TemperatureTwoPortsenTemSupAirTemperature sensor for supply air
Buildings.Controls.OBC.CDL.Reals.Sources.ConstantTRooSetPoiRoom temperature set point
Modelica.Thermal.HeatTransfer.Sensors.TemperatureSensorsenTemRooRoom temperature sensor
Buildings.Controls.OBC.CDL.Conversions.BooleanToRealmWat_flowConversion from boolean to real for water flow rate
Buildings.Controls.OBC.CDL.Reals.SubtractsubInputs different
Buildings.Controls.OBC.CDL.Reals.HysteresisconController for coil water flow rate

Contents

NameDescription
MediumAMedium for air
MediumWMedium for water

Revisions

  • April 9, 2024, by Hongxiang Fu:
    Specified nominalValuesDefineDefaultPressureCurve=true in the mover component to suppress a warning. This is for #3819.
  • December 11, 2023, by Jianjun Hu:
    Reimplemented on-off control to avoid using the obsolete OnOffController. This is for #3595.
  • September 20, 2021 by David Blum:
    Correct supply and return water parameterization.
    Use design conditions for UA parameterization in cooling coil.
    Use explicit calculation of sensible and latent load to determine design load on cooling coil.
    This is for #2624.
  • January 28, 2015 by Michael Wetter:
    Added thermal mass of furniture directly to air volume. This avoids an index reduction.
  • December 22, 2014 by Michael Wetter:
    Removed Modelica.Fluid.System to address issue #311.
  • January 11, 2012, by Michael Wetter:
    First implementation.