Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.Validation

Collection of validation models

Information

This package contains validation models for the classes in Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.

Note that most validation models contain simple input data which may not be realistic, but for which the correct output can be obtained through an analytic solution. The examples plot various outputs, which have been verified against these solutions. These model outputs are stored as reference data and used for continuous validation whenever models in the library change.

Package Content

Name Description
Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.Validation.Controller Controller Validate model for controlling VAV terminal box with reheat
Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.Validation.ModeAndSetPoints ModeAndSetPoints Validation models of reseting zone setpoint temperature

Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.Validation.Controller Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.Validation.Controller

Validate model for controlling VAV terminal box with reheat

Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.Validation.Controller

Information

This example validates Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.Controller.

Modelica definition

model Controller "Validate model for controlling VAV terminal box with reheat" Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.Controller con( AFlo=50, samplePeriod=120, V_flow_nominal=(50*3/3600)*6) "Controller for VAV terminal unit with reheat"; Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.Controller con1( AFlo=50, samplePeriod=120, V_flow_nominal=(50*3/3600)*6, have_occSen=true, have_winSen=true, have_CO2Sen=true) "Controller for VAV terminal unit with reheat"; Buildings.Controls.OBC.CDL.Continuous.Sources.Constant TSetRooCoo(k=273.15 + 24) "Room cooling setpoint "; Buildings.Controls.OBC.CDL.Continuous.Sources.Ramp disAirFlo( offset=0.02, height=0.0168, duration=3600) "Discharge airflow rate"; Buildings.Controls.OBC.CDL.Continuous.Sources.Ramp TZon( height=6, offset=273.15 + 17, duration=3600) "Measured room temperature"; Buildings.Controls.OBC.CDL.Continuous.Sources.Ramp TDis( height=4, duration=3600, offset=273.15 + 18) "Terminal unit discharge air temperature"; Buildings.Controls.OBC.CDL.Continuous.Sources.Ramp TSup( height=4, duration=3600, offset=273.15 + 14) "AHU supply air temperature"; Buildings.Controls.OBC.CDL.Integers.Sources.Constant opeMod( final k=Buildings.Controls.OBC.ASHRAE.G36_PR1.Types.OperationModes.occupied) "AHU operation mode is Occupied"; Buildings.Controls.OBC.CDL.Continuous.Sources.Constant TSetRooHea(k=273.15 + 20) "Room heating setpoint"; Buildings.Controls.OBC.CDL.Continuous.Sources.Ramp ppmCO2( duration=3600, height=800, offset=200) "CO2 concentration"; Buildings.Controls.OBC.CDL.Logical.Sources.Pulse winSta(period=3600) "WIndow status"; Buildings.Controls.OBC.CDL.Continuous.Sources.Ramp nOcc( height=5, duration=4800, offset=0) "Number of occupants"; Buildings.Controls.OBC.CDL.Continuous.Round rou(n=0) "Round the input"; equation connect(TSetRooHea.y,con.TZonHeaSet); connect(TSetRooCoo.y, con.TZonCooSet); connect(disAirFlo.y, con.VDis_flow); connect(TZon.y, con.TZon); connect(TDis.y, con.TDis); connect(TSup.y, con.TSupAHU); connect(opeMod.y, con.uOpeMod); connect(nOcc.y, rou.u); connect(rou.y, con1.nOcc); connect(ppmCO2.y, con1.ppmCO2); connect(winSta.y, con1.uWin); connect(TSetRooHea.y,con1.TZonHeaSet); connect(TSetRooCoo.y, con1.TZonCooSet); connect(disAirFlo.y, con1.VDis_flow); connect(TZon.y, con1.TZon); connect(TDis.y, con1.TDis); connect(TSup.y, con1.TSupAHU); connect(opeMod.y, con1.uOpeMod); end Controller;

Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.Validation.ModeAndSetPoints Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.Validation.ModeAndSetPoints

Validation models of reseting zone setpoint temperature

Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.Validation.ModeAndSetPoints

Information

This example validates Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.ModeAndSetPoints.

Modelica definition

model ModeAndSetPoints "Validation models of reseting zone setpoint temperature" Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.ModeAndSetPoints setPoi( final numZon=2, final cooAdj=true, final heaAdj=true) "Output resetted zone setpoint remperature"; Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.ModeAndSetPoints setPoi1( final numZon=2, final have_occSen=true, final have_winSen=true) "Output resetted zone setpoint remperature"; Buildings.Controls.OBC.CDL.Continuous.Sources.Sine heaSetAdj[2]( each final freqHz=1/28800, each final amplitude=0.5) "Heating setpoint adjustment"; Buildings.Controls.OBC.CDL.Continuous.Sources.Sine cooSetAdj[2]( each final freqHz=1/28800) "Cooling setpoint adjustment"; Buildings.Controls.OBC.CDL.Continuous.Sources.Sine TZon1( final amplitude=5, final offset=18 + 273.15, final freqHz=1/86400) "Zone 1 temperature"; Buildings.Controls.OBC.CDL.Continuous.Sources.Sine TZon2( final offset=18 + 273.15, final freqHz=1/86400, final amplitude=7.5) "Zone 2 temperature"; Buildings.Controls.OBC.CDL.Logical.Sources.Constant winSta1(final k=false) "Window status"; Buildings.Controls.OBC.CDL.Logical.Sources.Constant winSta2(final k=true) "Window status"; Buildings.Controls.OBC.CDL.Logical.Sources.Constant occSen1(final k=false) "Occupancy sensor"; Buildings.Controls.OBC.CDL.Logical.Sources.Constant occSen2(final k=true) "Occupancy sensor"; Buildings.Controls.OBC.CDL.Continuous.Sources.TimeTable occTim( final table=[0,0;occSta,1; occEnd,0; 24*3600,0], final smoothness=Buildings.Controls.OBC.CDL.Types.Smoothness.ConstantSegments); Buildings.Controls.OBC.CDL.Continuous.Sources.ModelTime modTim; Buildings.Controls.OBC.CDL.Continuous.Sources.Constant con( final k=24*3600) "One day in second"; Buildings.Controls.OBC.CDL.Continuous.Division div "Output first input divided by second input"; Buildings.Controls.OBC.CDL.Continuous.Round rou(final n=0) "Round real number to 0 digit"; Buildings.Controls.OBC.CDL.Continuous.Gain gai(final k=24*3600) "Begin time of each day"; Buildings.Controls.OBC.CDL.Continuous.LessEqual lesEqu "Check if it is beginning of next day"; Buildings.Controls.OBC.CDL.Continuous.AddParameter addPar1( final p=-1, final k=1) "Add parameter"; Buildings.Controls.OBC.CDL.Continuous.Gain gai1( final k=24*3600) "Begin of day"; Buildings.Controls.OBC.CDL.Logical.Switch swi "Beginning of current day"; Buildings.Controls.OBC.CDL.Continuous.Add curTim(final k2=-1) "Current time "; Buildings.Controls.OBC.CDL.Continuous.Add add2(final k2=-1) "Left time to beginning of current day occupancy "; Buildings.Controls.OBC.CDL.Continuous.Sources.Constant occStaTim( final k=occSta) "Occupancy start"; Buildings.Controls.OBC.CDL.Continuous.Add add1(final k2=-1) "Left time to the end of current day"; Buildings.Controls.OBC.CDL.Continuous.AddParameter addPar2( final p=occSta, final k=1) "Left time to next occupancy"; Buildings.Controls.OBC.CDL.Continuous.LessEqual lesEqu1 "Check if current time has already passed occupancy start time"; Buildings.Controls.OBC.CDL.Logical.Switch swi1 "Time to next occupancy"; Buildings.Controls.OBC.CDL.Continuous.GreaterEqualThreshold greEquThr( final threshold=0.5); protected final parameter Modelica.SIunits.Time occSta = 7*3600 "Occupancy start time"; final parameter Modelica.SIunits.Time occEnd = 19*3600 "Occupancy end time"; equation connect(TZon1.y, setPoi.TZon[1]); connect(TZon2.y, setPoi.TZon[2]); connect(cooSetAdj.y, setPoi.setAdj); connect(heaSetAdj.y, setPoi.heaSetAdj); connect(TZon1.y, setPoi1.TZon[1]); connect(TZon2.y, setPoi1.TZon[2]); connect(occSen1.y, setPoi1.uOccSen[1]); connect(occSen2.y, setPoi1.uOccSen[2]); connect(winSta1.y, setPoi1.uWinSta[1]); connect(winSta2.y, setPoi1.uWinSta[2]); connect(modTim.y,div. u1); connect(con.y,div. u2); connect(div.y,rou. u); connect(rou.y,gai. u); connect(gai.y,lesEqu. u1); connect(modTim.y,lesEqu. u2); connect(rou.y,addPar1. u); connect(addPar1.y,gai1. u); connect(lesEqu.y,swi. u2); connect(gai.y,swi. u1); connect(gai1.y,swi. u3); connect(modTim.y,curTim. u1); connect(swi.y,curTim. u2); connect(occStaTim.y,add2. u1); connect(con.y,add1. u1); connect(add1.y,addPar2. u); connect(occStaTim.y,lesEqu1. u2); connect(curTim.y,lesEqu1. u1); connect(lesEqu1.y,swi1. u2); connect(add2.y,swi1. u1); connect(addPar2.y,swi1. u3); connect(occTim.y[1],greEquThr. u); connect(curTim.y,add2. u2); connect(curTim.y,add1. u2); connect(greEquThr.y, setPoi.uOcc); connect(greEquThr.y, setPoi1.uOcc); connect(swi1.y, setPoi.tNexOcc); connect(swi1.y, setPoi1.tNexOcc); end ModeAndSetPoints;