Buildings.Experimental.DHC.Plants.BaseClasses

Package with base classes

Information

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

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

Package Content

Name Description
Buildings.Experimental.DHC.Plants.BaseClasses.PartialPlant PartialPlant Partial class for modeling a central plant

Buildings.Experimental.DHC.Plants.BaseClasses.PartialPlant Buildings.Experimental.DHC.Plants.BaseClasses.PartialPlant

Partial class for modeling a central plant

Buildings.Experimental.DHC.Plants.BaseClasses.PartialPlant

Information

Partial class to be used for modeling a central plant.

The connectors to the service lines are configured based on an enumeration defining the type of district system, see Buildings.Experimental.DHC.Types.DistrictSystemType. In case of a heating service line, the model allows for using two different media at the supply port port_bSerHea and at the return port_aSerHea to represent a steam supply and condensate return.

Parameters

TypeNameDefaultDescription
replaceable package MediumBuildings.Media.WaterService side medium
replaceable package MediumHea_bBuildings.Media.WaterService side medium at heating supply
Configuration
DistrictSystemTypetypBuildings.Experimental.DHC.T...Type of district system
Booleanhave_fanfalseSet to true if fan power is computed
Booleanhave_pumfalseSet to true if pump power is computed
Booleanhave_eleHeafalseSet to true if the plant has electric heating system
Booleanhave_eleCoofalseSet to true if the plant has electric cooling system
Booleanhave_weaBusfalseSet to true to use a weather bus
Assumptions
BooleanallowFlowReversalfalseSet to true to allow flow reversal in service lines

Connectors

TypeNameDescription
replaceable package MediumService side medium
replaceable package MediumHea_bService side medium at heating supply
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
BusweaBusWeather data bus
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]

Modelica definition

partial model PartialPlant "Partial class for modeling a central plant" replaceable package Medium=Buildings.Media.Water constrainedby Modelica.Media.Interfaces.PartialMedium "Service side medium"; replaceable package MediumHea_b=Buildings.Media.Water constrainedby Modelica.Media.Interfaces.PartialMedium "Service side medium at heating supply"; parameter Buildings.Experimental.DHC.Types.DistrictSystemType typ=Buildings.Experimental.DHC.Types.DistrictSystemType.CombinedGeneration2to4 "Type of district system"; parameter Boolean have_fan=false "Set to true if fan power is computed"; parameter Boolean have_pum=false "Set to true if pump power is computed"; parameter Boolean have_eleHea=false "Set to true if the plant has electric heating system"; // Placeholder parameter final parameter Integer nFue=0 "Number of fuel types (0 means no combustion system)"; parameter Boolean have_eleCoo=false "Set to true if the plant has electric cooling system"; parameter Boolean have_weaBus=false "Set to true to use a weather bus"; parameter Boolean allowFlowReversal=false "Set to true to allow flow reversal in service lines"; final parameter Buildings.Fluid.Data.Fuels.Generic fue[nFue] "Fuel type"; // IO CONNECTORS Modelica.Fluid.Interfaces.FluidPort_a port_aSerAmb( redeclare package Medium = Medium, m_flow(min=if allowFlowReversal then -Modelica.Constants.inf else 0), h_outflow(start=Medium.h_default, nominal=Medium.h_default)) if have_serAmb "Fluid connector for ambient water service supply line"; Modelica.Fluid.Interfaces.FluidPort_b port_bSerAmb( redeclare package Medium = Medium, m_flow(max=if allowFlowReversal then +Modelica.Constants.inf else 0), h_outflow(start=Medium.h_default, nominal=Medium.h_default)) if have_serAmb "Fluid connector for ambient water service return line"; Modelica.Fluid.Interfaces.FluidPort_a port_aSerHea( redeclare package Medium = Medium, m_flow(min=if allowFlowReversal then -Modelica.Constants.inf else 0), h_outflow(start=Medium.h_default, nominal=Medium.h_default)) if have_hea "Fluid connector for heating service supply line"; Modelica.Fluid.Interfaces.FluidPort_b port_bSerHea( redeclare package Medium = MediumHea_b, m_flow(max=if allowFlowReversal then +Modelica.Constants.inf else 0), h_outflow(start=MediumHea_b.h_default, nominal=MediumHea_b.h_default)) if have_hea "Fluid connector for heating service return line"; Modelica.Fluid.Interfaces.FluidPort_a port_aSerCoo( redeclare package Medium = Medium, m_flow(min=if allowFlowReversal then -Modelica.Constants.inf else 0), h_outflow(start=Medium.h_default, nominal=Medium.h_default)) if have_coo "Fluid connector for cooling service supply line"; Modelica.Fluid.Interfaces.FluidPort_b port_bSerCoo( redeclare package Medium = Medium, m_flow(max=if allowFlowReversal then +Modelica.Constants.inf else 0), h_outflow(start=Medium.h_default, nominal=Medium.h_default)) if have_coo "Fluid connector for cooling service return line"; Buildings.BoundaryConditions.WeatherData.Bus weaBus if have_weaBus "Weather data bus"; Buildings.Controls.OBC.CDL.Interfaces.RealOutput PHea( final unit="W") if have_eleHea "Power drawn by heating system"; Buildings.Controls.OBC.CDL.Interfaces.RealOutput PCoo( final unit="W") if have_eleCoo "Power drawn by cooling system"; Buildings.Controls.OBC.CDL.Interfaces.RealOutput PFan( final unit="W") if have_fan "Power drawn by fan motors"; Buildings.Controls.OBC.CDL.Interfaces.RealOutput PPum( final unit="W") if have_pum "Power drawn by pump motors"; Buildings.Controls.OBC.CDL.Interfaces.RealOutput QFue_flow[nFue]( each final unit="W") if nFue>0 "Fuel energy input rate"; protected final parameter Boolean have_hea=typ <> Buildings.Experimental.DHC.Types.DistrictSystemType.Cooling and typ <> Buildings.Experimental.DHC.Types.DistrictSystemType.CombinedGeneration5 "Boolean flag to enable fluid connectors for heating service line"; final parameter Boolean have_coo=typ == Buildings.Experimental.DHC.Types.DistrictSystemType.CombinedGeneration1 or typ == Buildings.Experimental.DHC.Types.DistrictSystemType.CombinedGeneration2to4 or typ == Buildings.Experimental.DHC.Types.DistrictSystemType.Cooling "Boolean flag to enable fluid connectors for cooling service line"; final parameter Boolean have_serAmb=typ == Buildings.Experimental.DHC.Types.DistrictSystemType.CombinedGeneration5 "Boolean flag to enable fluid connector for ambient water service line"; end PartialPlant;