Buildings.Examples.VAVReheat

Variable air volume flow system with terminal reheat and five thermal zones

Information

This package contains variable air volume flow models for office buildings.

Note

The models Buildings.ThermalZones.EnergyPlus.Examples.SmallOffice.ASHRAE2006Winter and Buildings.ThermalZones.EnergyPlus.Examples.SmallOffice.Guideline36Winter appear to be quite similar to Buildings.Examples.VAVReheat.ASHRAE2006 and Buildings.Examples.VAVReheat.Guideline36, respectively, because they all have the same HVAC system, control sequences, and all have five thermal zones. However, the models in Buildings.ThermalZones.EnergyPlus.Examples.SmallOffice are from the DOE Commercial Reference Building, Small Office, new construction, ASHRAE 90.1-2004, Version 1.3_5.0, whereas the models in Buildings.Examples.VAVReheat are from the DOE Commercial Building Benchmark, Medium Office, new construction, ASHRAE 90.1-2004, version 1.2_4.0. Therefore, the dimensions of the thermal zones in Buildings.ThermalZones.EnergyPlus.Examples.SmallOffice are considerably smaller than in Buildings.Examples.VAVReheat. As the sizing is scaled with the volumes of the thermal zones, the model structure is the same, but the design capacities are different, as is the energy consumption.

Extends from Modelica.Icons.ExamplesPackage (Icon for packages containing runnable examples).

Package Content

Name Description
Buildings.Examples.VAVReheat.ASHRAE2006 ASHRAE2006 Variable air volume flow system with terminal reheat and five thermal zones
Buildings.Examples.VAVReheat.Guideline36 Guideline36 Variable air volume flow system with terminal reheat and five thermal zones
Buildings.Examples.VAVReheat.Controls Controls Package with controller models
Buildings.Examples.VAVReheat.Validation Validation Collection of validation models
Buildings.Examples.VAVReheat.BaseClasses BaseClasses Package with base classes for Buildings.Examples.VAVReheat

Buildings.Examples.VAVReheat.ASHRAE2006 Buildings.Examples.VAVReheat.ASHRAE2006

Variable air volume flow system with terminal reheat and five thermal zones

Buildings.Examples.VAVReheat.ASHRAE2006

Information

This model consist of an HVAC system, a building envelope model and a model for air flow through building leakage and through open doors.

The HVAC system is a variable air volume (VAV) flow system with economizer and a heating and cooling coil in the air handler unit. There is also a reheat coil and an air damper in each of the five zone inlet branches. The figure below shows the schematic diagram of the HVAC system

image

See the model Buildings.Examples.VAVReheat.BaseClasses.PartialOpenLoop for a description of the HVAC system and the building envelope.

The control is an implementation of the control sequence VAV 2A2-21232 of the Sequences of Operation for Common HVAC Systems (ASHRAE, 2006). In this control sequence, the supply fan speed is modulated based on the duct static pressure. The return fan controller tracks the supply fan air flow rate. The duct static pressure set point is adjusted so that at least one VAV damper is 90% open. The heating coil valve, outside air damper, and cooling coil valve are modulated in sequence to maintain the supply air temperature set point. The economizer control provides the following functions: freeze protection, minimum outside air requirement, and supply air cooling, see Buildings.Examples.VAVReheat.Controls.Economizer. The controller of the terminal units tracks the room air temperature set point based on a "dual maximum with constant volume heating" logic, see Buildings.Examples.VAVReheat.Controls.RoomVAV.

There is also a finite state machine that transitions the mode of operation of the HVAC system between the modes occupied, unoccupied off, unoccupied night set back, unoccupied warm-up and unoccupied pre-cool. In the VAV model, all air flows are computed based on the duct static pressure distribution and the performance curves of the fans. Local loop control is implemented using proportional and proportional-integral controllers, while the supervisory control is implemented using a finite state machine.

A similar model but with a different control sequence can be found in Buildings.Examples.VAVReheat.Guideline36.

References

ASHRAE. Sequences of Operation for Common HVAC Systems. ASHRAE, Atlanta, GA, 2006.

Extends from Modelica.Icons.Example (Icon for runnable examples), Buildings.Examples.VAVReheat.BaseClasses.PartialOpenLoop (Partial model of variable air volume flow system with terminal reheat and five thermal zones).

Parameters

TypeNameDefaultDescription
VolumeVRooCorflo.VRooCorRoom volume corridor [m3]
VolumeVRooSouflo.VRooSouRoom volume south [m3]
VolumeVRooNorflo.VRooNorRoom volume north [m3]
VolumeVRooEasflo.VRooEasRoom volume east [m3]
VolumeVRooWesflo.VRooWesRoom volume west [m3]
AreaAFloCorflo.AFloCorFloor area corridor [m2]
AreaAFloSouflo.AFloSouFloor area south [m2]
AreaAFloNorflo.AFloNorFloor area north [m2]
AreaAFloEasflo.AFloEasFloor area east [m2]
AreaAFloWesflo.AFloWesFloor area west [m2]
AreaAFlo[numZon]{flo.AFloCor,flo.AFloSou,flo...Floor area of each zone [m2]
RealACHCor6Design air change per hour core [1/h]
RealACHSou6Design air change per hour south [1/h]
RealACHEas9Design air change per hour east [1/h]
RealACHNor6Design air change per hour north [1/h]
RealACHWes7Design air change per hour west [1/h]
MassFlowRatemCor_flow_nominalACHCor*VRooCor*convDesign mass flow rate core [kg/s]
MassFlowRatemSou_flow_nominalACHSou*VRooSou*convDesign mass flow rate south [kg/s]
MassFlowRatemEas_flow_nominalACHEas*VRooEas*convDesign mass flow rate east [kg/s]
MassFlowRatemNor_flow_nominalACHNor*VRooNor*convDesign mass flow rate north [kg/s]
MassFlowRatemWes_flow_nominalACHWes*VRooWes*convDesign mass flow rate west [kg/s]
MassFlowRatem_flow_nominal0.7*(mCor_flow_nominal + mSo...Nominal mass flow rate [kg/s]
RealratVFloHea0.3VAV box maximum air flow rate ratio in heating mode [1]
Anglelat41.98*3.14159/180Latitude [rad]
RealratOAFlo_A0.3e-3Outdoor airflow rate required per unit area [m3/(s.m2)]
RealratOAFlo_P2.5e-3Outdoor airflow rate required per person
RealratP_A5e-2Occupant density
RealeffZ0.8Zone air distribution effectiveness (limiting value) [1]
RealdivP0.7Occupant diversity ratio [1]
VolumeFlowRateVCorOA_flow_nominal(ratOAFlo_P*ratP_A + ratOAFl...Zone outdoor air flow rate [m3/s]
VolumeFlowRateVSouOA_flow_nominal(ratOAFlo_P*ratP_A + ratOAFl...Zone outdoor air flow rate [m3/s]
VolumeFlowRateVEasOA_flow_nominal(ratOAFlo_P*ratP_A + ratOAFl...Zone outdoor air flow rate [m3/s]
VolumeFlowRateVNorOA_flow_nominal(ratOAFlo_P*ratP_A + ratOAFl...Zone outdoor air flow rate [m3/s]
VolumeFlowRateVWesOA_flow_nominal(ratOAFlo_P*ratP_A + ratOAFl...Zone outdoor air flow rate [m3/s]
VolumeFlowRateVou_flow_nominal(divP*ratOAFlo_P*ratP_A + ra...System uncorrected outdoor air flow rate [m3/s]
RealeffVenif divP < 0.6 then 0.88*divP...System ventilation efficiency [1]
VolumeFlowRateVot_flow_nominalVou_flow_nominal/effVenSystem design outdoor air flow rate [m3/s]
TemperatureTHeaOn293.15Heating setpoint during on [K]
TemperatureTHeaOff285.15Heating setpoint during off [K]
TemperatureTCooOn297.15Cooling setpoint during on [K]
TemperatureTCooOff303.15Cooling setpoint during off [K]
PressureDifferencedpBuiStaSet12Building static pressure [Pa]
RealyFanMin0.1Minimum fan speed
TemperatureTHotWatInl_nominal55 + 273.15Reheat coil nominal inlet water temperature [K]
BooleanallowFlowReversaltrue= false to simplify equations, assuming, but not enforcing, no flow reversal
Booleanuse_windPressuretrueSet to true to enable wind pressure
RealratVMinCor_flowmax(1.5*VCorOA_flow_nominal,...Minimum discharge air flow rate ratio [1]
RealratVMinSou_flowmax(1.5*VSouOA_flow_nominal,...Minimum discharge air flow rate ratio [1]
RealratVMinEas_flowmax(1.5*VEasOA_flow_nominal,...Minimum discharge air flow rate ratio [1]
RealratVMinNor_flowmax(1.5*VNorOA_flow_nominal,...Minimum discharge air flow rate ratio [1]
RealratVMinWes_flowmax(1.5*VWesOA_flow_nominal,...Minimum discharge air flow rate ratio [1]
Experimental (may be changed in future releases)
BooleansampleModeltrueSet to true to time-sample the model, which can give shorter simulation time if there is already time sampling in the system model

Connectors

TypeNameDescription
BusweaBusWeather Data Bus
ControlBuscontrolBus 

Modelica definition

model ASHRAE2006 "Variable air volume flow system with terminal reheat and five thermal zones" extends Modelica.Icons.Example; extends Buildings.Examples.VAVReheat.BaseClasses.PartialOpenLoop( redeclare replaceable Buildings.Examples.VAVReheat.BaseClasses.Floor flo( final lat=lat, final sampleModel=sampleModel), amb(nPorts=3)); parameter Real ratVMinCor_flow(final unit="1")= max(1.5*VCorOA_flow_nominal, 0.15*mCor_flow_nominal/1.2) / (mCor_flow_nominal/1.2) "Minimum discharge air flow rate ratio"; parameter Real ratVMinSou_flow(final unit="1")= max(1.5*VSouOA_flow_nominal, 0.15*mSou_flow_nominal/1.2) / (mSou_flow_nominal/1.2) "Minimum discharge air flow rate ratio"; parameter Real ratVMinEas_flow(final unit="1")= max(1.5*VEasOA_flow_nominal, 0.15*mEas_flow_nominal/1.2) / (mEas_flow_nominal/1.2) "Minimum discharge air flow rate ratio"; parameter Real ratVMinNor_flow(final unit="1")= max(1.5*VNorOA_flow_nominal, 0.15*mNor_flow_nominal/1.2) / (mNor_flow_nominal/1.2) "Minimum discharge air flow rate ratio"; parameter Real ratVMinWes_flow(final unit="1")= max(1.5*VWesOA_flow_nominal, 0.15*mWes_flow_nominal/1.2) / (mWes_flow_nominal/1.2) "Minimum discharge air flow rate ratio"; Controls.FanVFD conFanSup(xSet_nominal(displayUnit="Pa") = 410, r_N_min= yFanMin) "Controller for fan"; Controls.ModeSelector modeSelector; Controls.ControlBus controlBus; Controls.Economizer conEco( have_reset=true, have_frePro=true, VOut_flow_min=Vot_flow_nominal) "Controller for economizer"; Controls.RoomTemperatureSetpoint TSetRoo( final THeaOn=THeaOn, final THeaOff=THeaOff, final TCooOn=TCooOn, final TCooOff=TCooOff); Controls.DuctStaticPressureSetpoint pSetDuc( nin=5, pMin=50) "Duct static pressure setpoint"; Controls.RoomVAV conVAVCor(ratVFloMin=ratVMinCor_flow, ratVFloHea=ratVFloHea) "Controller for terminal unit corridor"; Controls.RoomVAV conVAVSou(ratVFloMin=ratVMinSou_flow, ratVFloHea=ratVFloHea) "Controller for terminal unit south"; Controls.RoomVAV conVAVEas(ratVFloMin=ratVMinEas_flow, ratVFloHea=ratVFloHea) "Controller for terminal unit east"; Controls.RoomVAV conVAVNor(ratVFloMin=ratVMinNor_flow, ratVFloHea=ratVFloHea) "Controller for terminal unit north"; Controls.RoomVAV conVAVWes(ratVFloMin=ratVMinWes_flow, ratVFloHea=ratVFloHea) "Controller for terminal unit west"; Buildings.Controls.OBC.CDL.Logical.Or or2; Controls.SupplyAirTemperature conTSup "Supply air temperature and economizer controller"; Controls.SupplyAirTemperatureSetpoint TSupSet "Supply air temperature set point"; Buildings.Fluid.Actuators.Dampers.Exponential damExh( from_dp=false, riseTime=15, dpFixed_nominal=5, redeclare package Medium = MediumA, m_flow_nominal=m_flow_nominal, dpDamper_nominal=5) "Exhaust air damper"; equation connect(controlBus, modeSelector.cb); connect(min.y, controlBus.TRooMin); connect(ave.y, controlBus.TRooAve); connect(TRet.T, conEco.TRet); connect(TSetRoo.controlBus, controlBus); connect(dpDisSupFan.p_rel, conFanSup.u_m); connect(pSetDuc.y, conFanSup.u); connect(conEco.VOut_flow, VOut1.V_flow); connect(conVAVCor.TRoo, TRooAir.y5[1]); connect(conVAVSou.TRoo, TRooAir.y1[1]); connect(TRooAir.y2[1], conVAVEas.TRoo); connect(TRooAir.y3[1], conVAVNor.TRoo); connect(TRooAir.y4[1], conVAVWes.TRoo); connect(cor.yVAV, conVAVCor.yDam); connect(conVAVSou.yDam, sou.yVAV); connect(conVAVEas.yDam, eas.yVAV); connect(conVAVNor.yDam, nor.yVAV); connect(conVAVCor.TRooHeaSet, controlBus.TRooSetHea); connect(conVAVCor.TRooCooSet, controlBus.TRooSetCoo); connect(conVAVSou.TRooHeaSet, controlBus.TRooSetHea); connect(conVAVSou.TRooCooSet, controlBus.TRooSetCoo); connect(conVAVEas.TRooHeaSet, controlBus.TRooSetHea); connect(conVAVEas.TRooCooSet, controlBus.TRooSetCoo); connect(conVAVNor.TRooHeaSet, controlBus.TRooSetHea); connect(conVAVNor.TRooCooSet, controlBus.TRooSetCoo); connect(conVAVWes.TRooHeaSet, controlBus.TRooSetHea); connect(conVAVWes.TRooCooSet, controlBus.TRooSetCoo); connect(wes.yVAV, conVAVWes.yDam); connect(occSch.tNexOcc, controlBus.dTNexOcc); connect(occSch.occupied, controlBus.occupied); connect(pSetDuc.TOut, TOut.y); connect(TOut.y, controlBus.TOut); connect(conEco.controlBus, controlBus); connect(modeSelector.yFan, conFanSup.uFan); connect(conFanSup.y, fanSup.y); connect(or2.u2, modeSelector.yFan); connect(cor.y_actual, pSetDuc.u[1]); connect(sou.y_actual, pSetDuc.u[2]); connect(eas.y_actual, pSetDuc.u[3]); connect(nor.y_actual, pSetDuc.u[4]); connect(wes.y_actual, pSetDuc.u[5]); connect(TSup.T, conTSup.TSup); connect(conTSup.yHea, gaiHeaCoi.u); connect(conTSup.yCoo, gaiCooCoi.u); connect(conTSup.yOA, conEco.uOATSup); connect(or2.y, conTSup.uEna); connect(modeSelector.yEco, conEco.uEna); connect(TMix.T, conEco.TMix); connect(controlBus, TSupSet.controlBus); connect(TSupSet.TSet, conTSup.TSupSet); connect(conVAVCor.yVal, gaiHeaCoiCor.u); connect(conVAVSou.yVal, gaiHeaCoiSou.u); connect(conVAVEas.yVal, gaiHeaCoiEas.u); connect(conVAVNor.yVal, gaiHeaCoiNor.u); connect(conVAVWes.yVal, gaiHeaCoiWes.u); connect(damRet.y, conEco.yRet); connect(damExh.y, conEco.yOA); connect(damOut.y, conEco.yOA); connect(damExh.port_a, TRet.port_b); connect(damExh.port_b, amb.ports[3]); connect(freSta.y, or2.u1); end ASHRAE2006;

Buildings.Examples.VAVReheat.Guideline36 Buildings.Examples.VAVReheat.Guideline36

Variable air volume flow system with terminal reheat and five thermal zones

Buildings.Examples.VAVReheat.Guideline36

Information

This model consist of an HVAC system, a building envelope model and a model for air flow through building leakage and through open doors.

The HVAC system is a variable air volume (VAV) flow system with economizer and a heating and cooling coil in the air handler unit. There is also a reheat coil and an air damper in each of the five zone inlet branches.

See the model Buildings.Examples.VAVReheat.BaseClasses.PartialOpenLoop for a description of the HVAC system and the building envelope.

The control is based on ASHRAE Guideline 36, and implemented using the sequences from the library Buildings.Controls.OBC.ASHRAE.G36_PR1 for multi-zone VAV systems with economizer. The schematic diagram of the HVAC and control sequence is shown in the figure below.

image

A similar model but with a different control sequence can be found in Buildings.Examples.VAVReheat.ASHRAE2006. Note that this model, because of the frequent time sampling, has longer computing time than Buildings.Examples.VAVReheat.ASHRAE2006. The reason is that the time integrator cannot make large steps because it needs to set a time step each time the control samples its input.

Extends from Modelica.Icons.Example (Icon for runnable examples), Buildings.Examples.VAVReheat.BaseClasses.PartialOpenLoop (Partial model of variable air volume flow system with terminal reheat and five thermal zones).

Parameters

TypeNameDefaultDescription
VolumeVRooCorflo.VRooCorRoom volume corridor [m3]
VolumeVRooSouflo.VRooSouRoom volume south [m3]
VolumeVRooNorflo.VRooNorRoom volume north [m3]
VolumeVRooEasflo.VRooEasRoom volume east [m3]
VolumeVRooWesflo.VRooWesRoom volume west [m3]
AreaAFloCorflo.AFloCorFloor area corridor [m2]
AreaAFloSouflo.AFloSouFloor area south [m2]
AreaAFloNorflo.AFloNorFloor area north [m2]
AreaAFloEasflo.AFloEasFloor area east [m2]
AreaAFloWesflo.AFloWesFloor area west [m2]
AreaAFlo[numZon]{flo.AFloCor,flo.AFloSou,flo...Floor area of each zone [m2]
RealACHCor6Design air change per hour core [1/h]
RealACHSou6Design air change per hour south [1/h]
RealACHEas9Design air change per hour east [1/h]
RealACHNor6Design air change per hour north [1/h]
RealACHWes7Design air change per hour west [1/h]
MassFlowRatemCor_flow_nominalACHCor*VRooCor*convDesign mass flow rate core [kg/s]
MassFlowRatemSou_flow_nominalACHSou*VRooSou*convDesign mass flow rate south [kg/s]
MassFlowRatemEas_flow_nominalACHEas*VRooEas*convDesign mass flow rate east [kg/s]
MassFlowRatemNor_flow_nominalACHNor*VRooNor*convDesign mass flow rate north [kg/s]
MassFlowRatemWes_flow_nominalACHWes*VRooWes*convDesign mass flow rate west [kg/s]
MassFlowRatem_flow_nominal0.7*(mCor_flow_nominal + mSo...Nominal mass flow rate [kg/s]
RealratVFloHea0.3VAV box maximum air flow rate ratio in heating mode [1]
Anglelat41.98*3.14159/180Latitude [rad]
RealratOAFlo_A0.3e-3Outdoor airflow rate required per unit area [m3/(s.m2)]
RealratOAFlo_P2.5e-3Outdoor airflow rate required per person
RealratP_A5e-2Occupant density
RealeffZ0.8Zone air distribution effectiveness (limiting value) [1]
RealdivP0.7Occupant diversity ratio [1]
VolumeFlowRateVCorOA_flow_nominal(ratOAFlo_P*ratP_A + ratOAFl...Zone outdoor air flow rate [m3/s]
VolumeFlowRateVSouOA_flow_nominal(ratOAFlo_P*ratP_A + ratOAFl...Zone outdoor air flow rate [m3/s]
VolumeFlowRateVEasOA_flow_nominal(ratOAFlo_P*ratP_A + ratOAFl...Zone outdoor air flow rate [m3/s]
VolumeFlowRateVNorOA_flow_nominal(ratOAFlo_P*ratP_A + ratOAFl...Zone outdoor air flow rate [m3/s]
VolumeFlowRateVWesOA_flow_nominal(ratOAFlo_P*ratP_A + ratOAFl...Zone outdoor air flow rate [m3/s]
VolumeFlowRateVou_flow_nominal(divP*ratOAFlo_P*ratP_A + ra...System uncorrected outdoor air flow rate [m3/s]
RealeffVenif divP < 0.6 then 0.88*divP...System ventilation efficiency [1]
VolumeFlowRateVot_flow_nominalVou_flow_nominal/effVenSystem design outdoor air flow rate [m3/s]
TemperatureTHeaOn293.15Heating setpoint during on [K]
TemperatureTHeaOff285.15Heating setpoint during off [K]
TemperatureTCooOn297.15Cooling setpoint during on [K]
TemperatureTCooOff303.15Cooling setpoint during off [K]
PressureDifferencedpBuiStaSet12Building static pressure [Pa]
RealyFanMin0.1Minimum fan speed
TemperatureTHotWatInl_nominal55 + 273.15Reheat coil nominal inlet water temperature [K]
BooleanallowFlowReversaltrue= false to simplify equations, assuming, but not enforcing, no flow reversal
Booleanuse_windPressuretrueSet to true to enable wind pressure
VolumeFlowRateVPriSysMax_flowm_flow_nominal/1.2Maximum expected system primary airflow rate at design stage [m3/s]
VolumeFlowRateminZonPriFlo[numZon]{conVAVCor.VDisSetMin_flow,c...Minimum expected zone primary flow rate [m3/s]
TimesamplePeriod120Sample period of component, set to the same value as the trim and respond that process yPreSetReq [s]
PressureDifferencedpDisRetMax40Maximum return fan discharge static pressure setpoint [Pa]
Experimental (may be changed in future releases)
BooleansampleModeltrueSet to true to time-sample the model, which can give shorter simulation time if there is already time sampling in the system model

Connectors

TypeNameDescription
BusweaBusWeather Data Bus

Modelica definition

model Guideline36 "Variable air volume flow system with terminal reheat and five thermal zones" extends Modelica.Icons.Example; extends Buildings.Examples.VAVReheat.BaseClasses.PartialOpenLoop( redeclare replaceable Buildings.Examples.VAVReheat.BaseClasses.Floor flo( final lat=lat, final sampleModel=sampleModel), amb(nPorts=3), damOut( dpDamper_nominal=10, dpFixed_nominal=10), freSta(lockoutTime=3600)); parameter Modelica.SIunits.VolumeFlowRate VPriSysMax_flow=m_flow_nominal/1.2 "Maximum expected system primary airflow rate at design stage"; parameter Modelica.SIunits.VolumeFlowRate minZonPriFlo[numZon]={ conVAVCor.VDisSetMin_flow, conVAVSou.VDisSetMin_flow, conVAVEas.VDisSetMin_flow, conVAVNor.VDisSetMin_flow, conVAVWes.VDisSetMin_flow} "Minimum expected zone primary flow rate"; parameter Modelica.SIunits.Time samplePeriod=120 "Sample period of component, set to the same value as the trim and respond that process yPreSetReq"; parameter Modelica.SIunits.PressureDifference dpDisRetMax=40 "Maximum return fan discharge static pressure setpoint"; Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.Controller conVAVCor( V_flow_nominal=mCor_flow_nominal/1.2, AFlo=AFloCor, final samplePeriod=samplePeriod, VDisSetMin_flow=max(1.5*VCorOA_flow_nominal, 0.15*mCor_flow_nominal/1.2), VDisHeaSetMax_flow=ratVFloHea*mCor_flow_nominal/1.2) "Controller for terminal unit corridor"; Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.Controller conVAVSou( V_flow_nominal=mSou_flow_nominal/1.2, AFlo=AFloSou, final samplePeriod=samplePeriod, VDisSetMin_flow=max(1.5*VSouOA_flow_nominal, 0.15*mSou_flow_nominal/1.2), VDisHeaSetMax_flow=ratVFloHea*mSou_flow_nominal/1.2) "Controller for terminal unit south"; Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.Controller conVAVEas( V_flow_nominal=mEas_flow_nominal/1.2, AFlo=AFloEas, final samplePeriod=samplePeriod, VDisSetMin_flow=max(1.5*VEasOA_flow_nominal, 0.15*mEas_flow_nominal/1.2), VDisHeaSetMax_flow=ratVFloHea*mEas_flow_nominal/1.2) "Controller for terminal unit east"; Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.Controller conVAVNor( V_flow_nominal=mNor_flow_nominal/1.2, AFlo=AFloNor, final samplePeriod=samplePeriod, VDisSetMin_flow=max(1.5*VNorOA_flow_nominal, 0.15*mNor_flow_nominal/1.2), VDisHeaSetMax_flow=ratVFloHea*mNor_flow_nominal/1.2) "Controller for terminal unit north"; Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.Controller conVAVWes( V_flow_nominal=mWes_flow_nominal/1.2, AFlo=AFloWes, final samplePeriod=samplePeriod, VDisSetMin_flow=max(1.5*VWesOA_flow_nominal, 0.15*mWes_flow_nominal/1.2), VDisHeaSetMax_flow=ratVFloHea*mWes_flow_nominal/1.2) "Controller for terminal unit west"; Modelica.Blocks.Routing.Multiplex5 TDis "Discharge air temperatures"; Modelica.Blocks.Routing.Multiplex5 VDis_flow "Air flow rate at the terminal boxes"; Buildings.Controls.OBC.CDL.Integers.MultiSum TZonResReq(nin=5) "Number of zone temperature requests"; Buildings.Controls.OBC.CDL.Integers.MultiSum PZonResReq(nin=5) "Number of zone pressure requests"; Buildings.Controls.OBC.CDL.Logical.Switch swiFreSta "Switch for freeze stat"; Buildings.Controls.OBC.CDL.Continuous.Sources.Constant yFreHeaCoi(final k=1) "Flow rate signal for heating coil when freeze stat is on"; Buildings.Controls.OBC.ASHRAE.G36_PR1.AHUs.MultiZone.VAV.Controller conAHU( kMinOut=0.03, final pMaxSet=410, final yFanMin=yFanMin, final VPriSysMax_flow=VPriSysMax_flow, final peaSysPop=divP*sum({ratP_A*AFlo[i] for i in 1:numZon})) "AHU controller"; Buildings.Controls.OBC.ASHRAE.G36_PR1.AHUs.MultiZone.VAV.SetPoints.OutdoorAirFlow.Zone zonOutAirSet[numZon]( final AFlo=AFlo, final have_occSen=fill(false, numZon), final have_winSen=fill(false, numZon), final desZonPop={ratP_A*AFlo[i] for i in 1:numZon}, final minZonPriFlo=minZonPriFlo) "Zone level calculation of the minimum outdoor airflow setpoint"; Buildings.Controls.OBC.ASHRAE.G36_PR1.AHUs.MultiZone.VAV.SetPoints.OutdoorAirFlow.SumZone zonToSys(final numZon=numZon) "Sum up zone calculation output"; Buildings.Controls.OBC.CDL.Routing.RealReplicator reaRep1(final nout=numZon) "Replicate design uncorrected minimum outdoor airflow setpoint"; Buildings.Controls.OBC.CDL.Routing.BooleanReplicator booRep1(final nout=numZon) "Replicate signal whether the outdoor airflow is required"; Buildings.Controls.OBC.ASHRAE.G36_PR1.Generic.SetPoints.ZoneStatus zonSta[numZon] "Check zone temperature status"; Buildings.Controls.OBC.ASHRAE.G36_PR1.Generic.SetPoints.GroupStatus zonGroSta( final numZon=numZon) "Check zone group status according to the zones status"; Buildings.Controls.OBC.ASHRAE.G36_PR1.Generic.SetPoints.OperationMode opeModSel(final numZon=numZon); Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.SetPoints.ZoneTemperatures TZonSet[numZon]( final have_occSen=fill(false, numZon), final have_winSen=fill(false, numZon)) "Zone setpoint"; Buildings.Controls.OBC.CDL.Continuous.Sources.Constant warCooTim[numZon]( final k=fill(1800, numZon)) "Warm up and cool down time"; Buildings.Controls.OBC.CDL.Logical.Sources.Constant falSta[numZon]( final k=fill(false, numZon)) "All windows are closed, no zone has override switch"; Buildings.Controls.OBC.CDL.Routing.RealReplicator reaRep(nout=numZon) "Assume all zones have same occupancy schedule"; Buildings.Controls.OBC.CDL.Routing.BooleanReplicator booRep(nout=numZon) "Assume all zones have same occupancy schedule"; Buildings.Controls.OBC.CDL.Integers.Sources.Constant demLimLev[numZon]( final k=fill(0, numZon)) "Demand limit level, assumes to be 0"; Buildings.Controls.OBC.CDL.Routing.IntegerReplicator intRep( final nout=numZon) "All zones in same operation mode"; equation connect(conVAVCor.TZon, TRooAir.y5[1]); connect(conVAVSou.TZon, TRooAir.y1[1]); connect(TRooAir.y2[1], conVAVEas.TZon); connect(TRooAir.y3[1], conVAVNor.TZon); connect(TRooAir.y4[1], conVAVWes.TZon); connect(conVAVCor.TDis, cor.TSup); connect(sou.TSup, conVAVSou.TDis); connect(eas.TSup, conVAVEas.TDis); connect(nor.TSup, conVAVNor.TDis); connect(wes.TSup, conVAVWes.TDis); connect(cor.yVAV, conVAVCor.yDam); connect(conVAVSou.yDam, sou.yVAV); connect(conVAVEas.yDam, eas.yVAV); connect(conVAVNor.yDam, nor.yVAV); connect(wes.yVAV, conVAVWes.yDam); connect(conVAVCor.yZonTemResReq, TZonResReq.u[1]); connect(conVAVSou.yZonTemResReq, TZonResReq.u[2]); connect(conVAVEas.yZonTemResReq, TZonResReq.u[3]); connect(conVAVNor.yZonTemResReq, TZonResReq.u[4]); connect(conVAVWes.yZonTemResReq, TZonResReq.u[5]); connect(conVAVCor.yZonPreResReq, PZonResReq.u[1]); connect(conVAVSou.yZonPreResReq, PZonResReq.u[2]); connect(conVAVEas.yZonPreResReq, PZonResReq.u[3]); connect(conVAVNor.yZonPreResReq, PZonResReq.u[4]); connect(conVAVWes.yZonPreResReq, PZonResReq.u[5]); connect(cor.VSup_flow, VDis_flow.u1[1]); connect(sou.VSup_flow, VDis_flow.u2[1]); connect(eas.VSup_flow, VDis_flow.u3[1]); connect(nor.VSup_flow, VDis_flow.u4[1]); connect(wes.VSup_flow, VDis_flow.u5[1]); connect(cor.TSup, TDis.u1[1]); connect(sou.TSup, TDis.u2[1]); connect(eas.TSup, TDis.u3[1]); connect(nor.TSup, TDis.u4[1]); connect(wes.TSup, TDis.u5[1]); connect(conVAVCor.VDis_flow, cor.VSup_flow); connect(sou.VSup_flow, conVAVSou.VDis_flow); connect(eas.VSup_flow, conVAVEas.VDis_flow); connect(nor.VSup_flow, conVAVNor.VDis_flow); connect(wes.VSup_flow, conVAVWes.VDis_flow); connect(TSup.T, conVAVCor.TSupAHU); connect(TSup.T, conVAVSou.TSupAHU); connect(TSup.T, conVAVEas.TSupAHU); connect(TSup.T, conVAVNor.TSupAHU); connect(TSup.T, conVAVWes.TSupAHU); connect(swiFreSta.y, gaiHeaCoi.u); connect(yFreHeaCoi.y, swiFreSta.u1); connect(zonToSys.ySumDesZonPop, conAHU.sumDesZonPop); connect(zonToSys.VSumDesPopBreZon_flow, conAHU.VSumDesPopBreZon_flow); connect(zonToSys.VSumDesAreBreZon_flow, conAHU.VSumDesAreBreZon_flow); connect(zonToSys.yDesSysVenEff, conAHU.uDesSysVenEff); connect(zonToSys.VSumUncOutAir_flow, conAHU.VSumUncOutAir_flow); connect(zonToSys.VSumSysPriAir_flow, conAHU.VSumSysPriAir_flow); connect(zonToSys.uOutAirFra_max, conAHU.uOutAirFra_max); connect(zonOutAirSet.yDesZonPeaOcc, zonToSys.uDesZonPeaOcc); connect(zonOutAirSet.VDesPopBreZon_flow, zonToSys.VDesPopBreZon_flow); connect(zonOutAirSet.VDesAreBreZon_flow, zonToSys.VDesAreBreZon_flow); connect(zonOutAirSet.yDesPriOutAirFra, zonToSys.uDesPriOutAirFra); connect(zonOutAirSet.VUncOutAir_flow, zonToSys.VUncOutAir_flow); connect(zonOutAirSet.yPriOutAirFra, zonToSys.uPriOutAirFra); connect(zonOutAirSet.VPriAir_flow, zonToSys.VPriAir_flow); connect(conAHU.yAveOutAirFraPlu, zonToSys.yAveOutAirFraPlu); connect(conAHU.VDesUncOutAir_flow, reaRep1.u); connect(reaRep1.y, zonOutAirSet.VUncOut_flow_nominal); connect(conAHU.yReqOutAir, booRep1.u); connect(booRep1.y, zonOutAirSet.uReqOutAir); connect(flo.TRooAir, zonOutAirSet.TZon); connect(TDis.y, zonOutAirSet.TDis); connect(VDis_flow.y, zonOutAirSet.VDis_flow); connect(TZonResReq.y, conAHU.uZonTemResReq); connect(PZonResReq.y, conAHU.uZonPreResReq); connect(TOut.y, conAHU.TOut); connect(dpDisSupFan.p_rel, conAHU.ducStaPre); connect(TSup.T, conAHU.TSup); connect(TRet.T, conAHU.TOutCut); connect(VOut1.V_flow, conAHU.VOut_flow); connect(TMix.T, conAHU.TMix); connect(conAHU.yOutDamPos, damOut.y); connect(conAHU.yRetDamPos, damRet.y); connect(conAHU.yCoo, gaiCooCoi.u); connect(conAHU.yHea, swiFreSta.u3); connect(conAHU.ySupFanSpe, fanSup.y); connect(cor.y_actual,conVAVCor.yDam_actual); connect(sou.y_actual,conVAVSou.yDam_actual); connect(eas.y_actual,conVAVEas.yDam_actual); connect(nor.y_actual,conVAVNor.yDam_actual); connect(wes.y_actual,conVAVWes.yDam_actual); connect(warCooTim.y, zonSta.cooDowTim); connect(warCooTim.y, zonSta.warUpTim); connect(flo.TRooAir, zonSta.TZon); connect(zonSta.yCooTim, zonGroSta.uCooTim); connect(zonSta.yWarTim, zonGroSta.uWarTim); connect(zonSta.yOccHeaHig, zonGroSta.uOccHeaHig); connect(zonSta.yHigOccCoo, zonGroSta.uHigOccCoo); connect(zonSta.THeaSetOff, zonGroSta.THeaSetOff); connect(zonSta.yUnoHeaHig, zonGroSta.uUnoHeaHig); connect(zonSta.yEndSetBac, zonGroSta.uEndSetBac); connect(zonSta.TCooSetOff, zonGroSta.TCooSetOff); connect(zonSta.yHigUnoCoo, zonGroSta.uHigUnoCoo); connect(zonSta.yEndSetUp, zonGroSta.uEndSetUp); connect(flo.TRooAir, zonGroSta.TZon); connect(falSta.y, zonGroSta.uWin); connect(occSch.tNexOcc, reaRep.u); connect(reaRep.y, zonGroSta.tNexOcc); connect(occSch.occupied, booRep.u); connect(booRep.y, zonGroSta.uOcc); connect(falSta.y, zonGroSta.zonOcc); connect(zonGroSta.uGroOcc, opeModSel.uOcc); connect(zonGroSta.nexOcc, opeModSel.tNexOcc); connect(zonGroSta.yCooTim, opeModSel.maxCooDowTim); connect(zonGroSta.yWarTim, opeModSel.maxWarUpTim); connect(zonGroSta.yOccHeaHig, opeModSel.uOccHeaHig); connect(zonGroSta.yHigOccCoo, opeModSel.uHigOccCoo); connect(zonGroSta.yColZon, opeModSel.totColZon); connect(zonGroSta.ySetBac, opeModSel.uSetBac); connect(zonGroSta.yEndSetBac, opeModSel.uEndSetBac); connect(zonGroSta.TZonMax, opeModSel.TZonMax); connect(zonGroSta.TZonMin, opeModSel.TZonMin); connect(zonGroSta.yHotZon, opeModSel.totHotZon); connect(zonGroSta.ySetUp, opeModSel.uSetUp); connect(zonGroSta.yEndSetUp, opeModSel.uEndSetUp); connect(zonSta.THeaSetOn, TZonSet.TZonHeaSetOcc); connect(zonSta.THeaSetOff, TZonSet.TZonHeaSetUno); connect(zonSta.TCooSetOn, TZonSet.TZonCooSetOcc); connect(zonSta.TCooSetOff, TZonSet.TZonCooSetUno); connect(demLimLev.y, TZonSet.uCooDemLimLev); connect(demLimLev.y, TZonSet.uHeaDemLimLev); connect(opeModSel.yOpeMod, conVAVCor.uOpeMod); connect(opeModSel.yOpeMod, conVAVSou.uOpeMod); connect(opeModSel.yOpeMod, conVAVEas.uOpeMod); connect(opeModSel.yOpeMod, conVAVNor.uOpeMod); connect(opeModSel.yOpeMod, conVAVWes.uOpeMod); connect(opeModSel.yOpeMod, conAHU.uOpeMod); connect(TZonSet[1].TZonHeaSet, conAHU.TZonHeaSet); connect(TZonSet[1].TZonCooSet, conAHU.TZonCooSet); connect(TZonSet[1].TZonHeaSet, conVAVCor.TZonHeaSet); connect(TZonSet[2].TZonHeaSet, conVAVSou.TZonHeaSet); connect(TZonSet[3].TZonHeaSet, conVAVEas.TZonHeaSet); connect(TZonSet[4].TZonHeaSet, conVAVNor.TZonHeaSet); connect(TZonSet[5].TZonHeaSet, conVAVWes.TZonHeaSet); connect(TZonSet[1].TZonCooSet, conVAVCor.TZonCooSet); connect(TZonSet[2].TZonCooSet, conVAVSou.TZonCooSet); connect(TZonSet[3].TZonCooSet, conVAVEas.TZonCooSet); connect(TZonSet[4].TZonCooSet, conVAVNor.TZonCooSet); connect(TZonSet[5].TZonCooSet, conVAVWes.TZonCooSet); connect(opeModSel.yOpeMod, intRep.u); connect(intRep.y, TZonSet.uOpeMod); connect(zonGroSta.yOpeWin, opeModSel.uOpeWin); connect(conVAVCor.yVal, gaiHeaCoiCor.u); connect(conVAVSou.yVal, gaiHeaCoiSou.u); connect(conVAVEas.yVal, gaiHeaCoiEas.u); connect(conVAVNor.yVal, gaiHeaCoiNor.u); connect(conVAVWes.yVal, gaiHeaCoiWes.u); connect(amb.ports[3], TRet.port_b); connect(freSta.y, swiFreSta.u2); end Guideline36;