Buildings.Applications.DataCenters.ChillerCooled.Equipment

Equipment models for chiller cooled data centers

Information

Package with equipment models for chiller cooled data centers.

Extends from Modelica.Icons.VariantsPackage (Icon for package containing variants).

Package Content

Name Description
Buildings.Applications.DataCenters.ChillerCooled.Equipment.CoolingCoilHumidifyingHeating CoolingCoilHumidifyingHeating  
Buildings.Applications.DataCenters.ChillerCooled.Equipment.ElectricChillerParallel ElectricChillerParallel Multiple identical electric chillers
Buildings.Applications.DataCenters.ChillerCooled.Equipment.ElectricHeater ElectricHeater Model for electric heater
Buildings.Applications.DataCenters.ChillerCooled.Equipment.FlowMachine_m FlowMachine_m Identical m_flow controlled pumps
Buildings.Applications.DataCenters.ChillerCooled.Equipment.FlowMachine_y FlowMachine_y Identical speed controlled flow machines
Buildings.Applications.DataCenters.ChillerCooled.Equipment.HeatExchanger_TSet HeatExchanger_TSet Heat exchanger
Buildings.Applications.DataCenters.ChillerCooled.Equipment.IntegratedPrimaryLoadSide IntegratedPrimaryLoadSide Integrated water-side economizer on the load side in a primary-only chilled water system
Buildings.Applications.DataCenters.ChillerCooled.Equipment.IntegratedPrimaryPlantSide IntegratedPrimaryPlantSide Integrated waterside economizer on the plant side in a primary-only chilled water System
Buildings.Applications.DataCenters.ChillerCooled.Equipment.IntegratedPrimarySecondary IntegratedPrimarySecondary Integrated waterside economizer on the load side in a primary-secondary chilled water system
Buildings.Applications.DataCenters.ChillerCooled.Equipment.NonIntegrated NonIntegrated Non-integrated waterside economizer in chilled water system
Buildings.Applications.DataCenters.ChillerCooled.Equipment.WatersideEconomizer WatersideEconomizer Waterside economizer
Buildings.Applications.DataCenters.ChillerCooled.Equipment.Validation Validation Collection of models that validate the Buildings.Applications.DataCenters.ChillerCooled package
Buildings.Applications.DataCenters.ChillerCooled.Equipment.BaseClasses BaseClasses Package with base classes for Buildings.Applications.DataCenters.ChillerCooled

Buildings.Applications.DataCenters.ChillerCooled.Equipment.CoolingCoilHumidifyingHeating Buildings.Applications.DataCenters.ChillerCooled.Equipment.CoolingCoilHumidifyingHeating


Buildings.Applications.DataCenters.ChillerCooled.Equipment.CoolingCoilHumidifyingHeating

Information

This model can represent a typical air handler with a cooling coil, a variable-speed fan, a humidifier and an electric reheater. The heating coil is not included in this model.

The water-side valve can be manipulated to control the outlet temperature on air side, as shown in Buildings.Applications.DataCenters.AHUs.Example.AirHandlingUnitControl.

It's usually undesired to control the outlet air temperature by simultenanously manipulating the water-valve and reheater, because energy waste could happen in this case. For example, under the part-load condition, the water valve might be in its maximum position with the reheater turning on to maintain the outlet air temperature. To avoid that water-valve and reheater control the outlet temperature at the same time, a buit-in reheater on/off controller is implemented. The detailed control logic about the reheater on/off control is shown in Buildings.Applications.DataCenters.ChillerCooled.Controls.Reheat.

The humidfier is an adiabatic spray air washer with a prescribed outlet water vapor mass fraction in kg/kg total air. During the humidification, the enthalpy remains constant. Details can be found in Buildings.Fluid.Humidifiers.SprayAirWasher_X. The humidifer can be turned off when the prescribed mass fraction is smaller than the current state at the outlet, for example, XSet=0.

Extends from Buildings.Applications.DataCenters.ChillerCooled.Equipment.BaseClasses.PartialCoolingCoilHumidifyingHeating (Partial AHU model ).

Parameters

TypeNameDefaultDescription
replaceable package Medium1PartialMediumMedium 1 in the component
replaceable package Medium2PartialMediumMedium 2 in the component
GenericperFanredeclare parameter Building...Performance data for the fan
RealyValSwi Switch point for valve signal [1]
RealyValDeaBan0.1Deadband for valve signal [1]
TemperatureDifferencedTSwi0Switch point for temperature difference [K]
TemperatureDifferencedTDeaBan0.5Deadband for temperature difference [K]
TimetWai60Waiting time [s]
Nominal condition
MassFlowRatem1_flow_nominal Nominal mass flow rate [kg/s]
MassFlowRatem2_flow_nominal Nominal mass flow rate [kg/s]
PressureDifferencedpValve_nominal Nominal pressure drop of fully open valve, used if CvData=Buildings.Fluid.Types.CvTypes.OpPoint [Pa]
PressureDifferencedp1_nominal Pressure difference [Pa]
PressureDifferencedp2_nominal Pressure difference [Pa]
Cooling coil
ThermalConductanceUA_nominal Thermal conductance at nominal flow for sensible heat, used to compute time constant [W/K]
Realr_nominal2/3Ratio between air-side and water-side convective heat transfer coefficient
Timetau120Time constant at nominal flow of medium 1 [s]
Timetau21Time constant at nominal flow of medium 2 [s]
Timetau_m20Time constant of metal at nominal UA value [s]
IntegernEle4Number of pipe segments used for discretization in the cooling coil
Flow Coefficient
CvTypesCvDataBuildings.Fluid.Types.CvType...Selection of flow coefficient
RealKv Kv (metric) flow coefficient [m3/h/(bar)^(1/2)]
RealCv Cv (US) flow coefficient [USG/min/(psi)^(1/2)]
AreaAv Av (metric) flow coefficient [m2]
Valve
Reall0.0001Valve leakage, l=Kv(y=0)/Kv(y=1)
RealkFixedm1_flow_nominal/sqrt(dp1_nom...Flow coefficient of fixed resistance that may be in series with valve, k=m_flow/sqrt(dp), with unit=(kg.m)^(1/2)
RealR50Rangeability, R=50...100 typically
Realdelta00.01Range of significant deviation from equal percentage law
Fan
InputTypeinputTypeBuildings.Fluid.Types.InputT...Control input type
BooleanaddPowerToMediumtrueSet to false to avoid any power (=heat and flow work) being added to medium (may give simpler equations)
Electric heater
EfficiencyetaHea1.0Efficiency of electrical heater [1]
HeatFlowRateQHeaMax_flow Nominal heating capacity of eletric heater,positive [W]
Humidifier
MassFlowRatemWatMax_flow Nominal humidification capacity for humidifier, positive for humidification [kg/s]
TemperatureTHum293.15Temperature of water that is added to the fluid stream by the humidifier [K]
Assumptions
BooleanallowFlowReversal1true= false to simplify equations, assuming, but not enforcing, no flow reversal for medium 1
BooleanallowFlowReversal2true= false to simplify equations, assuming, but not enforcing, no flow reversal for medium 2
Advanced
MassFlowRatem1_flow_small1E-4*abs(m1_flow_nominal)Small mass flow rate for regularization of zero flow [kg/s]
MassFlowRatem2_flow_small1E-4*abs(m2_flow_nominal)Small mass flow rate for regularization of zero flow [kg/s]
Dynamics
Equations
DynamicsenergyDynamicsModelica.Fluid.Types.Dynamic...Type of energy balance: dynamic (3 initialization options) or steady state
DynamicsmassDynamicsenergyDynamicsType of mass balance: dynamic (3 initialization options) or steady state
Valve
Booleanuse_inputFilterValvetrue= true, if opening is filtered with a 2nd order CriticalDamping filter for the water-side valve
TimeriseTimeValve120Rise time of the filter for the water-side valve (time to reach 99.6 % of an opening step) [s]
InitinitValveModelica.Blocks.Types.Init.I...Type of initialization (no init/steady state/initial state/initial output)
RealyValve_start1Initial value of output
Fan
TimetauFan1Time constant at nominal flow (if energyDynamics <> SteadyState) [s]
Booleanuse_inputFilterFantrue= true, if speed is filtered with a 2nd order CriticalDamping filter
TimeriseTimeFan30Rise time of the filter (time to reach 99.6 % of the speed) [s]
InitinitFanModelica.Blocks.Types.Init.I...Type of initialization (no init/steady state/initial state/initial output)
RealyFan_start0Initial value of speed [1]
Electric heater
TimetauEleHea10Time constant at nominal flow for electric heater (if energyDynamics <> SteadyState) [s]
Humidifier
TimetauHum10Time constant at nominal flow for humidifier(if energyDynamics <> SteadyState) [s]
Flow resistance
Medium 1
Booleanfrom_dp1false= true, use m_flow = f(dp) else dp = f(m_flow)
BooleanlinearizeFlowResistance1false= true, use linear relation between m_flow and dp for any flow rate
RealdeltaM10.1Fraction of nominal flow rate where flow transitions to laminar
Medium 2
Booleanfrom_dp2false= true, use m_flow = f(dp) else dp = f(m_flow)
BooleanlinearizeFlowResistance2false= true, use linear relation between m_flow and dp for any flow rate
RealdeltaM20.1Fraction of nominal flow rate where flow transitions to laminar
Heat transfer
Cooling coil
BooleanwaterSideFlowDependenttrueSet to false to make water-side hA independent of mass flow rate
BooleanairSideFlowDependenttrueSet to false to make air-side hA independent of mass flow rate
BooleanwaterSideTemperatureDependentfalseSet to false to make water-side hA independent of temperature
BooleanairSideTemperatureDependentfalseSet to false to make air-side hA independent of temperature
Initialization
AbsolutePressurep_startMedium2.p_defaultStart value of pressure [Pa]
TemperatureT_startMedium2.T_defaultStart value of temperature [K]
MassFractionX_start[Medium2.nX]Medium2.X_defaultStart value of mass fractions m_i/m [kg/kg]
ExtraPropertyC_start[Medium2.nC]fill(0, Medium2.nC)Start value of trace substances
ExtraPropertyC_nominal[Medium2.nC]fill(1E-2, Medium2.nC)Nominal value of trace substances. (Set to typical order of magnitude.)

Connectors

TypeNameDescription
FluidPort_aport_a1Fluid connector a1 (positive design flow direction is from port_a1 to port_b1)
FluidPort_bport_b1Fluid connector b1 (positive design flow direction is from port_a1 to port_b1)
FluidPort_aport_a2Fluid connector a2 (positive design flow direction is from port_a2 to port_b2)
FluidPort_bport_b2Fluid connector b2 (positive design flow direction is from port_a2 to port_b2)
input RealInputuValActuator position (0: closed, 1: open) on water side [1]
input RealInputuFanContinuous input signal for the fan
output RealOutputPFanElectrical power consumed by the fan [W]
output RealOutputyValActual valve position [1]
input IntegerInputstageStage input signal for the pressure head
output RealOutputPHeaPower consumed by electric heater [W]
input RealInputTSetSet point temperature of the fluid that leaves port_b [K]
input RealInputXSet_wSet point for water vapor mass fraction in kg/kg total air of the fluid that leaves port_b [1]

Modelica definition

model CoolingCoilHumidifyingHeating extends Buildings.Applications.DataCenters.ChillerCooled.Equipment.BaseClasses.PartialCoolingCoilHumidifyingHeating ( redeclare Buildings.Fluid.Actuators.Valves.TwoWayEqualPercentage watVal( final R=R, final delta0=delta0), redeclare final Buildings.Fluid.Movers.SpeedControlled_y fan); // Parameters for water-side valve parameter Real R=50 "Rangeability, R=50...100 typically"; parameter Real delta0=0.01 "Range of significant deviation from equal percentage law"; // Parameters for electric heater parameter Modelica.SIunits.Time tauEleHea = 10 "Time constant at nominal flow for electric heater (if energyDynamics <> SteadyState)"; parameter Modelica.SIunits.Efficiency etaHea = 1.0 "Efficiency of electrical heater"; parameter Modelica.SIunits.HeatFlowRate QHeaMax_flow(min=0) "Nominal heating capacity of eletric heater,positive"; // Parameters for humidifier parameter Modelica.SIunits.MassFlowRate mWatMax_flow(min=0) "Nominal humidification capacity for humidifier, positive for humidification"; parameter Modelica.SIunits.Temperature THum = 293.15 "Temperature of water that is added to the fluid stream by the humidifier"; parameter Modelica.SIunits.Time tauHum = 10 "Time constant at nominal flow for humidifier(if energyDynamics <> SteadyState)"; // parameters for heater controller parameter Real yValSwi(min=0, max=1, unit="1") "Switch point for valve signal"; parameter Real yValDeaBan(min=0, max=1, unit="1")=0.1 "Deadband for valve signal"; parameter Modelica.SIunits.TemperatureDifference dTSwi=0 "Switch point for temperature difference"; parameter Modelica.SIunits.TemperatureDifference dTDeaBan=0.5 "Deadband for temperature difference"; parameter Modelica.SIunits.Time tWai=60 "Waiting time"; Modelica.Blocks.Interfaces.RealOutput PHea( final unit = "W", final quantity = "Power") "Power consumed by electric heater"; Modelica.Blocks.Interfaces.RealInput TSet( final unit = "K", final quantity = "ThermodynamicTemperature") "Set point temperature of the fluid that leaves port_b"; Modelica.Blocks.Interfaces.RealInput XSet_w( final unit = "1", final quantity = "MassFraction", min = 0, max = 0.03) "Set point for water vapor mass fraction in kg/kg total air of the fluid that leaves port_b"; Modelica.Blocks.Sources.RealExpression dT(y(final unit="K")=T_inflow_hea - TSet) "Difference between inlet temperature and temperature setpoint of the reheater"; Buildings.Fluid.Humidifiers.SprayAirWasher_X hum( redeclare final package Medium = Medium2, final allowFlowReversal=allowFlowReversal2, final m_flow_small=m2_flow_small, final show_T=show_T, final massDynamics=massDynamics, final tau=tauHum, final homotopyInitialization=homotopyInitialization, final dp_nominal=0, final m_flow_nominal=m2_flow_nominal, final mWatMax_flow=mWatMax_flow, final X_start=X_start, final from_dp=from_dp2, final linearizeFlowResistance=linearizeFlowResistance2, final deltaM=deltaM2) "Humidifier"; Buildings.Applications.DataCenters.ChillerCooled.Equipment.ElectricHeater eleHea( redeclare final package Medium = Medium2, final allowFlowReversal=allowFlowReversal2, final show_T=show_T, final m_flow_small=m2_flow_small, final energyDynamics=energyDynamics, final tau=tauEleHea, final homotopyInitialization=homotopyInitialization, final dp_nominal=0, final QMax_flow=QHeaMax_flow, final eta=etaHea, final m_flow_nominal=m2_flow_nominal, final T_start=T_start, final from_dp=from_dp2, final linearizeFlowResistance=linearizeFlowResistance2, final deltaM=deltaM2) "Electric heater"; Buildings.Applications.DataCenters.ChillerCooled.Controls.Reheat heaCon( final yValSwi=yValSwi, final yValDeaBan=yValDeaBan, final dTSwi=dTSwi, final dTDeaBan=dTDeaBan, final tWai=tWai) "Reheater on/off controller"; protected Medium2.Temperature T_inflow_hea= Medium2.temperature(state=Medium2.setState_phX(port_b2.p, noEvent(actualStream(port_b2.h_outflow)), noEvent(actualStream(port_b2.Xi_outflow)))) "Temperature of inflowing fluid at port_a of reheater"; equation connect(TSet, eleHea.TSet); connect(XSet_w, hum.X_w); connect(fan.port_a, eleHea.port_b); connect(eleHea.port_a, hum.port_b); connect(hum.port_a, cooCoi.port_b2); connect(eleHea.P, PHea); connect(uFan,fan.y); connect(heaCon.y, eleHea.on); connect(dT.y, heaCon.dT); connect(heaCon.yVal, watVal.y_actual); end CoolingCoilHumidifyingHeating;

Buildings.Applications.DataCenters.ChillerCooled.Equipment.ElectricChillerParallel Buildings.Applications.DataCenters.ChillerCooled.Equipment.ElectricChillerParallel

Multiple identical electric chillers

Buildings.Applications.DataCenters.ChillerCooled.Equipment.ElectricChillerParallel

Information

This model implements a chiller parallel with num identical chillers. For the chiller model please see Buildings.Fluid.Chillers.ElectricEIR.

Note that although the chillers have identical nominal conditions, they can have different performance curves specified in performance data per.

Extends from Buildings.Applications.DataCenters.ChillerCooled.Equipment.BaseClasses.PartialParallelElectricEIR (Partial model for electric chiller parallel).

Parameters

TypeNameDefaultDescription
replaceable package Medium1PartialMediumMedium 1 in the component
replaceable package Medium2PartialMediumMedium 2 in the component
Integernum2Number of equipment
Genericper[num]redeclare parameter Building...Performance data
Nominal condition
MassFlowRatem1_flow_nominal Nominal mass flow rate [kg/s]
MassFlowRatem2_flow_nominal Nominal mass flow rate [kg/s]
PressureDifferencedp1_nominal Pressure difference [Pa]
PressureDifferencedp2_nominal Pressure difference [Pa]
Two-way valve
CvTypesCvDataBuildings.Fluid.Types.CvType...Selection of flow coefficient
RealKv[numVal] Kv (metric) flow coefficient [m3/h/(bar)^(1/2)]
RealCv[numVal] Cv (US) flow coefficient [USG/min/(psi)^(1/2)]
AreaAv[numVal] Av (metric) flow coefficient [m2]
PressureDifferencedpValve_nominal[numVal]fill(6000, numVal)Nominal pressure drop of fully open valve, used if CvData=Buildings.Fluid.Types.CvTypes.OpPoint [Pa]
Reall[2]{0.0001,0.0001}Valve leakage, l=Kv(y=0)/Kv(y=1)
RealkFixed[2]{m1_flow_nominal,m2_flow_nom...Flow coefficient of fixed resistance that may be in series with valve 1, k=m_flow/sqrt(dp), with unit=(kg.m)^(1/2).
Assumptions
BooleanallowFlowReversal1true= false to simplify equations, assuming, but not enforcing, no flow reversal for medium 1
BooleanallowFlowReversal2true= false to simplify equations, assuming, but not enforcing, no flow reversal for medium 2
Advanced
MassFlowRatem1_flow_small1E-4*abs(m1_flow_nominal)Small mass flow rate for regularization of zero flow [kg/s]
MassFlowRatem2_flow_small1E-4*abs(m2_flow_nominal)Small mass flow rate for regularization of zero flow [kg/s]
Diagnostics
Booleanshow_Tfalse= true, if actual temperature at port is computed
Two-way valve
DensityrhoStd[numVal]{Medium1.density_pTX(101325,...Inlet density for which valve coefficients are defined [kg/m3]
Flow resistance
Medium 1
Booleanfrom_dp1false= true, use m_flow = f(dp) else dp = f(m_flow)
BooleanlinearizeFlowResistance1false= true, use linear relation between m_flow and dp for any flow rate
RealdeltaM10.1Fraction of nominal flow rate where flow transitions to laminar
Medium 2
Booleanfrom_dp2false= true, use m_flow = f(dp) else dp = f(m_flow)
BooleanlinearizeFlowResistance2false= true, use linear relation between m_flow and dp for any flow rate
RealdeltaM20.1Fraction of nominal flow rate where flow transitions to laminar
Dynamics
Filtered opening
Booleanuse_inputFiltertrue= true, if opening is filtered with a 2nd order CriticalDamping filter
TimeriseTimeValve120Rise time of the filter (time to reach 99.6 % of an opening step) [s]
InitinitValveModelica.Blocks.Types.Init.I...Type of initialization (no init/steady state/initial state/initial output)
RealyValve_start[numFil]fill(1, numFil)Initial value of output:0-closed, 1-fully opened
Nominal condition
Timetau130Time constant at nominal flow in chillers [s]
Timetau230Time constant at nominal flow in chillers [s]
Equations
DynamicsenergyDynamicsModelica.Fluid.Types.Dynamic...Type of energy balance: dynamic (3 initialization options) or steady state
DynamicsmassDynamicsenergyDynamicsType of mass balance: dynamic (3 initialization options) or steady state
Initialization
Medium 1
AbsolutePressurep1_startMedium1.p_defaultStart value of pressure [Pa]
TemperatureT1_startMedium1.T_defaultStart value of temperature [K]
MassFractionX1_start[Medium1.nX]Medium1.X_defaultStart value of mass fractions m_i/m [kg/kg]
ExtraPropertyC1_start[Medium1.nC]fill(0, Medium1.nC)Start value of trace substances
ExtraPropertyC1_nominal[Medium1.nC]fill(1E-2, Medium1.nC)Nominal value of trace substances. (Set to typical order of magnitude.)
Medium 2
AbsolutePressurep2_startMedium2.p_defaultStart value of pressure [Pa]
TemperatureT2_startMedium2.T_defaultStart value of temperature [K]
MassFractionX2_start[Medium2.nX]Medium2.X_defaultStart value of mass fractions m_i/m [kg/kg]
ExtraPropertyC2_start[Medium2.nC]fill(0, Medium2.nC)Start value of trace substances
ExtraPropertyC2_nominal[Medium2.nC]fill(1E-2, Medium2.nC)Nominal value of trace substances. (Set to typical order of magnitude.)

Connectors

TypeNameDescription
FluidPort_aport_a1Fluid connector a1 (positive design flow direction is from port_a1 to port_b1)
FluidPort_bport_b1Fluid connector b1 (positive design flow direction is from port_a1 to port_b1)
FluidPort_aport_a2Fluid connector a2 (positive design flow direction is from port_a2 to port_b2)
FluidPort_bport_b2Fluid connector b2 (positive design flow direction is from port_a2 to port_b2)
input BooleanInputon[num]Set to true to enable equipment, or false to disable equipment
input RealInputTSetSet point for leaving water temperature [K]
output RealOutputP[num]Electric power consumed by chiller compressor [W]

Modelica definition

model ElectricChillerParallel "Multiple identical electric chillers" extends Buildings.Applications.DataCenters.ChillerCooled.Equipment.BaseClasses.PartialParallelElectricEIR ( redeclare final Buildings.Fluid.Chillers.ElectricEIR chi[num]( final per=per)); replaceable parameter Buildings.Fluid.Chillers.Data.ElectricEIR.Generic per[num] "Performance data"; end ElectricChillerParallel;

Buildings.Applications.DataCenters.ChillerCooled.Equipment.ElectricHeater Buildings.Applications.DataCenters.ChillerCooled.Equipment.ElectricHeater

Model for electric heater

Buildings.Applications.DataCenters.ChillerCooled.Equipment.ElectricHeater

Information

Model for an ideal heater that controls its outlet temperature to a prescribed outlet temperature with constant efficiency.

The switch model swi is used to turn on/off the heater.

Extends from Buildings.Fluid.Interfaces.PartialTwoPortInterface (Partial model transporting fluid between two ports without storing mass or energy), Buildings.Fluid.Interfaces.TwoPortFlowResistanceParameters (Parameters for flow resistance for models with two ports).

Parameters

TypeNameDefaultDescription
replaceable package MediumPartialMediumMedium in the component
Efficiencyeta1Effciency of electrical heater [1]
HeatFlowRateQMax_flowModelica.Constants.infMaximum heat flow rate for heating (positive) [W]
Nominal condition
MassFlowRatem_flow_nominal Nominal mass flow rate [kg/s]
PressureDifferencedp_nominal Pressure difference [Pa]
Assumptions
BooleanallowFlowReversaltrue= false to simplify equations, assuming, but not enforcing, no flow reversal
Advanced
MassFlowRatem_flow_small1E-4*abs(m_flow_nominal)Small mass flow rate for regularization of zero flow [kg/s]
Diagnostics
Booleanshow_Tfalse= true, if actual temperature at port is computed
Flow resistance
BooleancomputeFlowResistance(abs(dp_nominal) > Modelica....=true, compute flow resistance. Set to false to assume no friction
Booleanfrom_dpfalse= true, use m_flow = f(dp) else dp = f(m_flow)
BooleanlinearizeFlowResistancefalse= true, use linear relation between m_flow and dp for any flow rate
RealdeltaM0.1Fraction of nominal flow rate where flow transitions to laminar
Initialization
TemperatureT_startMedium.T_defaultStart value of temperature [K]
Dynamics
Equations
DynamicsenergyDynamicsModelica.Fluid.Types.Dynamic...Type of energy balance: dynamic (3 initialization options) or steady state
Timetau10Time constant at nominal flow rate (used if energyDynamics or massDynamics not equal Modelica.Fluid.Types.Dynamics.SteadyState) [s]

Connectors

TypeNameDescription
FluidPort_aport_aFluid connector a (positive design flow direction is from port_a to port_b)
FluidPort_bport_bFluid connector b (positive design flow direction is from port_a to port_b)
output RealOutputQ_flowHeat flow rate added to the fluid (if flow is from port_a to port_b) [W]
output RealOutputPElectrical power consumed [W]
input BooleanInputonSet to true to enable heater, or false to disable heater
input RealInputTSetSet point temperature of the fluid that leaves port_b [K]

Modelica definition

model ElectricHeater "Model for electric heater" extends Buildings.Fluid.Interfaces.PartialTwoPortInterface; extends Buildings.Fluid.Interfaces.TwoPortFlowResistanceParameters( final computeFlowResistance=(abs(dp_nominal) > Modelica.Constants.eps)); constant Boolean homotopyInitialization = true "= true, use homotopy method"; parameter Modelica.SIunits.Efficiency eta(max=1) = 1 "Effciency of electrical heater"; parameter Modelica.SIunits.HeatFlowRate QMax_flow(min=0) = Modelica.Constants.inf "Maximum heat flow rate for heating (positive)"; parameter Modelica.SIunits.Temperature T_start=Medium.T_default "Start value of temperature"; // Dynamics parameter Modelica.Fluid.Types.Dynamics energyDynamics=Modelica.Fluid.Types.Dynamics.SteadyState "Type of energy balance: dynamic (3 initialization options) or steady state"; parameter Modelica.SIunits.Time tau(min=0) = 10 "Time constant at nominal flow rate (used if energyDynamics or massDynamics not equal Modelica.Fluid.Types.Dynamics.SteadyState)"; Modelica.Blocks.Interfaces.RealOutput Q_flow( final quantity="HeatFlowRate", final unit="W") "Heat flow rate added to the fluid (if flow is from port_a to port_b)"; Modelica.Blocks.Interfaces.RealOutput P( final quantity="Power", final unit="W") "Electrical power consumed"; Modelica.Blocks.Interfaces.BooleanInput on "Set to true to enable heater, or false to disable heater"; Modelica.Blocks.Interfaces.RealInput TSet( final unit="K", final quantity = "ThermodynamicTemperature", displayUnit="degC") "Set point temperature of the fluid that leaves port_b"; Buildings.Fluid.HeatExchangers.Heater_T hea( final energyDynamics=energyDynamics, final T_start=T_start, final tau=tau, final from_dp=from_dp, final linearizeFlowResistance=linearizeFlowResistance, final deltaM=deltaM, final m_flow_small=m_flow_small, final show_T=show_T, final homotopyInitialization=homotopyInitialization, final allowFlowReversal=allowFlowReversal, redeclare package Medium = Medium, final m_flow_nominal=m_flow_nominal, final dp_nominal=dp_nominal, final QMax_flow=QMax_flow) "Heater with prescribed temperature"; Modelica.Blocks.Math.Gain gaiEff(final k=1/eta) "Gain for efficiency"; protected Modelica.Blocks.Logical.Switch swi "Switch for temperature setpoint"; Modelica.Blocks.Sources.Constant zer(final k=-273.15) "Zero signal"; initial equation assert(homotopyInitialization, "In " + getInstanceName() + ": The constant homotopyInitialization has been modified from its default value. This constant will be removed in future releases.", level = AssertionLevel.warning); equation connect(port_a, hea.port_a); connect(hea.port_b, port_b); connect(hea.Q_flow, Q_flow); connect(on, swi.u2); connect(swi.y, hea.TSet); connect(TSet, swi.u1); connect(zer.y, swi.u3); connect(hea.Q_flow, gaiEff.u); connect(gaiEff.y, P); end ElectricHeater;

Buildings.Applications.DataCenters.ChillerCooled.Equipment.FlowMachine_m Buildings.Applications.DataCenters.ChillerCooled.Equipment.FlowMachine_m

Identical m_flow controlled pumps

Buildings.Applications.DataCenters.ChillerCooled.Equipment.FlowMachine_m

Information

This model implements a parallel of identical pumps with m_flow being controlled. The number can be specified by setting a value of num. The shutoff valves are used to avoid circulating flow among pumps.

Extends from Buildings.Applications.DataCenters.ChillerCooled.Equipment.BaseClasses.PartialPumpParallel (Partial model for pump parallel).

Parameters

TypeNameDefaultDescription
replaceable package MediumPartialMediumMedium in the component
Genericper[num]redeclare parameter Building...Record with performance data
Integernum2The number of pumps
Realthreshold0.05Hysteresis threshold
Nominal condition
MassFlowRatem_flow_nominal Nominal mass flow rate [kg/s]
PressureDifferencedpValve_nominal Nominal pressure drop of fully open valve, used if CvData=Buildings.Fluid.Types.CvTypes.OpPoint [Pa]
Flow Coefficient
CvTypesCvDataBuildings.Fluid.Types.CvType...Selection of flow coefficient
RealKv Kv (metric) flow coefficient [m3/h/(bar)^(1/2)]
RealCv Cv (US) flow coefficient [USG/min/(psi)^(1/2)]
AreaAv Av (metric) flow coefficient [m2]
Pressure-flow linearization
RealdeltaM0.02Fraction of nominal flow rate where linearization starts, if y=1
Pump
BooleanaddPowerToMediumfalseSet to false to avoid any power (=heat and flow work) being added to medium (may give simpler equations)
Two-way valve
Reall0.0001Valve leakage, l=Kv(y=0)/Kv(y=1)
RealkFixedm_flow_nominal/sqrt(dpValve_...Flow coefficient of fixed resistance that may be in series with valve, k=m_flow/sqrt(dp), with unit=(kg.m)^(1/2).
Assumptions
BooleanallowFlowReversaltrue= false to simplify equations, assuming, but not enforcing, no flow reversal
Advanced
MassFlowRatem_flow_small1E-4*abs(m_flow_nominal)Small mass flow rate for regularization of zero flow [kg/s]
Diagnostics
Booleanshow_Tfalse= true, if actual temperature at port is computed
Nominal condition
DensityrhoStdMedium.density_pTX(101325, 2...Inlet density for which valve coefficients are defined [kg/m3]
Dynamics
Pump
Timetau1Time constant at nominal flow (if energyDynamics <> SteadyState) [s]
Booleanuse_inputFiltertrue= true, if speed is filtered with a 2nd order CriticalDamping filter
TimeriseTimePump30Rise time of the filter (time to reach 99.6 % of the speed) [s]
InitinitModelica.Blocks.Types.Init.I...Type of initialization (no init/steady state/initial state/initial output)
RealyPump_start[num]fill(0, num)Initial value of pump signals
Valve
TimeriseTimeValve120Rise time of the filter (time to reach 99.6 % of the speed) [s]
RealyValve_start[num]fill(0, num)Initial value of pump signals
Equations
DynamicsenergyDynamicsModelica.Fluid.Types.Dynamic...Type of energy balance: dynamic (3 initialization options) or steady state
DynamicsmassDynamicsenergyDynamicsType of mass balance: dynamic (3 initialization options) or steady state
Initialization
AbsolutePressurep_startMedium.p_defaultStart value of pressure [Pa]
TemperatureT_startMedium.T_defaultStart value of temperature [K]
MassFractionX_start[Medium.nX]Medium.X_defaultStart value of mass fractions m_i/m [kg/kg]
ExtraPropertyC_start[Medium.nC]fill(0, Medium.nC)Start value of trace substances
ExtraPropertyC_nominal[Medium.nC]fill(1E-2, Medium.nC)Nominal value of trace substances. (Set to typical order of magnitude.)
Flow resistance
Booleanfrom_dpfalse= true, use m_flow = f(dp) else dp = f(m_flow)
BooleanlinearizeFlowResistancefalse= true, use linear relation between m_flow and dp for any flow rate

Connectors

TypeNameDescription
FluidPort_aport_aFluid connector a (positive design flow direction is from port_a to port_b)
FluidPort_bport_bFluid connector b (positive design flow direction is from port_a to port_b)
input RealInputu[num]Continuous input signal for the flow machine [1]
output RealOutputP[num]Electrical power consumed by the pumps [W]

Modelica definition

model FlowMachine_m "Identical m_flow controlled pumps" extends Buildings.Applications.DataCenters.ChillerCooled.Equipment.BaseClasses.PartialPumpParallel ( redeclare final Buildings.Fluid.Movers.FlowControlled_m_flow pum( each final m_flow_nominal = m_flow_nominal, final m_flow_start=yPump_start*m_flow_nominal), rhoStd=Medium.density_pTX(101325, 273.15+4, Medium.X_default)); Modelica.Blocks.Math.Gain gaiM_flow[num](each final k=m_flow_nominal) "Gain for mass flow rate"; equation connect(gaiM_flow.y, pum.m_flow_in); connect(gaiM_flow.u, u); end FlowMachine_m;

Buildings.Applications.DataCenters.ChillerCooled.Equipment.FlowMachine_y Buildings.Applications.DataCenters.ChillerCooled.Equipment.FlowMachine_y

Identical speed controlled flow machines

Buildings.Applications.DataCenters.ChillerCooled.Equipment.FlowMachine_y

Information

This model implements a parallel of identical pumps with speed being controlled. The number can be specified by setting a value of num. The shutoff valves are used to avoid circulating flow among pumps.

Extends from Buildings.Applications.DataCenters.ChillerCooled.Equipment.BaseClasses.PartialPumpParallel (Partial model for pump parallel).

Parameters

TypeNameDefaultDescription
replaceable package MediumPartialMediumMedium in the component
Genericper[num]redeclare parameter Building...Record with performance data
Integernum2The number of pumps
Realthreshold0.05Hysteresis threshold
Nominal condition
MassFlowRatem_flow_nominal Nominal mass flow rate [kg/s]
PressureDifferencedpValve_nominal Nominal pressure drop of fully open valve, used if CvData=Buildings.Fluid.Types.CvTypes.OpPoint [Pa]
Flow Coefficient
CvTypesCvDataBuildings.Fluid.Types.CvType...Selection of flow coefficient
RealKv Kv (metric) flow coefficient [m3/h/(bar)^(1/2)]
RealCv Cv (US) flow coefficient [USG/min/(psi)^(1/2)]
AreaAv Av (metric) flow coefficient [m2]
Pressure-flow linearization
RealdeltaM0.02Fraction of nominal flow rate where linearization starts, if y=1
Pump
BooleanaddPowerToMediumfalseSet to false to avoid any power (=heat and flow work) being added to medium (may give simpler equations)
Two-way valve
Reall0.0001Valve leakage, l=Kv(y=0)/Kv(y=1)
RealkFixedm_flow_nominal/sqrt(dpValve_...Flow coefficient of fixed resistance that may be in series with valve, k=m_flow/sqrt(dp), with unit=(kg.m)^(1/2).
Assumptions
BooleanallowFlowReversaltrue= false to simplify equations, assuming, but not enforcing, no flow reversal
Advanced
MassFlowRatem_flow_small1E-4*abs(m_flow_nominal)Small mass flow rate for regularization of zero flow [kg/s]
Diagnostics
Booleanshow_Tfalse= true, if actual temperature at port is computed
Nominal condition
DensityrhoStdMedium.density_pTX(101325, 2...Inlet density for which valve coefficients are defined [kg/m3]
Dynamics
Pump
Timetau1Time constant at nominal flow (if energyDynamics <> SteadyState) [s]
Booleanuse_inputFiltertrue= true, if speed is filtered with a 2nd order CriticalDamping filter
TimeriseTimePump30Rise time of the filter (time to reach 99.6 % of the speed) [s]
InitinitModelica.Blocks.Types.Init.I...Type of initialization (no init/steady state/initial state/initial output)
RealyPump_start[num]fill(0, num)Initial value of pump signals
Valve
TimeriseTimeValve120Rise time of the filter (time to reach 99.6 % of the speed) [s]
RealyValve_start[num]fill(0, num)Initial value of pump signals
Equations
DynamicsenergyDynamicsModelica.Fluid.Types.Dynamic...Type of energy balance: dynamic (3 initialization options) or steady state
DynamicsmassDynamicsenergyDynamicsType of mass balance: dynamic (3 initialization options) or steady state
Initialization
AbsolutePressurep_startMedium.p_defaultStart value of pressure [Pa]
TemperatureT_startMedium.T_defaultStart value of temperature [K]
MassFractionX_start[Medium.nX]Medium.X_defaultStart value of mass fractions m_i/m [kg/kg]
ExtraPropertyC_start[Medium.nC]fill(0, Medium.nC)Start value of trace substances
ExtraPropertyC_nominal[Medium.nC]fill(1E-2, Medium.nC)Nominal value of trace substances. (Set to typical order of magnitude.)
Flow resistance
Booleanfrom_dpfalse= true, use m_flow = f(dp) else dp = f(m_flow)
BooleanlinearizeFlowResistancefalse= true, use linear relation between m_flow and dp for any flow rate

Connectors

TypeNameDescription
FluidPort_aport_aFluid connector a (positive design flow direction is from port_a to port_b)
FluidPort_bport_bFluid connector b (positive design flow direction is from port_a to port_b)
input RealInputu[num]Continuous input signal for the flow machine [1]
output RealOutputP[num]Electrical power consumed by the pumps [W]

Modelica definition

model FlowMachine_y "Identical speed controlled flow machines" extends Buildings.Applications.DataCenters.ChillerCooled.Equipment.BaseClasses.PartialPumpParallel ( redeclare final Buildings.Fluid.Movers.SpeedControlled_y pum, rhoStd=Medium.density_pTX(101325, 273.15+4, Medium.X_default)); equation connect(u, pum.y); end FlowMachine_y;

Buildings.Applications.DataCenters.ChillerCooled.Equipment.HeatExchanger_TSet Buildings.Applications.DataCenters.ChillerCooled.Equipment.HeatExchanger_TSet

Heat exchanger

Buildings.Applications.DataCenters.ChillerCooled.Equipment.HeatExchanger_TSet

Information

This module impliments a heat exchanger model with a built-in PID controller to control the outlet temperature at port_b2 if set parameter use_controller=true . Otherwise, if set use_controller=false, the PID controller and the three-way valve are removed and the outlet temperature at port_b2 will not be controlled.

Note that if the three-way valve is activated, it'll have the same differential pressure as the heat exchanger.

Extends from Buildings.Applications.DataCenters.ChillerCooled.Equipment.BaseClasses.PartialHeatExchanger (Partial model for heat exchangers ), Buildings.Applications.DataCenters.ChillerCooled.Equipment.BaseClasses.PartialControllerInterface (Partial interface model for waterside economizer temperature controller).

Parameters

TypeNameDefaultDescription
replaceable package Medium1PartialMediumMedium 1 in the component
replaceable package Medium2PartialMediumMedium 2 in the component
Booleanactivate_ThrWayValuse_controllerActivate the use of three-way valve: True-use three-way valve; False-not use the three-way valve
Efficiencyeta constant effectiveness [1]
Booleanuse_controllertrueSet to ture if the built-in controller is enabled to maintain the outlet temperature on the load side of a heat exchanger
Nominal condition
MassFlowRatem1_flow_nominal Nominal mass flow rate [kg/s]
MassFlowRatem2_flow_nominal Nominal mass flow rate [kg/s]
PressureDifferencedp1_nominal Pressure difference [Pa]
PressureDifferencedp2_nominal Pressure difference [Pa]
Three-way Valve
RealfraK_ThrWayVal0.7Fraction Kv(port_3&rarr;port_2)/Kv(port_1&rarr;port_2)for the three-way valve
Reall_ThrWayVal[2]{0.0001,0.0001}Bypass valve leakage, l=Kv(y=0)/Kv(y=1)
RealR50Rangeability, R=50...100 typically for the three-way valve
Realdelta00.01Range of significant deviation from equal percentage law for the three-way valve
Assumptions
BooleanallowFlowReversal1true= false to simplify equations, assuming, but not enforcing, no flow reversal for medium 1
BooleanallowFlowReversal2true= false to simplify equations, assuming, but not enforcing, no flow reversal for medium 2
Advanced
MassFlowRatem1_flow_small1E-4*abs(m1_flow_nominal)Small mass flow rate for regularization of zero flow [kg/s]
MassFlowRatem2_flow_small1E-4*abs(m2_flow_nominal)Small mass flow rate for regularization of zero flow [kg/s]
PortFlowDirectionportFlowDirection_1Modelica.Fluid.Types.PortFlo...Flow direction for port_1 in the three-way valve
PortFlowDirectionportFlowDirection_2Modelica.Fluid.Types.PortFlo...Flow direction for port_2 in the three-way valve
PortFlowDirectionportFlowDirection_3Modelica.Fluid.Types.PortFlo...Flow direction for port_3 in the three-way valve
Diagnostics
Booleanshow_Tfalse= true, if actual temperature at port is computed
Nominal condition
DensityrhoStdMedium2.density_pTX(101325, ...Inlet density for which valve coefficients are defined [kg/m3]
Flow resistance
Medium 1
Booleanfrom_dp1false= true, use m_flow = f(dp) else dp = f(m_flow)
BooleanlinearizeFlowResistance1false= true, use linear relation between m_flow and dp for any flow rate
RealdeltaM10.1Fraction of nominal flow rate where flow transitions to laminar
Medium 2
Booleanfrom_dp2false= true, use m_flow = f(dp) else dp = f(m_flow)
BooleanlinearizeFlowResistance2false= true, use linear relation between m_flow and dp for any flow rate
RealdeltaM20.1Fraction of nominal flow rate where flow transitions to laminar
Dynamics
Equations
DynamicsenergyDynamicsModelica.Fluid.Types.Dynamic...Type of energy balance: dynamic (3 initialization options) or steady state
DynamicsmassDynamicsenergyDynamicsType of mass balance: dynamic (3 initialization options) or steady state
Filtered opening
Booleanuse_inputFiltertrue= true, if opening is filtered with a 2nd order CriticalDamping filter
TimeriseTime120Rise time of the filter (time to reach 99.6 % of an opening step) [s]
InitinitModelica.Blocks.Types.Init.I...Type of initialization (no init/steady state/initial state/initial output)
RealyThrWayVal_start1Initial value of output from the filter in the bypass valve
Nominal condition
TimetauThrWayVal10Time constant at nominal flow for dynamic energy and momentum balance of the three-way valve [s]
Initialization
AbsolutePressurep_startMedium.p_defaultStart value of pressure [Pa]
TemperatureT_startMedium.T_defaultStart value of temperature [K]
MassFractionX_start[Medium.nX]Medium.X_defaultStart value of mass fractions m_i/m [kg/kg]
ExtraPropertyC_start[Medium.nC]fill(0, Medium.nC)Start value of trace substances
ExtraPropertyC_nominal[Medium.nC]fill(1E-2, Medium.nC)Nominal value of trace substances. (Set to typical order of magnitude.)
Controller
SimpleControllercontrollerTypeModelica.Blocks.Types.Simple...Type of controller
Realk1Gain of controller [1]
TimeTi0.5Time constant of integrator block [s]
TimeTd0.1Time constant of derivative block [s]
RealyMax1Upper limit of output
RealyMin0Lower limit of output
Realwp1Set-point weight for Proportional block (0..1)
Realwd0Set-point weight for Derivative block (0..1)
RealNi0.9Ni*Ti is time constant of anti-windup compensation
RealNd10The higher Nd, the more ideal the derivative block
BooleanreverseActiontrueSet to true for throttling the water flow rate through a cooling coil controller
Initialization
InitPIDinitTypeModelica.Blocks.Types.InitPI...Type of initialization (1: no init, 2: steady state, 3: initial state, 4: initial output)
Realxi_start0Initial or guess value value for integrator output (= integrator state)
Realxd_start0Initial or guess value for state of derivative block
RealyCon_start0Initial value of output from the controller
Integrator reset
ResetresetBuildings.Types.Reset.DisabledType of controller output reset
Realy_resetxi_startValue to which the controller output is reset if the boolean trigger has a rising edge, used if reset == Buildings.Types.Reset.Parameter

Connectors

TypeNameDescription
FluidPort_aport_a1Fluid connector a1 (positive design flow direction is from port_a1 to port_b1)
FluidPort_bport_b1Fluid connector b1 (positive design flow direction is from port_a1 to port_b1)
FluidPort_aport_a2Fluid connector a2 (positive design flow direction is from port_a2 to port_b2)
FluidPort_bport_b2Fluid connector b2 (positive design flow direction is from port_a2 to port_b2)
input BooleanInputtriggerResets the controller output when trigger becomes true
input RealInputy_reset_inInput signal for state to which integrator is reset, enabled if reset = Buildings.Types.Reset.Input
input RealInputTSetTemperature setpoint for port_b2 [K]

Modelica definition

model HeatExchanger_TSet "Heat exchanger" extends Buildings.Applications.DataCenters.ChillerCooled.Equipment.BaseClasses.PartialHeatExchanger ( final activate_ThrWayVal=use_controller); extends Buildings.Applications.DataCenters.ChillerCooled.Equipment.BaseClasses.PartialControllerInterface; Modelica.Blocks.Interfaces.RealInput TSet( final unit="K", final quantity="ThermodynamicTemperature", displayUnit="degC") if use_controller "Temperature setpoint for port_b2"; Buildings.Controls.Continuous.LimPID con( final controllerType=controllerType, final k=k, final Ti=Ti, final Td=Td, final yMax=yMax, final yMin=yMin, final wp=wp, final wd=wd, final Ni=Ni, final Nd=Nd, final initType=initType, final xi_start=xi_start, final xd_start=xd_start, final y_start=yCon_start, final reverseAction=reverseAction, final reset=reset, final y_reset=y_reset) if use_controller "Controller for temperature at port_b2"; Modelica.Blocks.Sources.RealExpression T_b2(y=T_outflow) if use_controller "Temperature at port_b2"; protected Medium2.Temperature T_outflow = Medium2.temperature(state=Medium2.setState_phX( p=port_b2.p, h=actualStream(port_b2.h_outflow), X=actualStream(port_b2.Xi_outflow))) "Temperature of outflowing fluid at port_b on medium 2 side"; equation if use_controller then connect(T_b2.y, con.u_m); connect(TSet, con.u_s); connect(con.y, thrWayVal.y); end if; connect(y_reset_in, con.y_reset_in); connect(trigger, con.trigger); end HeatExchanger_TSet;

Buildings.Applications.DataCenters.ChillerCooled.Equipment.IntegratedPrimaryLoadSide Buildings.Applications.DataCenters.ChillerCooled.Equipment.IntegratedPrimaryLoadSide

Integrated water-side economizer on the load side in a primary-only chilled water system

Buildings.Applications.DataCenters.ChillerCooled.Equipment.IntegratedPrimaryLoadSide

Information

This model implements an integrated water-side economizer (WSE) on the load side of the primary-only chilled water system, as shown in the following figure. In the configuration, users can model multiple chillers with only one integrated WSE.

image

Implementation

The WSE located on the load side can see the warmest return chilled water, and hence can maximize the use time of the heat exchanger. This system have three operation modes: free cooling (FC) mode, partial mechanical cooling (PMC) mode and fully mechanical cooling (FMC) mode.

There are 7 valves for on/off use only, which can be controlled in order to switch among FC, PMC and FMC mode.

The details about how to switch among different cooling modes are shown as:

For Free Cooling (FC) Mode:

For Partially Mechanical Cooling (PMC) Mode:

For Fully Mechanical Cooling (FMC) Mode:

Reference

Extends from Buildings.Applications.DataCenters.ChillerCooled.Equipment.BaseClasses.PartialIntegratedPrimary (Integrated water-side economizer for primary-only chilled water system).

Parameters

TypeNameDefaultDescription
replaceable package Medium1PartialMediumMedium 1 in the component
replaceable package Medium2PartialMediumMedium 2 in the component
Booleanuse_controllertrueSet to ture if the built-in controller is enabled to maintain the outlet temperature on the load side of a heat exchanger
Chiller
MassFlowRatem1_flow_chi_nominal Nominal mass flow rate on the medium 1 side in the chiller [kg/s]
MassFlowRatem2_flow_chi_nominal Nominal mass flow rate on the medium 2 side in the chiller [kg/s]
PressureDifferencedp1_chi_nominal Pressure difference on medium 1 side in the chillers [Pa]
PressureDifferencedp2_chi_nominal Pressure difference on medium 2 side in the chillers [Pa]
IntegernumChi Number of chillers
GenericperChi[numChi]redeclare parameter Building...Performance data for chillers
Waterside economizer
MassFlowRatem1_flow_wse_nominal Nominal mass flow rate on the medium 1 side in the waterside economizer [kg/s]
MassFlowRatem2_flow_wse_nominal Nominal mass flow rate on the medium 2 side in the waterside economizer [kg/s]
PressureDifferencedp1_wse_nominal Pressure difference on medium 1 side in the watersie economizer [Pa]
PressureDifferencedp2_wse_nominal Pressure difference on medium 2 side in the waterside economizer [Pa]
Efficiencyeta0.8Heat exchange effectiveness [1]
Two-way valve
CvTypesCvDataBuildings.Fluid.Types.CvType...Selection of flow coefficient
RealKv[numVal] Kv (metric) flow coefficient [m3/h/(bar)^(1/2)]
RealCv[numVal] Cv (US) flow coefficient [USG/min/(psi)^(1/2)]
AreaAv[numVal] Av (metric) flow coefficient [m2]
MassFlowRatem_flow_nominal[numVal]{m1_flow_chi_nominal,m2_flow...Nominal mass flow rate [kg/s]
PressureDifferencedpValve_nominal[numVal]fill(6000, numVal)Nominal pressure drop of fully open valve, used if CvData=Buildings.Fluid.Types.CvTypes.OpPoint [Pa]
ReallValChi[2]{0.0001,0.0001}Valve leakage, l=Kv(y=0)/Kv(y=1)
RealkFixedValChi[2]{m1_flow_chi_nominal,m2_flow...Flow coefficient of fixed resistance that may be in series with valves in chillers, k=m_flow/sqrt(dp), with unit=(kg.m)^(1/2).
ReallValWSE[2]{0.0001,0.0001}Valve leakage, l=Kv(y=0)/Kv(y=1)
RealkFixedValWSE[2]{m1_flow_wse_nominal/sqrt(dp...Flow coefficient of fixed resistance that may be in series with valves in WSE, k=m_flow/sqrt(dp), with unit=(kg.m)^(1/2).
ReallVal50.0001Valve leakage, l=Kv(y=0)/Kv(y=1)
ReallVal60.0001Valve leakage, l=Kv(y=0)/Kv(y=1)
Three-way Valve
RealfraK_ThrWayVal0.7Fraction Kv(port_3&rarr;port_2)/Kv(port_1&rarr;port_2)for the three-way valve
Reall_ThrWayVal[2]{0.0001,0.0001}Bypass valve leakage, l=Kv(y=0)/Kv(y=1)
RealR50Rangeability, R=50...100 typically for the three-way valve
Realdelta00.01Range of significant deviation from equal percentage law for the three-way valve
Pump
IntegernumPumnumChiNumber of pumps
GenericperPum[numPum]redeclare parameter Building...Performance data for the pumps
BooleanaddPowerToMediumtrueSet to false to avoid any power (=heat and flow work) being added to medium (may give simpler equations)
ReallValPum0.0001Valve leakage, l=Kv(y=0)/Kv(y=1)
RealkFixedValPumpum.m_flow_nominal/sqrt(pum....Flow coefficient of fixed resistance that may be in series with valve, k=m_flow/sqrt(dp), with unit=(kg.m)^(1/2).
Assumptions
BooleanallowFlowReversal1true= false to simplify equations, assuming, but not enforcing, no flow reversal for medium 1
BooleanallowFlowReversal2true= false to simplify equations, assuming, but not enforcing, no flow reversal for medium 2
Advanced
MassFlowRatem1_flow_small1E-4*abs(m1_flow_chi_nominal)Small mass flow rate for regularization of zero flow [kg/s]
MassFlowRatem2_flow_small1E-4*abs(m2_flow_chi_nominal)Small mass flow rate for regularization of zero flow [kg/s]
PortFlowDirectionportFlowDirection_1Modelica.Fluid.Types.PortFlo...Flow direction for port_1 in the three-way valve
PortFlowDirectionportFlowDirection_2Modelica.Fluid.Types.PortFlo...Flow direction for port_2 in the three-way valve
PortFlowDirectionportFlowDirection_3Modelica.Fluid.Types.PortFlo...Flow direction for port_3 in the three-way valve
Diagnostics
Booleanshow_Tfalse= true, if actual temperature at port is computed
Two-way valve
DensityrhoStd[numVal]{Medium1.density_pTX(101325,...Inlet density for which valve coefficients are defined [kg/m3]
Flow resistance
Medium 1
Booleanfrom_dp1false= true, use m_flow = f(dp) else dp = f(m_flow)
BooleanlinearizeFlowResistance1false= true, use linear relation between m_flow and dp for any flow rate
RealdeltaM10.1Fraction of nominal flow rate where flow transitions to laminar
Medium 2
Booleanfrom_dp2false= true, use m_flow = f(dp) else dp = f(m_flow)
BooleanlinearizeFlowResistance2false= true, use linear relation between m_flow and dp for any flow rate
RealdeltaM20.1Fraction of nominal flow rate where flow transitions to laminar
Controller
SimpleControllercontrollerTypeModelica.Blocks.Types.Simple...Type of controller
Realk1Gain of controller [1]
TimeTi0.5Time constant of integrator block [s]
TimeTd0.1Time constant of derivative block [s]
RealyMax1Upper limit of output
RealyMin0Lower limit of output
Realwp1Set-point weight for Proportional block (0..1)
Realwd0Set-point weight for Derivative block (0..1)
RealNi0.9Ni*Ti is time constant of anti-windup compensation
RealNd10The higher Nd, the more ideal the derivative block
Initialization
InitPIDinitTypeModelica.Blocks.Types.InitPI...Type of initialization (1: no init, 2: steady state, 3: initial state, 4: initial output)
Realxi_start0Initial or guess value value for integrator output (= integrator state)
Realxd_start0Initial or guess value for state of derivative block
RealyCon_start0Initial value of output from the controller
Integrator reset
ResetresetBuildings.Types.Reset.DisabledType of controller output reset
Realy_resetxi_startValue to which the controller output is reset if the boolean trigger has a rising edge, used if reset == Buildings.Types.Reset.Parameter
Dynamics
Filtered opening
Booleanuse_inputFiltertrue= true, if opening is filtered with a 2nd order CriticalDamping filter
TimeriseTimeValve120Rise time of the filter (time to reach 99.6 % of an opening step) [s]
InitinitValveModelica.Blocks.Types.Init.I...Type of initialization (no init/steady state/initial state/initial output)
RealyValChi_start[numChi]fill(0, numChi)Initial value of output from on/off valves in chillers
RealyValWSE_start0Initial value of output from on/off valve in WSE
RealyThrWayValWSE_start0Initial value of output from three-way bypass valve in WSE
RealyVal5_start0Initial value of output:0-closed, 1-fully opened
RealyVal6_start1 - yVal5_startInitial value of output:0-closed, 1-fully opened
RealyValPum_start[numPum]fill(0, numPum)Initial value of output:0-closed, 1-fully opened
Equations
DynamicsenergyDynamicsModelica.Fluid.Types.Dynamic...Type of energy balance: dynamic (3 initialization options) or steady state
DynamicsmassDynamicsenergyDynamicsType of mass balance: dynamic (3 initialization options) or steady state
Chiller
TimetauChi130Time constant at nominal flow in chillers [s]
TimetauChi230Time constant at nominal flow in chillers [s]
Waterside economizer
TimetauWSE10Time constant at nominal flow for dynamic energy and momentum balance of the three-way valve [s]
Temperature Sensor
TimetauSenT1Time constant at nominal flow rate (use tau=0 for steady-state sensor, but see user guide for potential problems) [s]
InitinitTSenorModelica.Blocks.Types.Init.I...Type of initialization of the temperature sensor (InitialState and InitialOutput are identical)
Pump
TimetauPump1Time constant of fluid volume for nominal flow in pumps, used if energy or mass balance is dynamic [s]
Filtered speed
TimeriseTimePump30Rise time of the filter (time to reach 99.6 % of an opening step) [s]
InitinitPuminitValveType of initialization (no init/steady state/initial state/initial output)
RealyPum_start[numPum]fill(0, numPum)Initial value of output:0-closed, 1-fully opened
Initialization
Medium 1
AbsolutePressurep1_startMedium1.p_defaultStart value of pressure [Pa]
TemperatureT1_startMedium1.T_defaultStart value of temperature [K]
MassFractionX1_start[Medium1.nX]Medium1.X_defaultStart value of mass fractions m_i/m [kg/kg]
ExtraPropertyC1_start[Medium1.nC]fill(0, Medium1.nC)Start value of trace substances
ExtraPropertyC1_nominal[Medium1.nC]fill(1E-2, Medium1.nC)Nominal value of trace substances. (Set to typical order of magnitude.)
Medium 2
AbsolutePressurep2_startMedium2.p_defaultStart value of pressure [Pa]
TemperatureT2_startMedium2.T_defaultStart value of temperature [K]
MassFractionX2_start[Medium2.nX]Medium2.X_defaultStart value of mass fractions m_i/m [kg/kg]
ExtraPropertyC2_start[Medium2.nC]fill(0, Medium2.nC)Start value of trace substances
ExtraPropertyC2_nominal[Medium2.nC]fill(1E-2, Medium2.nC)Nominal value of trace substances. (Set to typical order of magnitude.)

Connectors

TypeNameDescription
FluidPort_aport_a1Fluid connector a1 (positive design flow direction is from port_a1 to port_b1)
FluidPort_bport_b1Fluid connector b1 (positive design flow direction is from port_a1 to port_b1)
FluidPort_aport_a2Fluid connector a2 (positive design flow direction is from port_a2 to port_b2)
FluidPort_bport_b2Fluid connector b2 (positive design flow direction is from port_a2 to port_b2)
input RealInputTSetSet point for leaving water temperature [K]
input BooleanInputon[num]Set to true to enable equipment, or false to disable equipment
input BooleanInputtriggerResets the controller output when trigger becomes true
input RealInputy_reset_inInput signal for state to which integrator is reset, enabled if reset = Buildings.Types.Reset.Input
output RealOutputTCHWSupWSEChilled water supply temperature in the waterside economizer [K]
output RealOutputpowChi[numChi]Electric power consumed by chiller compressor [W]
input RealInputyVal6Actuator position for valve 6 (0: closed, 1: open) [1]
input RealInputyVal5Actuator position for valve 5(0: closed, 1: open) [1]
input RealInputyPum[numPum]Constant normalized rotational speed [1]
output RealOutputpowPum[numPum]Electrical power consumed by the pumps [W]

Modelica definition

model IntegratedPrimaryLoadSide "Integrated water-side economizer on the load side in a primary-only chilled water system" extends Buildings.Applications.DataCenters.ChillerCooled.Equipment.BaseClasses.PartialIntegratedPrimary ( final m_flow_nominal={m1_flow_chi_nominal,m2_flow_chi_nominal,m1_flow_wse_nominal, m2_flow_chi_nominal,numChi*m2_flow_chi_nominal,m2_flow_wse_nominal}, rhoStd = {Medium1.density_pTX(101325, 273.15+4, Medium1.X_default), Medium2.density_pTX(101325, 273.15+4, Medium2.X_default), Medium1.density_pTX(101325, 273.15+4, Medium1.X_default), Medium2.density_pTX(101325, 273.15+4, Medium2.X_default), Medium2.density_pTX(101325, 273.15+4, Medium2.X_default), Medium2.density_pTX(101325, 273.15+4, Medium2.X_default)}); //Dynamics parameter Modelica.SIunits.Time tauPump = 1 "Time constant of fluid volume for nominal flow in pumps, used if energy or mass balance is dynamic"; //Pump parameter Integer numPum = numChi "Number of pumps"; replaceable parameter Buildings.Fluid.Movers.Data.Generic perPum[numPum] "Performance data for the pumps"; parameter Boolean addPowerToMedium = true "Set to false to avoid any power (=heat and flow work) being added to medium (may give simpler equations)"; parameter Modelica.SIunits.Time riseTimePump = 30 "Rise time of the filter (time to reach 99.6 % of an opening step)"; parameter Modelica.Blocks.Types.Init initPum = initValve "Type of initialization (no init/steady state/initial state/initial output)"; parameter Real[numPum] yPum_start = fill(0,numPum) "Initial value of output:0-closed, 1-fully opened"; parameter Real[numPum] yValPum_start = fill(0,numPum) "Initial value of output:0-closed, 1-fully opened"; parameter Real lValPum = 0.0001 "Valve leakage, l=Kv(y=0)/Kv(y=1)"; parameter Real kFixedValPum = pum.m_flow_nominal/sqrt(pum.dpValve_nominal) "Flow coefficient of fixed resistance that may be in series with valve, k=m_flow/sqrt(dp), with unit=(kg.m)^(1/2)."; Modelica.Blocks.Interfaces.RealInput yPum[numPum]( each final unit = "1", each min=0, each max=1) "Constant normalized rotational speed"; Modelica.Blocks.Interfaces.RealOutput powPum[numPum]( each final quantity="Power", each final unit="W") "Electrical power consumed by the pumps"; Buildings.Applications.DataCenters.ChillerCooled.Equipment.FlowMachine_y pum( redeclare final package Medium = Medium2, final p_start=p2_start, final T_start=T2_start, final X_start=X2_start, final C_start=C2_start, final C_nominal=C2_nominal, final m_flow_small=m2_flow_small, final show_T=show_T, final per=perPum, addPowerToMedium=addPowerToMedium, final energyDynamics=energyDynamics, final massDynamics=massDynamics, final use_inputFilter=use_inputFilter, final init=initPum, final tau=tauPump, final allowFlowReversal=allowFlowReversal2, final num=numPum, final m_flow_nominal=m2_flow_chi_nominal, dpValve_nominal=6000, final CvData=Buildings.Fluid.Types.CvTypes.OpPoint, final deltaM=deltaM2, final riseTimePump=riseTimePump, final riseTimeValve=riseTimeValve, final yValve_start=yValPum_start, final l=lValPum, final kFixed=kFixedValPum, final yPump_start=yPum_start, final from_dp=from_dp2, final homotopyInitialization=homotopyInitialization, final linearizeFlowResistance=linearizeFlowResistance2) "Pumps"; equation connect(val5.port_b, pum.port_a); connect(pum.port_b,val6.port_a); connect(yPum, pum.u); connect(pum.P, powPum); end IntegratedPrimaryLoadSide;

Buildings.Applications.DataCenters.ChillerCooled.Equipment.IntegratedPrimaryPlantSide Buildings.Applications.DataCenters.ChillerCooled.Equipment.IntegratedPrimaryPlantSide

Integrated waterside economizer on the plant side in a primary-only chilled water System

Buildings.Applications.DataCenters.ChillerCooled.Equipment.IntegratedPrimaryPlantSide

Information

This model implements an integrated water-side economizer (WSE) on the plant side of the primary-only chilled water system, as shown in the following figure. In the configuration, users can model multiple chillers with only one integrated WSE.

image

Implementation

The WSE located on the load side can see the warmest return chilled water, and hence can maximize the use time of the heat exchanger. This system have three operation modes: free cooling (FC) mode, partial mechanical cooling (PMC) mode and fully mechanical cooling (FMC) mode.

There are 6 valves for on/off use only, which can be controlled in order to switch among FC, PMC and FMC mode.

The details about how to switch among different cooling modes are shown as:

For Free Cooling (FC) Mode:

For Partially Mechanical Cooling (PMC) Mode:

For fully Mechanical Cooling (FMC) Mode:

Extends from Buildings.Applications.DataCenters.ChillerCooled.Equipment.BaseClasses.PartialIntegratedPrimary (Integrated water-side economizer for primary-only chilled water system).

Parameters

TypeNameDefaultDescription
replaceable package Medium1PartialMediumMedium 1 in the component
replaceable package Medium2PartialMediumMedium 2 in the component
Booleanuse_controllertrueSet to ture if the built-in controller is enabled to maintain the outlet temperature on the load side of a heat exchanger
Chiller
MassFlowRatem1_flow_chi_nominal Nominal mass flow rate on the medium 1 side in the chiller [kg/s]
MassFlowRatem2_flow_chi_nominal Nominal mass flow rate on the medium 2 side in the chiller [kg/s]
PressureDifferencedp1_chi_nominal Pressure difference on medium 1 side in the chillers [Pa]
PressureDifferencedp2_chi_nominal Pressure difference on medium 2 side in the chillers [Pa]
IntegernumChi Number of chillers
GenericperChi[numChi]redeclare parameter Building...Performance data for chillers
Waterside economizer
MassFlowRatem1_flow_wse_nominal Nominal mass flow rate on the medium 1 side in the waterside economizer [kg/s]
MassFlowRatem2_flow_wse_nominal Nominal mass flow rate on the medium 2 side in the waterside economizer [kg/s]
PressureDifferencedp1_wse_nominal Pressure difference on medium 1 side in the watersie economizer [Pa]
PressureDifferencedp2_wse_nominal Pressure difference on medium 2 side in the waterside economizer [Pa]
Efficiencyeta0.8Heat exchange effectiveness [1]
Two-way valve
CvTypesCvDataBuildings.Fluid.Types.CvType...Selection of flow coefficient
RealKv[numVal] Kv (metric) flow coefficient [m3/h/(bar)^(1/2)]
RealCv[numVal] Cv (US) flow coefficient [USG/min/(psi)^(1/2)]
AreaAv[numVal] Av (metric) flow coefficient [m2]
MassFlowRatem_flow_nominal[numVal]{m1_flow_chi_nominal,m2_flow...Nominal mass flow rate [kg/s]
PressureDifferencedpValve_nominal[numVal]fill(6000, numVal)Nominal pressure drop of fully open valve, used if CvData=Buildings.Fluid.Types.CvTypes.OpPoint [Pa]
ReallValChi[2]{0.0001,0.0001}Valve leakage, l=Kv(y=0)/Kv(y=1)
RealkFixedValChi[2]{m1_flow_chi_nominal,m2_flow...Flow coefficient of fixed resistance that may be in series with valves in chillers, k=m_flow/sqrt(dp), with unit=(kg.m)^(1/2).
ReallValWSE[2]{0.0001,0.0001}Valve leakage, l=Kv(y=0)/Kv(y=1)
RealkFixedValWSE[2]{m1_flow_wse_nominal/sqrt(dp...Flow coefficient of fixed resistance that may be in series with valves in WSE, k=m_flow/sqrt(dp), with unit=(kg.m)^(1/2).
ReallVal50.0001Valve leakage, l=Kv(y=0)/Kv(y=1)
ReallVal60.0001Valve leakage, l=Kv(y=0)/Kv(y=1)
Three-way Valve
RealfraK_ThrWayVal0.7Fraction Kv(port_3&rarr;port_2)/Kv(port_1&rarr;port_2)for the three-way valve
Reall_ThrWayVal[2]{0.0001,0.0001}Bypass valve leakage, l=Kv(y=0)/Kv(y=1)
RealR50Rangeability, R=50...100 typically for the three-way valve
Realdelta00.01Range of significant deviation from equal percentage law for the three-way valve
Assumptions
BooleanallowFlowReversal1true= false to simplify equations, assuming, but not enforcing, no flow reversal for medium 1
BooleanallowFlowReversal2true= false to simplify equations, assuming, but not enforcing, no flow reversal for medium 2
Advanced
MassFlowRatem1_flow_small1E-4*abs(m1_flow_chi_nominal)Small mass flow rate for regularization of zero flow [kg/s]
MassFlowRatem2_flow_small1E-4*abs(m2_flow_chi_nominal)Small mass flow rate for regularization of zero flow [kg/s]
PortFlowDirectionportFlowDirection_1Modelica.Fluid.Types.PortFlo...Flow direction for port_1 in the three-way valve
PortFlowDirectionportFlowDirection_2Modelica.Fluid.Types.PortFlo...Flow direction for port_2 in the three-way valve
PortFlowDirectionportFlowDirection_3Modelica.Fluid.Types.PortFlo...Flow direction for port_3 in the three-way valve
Diagnostics
Booleanshow_Tfalse= true, if actual temperature at port is computed
Two-way valve
DensityrhoStd[numVal]{Medium1.density_pTX(101325,...Inlet density for which valve coefficients are defined [kg/m3]
Flow resistance
Medium 1
Booleanfrom_dp1false= true, use m_flow = f(dp) else dp = f(m_flow)
BooleanlinearizeFlowResistance1false= true, use linear relation between m_flow and dp for any flow rate
RealdeltaM10.1Fraction of nominal flow rate where flow transitions to laminar
Medium 2
Booleanfrom_dp2false= true, use m_flow = f(dp) else dp = f(m_flow)
BooleanlinearizeFlowResistance2false= true, use linear relation between m_flow and dp for any flow rate
RealdeltaM20.1Fraction of nominal flow rate where flow transitions to laminar
Controller
SimpleControllercontrollerTypeModelica.Blocks.Types.Simple...Type of controller
Realk1Gain of controller [1]
TimeTi0.5Time constant of integrator block [s]
TimeTd0.1Time constant of derivative block [s]
RealyMax1Upper limit of output
RealyMin0Lower limit of output
Realwp1Set-point weight for Proportional block (0..1)
Realwd0Set-point weight for Derivative block (0..1)
RealNi0.9Ni*Ti is time constant of anti-windup compensation
RealNd10The higher Nd, the more ideal the derivative block
Initialization
InitPIDinitTypeModelica.Blocks.Types.InitPI...Type of initialization (1: no init, 2: steady state, 3: initial state, 4: initial output)
Realxi_start0Initial or guess value value for integrator output (= integrator state)
Realxd_start0Initial or guess value for state of derivative block
RealyCon_start0Initial value of output from the controller
Integrator reset
ResetresetBuildings.Types.Reset.DisabledType of controller output reset
Realy_resetxi_startValue to which the controller output is reset if the boolean trigger has a rising edge, used if reset == Buildings.Types.Reset.Parameter
Dynamics
Filtered opening
Booleanuse_inputFiltertrue= true, if opening is filtered with a 2nd order CriticalDamping filter
TimeriseTimeValve120Rise time of the filter (time to reach 99.6 % of an opening step) [s]
InitinitValveModelica.Blocks.Types.Init.I...Type of initialization (no init/steady state/initial state/initial output)
RealyValChi_start[numChi]fill(0, numChi)Initial value of output from on/off valves in chillers
RealyValWSE_start0Initial value of output from on/off valve in WSE
RealyThrWayValWSE_start0Initial value of output from three-way bypass valve in WSE
RealyVal5_start0Initial value of output:0-closed, 1-fully opened
RealyVal6_start1 - yVal5_startInitial value of output:0-closed, 1-fully opened
Equations
DynamicsenergyDynamicsModelica.Fluid.Types.Dynamic...Type of energy balance: dynamic (3 initialization options) or steady state
DynamicsmassDynamicsenergyDynamicsType of mass balance: dynamic (3 initialization options) or steady state
Chiller
TimetauChi130Time constant at nominal flow in chillers [s]
TimetauChi230Time constant at nominal flow in chillers [s]
Waterside economizer
TimetauWSE10Time constant at nominal flow for dynamic energy and momentum balance of the three-way valve [s]
Temperature Sensor
TimetauSenT1Time constant at nominal flow rate (use tau=0 for steady-state sensor, but see user guide for potential problems) [s]
InitinitTSenorModelica.Blocks.Types.Init.I...Type of initialization of the temperature sensor (InitialState and InitialOutput are identical)
Initialization
Medium 1
AbsolutePressurep1_startMedium1.p_defaultStart value of pressure [Pa]
TemperatureT1_startMedium1.T_defaultStart value of temperature [K]
MassFractionX1_start[Medium1.nX]Medium1.X_defaultStart value of mass fractions m_i/m [kg/kg]
ExtraPropertyC1_start[Medium1.nC]fill(0, Medium1.nC)Start value of trace substances
ExtraPropertyC1_nominal[Medium1.nC]fill(1E-2, Medium1.nC)Nominal value of trace substances. (Set to typical order of magnitude.)
Medium 2
AbsolutePressurep2_startMedium2.p_defaultStart value of pressure [Pa]
TemperatureT2_startMedium2.T_defaultStart value of temperature [K]
MassFractionX2_start[Medium2.nX]Medium2.X_defaultStart value of mass fractions m_i/m [kg/kg]
ExtraPropertyC2_start[Medium2.nC]fill(0, Medium2.nC)Start value of trace substances
ExtraPropertyC2_nominal[Medium2.nC]fill(1E-2, Medium2.nC)Nominal value of trace substances. (Set to typical order of magnitude.)

Connectors

TypeNameDescription
FluidPort_aport_a1Fluid connector a1 (positive design flow direction is from port_a1 to port_b1)
FluidPort_bport_b1Fluid connector b1 (positive design flow direction is from port_a1 to port_b1)
FluidPort_aport_a2Fluid connector a2 (positive design flow direction is from port_a2 to port_b2)
FluidPort_bport_b2Fluid connector b2 (positive design flow direction is from port_a2 to port_b2)
input RealInputTSetSet point for leaving water temperature [K]
input BooleanInputon[num]Set to true to enable equipment, or false to disable equipment
input BooleanInputtriggerResets the controller output when trigger becomes true
input RealInputy_reset_inInput signal for state to which integrator is reset, enabled if reset = Buildings.Types.Reset.Input
output RealOutputTCHWSupWSEChilled water supply temperature in the waterside economizer [K]
output RealOutputpowChi[numChi]Electric power consumed by chiller compressor [W]
input RealInputyVal6Actuator position for valve 6 (0: closed, 1: open) [1]
input RealInputyVal5Actuator position for valve 5(0: closed, 1: open) [1]

Modelica definition

model IntegratedPrimaryPlantSide "Integrated waterside economizer on the plant side in a primary-only chilled water System" extends Buildings.Applications.DataCenters.ChillerCooled.Equipment.BaseClasses.PartialIntegratedPrimary ( final m_flow_nominal={m1_flow_chi_nominal,m2_flow_chi_nominal,m1_flow_chi_nominal, m2_flow_chi_nominal,numChi*m2_flow_chi_nominal,m2_flow_chi_nominal}, rhoStd = {Medium1.density_pTX(101325, 273.15+4, Medium1.X_default), Medium2.density_pTX(101325, 273.15+4, Medium2.X_default), Medium1.density_pTX(101325, 273.15+4, Medium1.X_default), Medium2.density_pTX(101325, 273.15+4, Medium2.X_default), Medium2.density_pTX(101325, 273.15+4, Medium2.X_default), Medium2.density_pTX(101325, 273.15+4, Medium2.X_default)}); equation connect(val5.port_b,val6.port_a); end IntegratedPrimaryPlantSide;

Buildings.Applications.DataCenters.ChillerCooled.Equipment.IntegratedPrimarySecondary Buildings.Applications.DataCenters.ChillerCooled.Equipment.IntegratedPrimarySecondary

Integrated waterside economizer on the load side in a primary-secondary chilled water system

Buildings.Applications.DataCenters.ChillerCooled.Equipment.IntegratedPrimarySecondary

Information

This model implements an integrated water-side economizer (WSE) on the load side of the primary-secondary chilled water system, as shown in the following figure. In the configuration, users can model multiple chillers with only one integrated WSE.

image

Implementation

The WSE located on the load side can see the warmest return chilled water, and hence can maximize the hours when the WSE can operate. Also it allows the primary pumps to be shut off when the WSE can handle the entire load. This system have three operation modes: free cooling (FC) mode, partial mechanical cooling (PMC) mode and fully mechanical cooling (FMC) mode.

There are 5 valves for on/off use only, which can be controlled in order to switch among FC, PMC and FMC mode.

The details about how to switch among different cooling modes are shown as:

For Free Cooling (FC) Mode:

For Partially Mechanical Cooling (PMC) Mode:

For Fully Mechanical Cooling (FMC) Mode:

Reference

Extends from Buildings.Applications.DataCenters.ChillerCooled.Equipment.BaseClasses.PartialChillerWSE (Partial model for chiller and WSE package).

Parameters

TypeNameDefaultDescription
replaceable package Medium1PartialMediumMedium 1 in the component
replaceable package Medium2PartialMediumMedium 2 in the component
Booleanuse_controllertrueSet to ture if the built-in controller is enabled to maintain the outlet temperature on the load side of a heat exchanger
IntegernumVal5Number of valves
Chiller
MassFlowRatem1_flow_chi_nominal Nominal mass flow rate on the medium 1 side in the chiller [kg/s]
MassFlowRatem2_flow_chi_nominal Nominal mass flow rate on the medium 2 side in the chiller [kg/s]
PressureDifferencedp1_chi_nominal Pressure difference on medium 1 side in the chillers [Pa]
PressureDifferencedp2_chi_nominal Pressure difference on medium 2 side in the chillers [Pa]
IntegernumChi Number of chillers
GenericperChi[numChi]redeclare parameter Building...Performance data for chillers
Waterside economizer
MassFlowRatem1_flow_wse_nominal Nominal mass flow rate on the medium 1 side in the waterside economizer [kg/s]
MassFlowRatem2_flow_wse_nominal Nominal mass flow rate on the medium 2 side in the waterside economizer [kg/s]
PressureDifferencedp1_wse_nominal Pressure difference on medium 1 side in the watersie economizer [Pa]
PressureDifferencedp2_wse_nominal Pressure difference on medium 2 side in the waterside economizer [Pa]
Efficiencyeta0.8Heat exchange effectiveness [1]
Two-way valve
CvTypesCvDataBuildings.Fluid.Types.CvType...Selection of flow coefficient
RealKv[numVal] Kv (metric) flow coefficient [m3/h/(bar)^(1/2)]
RealCv[numVal] Cv (US) flow coefficient [USG/min/(psi)^(1/2)]
AreaAv[numVal] Av (metric) flow coefficient [m2]
MassFlowRatem_flow_nominal[numVal]{m1_flow_chi_nominal,m2_flow...Nominal mass flow rate [kg/s]
PressureDifferencedpValve_nominal[numVal]fill(6000, numVal)Nominal pressure drop of fully open valve, used if CvData=Buildings.Fluid.Types.CvTypes.OpPoint [Pa]
ReallValChi[2]{0.0001,0.0001}Valve leakage, l=Kv(y=0)/Kv(y=1)
RealkFixedValChi[2]{m1_flow_chi_nominal,m2_flow...Flow coefficient of fixed resistance that may be in series with valves in chillers, k=m_flow/sqrt(dp), with unit=(kg.m)^(1/2).
ReallValWSE[2]{0.0001,0.0001}Valve leakage, l=Kv(y=0)/Kv(y=1)
RealkFixedValWSE[2]{m1_flow_wse_nominal/sqrt(dp...Flow coefficient of fixed resistance that may be in series with valves in WSE, k=m_flow/sqrt(dp), with unit=(kg.m)^(1/2).
Three-way Valve
RealfraK_ThrWayVal0.7Fraction Kv(port_3&rarr;port_2)/Kv(port_1&rarr;port_2)for the three-way valve
Reall_ThrWayVal[2]{0.0001,0.0001}Bypass valve leakage, l=Kv(y=0)/Kv(y=1)
RealR50Rangeability, R=50...100 typically for the three-way valve
Realdelta00.01Range of significant deviation from equal percentage law for the three-way valve
Pump
IntegernumPumnumChiNumber of pumps
MassFlowRatem_flow_pum_nominalm2_flow_chi_nominalNominal flow rate of the pump [kg/s]
GenericperPum[numPum]redeclare parameter Building...Performance data for primary pumps
BooleanaddPowerToMediumtrueSet to false to avoid any power (=heat and flow work) being added to medium (may give simpler equations)
ReallValPum0.0001Valve leakage, l=Kv(y=0)/Kv(y=1)
RealkFixedValPumpum.m_flow_nominal/sqrt(pum....Flow coefficient of fixed resistance that may be in series with valve, k=m_flow/sqrt(dp), with unit=(kg.m)^(1/2).
PressureDifferencedpValPum_nominal6000Nominal differential pressure of the shutoff valves for primary pumps [Pa]
Shutoff valve
ReallVal50.0001Valve 5 leakage, l=Kv(y=0)/Kv(y=1)
Assumptions
BooleanallowFlowReversal1true= false to simplify equations, assuming, but not enforcing, no flow reversal for medium 1
BooleanallowFlowReversal2true= false to simplify equations, assuming, but not enforcing, no flow reversal for medium 2
Advanced
MassFlowRatem1_flow_small1E-4*abs(m1_flow_chi_nominal)Small mass flow rate for regularization of zero flow [kg/s]
MassFlowRatem2_flow_small1E-4*abs(m2_flow_chi_nominal)Small mass flow rate for regularization of zero flow [kg/s]
PortFlowDirectionportFlowDirection_1Modelica.Fluid.Types.PortFlo...Flow direction for port_1 in the three-way valve
PortFlowDirectionportFlowDirection_2Modelica.Fluid.Types.PortFlo...Flow direction for port_2 in the three-way valve
PortFlowDirectionportFlowDirection_3Modelica.Fluid.Types.PortFlo...Flow direction for port_3 in the three-way valve
Diagnostics
Booleanshow_Tfalse= true, if actual temperature at port is computed
Two-way valve
DensityrhoStd[numVal]{Medium1.density_pTX(101325,...Inlet density for which valve coefficients are defined [kg/m3]
Flow resistance
Medium 1
Booleanfrom_dp1false= true, use m_flow = f(dp) else dp = f(m_flow)
BooleanlinearizeFlowResistance1false= true, use linear relation between m_flow and dp for any flow rate
RealdeltaM10.1Fraction of nominal flow rate where flow transitions to laminar
Medium 2
Booleanfrom_dp2false= true, use m_flow = f(dp) else dp = f(m_flow)
BooleanlinearizeFlowResistance2false= true, use linear relation between m_flow and dp for any flow rate
RealdeltaM20.1Fraction of nominal flow rate where flow transitions to laminar
Controller
SimpleControllercontrollerTypeModelica.Blocks.Types.Simple...Type of controller
Realk1Gain of controller [1]
TimeTi0.5Time constant of integrator block [s]
TimeTd0.1Time constant of derivative block [s]
RealyMax1Upper limit of output
RealyMin0Lower limit of output
Realwp1Set-point weight for Proportional block (0..1)
Realwd0Set-point weight for Derivative block (0..1)
RealNi0.9Ni*Ti is time constant of anti-windup compensation
RealNd10The higher Nd, the more ideal the derivative block
Initialization
InitPIDinitTypeModelica.Blocks.Types.InitPI...Type of initialization (1: no init, 2: steady state, 3: initial state, 4: initial output)
Realxi_start0Initial or guess value value for integrator output (= integrator state)
Realxd_start0Initial or guess value for state of derivative block
RealyCon_start0Initial value of output from the controller
Integrator reset
ResetresetBuildings.Types.Reset.DisabledType of controller output reset
Realy_resetxi_startValue to which the controller output is reset if the boolean trigger has a rising edge, used if reset == Buildings.Types.Reset.Parameter
Dynamics
Filtered opening
Booleanuse_inputFiltertrue= true, if opening is filtered with a 2nd order CriticalDamping filter
TimeriseTimeValve120Rise time of the filter (time to reach 99.6 % of an opening step) [s]
InitinitValveModelica.Blocks.Types.Init.I...Type of initialization (no init/steady state/initial state/initial output)
RealyValChi_start[numChi]fill(0, numChi)Initial value of output from on/off valves in chillers
RealyValWSE_start0Initial value of output from on/off valve in WSE
RealyThrWayValWSE_start0Initial value of output from three-way bypass valve in WSE
RealyValPum_start[numPum]fill(0, numPum)Initial value of output:0-closed, 1-fully opened
RealyVal5_start0Initial value of output from valve 5:0-closed, 1-fully opened
Equations
DynamicsenergyDynamicsModelica.Fluid.Types.Dynamic...Type of energy balance: dynamic (3 initialization options) or steady state
DynamicsmassDynamicsenergyDynamicsType of mass balance: dynamic (3 initialization options) or steady state
Chiller
TimetauChi130Time constant at nominal flow in chillers [s]
TimetauChi230Time constant at nominal flow in chillers [s]
Waterside economizer
TimetauWSE10Time constant at nominal flow for dynamic energy and momentum balance of the three-way valve [s]
Temperature Sensor
TimetauSenT1Time constant at nominal flow rate (use tau=0 for steady-state sensor, but see user guide for potential problems) [s]
InitinitTSenorModelica.Blocks.Types.Init.I...Type of initialization of the temperature sensor (InitialState and InitialOutput are identical)
Pump
TimetauPump1Time constant of fluid volume for nominal flow in pumps, used if energy or mass balance is dynamic [s]
Filtered flowrate
TimeriseTimePump30Rise time of the filter (time to reach 99.6 % of an opening step) [s]
InitinitPuminitValveType of initialization (no init/steady state/initial state/initial output)
RealyPum_start[numPum]fill(0, numPum)Initial value of output from pumps:0-closed, 1-fully opened
Realm_flow_start[numPum]fill(0, numPum)Initial value of output from pumps
Initialization
Medium 1
AbsolutePressurep1_startMedium1.p_defaultStart value of pressure [Pa]
TemperatureT1_startMedium1.T_defaultStart value of temperature [K]
MassFractionX1_start[Medium1.nX]Medium1.X_defaultStart value of mass fractions m_i/m [kg/kg]
ExtraPropertyC1_start[Medium1.nC]fill(0, Medium1.nC)Start value of trace substances
ExtraPropertyC1_nominal[Medium1.nC]fill(1E-2, Medium1.nC)Nominal value of trace substances. (Set to typical order of magnitude.)
Medium 2
AbsolutePressurep2_startMedium2.p_defaultStart value of pressure [Pa]
TemperatureT2_startMedium2.T_defaultStart value of temperature [K]
MassFractionX2_start[Medium2.nX]Medium2.X_defaultStart value of mass fractions m_i/m [kg/kg]
ExtraPropertyC2_start[Medium2.nC]fill(0, Medium2.nC)Start value of trace substances
ExtraPropertyC2_nominal[Medium2.nC]fill(1E-2, Medium2.nC)Nominal value of trace substances. (Set to typical order of magnitude.)

Connectors

TypeNameDescription
FluidPort_aport_a1Fluid connector a1 (positive design flow direction is from port_a1 to port_b1)
FluidPort_bport_b1Fluid connector b1 (positive design flow direction is from port_a1 to port_b1)
FluidPort_aport_a2Fluid connector a2 (positive design flow direction is from port_a2 to port_b2)
FluidPort_bport_b2Fluid connector b2 (positive design flow direction is from port_a2 to port_b2)
input RealInputTSetSet point for leaving water temperature [K]
input BooleanInputon[num]Set to true to enable equipment, or false to disable equipment
input BooleanInputtriggerResets the controller output when trigger becomes true
input RealInputy_reset_inInput signal for state to which integrator is reset, enabled if reset = Buildings.Types.Reset.Input
output RealOutputTCHWSupWSEChilled water supply temperature in the waterside economizer [K]
output RealOutputpowChi[numChi]Electric power consumed by chiller compressor [W]
input RealInputyPum[numPum]Prescribed normalized flowrate for primary pumps: 1 - nominal flowrate, 0 - no flowrate [1]
input RealInputyVal5Actuator position for valve 5 (0: closed, 1: open) [1]
output RealOutputpowPum[numPum]Electrical power consumed by the pumps [W]

Modelica definition

model IntegratedPrimarySecondary "Integrated waterside economizer on the load side in a primary-secondary chilled water system" extends Buildings.Applications.DataCenters.ChillerCooled.Equipment.BaseClasses.PartialChillerWSE ( final numVal=5, final m_flow_nominal={m1_flow_chi_nominal,m2_flow_chi_nominal,m1_flow_chi_nominal, m2_flow_wse_nominal,numChi*m2_flow_chi_nominal}, rhoStd = {Medium1.density_pTX(101325, 273.15+4, Medium1.X_default), Medium2.density_pTX(101325, 273.15+4, Medium2.X_default), Medium1.density_pTX(101325, 273.15+4, Medium1.X_default), Medium2.density_pTX(101325, 273.15+4, Medium2.X_default), Medium2.density_pTX(101325, 273.15+4, Medium2.X_default)}); // Dynamics parameter Modelica.SIunits.Time tauPump = 1 "Time constant of fluid volume for nominal flow in pumps, used if energy or mass balance is dynamic"; //Pump parameter Integer numPum=numChi "Number of pumps"; parameter Modelica.SIunits.MassFlowRate m_flow_pum_nominal(min=0)=m2_flow_chi_nominal "Nominal flow rate of the pump"; replaceable parameter Buildings.Fluid.Movers.Data.Generic perPum[numPum] "Performance data for primary pumps"; parameter Boolean addPowerToMedium=true "Set to false to avoid any power (=heat and flow work) being added to medium (may give simpler equations)"; parameter Modelica.SIunits.Time riseTimePump = 30 "Rise time of the filter (time to reach 99.6 % of an opening step)"; parameter Modelica.Blocks.Types.Init initPum=initValve "Type of initialization (no init/steady state/initial state/initial output)"; parameter Real[numPum] yPum_start(each min=0)=fill(0,numPum) "Initial value of output from pumps:0-closed, 1-fully opened"; parameter Real[numPum] m_flow_start(each min=0)=fill(0,numPum) "Initial value of output from pumps"; parameter Real[numPum] yValPum_start = fill(0,numPum) "Initial value of output:0-closed, 1-fully opened"; parameter Real lValPum=0.0001 "Valve leakage, l=Kv(y=0)/Kv(y=1)"; parameter Real kFixedValPum=pum.m_flow_nominal/sqrt(pum.dpValve_nominal) "Flow coefficient of fixed resistance that may be in series with valve, k=m_flow/sqrt(dp), with unit=(kg.m)^(1/2)."; parameter Modelica.SIunits.PressureDifference dpValPum_nominal = 6000 "Nominal differential pressure of the shutoff valves for primary pumps"; //Valve parameter Real lVal5(min=1e-10,max=1) = 0.0001 "Valve 5 leakage, l=Kv(y=0)/Kv(y=1)"; parameter Real yVal5_start = 0 "Initial value of output from valve 5:0-closed, 1-fully opened"; Modelica.Blocks.Interfaces.RealInput yPum[numPum]( each final unit = "1", each min = 0, each max = 1) "Prescribed normalized flowrate for primary pumps: 1 - nominal flowrate, 0 - no flowrate"; Modelica.Blocks.Interfaces.RealInput yVal5( final unit = "1", min = 0, max = 1) "Actuator position for valve 5 (0: closed, 1: open)"; Modelica.Blocks.Interfaces.RealOutput powPum[numPum]( each final quantity="Power", each final unit = "W") "Electrical power consumed by the pumps"; Buildings.Fluid.Actuators.Valves.TwoWayLinear val5( redeclare final package Medium = Medium2, final CvData=Buildings.Fluid.Types.CvTypes.OpPoint, final allowFlowReversal=allowFlowReversal2, final m_flow_nominal=numChi*m2_flow_chi_nominal, final show_T=show_T, final from_dp=from_dp2, final homotopyInitialization=homotopyInitialization, final linearized=linearizeFlowResistance2, final deltaM=deltaM2, final use_inputFilter=use_inputFilter, final riseTime=riseTimeValve, final init=initValve, final dpFixed_nominal=0, final dpValve_nominal=dpValve_nominal[5], final kFixed=0, final rhoStd=rhoStd[5], final y_start=yVal5_start, final l=lVal5) "Bypass valve: closed when fully mechanic cooling is activated; open when fully mechanic cooling is activated"; Buildings.Applications.DataCenters.ChillerCooled.Equipment.FlowMachine_m pum( redeclare final package Medium = Medium2, final p_start=p2_start, final T_start=T2_start, final X_start=X2_start, final C_start=C2_start, final C_nominal=C2_nominal, final allowFlowReversal=allowFlowReversal2, final m_flow_small=m2_flow_small, final show_T=show_T, final per=perPum, final addPowerToMedium=addPowerToMedium, final energyDynamics=energyDynamics, final massDynamics=massDynamics, final use_inputFilter=use_inputFilter, final init=initPum, final tau=tauPump, final m_flow_nominal=m_flow_pum_nominal, final num=numPum, final deltaM=deltaM2, final dpValve_nominal=dpValPum_nominal, final l=lValPum, final kFixed=kFixedValPum, final riseTimeValve=riseTimeValve, final yValve_start=yValPum_start, final from_dp=from_dp2, final homotopyInitialization=homotopyInitialization, final linearizeFlowResistance=linearizeFlowResistance2, final CvData=Buildings.Fluid.Types.CvTypes.OpPoint, final riseTimePump=riseTimePump, final yPump_start=yPum_start) "Constant speed pumps"; Buildings.Fluid.Sensors.MassFlowRate bypFlo(redeclare package Medium = Medium2) "Bypass water mass flowrate"; equation connect(wse.port_a2, port_a2); connect(port_a2,val5. port_a); connect(pum.port_b, chiPar.port_a2); connect(val5.y, yVal5); connect(chiPar.port_b2, port_b2); connect(val5.port_b, bypFlo.port_b); connect(bypFlo.port_a, port_b2); connect(senTem.port_b, val5.port_b); connect(yPum, pum.u); connect(pum.port_a, val5.port_b); connect(pum.P, powPum); end IntegratedPrimarySecondary;

Buildings.Applications.DataCenters.ChillerCooled.Equipment.NonIntegrated Buildings.Applications.DataCenters.ChillerCooled.Equipment.NonIntegrated

Non-integrated waterside economizer in chilled water system

Buildings.Applications.DataCenters.ChillerCooled.Equipment.NonIntegrated

Information

This model implements a non-integrated water-side economizer (WSE) in the chilled water system, as shown in the following figure. In the configuration, users can model multiple chillers with only one integrated WSE. This model can be used in both primary-only and primary-secondary pumping system.

image

Implementation

The WSE is in parallel with chillers on both the condenser and chilled water sides. If the economizer cannot meet the entire load then it must be shut off. Otherwise, the relatively warm economier leaving water will be mixed with the cold chiller leaving water and hence the plant leaving water temperature will be above setpoint. For this configuration, there are only two cooling modes: free cooling (FC) mode and fully mechanical cooling (FMC) mode.

There are 4 valves for on/off use only, which can be controlled in order to switch between FC and FMC mode.

The details about how to switch among different cooling modes are shown as:

For Free Cooling (FC) Mode:

For Fully Mechanical Cooling (FMC) Mode:

Extends from Buildings.Applications.DataCenters.ChillerCooled.Equipment.BaseClasses.PartialChillerWSE (Partial model for chiller and WSE package).

Parameters

TypeNameDefaultDescription
replaceable package Medium1PartialMediumMedium 1 in the component
replaceable package Medium2PartialMediumMedium 2 in the component
Booleanuse_controllertrueSet to ture if the built-in controller is enabled to maintain the outlet temperature on the load side of a heat exchanger
IntegernumVal4Number of valves
Chiller
MassFlowRatem1_flow_chi_nominal Nominal mass flow rate on the medium 1 side in the chiller [kg/s]
MassFlowRatem2_flow_chi_nominal Nominal mass flow rate on the medium 2 side in the chiller [kg/s]
PressureDifferencedp1_chi_nominal Pressure difference on medium 1 side in the chillers [Pa]
PressureDifferencedp2_chi_nominal Pressure difference on medium 2 side in the chillers [Pa]
IntegernumChi Number of chillers
GenericperChi[numChi]redeclare parameter Building...Performance data for chillers
Waterside economizer
MassFlowRatem1_flow_wse_nominal Nominal mass flow rate on the medium 1 side in the waterside economizer [kg/s]
MassFlowRatem2_flow_wse_nominal Nominal mass flow rate on the medium 2 side in the waterside economizer [kg/s]
PressureDifferencedp1_wse_nominal Pressure difference on medium 1 side in the watersie economizer [Pa]
PressureDifferencedp2_wse_nominal Pressure difference on medium 2 side in the waterside economizer [Pa]
Efficiencyeta0.8Heat exchange effectiveness [1]
Two-way valve
CvTypesCvDataBuildings.Fluid.Types.CvType...Selection of flow coefficient
RealKv[numVal] Kv (metric) flow coefficient [m3/h/(bar)^(1/2)]
RealCv[numVal] Cv (US) flow coefficient [USG/min/(psi)^(1/2)]
AreaAv[numVal] Av (metric) flow coefficient [m2]
MassFlowRatem_flow_nominal[numVal]{m1_flow_chi_nominal,m2_flow...Nominal mass flow rate [kg/s]
PressureDifferencedpValve_nominal[numVal]fill(6000, numVal)Nominal pressure drop of fully open valve, used if CvData=Buildings.Fluid.Types.CvTypes.OpPoint [Pa]
ReallValChi[2]{0.0001,0.0001}Valve leakage, l=Kv(y=0)/Kv(y=1)
RealkFixedValChi[2]{m1_flow_chi_nominal,m2_flow...Flow coefficient of fixed resistance that may be in series with valves in chillers, k=m_flow/sqrt(dp), with unit=(kg.m)^(1/2).
ReallValWSE[2]{0.0001,0.0001}Valve leakage, l=Kv(y=0)/Kv(y=1)
RealkFixedValWSE[2]{m1_flow_wse_nominal/sqrt(dp...Flow coefficient of fixed resistance that may be in series with valves in WSE, k=m_flow/sqrt(dp), with unit=(kg.m)^(1/2).
Three-way Valve
RealfraK_ThrWayVal0.7Fraction Kv(port_3&rarr;port_2)/Kv(port_1&rarr;port_2)for the three-way valve
Reall_ThrWayVal[2]{0.0001,0.0001}Bypass valve leakage, l=Kv(y=0)/Kv(y=1)
RealR50Rangeability, R=50...100 typically for the three-way valve
Realdelta00.01Range of significant deviation from equal percentage law for the three-way valve
Assumptions
BooleanallowFlowReversal1true= false to simplify equations, assuming, but not enforcing, no flow reversal for medium 1
BooleanallowFlowReversal2true= false to simplify equations, assuming, but not enforcing, no flow reversal for medium 2
Advanced
MassFlowRatem1_flow_small1E-4*abs(m1_flow_chi_nominal)Small mass flow rate for regularization of zero flow [kg/s]
MassFlowRatem2_flow_small1E-4*abs(m2_flow_chi_nominal)Small mass flow rate for regularization of zero flow [kg/s]
PortFlowDirectionportFlowDirection_1Modelica.Fluid.Types.PortFlo...Flow direction for port_1 in the three-way valve
PortFlowDirectionportFlowDirection_2Modelica.Fluid.Types.PortFlo...Flow direction for port_2 in the three-way valve
PortFlowDirectionportFlowDirection_3Modelica.Fluid.Types.PortFlo...Flow direction for port_3 in the three-way valve
Diagnostics
Booleanshow_Tfalse= true, if actual temperature at port is computed
Two-way valve
DensityrhoStd[numVal]{Medium1.density_pTX(101325,...Inlet density for which valve coefficients are defined [kg/m3]
Flow resistance
Medium 1
Booleanfrom_dp1false= true, use m_flow = f(dp) else dp = f(m_flow)
BooleanlinearizeFlowResistance1false= true, use linear relation between m_flow and dp for any flow rate
RealdeltaM10.1Fraction of nominal flow rate where flow transitions to laminar
Medium 2
Booleanfrom_dp2false= true, use m_flow = f(dp) else dp = f(m_flow)
BooleanlinearizeFlowResistance2false= true, use linear relation between m_flow and dp for any flow rate
RealdeltaM20.1Fraction of nominal flow rate where flow transitions to laminar
Controller
SimpleControllercontrollerTypeModelica.Blocks.Types.Simple...Type of controller
Realk1Gain of controller [1]
TimeTi0.5Time constant of integrator block [s]
TimeTd0.1Time constant of derivative block [s]
RealyMax1Upper limit of output
RealyMin0Lower limit of output
Realwp1Set-point weight for Proportional block (0..1)
Realwd0Set-point weight for Derivative block (0..1)
RealNi0.9Ni*Ti is time constant of anti-windup compensation
RealNd10The higher Nd, the more ideal the derivative block
Initialization
InitPIDinitTypeModelica.Blocks.Types.InitPI...Type of initialization (1: no init, 2: steady state, 3: initial state, 4: initial output)
Realxi_start0Initial or guess value value for integrator output (= integrator state)
Realxd_start0Initial or guess value for state of derivative block
RealyCon_start0Initial value of output from the controller
Integrator reset
ResetresetBuildings.Types.Reset.DisabledType of controller output reset
Realy_resetxi_startValue to which the controller output is reset if the boolean trigger has a rising edge, used if reset == Buildings.Types.Reset.Parameter
Dynamics
Filtered opening
Booleanuse_inputFiltertrue= true, if opening is filtered with a 2nd order CriticalDamping filter
TimeriseTimeValve120Rise time of the filter (time to reach 99.6 % of an opening step) [s]
InitinitValveModelica.Blocks.Types.Init.I...Type of initialization (no init/steady state/initial state/initial output)
RealyValChi_start[numChi]fill(0, numChi)Initial value of output from on/off valves in chillers
RealyValWSE_start0Initial value of output from on/off valve in WSE
RealyThrWayValWSE_start0Initial value of output from three-way bypass valve in WSE
Equations
DynamicsenergyDynamicsModelica.Fluid.Types.Dynamic...Type of energy balance: dynamic (3 initialization options) or steady state
DynamicsmassDynamicsenergyDynamicsType of mass balance: dynamic (3 initialization options) or steady state
Chiller
TimetauChi130Time constant at nominal flow in chillers [s]
TimetauChi230Time constant at nominal flow in chillers [s]
Waterside economizer
TimetauWSE10Time constant at nominal flow for dynamic energy and momentum balance of the three-way valve [s]
Temperature Sensor
TimetauSenT1Time constant at nominal flow rate (use tau=0 for steady-state sensor, but see user guide for potential problems) [s]
InitinitTSenorModelica.Blocks.Types.Init.I...Type of initialization of the temperature sensor (InitialState and InitialOutput are identical)
Initialization
Medium 1
AbsolutePressurep1_startMedium1.p_defaultStart value of pressure [Pa]
TemperatureT1_startMedium1.T_defaultStart value of temperature [K]
MassFractionX1_start[Medium1.nX]Medium1.X_defaultStart value of mass fractions m_i/m [kg/kg]
ExtraPropertyC1_start[Medium1.nC]fill(0, Medium1.nC)Start value of trace substances
ExtraPropertyC1_nominal[Medium1.nC]fill(1E-2, Medium1.nC)Nominal value of trace substances. (Set to typical order of magnitude.)
Medium 2
AbsolutePressurep2_startMedium2.p_defaultStart value of pressure [Pa]
TemperatureT2_startMedium2.T_defaultStart value of temperature [K]
MassFractionX2_start[Medium2.nX]Medium2.X_defaultStart value of mass fractions m_i/m [kg/kg]
ExtraPropertyC2_start[Medium2.nC]fill(0, Medium2.nC)Start value of trace substances
ExtraPropertyC2_nominal[Medium2.nC]fill(1E-2, Medium2.nC)Nominal value of trace substances. (Set to typical order of magnitude.)

Connectors

TypeNameDescription
FluidPort_aport_a1Fluid connector a1 (positive design flow direction is from port_a1 to port_b1)
FluidPort_bport_b1Fluid connector b1 (positive design flow direction is from port_a1 to port_b1)
FluidPort_aport_a2Fluid connector a2 (positive design flow direction is from port_a2 to port_b2)
FluidPort_bport_b2Fluid connector b2 (positive design flow direction is from port_a2 to port_b2)
input RealInputTSetSet point for leaving water temperature [K]
input BooleanInputon[num]Set to true to enable equipment, or false to disable equipment
input BooleanInputtriggerResets the controller output when trigger becomes true
input RealInputy_reset_inInput signal for state to which integrator is reset, enabled if reset = Buildings.Types.Reset.Input
output RealOutputTCHWSupWSEChilled water supply temperature in the waterside economizer [K]
output RealOutputpowChi[numChi]Electric power consumed by chiller compressor [W]

Modelica definition

model NonIntegrated "Non-integrated waterside economizer in chilled water system" extends Buildings.Applications.DataCenters.ChillerCooled.Equipment.BaseClasses.PartialChillerWSE ( final numVal=4, final m_flow_nominal={m1_flow_chi_nominal,m2_flow_chi_nominal,m1_flow_wse_nominal, m2_flow_wse_nominal}, rhoStd = {Medium1.density_pTX(101325, 273.15+4, Medium1.X_default), Medium2.density_pTX(101325, 273.15+4, Medium2.X_default), Medium1.density_pTX(101325, 273.15+4, Medium1.X_default), Medium2.density_pTX(101325, 273.15+4, Medium2.X_default)}); equation connect(port_a2, wse.port_a2); connect(port_a2, chiPar.port_a2); connect(chiPar.port_b2, port_b2); connect(senTem.port_b, port_b2); end NonIntegrated;

Buildings.Applications.DataCenters.ChillerCooled.Equipment.WatersideEconomizer Buildings.Applications.DataCenters.ChillerCooled.Equipment.WatersideEconomizer

Waterside economizer

Buildings.Applications.DataCenters.ChillerCooled.Equipment.WatersideEconomizer

Information

This module impliments a waterside economizer model that consists of a heat exchanger and a shutoff valve on each medium side. This waterside economizer model can be used in two different control scenarios:

  1. The temperature at port_b2 is controlled by a built-in PID controller and a three-way valve by setting the parameter use_controller as true.
  2. The temperature at port_b2 is NOT controlled by a built-in controller by setting the parameter use_controller as false. Hence, an outside controller can be used to control the temperature. For example, in the free-cooling mode, the speed of variable-speed cooling tower fans can be adjusted to maintain the supply chilled water temperature around the setpoint.

Extends from Buildings.Applications.DataCenters.ChillerCooled.Equipment.BaseClasses.PartialPlantParallel (Partial source plant model with associated valves), Buildings.Fluid.Interfaces.LumpedVolumeDeclarations (Declarations for lumped volumes), Buildings.Applications.DataCenters.ChillerCooled.Equipment.BaseClasses.ThreeWayValveParameters (Model with parameters for a three-way valve), Buildings.Applications.DataCenters.ChillerCooled.Equipment.BaseClasses.PartialControllerInterface (Partial interface model for waterside economizer temperature controller).

Parameters

TypeNameDefaultDescription
replaceable package Medium1PartialMediumMedium 1 in the component
replaceable package Medium2PartialMediumMedium 2 in the component
Integernum1Number of equipment
replaceable package MediumPartialMediumMedium in the component
Booleanactivate_ThrWayValuse_controllerActivate the use of three-way valve: True-use three-way valve; False-not use the three-way valve
Booleanuse_controllertrueSet to ture if the built-in controller is enabled to maintain the outlet temperature on the load side of a heat exchanger
Efficiencyeta constant effectiveness [1]
Nominal condition
MassFlowRatem1_flow_nominal Nominal mass flow rate [kg/s]
MassFlowRatem2_flow_nominal Nominal mass flow rate [kg/s]
PressureDifferencedp1_nominal Pressure difference [Pa]
PressureDifferencedp2_nominal Pressure difference [Pa]
Two-way valve
CvTypesCvDataBuildings.Fluid.Types.CvType...Selection of flow coefficient
RealKv[numVal] Kv (metric) flow coefficient [m3/h/(bar)^(1/2)]
RealCv[numVal] Cv (US) flow coefficient [USG/min/(psi)^(1/2)]
AreaAv[numVal] Av (metric) flow coefficient [m2]
PressureDifferencedpValve_nominal[numVal]fill(6000, numVal)Nominal pressure drop of fully open valve, used if CvData=Buildings.Fluid.Types.CvTypes.OpPoint [Pa]
Reall[2]{0.0001,0.0001}Valve leakage, l=Kv(y=0)/Kv(y=1)
RealkFixed[2]{m1_flow_nominal/sqrt(dp1_no...Flow coefficient of fixed resistance that may be in series with valve 1, k=m_flow/sqrt(dp), with unit=(kg.m)^(1/2).
Three-way Valve
RealfraK_ThrWayVal0.7Fraction Kv(port_3&rarr;port_2)/Kv(port_1&rarr;port_2)for the three-way valve
Reall_ThrWayVal[2]{0.0001,0.0001}Bypass valve leakage, l=Kv(y=0)/Kv(y=1)
RealR50Rangeability, R=50...100 typically for the three-way valve
Realdelta00.01Range of significant deviation from equal percentage law for the three-way valve
Assumptions
BooleanallowFlowReversal1true= false to simplify equations, assuming, but not enforcing, no flow reversal for medium 1
BooleanallowFlowReversal2true= false to simplify equations, assuming, but not enforcing, no flow reversal for medium 2
Advanced
MassFlowRatem1_flow_small1E-4*abs(m1_flow_nominal)Small mass flow rate for regularization of zero flow [kg/s]
MassFlowRatem2_flow_small1E-4*abs(m2_flow_nominal)Small mass flow rate for regularization of zero flow [kg/s]
PortFlowDirectionportFlowDirection_1Modelica.Fluid.Types.PortFlo...Flow direction for port_1 in the three-way valve
PortFlowDirectionportFlowDirection_2Modelica.Fluid.Types.PortFlo...Flow direction for port_2 in the three-way valve
PortFlowDirectionportFlowDirection_3Modelica.Fluid.Types.PortFlo...Flow direction for port_3 in the three-way valve
Diagnostics
Booleanshow_Tfalse= true, if actual temperature at port is computed
Two-way valve
DensityrhoStd[numVal]{Medium1.density_pTX(101325,...Inlet density for which valve coefficients are defined [kg/m3]
Flow resistance
Medium 1
Booleanfrom_dp1false= true, use m_flow = f(dp) else dp = f(m_flow)
BooleanlinearizeFlowResistance1false= true, use linear relation between m_flow and dp for any flow rate
RealdeltaM10.1Fraction of nominal flow rate where flow transitions to laminar
Medium 2
Booleanfrom_dp2false= true, use m_flow = f(dp) else dp = f(m_flow)
BooleanlinearizeFlowResistance2false= true, use linear relation between m_flow and dp for any flow rate
RealdeltaM20.1Fraction of nominal flow rate where flow transitions to laminar
Dynamics
Filtered opening
Booleanuse_inputFiltertrue= true, if opening is filtered with a 2nd order CriticalDamping filter
TimeriseTimeValve120Rise time of the filter (time to reach 99.6 % of an opening step) [s]
InitinitValveModelica.Blocks.Types.Init.I...Type of initialization (no init/steady state/initial state/initial output)
RealyValve_start[numFil]{yValWSE_start}Initial value of output:0-closed, 1-fully opened
RealyThrWayVal_start1Initial value of output from the filter in the bypass valve
RealyValWSE_start1Initial value of output from the filter in the shutoff valve
Equations
DynamicsenergyDynamicsModelica.Fluid.Types.Dynamic...Type of energy balance: dynamic (3 initialization options) or steady state
DynamicsmassDynamicsenergyDynamicsType of mass balance: dynamic (3 initialization options) or steady state
RealmSenFac1Factor for scaling the sensible thermal mass of the volume
Nominal condition
TimetauThrWayVal10Time constant at nominal flow for dynamic energy and momentum balance of the three-way valve [s]
Initialization
AbsolutePressurep_startMedium.p_defaultStart value of pressure [Pa]
TemperatureT_startMedium.T_defaultStart value of temperature [K]
MassFractionX_start[Medium.nX]Medium.X_defaultStart value of mass fractions m_i/m [kg/kg]
ExtraPropertyC_start[Medium.nC]fill(0, Medium.nC)Start value of trace substances
ExtraPropertyC_nominal[Medium.nC]fill(1E-2, Medium.nC)Nominal value of trace substances. (Set to typical order of magnitude.)
Controller
SimpleControllercontrollerTypeModelica.Blocks.Types.Simple...Type of controller
Realk1Gain of controller [1]
TimeTi0.5Time constant of integrator block [s]
TimeTd0.1Time constant of derivative block [s]
RealyMax1Upper limit of output
RealyMin0Lower limit of output
Realwp1Set-point weight for Proportional block (0..1)
Realwd0Set-point weight for Derivative block (0..1)
RealNi0.9Ni*Ti is time constant of anti-windup compensation
RealNd10The higher Nd, the more ideal the derivative block
BooleanreverseActiontrueSet to true for throttling the water flow rate through a cooling coil controller
Initialization
InitPIDinitTypeModelica.Blocks.Types.InitPI...Type of initialization (1: no init, 2: steady state, 3: initial state, 4: initial output)
Realxi_start0Initial or guess value value for integrator output (= integrator state)
Realxd_start0Initial or guess value for state of derivative block
RealyCon_start0Initial value of output from the controller
Integrator reset
ResetresetBuildings.Types.Reset.DisabledType of controller output reset
Realy_resetxi_startValue to which the controller output is reset if the boolean trigger has a rising edge, used if reset == Buildings.Types.Reset.Parameter

Connectors

TypeNameDescription
FluidPort_aport_a1Fluid connector a1 (positive design flow direction is from port_a1 to port_b1)
FluidPort_bport_b1Fluid connector b1 (positive design flow direction is from port_a1 to port_b1)
FluidPort_aport_a2Fluid connector a2 (positive design flow direction is from port_a2 to port_b2)
FluidPort_bport_b2Fluid connector b2 (positive design flow direction is from port_a2 to port_b2)
input BooleanInputon[num]Set to true to enable equipment, or false to disable equipment
replaceable package MediumMedium in the component
input BooleanInputtriggerResets the controller output when trigger becomes true
input RealInputy_reset_inInput signal for state to which integrator is reset, enabled if reset = Buildings.Types.Reset.Input
input RealInputTSetSet point for leaving water temperature [K]

Modelica definition

model WatersideEconomizer "Waterside economizer" extends Buildings.Applications.DataCenters.ChillerCooled.Equipment.BaseClasses.PartialPlantParallel ( final num=1, val2(each final dpFixed_nominal=0), val1(each final dpFixed_nominal=dp1_nominal), kFixed={m1_flow_nominal/sqrt(dp1_nominal),0}, final yValve_start={yValWSE_start}); extends Buildings.Fluid.Interfaces.LumpedVolumeDeclarations( final mSenFac=1, redeclare final package Medium=Medium2); extends Buildings.Applications.DataCenters.ChillerCooled.Equipment.BaseClasses.ThreeWayValveParameters ( final activate_ThrWayVal=use_controller); extends Buildings.Applications.DataCenters.ChillerCooled.Equipment.BaseClasses.PartialControllerInterface; // Filter opening parameter Real yThrWayVal_start=1 "Initial value of output from the filter in the bypass valve"; parameter Real yValWSE_start=1 "Initial value of output from the filter in the shutoff valve"; // Heat exchanger parameter Modelica.SIunits.Efficiency eta(start=0.8) "constant effectiveness"; // Bypass valve parameters parameter Modelica.SIunits.Time tauThrWayVal=10 "Time constant at nominal flow for dynamic energy and momentum balance of the three-way valve"; Modelica.Blocks.Interfaces.RealInput TSet( unit="K", displayUnit="degC") if use_controller "Set point for leaving water temperature"; Buildings.Applications.DataCenters.ChillerCooled.Equipment.HeatExchanger_TSet heaExc( redeclare final replaceable package Medium1 = Medium1, redeclare final replaceable package Medium2 = Medium2, final use_controller=use_controller, final m1_flow_nominal=m1_flow_nominal, final m2_flow_nominal=m2_flow_nominal, final dp1_nominal=dp1_nominal, final dp2_nominal=dp2_nominal, final controllerType=controllerType, final k=k, final Ti=Ti, final Td=Td, final yMax=yMax, final yMin=yMin, final wp=wp, final wd=wd, final Ni=Ni, final Nd=Nd, final initType=initType, final xi_start=xi_start, final xd_start=xd_start, final yCon_start=yCon_start, final reset=reset, final y_reset=y_reset, final allowFlowReversal1=allowFlowReversal1, final allowFlowReversal2=allowFlowReversal2, final m1_flow_small=m1_flow_small, final m2_flow_small=m2_flow_small, final show_T=show_T, final from_dp1=from_dp1, final linearizeFlowResistance1=linearizeFlowResistance1, final deltaM1=deltaM1, final from_dp2=from_dp2, final linearizeFlowResistance2=linearizeFlowResistance2, final deltaM2=deltaM2, final homotopyInitialization=homotopyInitialization, final energyDynamics=energyDynamics, final massDynamics=massDynamics, final p_start=p_start, final T_start=T_start, final X_start=X_start, final C_start=C_start, final C_nominal=C_nominal, final use_inputFilter=use_inputFilter, final riseTime=riseTimeValve, final init=initValve, final yThrWayVal_start=yThrWayVal_start, final eta=eta, final fraK_ThrWayVal=fraK_ThrWayVal, final l_ThrWayVal=l_ThrWayVal, final R=R, final delta0=delta0, final tauThrWayVal=tauThrWayVal, final portFlowDirection_1=portFlowDirection_1, final portFlowDirection_2=portFlowDirection_2, final portFlowDirection_3=portFlowDirection_3, final rhoStd=rhoStd[2], final reverseAction=reverseAction) "Water-to-water heat exchanger"; equation connect(port_a1, heaExc.port_a1); connect(heaExc.port_a2, port_a2); connect(TSet, heaExc.TSet); connect(y_reset_in, heaExc.y_reset_in); connect(trigger, heaExc.trigger); connect(heaExc.port_b1, val1[1].port_a); connect(val2[1].port_a, heaExc.port_b2); end WatersideEconomizer;