Buildings.Air.Systems.SingleZone.VAV.Examples.BaseClasses

Package with base classes for Buildings.Air.Systems.SingleZone.VAV.Examples

Information

This package contains base classes that are used to construct the models in Buildings.Air.Systems.SingleZone.VAV.Examples.

Extends from Modelica.Icons.BasesPackage (Icon for packages containing base classes).

Package Content

Name Description
Buildings.Air.Systems.SingleZone.VAV.Examples.BaseClasses.InternalLoads InternalLoads Schedule for time varying internal loads
Buildings.Air.Systems.SingleZone.VAV.Examples.BaseClasses.Room Room BESTest Case 600 with fluid ports for air HVAC and internal load

Buildings.Air.Systems.SingleZone.VAV.Examples.BaseClasses.InternalLoads Buildings.Air.Systems.SingleZone.VAV.Examples.BaseClasses.InternalLoads

Schedule for time varying internal loads

Buildings.Air.Systems.SingleZone.VAV.Examples.BaseClasses.InternalLoads

Information

Internal load profile for the thermal zone.

Extends from Modelica.Blocks.Sources.CombiTimeTable (Table look-up with respect to time and linear/periodic extrapolation methods (data from matrix/file)).

Parameters

TypeNameDefaultDescription
Table data definition
BooleantableOnFilefalse= true, if table is defined on file or in function usertab
Realtable[:, :][0, 0.1; 8*3600, 0.1; 8*3600...Table matrix (time = first column; e.g., table=[0,2])
StringtableName"NoName"Table name on file or in function usertab (see docu)
StringfileName"NoName"File where matrix is stored
BooleanverboseReadtrue= true, if info message that file is loading is to be printed
Table data interpretation
Integercolumns[:]{2}Columns of table to be interpolated
SmoothnesssmoothnessModelica.Blocks.Types.Smooth...Smoothness of table interpolation
ExtrapolationextrapolationModelica.Blocks.Types.Extrap...Extrapolation of data outside the definition range
Realoffset[:]{0}Offsets of output signals
TimestartTime0Output = offset for time < startTime [s]
TimetimeScale1Time scale of first table column [s]

Connectors

TypeNameDescription
output RealOutputy[nout]Connector of Real output signals

Modelica definition

model InternalLoads "Schedule for time varying internal loads" extends Modelica.Blocks.Sources.CombiTimeTable( extrapolation=Modelica.Blocks.Types.Extrapolation.Periodic, table=[0, 0.1; 8*3600, 0.1; 8*3600, 1.0; 18*3600, 1.0; 18*3600, 0.1; 24*3600, 0.1], columns={2}); end InternalLoads;

Buildings.Air.Systems.SingleZone.VAV.Examples.BaseClasses.Room Buildings.Air.Systems.SingleZone.VAV.Examples.BaseClasses.Room

BESTest Case 600 with fluid ports for air HVAC and internal load

Buildings.Air.Systems.SingleZone.VAV.Examples.BaseClasses.Room

Information

This is a single zone model based on the envelope of the BESTEST Case 600 building, though it has some modifications. Supply and return air ports are included for simulation with air-based HVAC systems. Heating and cooling setpoints and internal loads are time-varying according to an assumed occupancy schedule.

This zone model utilizes schedules and constructions from the Schedules and Constructions packages.

Parameters

TypeNameDefaultDescription
replaceable package MediumABuildings.Media.AirMedium model
MassFlowRatemAir_flow_nominal Design airflow rate of system [kg/s]
Anglelat Building latitude [rad]
AngleS_Buildings.Types.Azimuth.SAzimuth for south walls [rad]
AngleE_Buildings.Types.Azimuth.EAzimuth for east walls [rad]
AngleW_Buildings.Types.Azimuth.WAzimuth for west walls [rad]
AngleN_Buildings.Types.Azimuth.NAzimuth for north walls [rad]
AngleC_Buildings.Types.Tilt.CeilingTilt for ceiling [rad]
AngleF_Buildings.Types.Tilt.FloorTilt for floor [rad]
AngleZ_Buildings.Types.Tilt.WallTilt for wall [rad]
IntegernConExtWin1Number of constructions with a window
IntegernConBou1Number of surface that are connected to constructions that are modeled inside the room
GenericmatExtWal Exterior wall
GenericmatFlo Floor
Genericsoil Soil properties
Genericroof Roof
Win600window600 Window

Connectors

TypeNameDescription
replaceable package MediumAMedium model
FluidPort_asupplyAirSupply air
FluidPort_breturnAirReturn air
BusweaBusWeather data bus
output RealOutputTRooAirRoom air temperature

Modelica definition

model Room "BESTest Case 600 with fluid ports for air HVAC and internal load" replaceable package MediumA = Buildings.Media.Air "Medium model"; parameter Modelica.SIunits.MassFlowRate mAir_flow_nominal "Design airflow rate of system"; parameter Modelica.SIunits.Angle lat "Building latitude"; parameter Modelica.SIunits.Angle S_=Buildings.Types.Azimuth.S "Azimuth for south walls"; parameter Modelica.SIunits.Angle E_=Buildings.Types.Azimuth.E "Azimuth for east walls"; parameter Modelica.SIunits.Angle W_=Buildings.Types.Azimuth.W "Azimuth for west walls"; parameter Modelica.SIunits.Angle N_=Buildings.Types.Azimuth.N "Azimuth for north walls"; parameter Modelica.SIunits.Angle C_=Buildings.Types.Tilt.Ceiling "Tilt for ceiling"; parameter Modelica.SIunits.Angle F_=Buildings.Types.Tilt.Floor "Tilt for floor"; parameter Modelica.SIunits.Angle Z_=Buildings.Types.Tilt.Wall "Tilt for wall"; parameter Integer nConExtWin=1 "Number of constructions with a window"; parameter Integer nConBou=1 "Number of surface that are connected to constructions that are modeled inside the room"; parameter Buildings.HeatTransfer.Data.OpaqueConstructions.Generic matExtWal( nLay=3, absIR_a=0.9, absIR_b=0.9, absSol_a=0.6, absSol_b=0.6, material={Buildings.HeatTransfer.Data.Solids.Generic( x=0.009, k=0.140, c=900, d=530, nStaRef=Buildings.ThermalZones.Detailed.Validation.BESTEST.nStaRef), Buildings.HeatTransfer.Data.Solids.Generic( x=0.066, k=0.040, c=840, d=12, nStaRef=Buildings.ThermalZones.Detailed.Validation.BESTEST.nStaRef), Buildings.HeatTransfer.Data.Solids.Generic( x=0.012, k=0.160, c=840, d=950, nStaRef=Buildings.ThermalZones.Detailed.Validation.BESTEST.nStaRef)}) "Exterior wall"; parameter Buildings.HeatTransfer.Data.OpaqueConstructions.Generic matFlo( final nLay=2, absIR_a=0.9, absIR_b=0.9, absSol_a=0.6, absSol_b=0.6, material={Buildings.HeatTransfer.Data.Solids.Generic( x=1.003, k=0.040, c=0, d=0, nStaRef=Buildings.ThermalZones.Detailed.Validation.BESTEST.nStaRef), Buildings.HeatTransfer.Data.Solids.Generic( x=0.025, k=0.140, c=1200, d=650, nStaRef=Buildings.ThermalZones.Detailed.Validation.BESTEST.nStaRef)}) "Floor"; parameter Buildings.HeatTransfer.Data.Solids.Generic soil( x=2, k=1.3, c=800, d=1500) "Soil properties"; parameter Buildings.HeatTransfer.Data.OpaqueConstructions.Generic roof( nLay=3, absIR_a=0.9, absIR_b=0.9, absSol_a=0.6, absSol_b=0.6, material={Buildings.HeatTransfer.Data.Solids.Generic( x=0.019, k=0.140, c=900, d=530, nStaRef=Buildings.ThermalZones.Detailed.Validation.BESTEST.nStaRef), Buildings.HeatTransfer.Data.Solids.Generic( x=0.1118, k=0.040, c=840, d=12, nStaRef=Buildings.ThermalZones.Detailed.Validation.BESTEST.nStaRef), Buildings.HeatTransfer.Data.Solids.Generic( x=0.010, k=0.160, c=840, d=950, nStaRef=Buildings.ThermalZones.Detailed.Validation.BESTEST.nStaRef)}) "Roof"; parameter Buildings.ThermalZones.Detailed.Validation.BESTEST.Data.Win600 window600( UFra=3, haveExteriorShade=false, haveInteriorShade=false) "Window"; Buildings.HeatTransfer.Conduction.SingleLayer soi( A=48, material=soil, steadyStateInitial=true, stateAtSurface_a=false, stateAtSurface_b=true, T_a_start=283.15, T_b_start=283.75) "2 m deep soil (per definition on p.4 of ASHRAE 140-2007)"; Modelica.Fluid.Interfaces.FluidPort_a supplyAir(redeclare final package Medium = MediumA) "Supply air"; Modelica.Fluid.Interfaces.FluidPort_b returnAir(redeclare final package Medium = MediumA) "Return air"; Buildings.BoundaryConditions.WeatherData.Bus weaBus "Weather data bus"; Modelica.Blocks.Interfaces.RealOutput TRooAir "Room air temperature"; Buildings.ThermalZones.Detailed.MixedAir roo( redeclare package Medium = MediumA, nPorts=5, hRoo=2.7, nConExtWin=nConExtWin, nConBou=1, energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial, AFlo=48, datConBou( layers={matFlo}, each A=48, each til=F_), datConExt( layers={roof,matExtWal,matExtWal,matExtWal}, A={48,6*2.7,6*2.7,8*2.7}, til={C_,Z_,Z_,Z_}, azi={S_,W_,E_,N_}), nConExt=4, nConPar=0, nSurBou=0, datConExtWin( layers={matExtWal}, A={8*2.7}, glaSys={window600}, wWin={2*3}, hWin={2}, fFra={0.001}, til={Z_}, azi={S_}), massDynamics=Modelica.Fluid.Types.Dynamics.SteadyState, lat=lat, intConMod=Buildings.HeatTransfer.Types.InteriorConvection.Temperature, extConMod=Buildings.HeatTransfer.Types.ExteriorConvection.TemperatureWind, steadyStateWindow=false) "Room model for Case 600"; Modelica.Blocks.Sources.Constant qConGai_flow(k=192/48) "Convective heat gain"; Modelica.Blocks.Sources.Constant qRadGai_flow(k=288/48) "Radiative heat gain"; Modelica.Blocks.Routing.Multiplex3 mul "Multiplex"; Modelica.Blocks.Sources.Constant qLatGai_flow(k=96/48) "Latent heat gain"; Modelica.Thermal.HeatTransfer.Sources.FixedTemperature TSoi[nConBou](each T=283.15) "Boundary condition for construction"; Fluid.Sources.MassFlowSource_WeatherData sinInf( redeclare package Medium = MediumA, nPorts=1, use_m_flow_in=true) "Sink model for air infiltration"; Modelica.Blocks.Sources.Constant InfiltrationRate(k=48*2.7*0.5/3600) "0.41 ACH adjusted for the altitude (0.5 at sea level)"; Modelica.Blocks.Math.Product product; Buildings.Fluid.Sensors.Density density(redeclare package Medium = MediumA) "Air density inside the building"; Modelica.Thermal.HeatTransfer.Sensors.TemperatureSensor senTZon "Zone air temperature sensor"; Fluid.Sources.MassFlowSource_WeatherData souInf( redeclare package Medium = MediumA, use_m_flow_in=true, nPorts=1) "Source model for air infiltration"; Buildings.Air.Systems.SingleZone.VAV.Examples.BaseClasses.InternalLoads intLoad "Internal loads"; protected Modelica.Blocks.Math.Product pro1 "Product for internal gain"; Modelica.Blocks.Math.Product pro2 "Product for internal gain"; Modelica.Blocks.Math.Product pro3 "Product for internal gain"; Modelica.Blocks.Math.Gain gaiInf(final k=-1) "Gain for infiltration"; equation connect(mul.y, roo.qGai_flow); connect(density.port, roo.ports[1]); connect(density.d, product.u2); connect(TSoi[1].port, soi.port_a); connect(soi.port_b, roo.surf_conBou[1]); connect(sinInf.ports[1], roo.ports[2]); connect(weaBus, sinInf.weaBus); connect(weaBus, roo.weaBus); connect(senTZon.T, TRooAir); connect(senTZon.port, roo.heaPorAir); connect(qRadGai_flow.y, pro1.u1); connect(qLatGai_flow.y, pro2.u1); connect(qConGai_flow.y, pro3.u1); connect(intLoad.y[1], pro2.u2); connect(pro1.y, mul.u1[1]); connect(pro3.y, mul.u2[1]); connect(pro2.y, mul.u3[1]); connect(souInf.weaBus, weaBus); connect(souInf.ports[1], roo.ports[3]); connect(product.y, gaiInf.u); connect(gaiInf.y, souInf.m_flow_in); connect(product.y, sinInf.m_flow_in); connect(supplyAir, roo.ports[4]); connect(returnAir, roo.ports[5]); connect(InfiltrationRate.y, product.u1); connect(intLoad.y[1], pro1.u2); connect(pro3.u2, intLoad.y[1]); end Room;