Buildings.Experimental.DHC.EnergyTransferStations.Combined.Generation5.BaseClasses

Package with base classes

Information

This package contains base classes that are used to construct the classes in Buildings.Experimental.DHC.EnergyTransferStations.Combined.Generation5.

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

Package Content

Name Description
Buildings.Experimental.DHC.EnergyTransferStations.Combined.Generation5.BaseClasses.PartialParallel PartialParallel Partial ETS model with district heat exchanger and parallel connection of production systems

Buildings.Experimental.DHC.EnergyTransferStations.Combined.Generation5.BaseClasses.PartialParallel Buildings.Experimental.DHC.EnergyTransferStations.Combined.Generation5.BaseClasses.PartialParallel

Partial ETS model with district heat exchanger and parallel connection of production systems

Buildings.Experimental.DHC.EnergyTransferStations.Combined.Generation5.BaseClasses.PartialParallel

Information

This is a base model providing the hydronic configuration for an energy transfer station as described in the schematics below. It is typically used to integrate systems providing both heating water and chilled water, such as heat recovery chillers. Furthermore, it can be connected to an adjustable number (nSouAmb) of systems serving as ambient sources (including the district heat exchanger).

Models that extend this base class must

Eventually, note that this hydronic layout is not compatible with a compressor-less cooling mode using only the district heat exchanger.

Sequence chart

Extends from DHC.EnergyTransferStations.BaseClasses.PartialETS (Partial class for modeling an energy transfer station).

Parameters

TypeNameDefaultDescription
replaceable package MediumSerWaterService side medium
replaceable package MediumSerHea_aWaterService side medium at heating inlet
replaceable package MediumBuiWaterBuilding side medium
Genericfue[nFue] Fuel type
ConnectionConfigurationconConEnergyTransferStations.Types...District connection configuration
IntegernSysHea Number of heating systems
IntegernSysCoonSysHeaNumber of cooling systems
IntegernSouAmb1Number of ambient sources
PartialSupervisoryconSupredeclare Generation5.Contro...Supervisory controller
Configuration
DistrictSystemTypetypDHC.Types.DistrictSystemType...Type of district system
Booleanhave_heaWattrueSet to true if the ETS supplies heating water
Booleanhave_hotWatfalseSet to true if the ETS supplies hot water
Booleanhave_chiWattrueSet to true if the ETS supplies chilled water
Booleanhave_fanfalseSet to true if fan power is computed
Booleanhave_pumtrueSet to true if pump power is computed
Booleanhave_eleHeafalseSet to true if the ETS has electric heating system
IntegernFue0Number of fuel types (0 means no combustion system)
Booleanhave_eleCoofalseSet to true if the ETS has electric cooling system
Booleanhave_weaBusfalseSet to true to use a weather bus
Nominal condition
HeatFlowRateQHeaWat_flow_nominal0Nominal capacity of heating system (>=0) [W]
HeatFlowRateQHotWat_flow_nominal0Nominal capacity of hot water production system (>=0) [W]
HeatFlowRateQChiWat_flow_nominal0Nominal capacity of cooling system (<=0) [W]
PressureDifferencedpValIso_nominal2E3Nominal pressure drop of ambient circuit isolation valves [Pa]
District heat exchanger
PressureDifferencedp1Hex_nominal Nominal pressure drop across heat exchanger on district side [Pa]
PressureDifferencedp2Hex_nominal Nominal pressure drop across heat exchanger on building side [Pa]
HeatFlowRateQHex_flow_nominal Nominal heat flow rate through heat exchanger (from district to building) [W]
TemperatureT_a1Hex_nominal Nominal water inlet temperature on district side [K]
TemperatureT_b1Hex_nominal Nominal water outlet temperature on district side [K]
TemperatureT_a2Hex_nominal Nominal water inlet temperature on building side [K]
TemperatureT_b2Hex_nominal Nominal water outlet temperature on building side [K]
TemperatureDifferencedT1HexSet[2] Primary side deltaT set point schedule (index 1 for heat rejection) [K]
RealspePum1HexMin0.1Heat exchanger primary pump minimum speed (fractional) [1]
RealyVal1HexMin0.1Minimum valve opening for temperature measurement (fractional) [1]
RealspePum2HexMin0.1Heat exchanger secondary pump minimum speed (fractional) [1]
GenericperPum1HexperPum1Hex(motorCooledByFlui...Record with performance data for primary pump
GenericperPum2HexperPum2Hex(motorCooledByFlui...Record with performance data for secondary pump
Buffer Tank
VolumeVTanHeaWat Heating water tank volume [m3]
LengthhTanHeaWat(VTanHeaWat*16/Modelica.Cons...Heating water tank height (assuming twice the diameter) [m]
LengthdInsTanHeaWat0.1Heating water tank insulation thickness [m]
VolumeVTanChiWat Chilled water tank volume [m3]
LengthhTanChiWat(VTanChiWat*16/Modelica.Cons...Chilled water tank height (without insulation) [m]
LengthdInsTanChiWat0.1Chilled water tank insulation thickness [m]
IntegernSegTan3Number of volume segments for tanks
Assumptions
BooleanallowFlowReversalSerfalseSet to true to allow flow reversal on service side
BooleanallowFlowReversalBuifalseSet to true to allow flow reversal on building side

Connectors

TypeNameDescription
FluidPorts_aports_aHeaWat[nPorts_aHeaWat]Fluid connectors for heating water return (from building)
FluidPorts_bports_bHeaWat[nPorts_bHeaWat]Fluid connectors for heating water supply (to building)
FluidPorts_aports_aChiWat[nPorts_aChiWat]Fluid connectors for chilled water return (from building)
FluidPorts_bports_bChiWat[nPorts_bChiWat]Fluid connectors for chilled water supply (to building)
FluidPort_aport_aSerAmbFluid connector for ambient water service supply line
FluidPort_bport_bSerAmbFluid connector for ambient water service return line
FluidPort_aport_aSerHeaFluid connector for heating service supply line
FluidPort_bport_bSerHeaFluid connector for heating service return line
FluidPort_aport_aSerCooFluid connector for cooling service supply line
FluidPort_bport_bSerCooFluid connector for cooling service return line
output RealOutputPHeaPower drawn by heating system [W]
output RealOutputPCooPower drawn by cooling system [W]
output RealOutputPFanPower drawn by fan motors [W]
output RealOutputPPumPower drawn by pump motors [W]
output RealOutputQFue_flow[nFue]Fuel energy input rate [W]
BusweaBusWeather data bus
input BooleanInputuHeaHeating enable signal
input BooleanInputuCooCooling enable signal
input RealInputTHeaWatSupSetHeating water supply temperature set point [K]
input RealInputTChiWatSupSetChilled water supply temperature set point [K]
output RealOutputdHHeaWat_flowHeating water distributed energy flow rate [W]
output RealOutputdHChiWat_flowChilled water distributed energy flow rate [W]

Modelica definition

model PartialParallel "Partial ETS model with district heat exchanger and parallel connection of production systems" extends DHC.EnergyTransferStations.BaseClasses.PartialETS( final typ=DHC.Types.DistrictSystemType.CombinedGeneration5, final have_heaWat=true, final have_chiWat=true, final have_pum=true, have_hotWat=false, have_eleHea=false, have_weaBus=false, nPorts_bChiWat=1, nPorts_aChiWat=1, nPorts_bHeaWat=1, nPorts_aHeaWat=1); parameter EnergyTransferStations.Types.ConnectionConfiguration conCon= EnergyTransferStations.Types.ConnectionConfiguration.Pump "District connection configuration"; parameter Integer nSysHea "Number of heating systems"; parameter Integer nSysCoo=nSysHea "Number of cooling systems"; parameter Integer nSouAmb=1 "Number of ambient sources"; parameter Modelica.SIunits.PressureDifference dpValIso_nominal( displayUnit="Pa")=2E3 "Nominal pressure drop of ambient circuit isolation valves"; parameter Modelica.SIunits.PressureDifference dp1Hex_nominal( displayUnit="Pa") "Nominal pressure drop across heat exchanger on district side"; parameter Modelica.SIunits.PressureDifference dp2Hex_nominal( displayUnit="Pa") "Nominal pressure drop across heat exchanger on building side"; parameter Modelica.SIunits.HeatFlowRate QHex_flow_nominal "Nominal heat flow rate through heat exchanger (from district to building)"; parameter Modelica.SIunits.Temperature T_a1Hex_nominal "Nominal water inlet temperature on district side"; parameter Modelica.SIunits.Temperature T_b1Hex_nominal "Nominal water outlet temperature on district side"; parameter Modelica.SIunits.Temperature T_a2Hex_nominal "Nominal water inlet temperature on building side"; parameter Modelica.SIunits.Temperature T_b2Hex_nominal "Nominal water outlet temperature on building side"; parameter Modelica.SIunits.TemperatureDifference dT1HexSet[2] "Primary side deltaT set point schedule (index 1 for heat rejection)"; parameter Real spePum1HexMin( final unit="1", min=0)=0.1 "Heat exchanger primary pump minimum speed (fractional)"; parameter Real yVal1HexMin( final unit="1", min=0.01)=0.1 "Minimum valve opening for temperature measurement (fractional)"; parameter Real spePum2HexMin( final unit="1", min=0.01)=0.1 "Heat exchanger secondary pump minimum speed (fractional)"; replaceable parameter Buildings.Fluid.Movers.Data.Generic perPum1Hex( motorCooledByFluid=false) constrainedby Buildings.Fluid.Movers.Data.Generic "Record with performance data for primary pump"; replaceable parameter Buildings.Fluid.Movers.Data.Generic perPum2Hex( motorCooledByFluid=false) constrainedby Buildings.Fluid.Movers.Data.Generic "Record with performance data for secondary pump"; parameter Modelica.SIunits.Volume VTanHeaWat "Heating water tank volume"; parameter Modelica.SIunits.Length hTanHeaWat=(VTanHeaWat*16/Modelica.Constants.pi)^(1/3) "Heating water tank height (assuming twice the diameter)"; parameter Modelica.SIunits.Length dInsTanHeaWat=0.1 "Heating water tank insulation thickness"; parameter Modelica.SIunits.Volume VTanChiWat "Chilled water tank volume"; parameter Modelica.SIunits.Length hTanChiWat=(VTanChiWat*16/Modelica.Constants.pi)^(1/3) "Chilled water tank height (without insulation)"; parameter Modelica.SIunits.Length dInsTanChiWat=0.1 "Chilled water tank insulation thickness"; parameter Integer nSegTan=3 "Number of volume segments for tanks"; // IO VARIABLES Buildings.Controls.OBC.CDL.Interfaces.BooleanInput uHea "Heating enable signal"; Buildings.Controls.OBC.CDL.Interfaces.BooleanInput uCoo "Cooling enable signal"; Buildings.Controls.OBC.CDL.Interfaces.RealInput THeaWatSupSet( final unit="K", displayUnit="degC") "Heating water supply temperature set point"; Buildings.Controls.OBC.CDL.Interfaces.RealInput TChiWatSupSet( final unit="K", displayUnit="degC") "Chilled water supply temperature set point"; Buildings.Controls.OBC.CDL.Interfaces.RealOutput dHHeaWat_flow( final unit="W") "Heating water distributed energy flow rate"; Buildings.Controls.OBC.CDL.Interfaces.RealOutput dHChiWat_flow( final unit="W") "Chilled water distributed energy flow rate"; // COMPONENTS replaceable Generation5.Controls.BaseClasses.PartialSupervisory conSup constrainedby Generation5.Controls.BaseClasses.PartialSupervisory( final nSouAmb=nSouAmb) "Supervisory controller"; Fluid.Actuators.Valves.TwoWayLinear valIsoEva( redeclare final package Medium=MediumBui, final dpValve_nominal=dpValIso_nominal, final m_flow_nominal=colAmbWat.mDis_flow_nominal, use_inputFilter=false) "Evaporator to ambient loop isolation valve"; Fluid.Actuators.Valves.TwoWayLinear valIsoCon( redeclare final package Medium=MediumBui, final dpValve_nominal=dpValIso_nominal, final m_flow_nominal=colAmbWat.mDis_flow_nominal, use_inputFilter=false) "Condenser to ambient loop isolation valve"; Subsystems.HeatExchanger hex( redeclare final package Medium1=MediumSer, redeclare final package Medium2=MediumBui, final perPum1=perPum1Hex, final perPum2=perPum2Hex, final allowFlowReversal1=allowFlowReversalSer, final allowFlowReversal2=allowFlowReversalBui, final conCon=conCon, final dp1Hex_nominal=dp1Hex_nominal, final dp2Hex_nominal=dp2Hex_nominal, final QHex_flow_nominal=QHex_flow_nominal, final T_a1Hex_nominal=T_a1Hex_nominal, final T_b1Hex_nominal=T_b1Hex_nominal, final T_a2Hex_nominal=T_a2Hex_nominal, final T_b2Hex_nominal=T_b2Hex_nominal, final dT1HexSet=dT1HexSet, final spePum1HexMin=spePum1HexMin, final yVal1HexMin=yVal1HexMin, final spePum2HexMin=spePum2HexMin) "District heat exchanger"; EnergyTransferStations.BaseClasses.StratifiedTank tanChiWat( redeclare final package Medium=MediumBui, final m_flow_nominal=colChiWat.mDis_flow_nominal, final VTan=VTanChiWat, final hTan=hTanChiWat, final dIns=dInsTanChiWat, final nSeg=nSegTan) "Chilled water tank"; EnergyTransferStations.BaseClasses.StratifiedTank tanHeaWat( redeclare final package Medium=MediumBui, final m_flow_nominal=colHeaWat.mDis_flow_nominal, final VTan=VTanHeaWat, final hTan=hTanHeaWat, final dIns=dInsTanHeaWat, final nSeg=nSegTan) "Heating water tank"; EnergyTransferStations.BaseClasses.CollectorDistributor colChiWat( redeclare final package Medium=MediumBui, final nCon=1+nSysCoo, mCon_flow_nominal={colAmbWat.mDis_flow_nominal}) "Collector/distributor for chilled water"; EnergyTransferStations.BaseClasses.CollectorDistributor colHeaWat( redeclare final package Medium=MediumBui, final nCon=1+nSysHea, mCon_flow_nominal={colAmbWat.mDis_flow_nominal}) "Collector/distributor for heating water"; EnergyTransferStations.BaseClasses.CollectorDistributor colAmbWat( redeclare final package Medium=MediumBui, final nCon=nSouAmb, mCon_flow_nominal={hex.m2_flow_nominal}) "Collector/distributor for ambient water"; Buildings.Controls.OBC.CDL.Continuous.MultiSum totPPum( nin=1) "Total pump power"; Buildings.Controls.OBC.CDL.Continuous.MultiSum totPHea( nin=1) "Total power drawn by heating system"; Buildings.Controls.OBC.CDL.Continuous.MultiSum totPCoo( nin=1) "Total power drawn by cooling system"; Networks.BaseClasses.DifferenceEnthalpyFlowRate dHFloChiWat( redeclare final package Medium1=MediumBui, final m_flow_nominal=colChiWat.mDis_flow_nominal) "Variation of enthalpy flow rate"; Networks.BaseClasses.DifferenceEnthalpyFlowRate dHFloHeaWat( redeclare final package Medium1=MediumBui, final m_flow_nominal=colHeaWat.mDis_flow_nominal) "Variation of enthalpy flow rate"; protected parameter Boolean have_val1Hex=conCon == Buildings.Experimental.DHC.EnergyTransferStations.Types.ConnectionConfiguration.TwoWayValve "True in case of control valve on district side, false in case of a pump"; equation connect(hex.PPum,totPPum.u[1]); connect(THeaWatSupSet,conSup.THeaWatSupPreSet); connect(port_aSerAmb, hex.port_a1); connect(hex.port_b1, port_bSerAmb); connect(tanHeaWat.TTop,conSup.THeaWatTop); connect(tanChiWat.TBot,conSup.TChiWatBot); connect(hex.port_b2,colAmbWat.ports_aCon[1]); connect(hex.port_a2,colAmbWat.ports_bCon[1]); connect(totPPum.y,PPum); connect(hex.yValIso_actual[1],valIsoCon.y_actual); connect(hex.yValIso_actual[2],valIsoEva.y_actual); connect(valIsoEva.port_b,colAmbWat.port_bDisSup); connect(valIsoCon.port_b,colAmbWat.port_aDisSup); connect(TChiWatSupSet,conSup.TChiWatSupPreSet); connect(uCoo,conSup.uCoo); connect(uHea,conSup.uHea); connect(valIsoEva.port_a,colChiWat.ports_aCon[1]); connect(colAmbWat.port_aDisRet,colChiWat.ports_bCon[1]); connect(conSup.yValIsoEva,valIsoEva.y); connect(conSup.yValIsoCon,valIsoCon.y); connect(conSup.yAmb[nSouAmb],hex.u); connect(colChiWat.port_bDisRet,tanChiWat.port_aBot); connect(colChiWat.port_aDisSup,tanChiWat.port_bTop); connect(colHeaWat.port_bDisRet,tanHeaWat.port_aTop); connect(tanHeaWat.port_bBot,colHeaWat.port_aDisSup); connect(valIsoCon.port_a,colHeaWat.ports_aCon[1]); connect(colAmbWat.port_bDisRet,colHeaWat.ports_bCon[1]); connect(totPHea.y,PHea); connect(totPCoo.y,PCoo); connect(tanChiWat.port_bBot,dHFloChiWat.port_a1); connect(dHFloChiWat.port_b1,ports_bChiWat[1]); connect(tanChiWat.port_aTop,dHFloChiWat.port_b2); connect(dHFloChiWat.port_a2,ports_aChiWat[1]); connect(dHFloChiWat.dH_flow,dHChiWat_flow); connect(tanHeaWat.port_bTop,dHFloHeaWat.port_a1); connect(dHFloHeaWat.port_b1,ports_bHeaWat[1]); connect(ports_aHeaWat[1],dHFloHeaWat.port_a2); connect(dHFloHeaWat.port_b2,tanHeaWat.port_aBot); connect(dHFloHeaWat.dH_flow,dHHeaWat_flow); end PartialParallel;