modelLoad
Model of a load on a hydronic circuit
Extends from Buildings.Fluid.Interfaces.PartialTwoPortInterface (Partial model with two ports and declaration of quantities that are used by many models).
Information
This model represents a thermal load on a hydronic circuit, typically
a terminal unit with recirculating air such as a fan coil unit. It takes the
fraction of the design load u as input and returns the control
valve demand signal yVal as output.
Modeling assumptions
The design pressure drop on the source side may be specified with
the parameter dpLiq_nominal.
The inlet conditions on the load side are constant and equal
to the design conditions. The mass flow rate is modulated based on the input
signal u, with a minimum value of u_min.
Parameters
| Type | Name | Default | Description |
|---|---|---|---|
| Buildings.Fluid.HydronicConfigurations.Types.Control | typ | Load type | |
| Modelica.Units.SI.MassFlowRate | mLiq_flow_nominal | 1 | Liquid mass flow rate at design conditions |
| Modelica.Units.SI.PressureDifference | dpLiq_nominal | 0 | Liquid pressure drop at design conditions |
| Modelica.Units.SI.MassFlowRate | mAir_flow_nominal | abs(Q_flow_nominal)/10/cpAir_nominal | Air mass flow rate at design conditions |
| Modelica.Units.SI.Temperature | TAirEnt_nominal | if typ == Buildings.Fluid.HydronicConfigurations.Types.Control.Heating then 20 + 273.15 else 26 + 273.15 | Air entering temperature at design conditions |
| Modelica.Units.SI.MassFraction | phiAirEnt_nominal | 0.5 | Air entering relative humidity at design conditions |
| Modelica.Units.SI.MassFraction | XAirEnt_nominal | Buildings.Utilities.Psychrometrics.Functions.X_pTphi(MediumAir.p_default, TAirEnt_nominal, phiAirEnt_nominal) | Air entering water mass fraction at design conditions (kg/kg air) |
| Modelica.Units.SI.MassFraction | xAirEnt_nominal | XAirEnt_nominal/(1 - XAirEnt_nominal) | Air entering humidity ratio at design conditions (kg/kg dry air) |
| Modelica.Units.SI.Temperature | TLiqEnt_nominal | if typ == Buildings.Fluid.HydronicConfigurations.Types.Control.Heating then 60 + 273.15 else 7 + 273.15 | Liquid entering temperature at design conditions |
| Modelica.Units.SI.Temperature | TLiqLvg_nominal | TLiqEnt_nominal + (if typ == Buildings.Fluid.HydronicConfigurations.Types.Control.Heating then -10 else +5) | Liquid leaving temperature at design conditions |
| Modelica.Units.SI.HeatFlowRate | Q_flow_nominal | (MediumLiq.specificEnthalpy_pTX(MediumLiq.p_default, TLiqEnt_nominal, X = MediumLiq.X_default) - MediumLiq.specificEnthalpy_pTX(MediumLiq.p_default, TLiqLvg_nominal, X = MediumLiq.X_default))*mLiq_flow_nominal | Transmitted heat flow rate at design conditions |
| Real | u_min | 0.1 | Minimum fan speed |
| Assumptions | |||
| Boolean | allowFlowReversal (from PartialTwoPort) | true | = false to simplify equations, assuming, but not enforcing, no flow reversal |
| Nominal condition | |||
| Modelica.Units.SI.MassFlowRate | m_flow_nominal (from PartialTwoPortInterface) | Nominal mass flow rate | |
| Advanced | |||
| Modelica.Units.SI.MassFlowRate | m_flow_small (from PartialTwoPortInterface) | 1E-4*abs(m_flow_nominal) | Small mass flow rate for regularization of zero flow |
| Advanced › Diagnostics | |||
| Boolean | show_T (from PartialTwoPortInterface) | false | = true, if actual temperature at port is computed |
| Valve controller | |||
| Buildings.Controls.OBC.CDL.Types.SimpleController | controllerType | Buildings.Controls.OBC.CDL.Types.SimpleController.PI | Type of controller |
| Real | k | 0.1 | Gain of controller |
| Real | Ti | 10 | Time constant of integrator block |
| Real | Td | 0.1 | Time constant of derivative block |
| Dynamics › Conservation equations | |||
| Modelica.Fluid.Types.Dynamics | energyDynamics | Modelica.Fluid.Types.Dynamics.FixedInitial | Type of energy balance: dynamic (3 initialization options) or steady state |
Connectors
| Type | Name | Default | Description |
|---|---|---|---|
| Modelica.Fluid.Interfaces.FluidPort_a | port_a (from PartialTwoPort) | Fluid connector a (positive design flow direction is from port_a to port_b) | |
| Modelica.Fluid.Interfaces.FluidPort_b | port_b (from PartialTwoPort) | Fluid connector b (positive design flow direction is from port_a to port_b) | |
| Buildings.Controls.OBC.CDL.Interfaces.RealInput | u | Fraction of design load | |
| Buildings.Controls.OBC.CDL.Interfaces.BooleanInput | u1 | System enable | |
| Buildings.Controls.OBC.CDL.Interfaces.RealOutput | yVal | Valve demand signal | |
| Buildings.Controls.OBC.CDL.Interfaces.RealOutput | dTLiq | Liquid deltaT | |
| Buildings.Controls.OBC.CDL.Interfaces.RealOutput | Q_flow | Total heat flow rate transferred to the load | |
| Buildings.Controls.OBC.CDL.Interfaces.RealOutput | yLoa_actual | Actual load fraction met |
Components
| Type | Name | Default | Description |
|---|---|---|---|
| Modelica.Units.SI.MassFlowRate | m_flow (from PartialTwoPortInterface) | port_a.m_flow | Mass flow rate from port_a to port_b (m_flow > 0 is design flow direction) |
| Modelica.Units.SI.PressureDifference | dp (from PartialTwoPortInterface) | port_a.p - port_b.p | Pressure difference between port_a and port_b |
| Medium.ThermodynamicState | sta_a (from PartialTwoPortInterface) | if allowFlowReversal then Medium.setState_phX(port_a.p, noEvent(actualStream(port_a.h_outflow)), noEvent(actualStream(port_a.Xi_outflow))) else Medium.setState_phX(port_a.p, noEvent(inStream(port_a.h_outflow)), noEvent(inStream(port_a.Xi_outflow))) | Medium properties in port_a |
| Medium.ThermodynamicState | sta_b (from PartialTwoPortInterface) | if allowFlowReversal then Medium.setState_phX(port_b.p, noEvent(actualStream(port_b.h_outflow)), noEvent(actualStream(port_b.Xi_outflow))) else Medium.setState_phX(port_b.p, noEvent(port_b.h_outflow), noEvent(port_b.Xi_outflow)) | Medium properties in port_b |
| Buildings.Fluid.Sources.Boundary_pT | outAir | Pressure boundary condition at coil outlet | |
| Buildings.Fluid.Sensors.TemperatureTwoPort | TAirLvg | Leaving air temperature sensor | |
| Buildings.Fluid.HeatExchangers.WetCoilEffectivenessNTU | coi | Coil | |
| Buildings.Fluid.Sources.MassFlowSource_T | souAir | Source for entering air | |
| Buildings.Controls.OBC.Utilities.PIDWithEnable | conPID | Controller | |
| Buildings.Fluid.Sensors.TemperatureTwoPort | TLiqEnt | Entering liquid temperature sensor | |
| Buildings.Fluid.Sensors.TemperatureTwoPort | TLiqLvg | Leaving liquid temperature sensor | |
| Buildings.Controls.OBC.CDL.Reals.Subtract | dT | Compute deltaT | |
| Modelica.Blocks.Sources.RealExpression | heaFlo | Access coil heat flow rate | |
| Modelica.Blocks.Sources.RealExpression | loaFra | Compute actual load fraction | |
| Buildings.Controls.OBC.CDL.Reals.Sources.Constant | uMin | Minimum speed | |
| Buildings.Controls.OBC.CDL.Reals.Max | max1 | Maximum of control signal and minimum speed | |
| Buildings.Controls.OBC.CDL.Conversions.BooleanToReal | enaRea | Cast enable signal to real | |
| Buildings.Controls.OBC.CDL.Reals.Multiply | mul | Zero out control signal if system is disabled | |
| Buildings.Controls.OBC.CDL.Reals.MultiplyByParameter | modMAir | Scale with design flow |
Contents
| Name | Description |
|---|---|
| Medium model for air | |
| Medium model for liquid (CHW or HHW) |
Revisions
-
December 8, 2025, by Antoine Gautier:
First implementation.