.Buildings.Examples.Tutorial.SpaceCooling.System1

Information

This part of the system model implements the room with a heat gain. The room is simplified as a volume of air, a prescribed heat source for the internal convective heat gain, and a heat conductor for steady-state heat conduction to the outside. To increase the heat capacity of the room, such as due to heat stored in furniture and in building constructions, the heat capacity of the room air was increased by a factor of three. The convective heat transfer coefficient is lumped into the heat conductor model.

Implementation

This section describes step by step how we implemented the model.

  1. First, to define the medium properties, we added the declaration

      replaceable package MediumA = Buildings.Media.Air "Medium for air";
    

    This will allow the propagation of the medium model to all models that contain air. In this example, there is only one model with air, but when we connect an air supply, there will be multiple models that use this medium.

    We called the medium MediumA to distinguish it from MediumW that we will use in later versions of the model for components that have water as a medium.

    Note that although the medium model is for unsaturated air, the cooling coil will be able to reduce the moisture content of the medium. Because the air outlet state of the cooling coil has a relative humidity below 100%, we can use this medium model and need not be able to model the fog region.

    We also defined the system-level parameters

      parameter Modelica.Units.SI.Volume V=6*10*3 "Room volume";
      parameter Modelica.Units.SI.MassFlowRate mA_flow_nominal = V*1.2*6/3600
        "Nominal mass flow rate";
      parameter Modelica.Units.SI.HeatFlowRate QRooInt_flow = 1000
        "Internal heat gains of the room";
    

    to declare that the room volume is 180 m3, that the room has a nominal mass flow rate of 6 air changes per hour and that the internal heat gains of the room are 1000 Watts. These parameters have been declared at the top-level of the model as they will be used in several other models. Declaring them at the top-level allows to propagate them to other models, and to easily change them at one location should this be required when revising the model.

  2. To model the room air, approximated as a completely mixed volume of air, an instance of Buildings.Fluid.MixingVolumes.MixingVolume has been used, as this model can be used with dry air or moist air. The medium model has been set to MediumA. We set the parameter energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial which will cause the initial conditions of the volume to be fixed to the values specified by the parameters on the Initialization tab.

    The nominal mass flow rate of the volume is set to mA_flow_nominal. The nominal mass flow rate is used for numerical reasons and should be set to the approximate order of magnitude. It only has an effect if the mass flow rate is near zero and what "near zero" means depends on the magnitude of m_flow_nominal, as it is used for the default value of the parameter m_flow_small on the Assumptions tag of the model. See also Buildings.Fluid.UsersGuide for an explanation of the purpose of m_flow_small.

  3. To increase the heat capacity of the room air to approximate energy storage in furniture and building constructions, we set the parameter mSenFac=3 in the instance vol. This will increase the sensible heat capacity of the room air by a factor of three.

  4. We used the instance heaCon to model the heat conductance to the ambient. Since our room should have a heat loss of 10 kW at a temperature difference of 30 Kelvin, we set the conductance to G=10000 ⁄ 30 W/K.

  5. Finally, we used the instance preHea to model a prescribed, constant heat gain of 1000 Watts, such as due to internal heat source.

This completes the initial version of the model. When simulating the model for 3 hours, or 10800 seconds, the response shown below should be seen.

image

To verify the correctness of the model, we can compare the simulated results to the following analytical solutions:

  1. At steady-state, the temperature difference to the outside should be Δ T = Q̇ ⁄ UA = 1000/(10000/30) = 3 Kelvin, which corresponds to a room temperature of -7°C.
  2. It can be shown that the time constant of the room is τ = C ⁄ UA = 1950 seconds, where C is the heat capacity of the room air and the thermal storage element that is connected to it, and G is the heat conductance.

Both analytical values agree with the simulation results shown in the above figure.

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.

Contents

NameDescription
MediumAMedium for air

Revisions


Generated at 2024-07-19T18:16:32Z by OpenModelicaOpenModelica 1.23.1 using GenerateDoc.mos