modelSystem2

2nd part of the system model, consisting of the room with heat transfer and a radiator

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

Information

This part of the system model adds a radiator with a prescribed mass flow rate to the system that is implemented in Buildings.Examples.Tutorial.Boiler.System1.

Implementation

This model was built as follows:

  1. First, we copied the model Buildings.Examples.Tutorial.Boiler.System1 and called it Buildings.Examples.Tutorial.Boiler.System2.

  2. Since this model uses water as the medium, we declared the water medium model at the top-level of the model by adding the lines

      replaceable package MediumW =
          Buildings.Media.Water "Medium model";
    
  3. To model the pump, a temperature sensor which we will need later for the control, and a flow sink, we made instances of the models Buildings.Fluid.Movers.FlowControlled_m_flow (instance pumRad for the pump that serves the radiators), Buildings.Fluid.Sensors.TemperatureTwoPort (instance temSup), Buildings.Fluid.HeatExchangers.Radiators.RadiatorEN442_2 (instance rad), and Buildings.Fluid.Sources.Boundary_pT (instance sou and sin for the sink and source reservoirs, which will later be replace by the boiler loop).

    In all of these instances, we set the medium model to MediumW. We also made an instance of the model Modelica.Thermal.HeatTransfer.Sensors.TemperatureSensor (instance temRoo) to measure the room temperature. We connected the model as shown in the figure below.

    image

    Note that there are two connections from the radiator to the room volume: One connection is for the convective heat flow rate, and the other is for the radiative heat flow rate. For simplicity, we assumed that the air and radiative temperature of the room are equal. Furthermore, we simplified the model by using only one radiator instead of multiple radiators, although this radiator will be quite large as it needs to provide a heat flow rate of 20 kW.

  4. Next, we computed the design mass flow rate for the radiator. According to the schematic drawing, the radiator should have at the design conditions a supply water temperature of 50°C and a return water temperature of 40°C. Thus, we define the radiator mass flow rate as

      parameter Modelica.Units.SI.HeatFlowRate Q_flow_nominal = 20000
        "Nominal heat flow rate of radiator";
      parameter Modelica.Units.SI.Temperature TRadSup_nominal = 273.15+50
        "Radiator nominal supply water temperature";
      parameter Modelica.Units.SI.Temperature TRadRet_nominal = 273.15+40
        "Radiator nominal return water temperature";
      parameter Modelica.Units.SI.MassFlowRate mRad_flow_nominal =
        Q_flow_nominal/4200/(TRadSup_nominal-TRadRet_nominal)
        "Radiator nominal mass flow rate";
    
  5. Now, we set the mass flow rate of pumRad and temSup to mRad_flow_nominal. We also set the temperature of the fluid that flows out of sou to TRadSup_nominal. We configured the parameters of the radiator model as

      Buildings.Fluid.HeatExchangers.Radiators.RadiatorEN442_2 rad(
        redeclare package Medium = MediumW,
        energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial,
        Q_flow_nominal=Q_flow_nominal,
        T_a_nominal=TRadSup_nominal,
        T_b_nominal=TRadRet_nominal) "Radiator";
    

    We configured the parameters of the pump model as

      Buildings.Fluid.Movers.FlowControlled_m_flow pumRad(
        redeclare package Medium = MediumW,
        energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial,
        m_flow_nominal=mRad_flow_nominal)
        "Pump for radiator";
    
  6. To enable the pump when the room temperature is below 19°C and to switch it off when the room temperature is below 21°C, we implemented the control blocks as shown in the figure below.

    image

    In this control sequence, the first block is a hysteresis element, which is modeled by Buildings.Controls.OBC.CDL.Reals.Hysteresis. It is configured as

      Buildings.Controls.OBC.CDL.Reals.Hysteresis hysPum(
        uLow=273.15 + 19,
        uHigh=273.15 + 21)
        "Pump hysteresis";
    

    to output false when the input signal falls below 19°C, and true when the input signal raises above 21°C. Next, we send the output to the instance not1, which outputs

      y= not u
    

    to negate the signal. The output of this signal is a boolean value, but the pump input signal is the required mass flow rate. Thus, we used the block Buildings.Controls.OBC.CDL.Conversions.BooleanToReal to convert the signal. We set the parameters of the boolean to real converter as

      Buildings.Controls.OBC.CDL.Conversions.BooleanToReal booToReaRad(
            realTrue=mRad_flow_nominal,
            realFalse=0) "Radiator pump signal";
    

    For numerical reasons, in particular in large system models, it is recommended to continuously change the mass flow rate, as opposed to having a step change. Therefore, in the instance pumRad, we leave the parameter use_riseTime at its default value true. This will approximate a continuous change in mass flow rate when the pump is switched on or off. Finally, we closed the control loop between the room temperature sensor and the pump input signal.

This completes the initial version of the model. When simulating the model for 2 days, or 172800 seconds, the response shown below should be seen.

image

The figure shows that the room temperature is maintained at 20°C when the internal heat gain is zero, and controlled around 19°C to 21°C when there is an internal heat gain. The temperature is slightly outside this temperature range because of the time lag that is caused by the thermal capacity of the radiator.

Notes

For a more realistic model of a room, the model Buildings.ThermalZones.Detailed.MixedAir could have been used. For transient heat conduction, models from the package Buildings.HeatTransfer.Conduction could have been used.

Parameters

TypeNameDefaultDescription
Modelica.Units.SI.HeatFlowRateQ_flow_nominal20000Nominal heat flow rate of radiator
Modelica.Units.SI.TemperatureTRadSup_nominal273.15 + 50Radiator nominal supply water temperature
Modelica.Units.SI.TemperatureTRadRet_nominal273.15 + 40Radiator nominal return water temperature
Modelica.Units.SI.MassFlowRatemRad_flow_nominalQ_flow_nominal/4200/(TRadSup_nominal - TRadRet_nominal)Radiator nominal mass flow rate
Modelica.Units.SI.VolumeV6*10*3Room volume
Modelica.Units.SI.MassFlowRatemA_flow_nominalV*1.2*6/3600Nominal mass flow rate
Modelica.Units.SI.HeatFlowRateQRooInt_flow4000Internal heat gains of the room

Components

TypeNameDefaultDescription
Buildings.Fluid.MixingVolumes.MixingVolumevol
Modelica.Thermal.HeatTransfer.Components.ThermalConductortheConThermal conductance with the ambient
Modelica.Thermal.HeatTransfer.Sources.FixedTemperatureTOutOutside temperature
Modelica.Thermal.HeatTransfer.Sources.PrescribedHeatFlowpreHeaPrescribed heat flow
Modelica.Thermal.HeatTransfer.Components.HeatCapacitorheaCapHeat capacity for furniture and walls
Buildings.Controls.OBC.CDL.Reals.Sources.TimeTabletimTabTime table for internal heat gain
Buildings.Fluid.HeatExchangers.Radiators.RadiatorEN442_2radRadiator
Buildings.Fluid.Sources.Boundary_pTsinSink for mass flow rate
Buildings.Fluid.Sensors.TemperatureTwoPorttemSupSupply water temperature
Modelica.Thermal.HeatTransfer.Sensors.TemperatureSensortemRooRoom temperature
Buildings.Fluid.Movers.FlowControlled_m_flowpumRadPump for radiator
Buildings.Fluid.Sources.Boundary_pTsouSink for mass flow rate
Buildings.Controls.OBC.CDL.Reals.HysteresishysPumPump hysteresis
Buildings.Controls.OBC.CDL.Conversions.BooleanToRealbooToReaRadRadiator pump signal
Buildings.Controls.OBC.CDL.Logical.Notnot1Negate output of hysteresis

Contents

NameDescription
MediumA
MediumWMedium model

Revisions

  • April 9, 2024, by Hongxiang Fu:
    Specified nominalValuesDefineDefaultPressureCurve=true in the mover component to suppress a warning. This is for #3819.
  • March 6, 2017, by Michael Wetter:
    Added missing density to computation of air mass flow rate.
    This is for #673.
  • December 22, 2014 by Michael Wetter:
    Removed Modelica.Fluid.System to address issue #311.
  • January 27, 2012, by Michael Wetter:
    First implementation.