Buildings.Fluid.CHPs.BaseClasses
Information
This package contains base classes that are used to construct the models in Buildings.Fluid.CHPs.
Extends from Modelica.Icons.BasesPackage (Icon for packages containing base classes).
Package Content
Name | Description |
---|---|
![]() |
Assert whether fuel flow is within boundary |
![]() |
Assert if electric power is outside boundaries |
![]() |
Assert if water flow is outside boundaries |
![]() |
Assert if water outlet temperature is outside boundaries |
![]() |
Define current operation mode |
![]() |
Efficiency curve described by a fifth order polynomial, function of three input variables |
![]() |
Energy conversion control volume |
![]() |
Energy conversion for typical CHP operation either in normal mode or warm-up mode based on time delay |
![]() |
Energy conversion during warm-up mode based on engine temperature |
![]() |
Heat exchange within the engine control volume |
![]() |
Constraints for electric power |
![]() |
Power consumption during stand-by and cool-down modes |
![]() |
Model evaluating the condition for transitioning from warm-up to normal mode |
![]() |
Internal controller for water flow rate |
![]() |
|
![]() |
Library of CHP operation modes |
![]() |
Validation of the baseclasses |
![]() |
Buildings.Fluid.CHPs.BaseClasses.AssertFuelFlow
Assert whether fuel flow is within boundary
Information
The model sends a warning message if the rate at which the fuel mass flow rate changes is outside the boundaries defined by the manufacturer.
Extends from Modelica.Blocks.Icons.Block (Basic graphical layout of input/output block).
Parameters
Type | Name | Default | Description |
---|---|---|---|
Real | dmFueMax_flow | dmFueMax_flow(final unit="kg... | Maximum rate at which fuel mass flow rate can change [kg/s2] |
Connectors
Type | Name | Description |
---|---|---|
input RealInput | mFue_flow | Fuel mass flow rate [kg/s] |
Modelica definition
Buildings.Fluid.CHPs.BaseClasses.AssertPower
Assert if electric power is outside boundaries
Information
The model sends a warning message if the power demand is outside the boundaries defined by the manufacturer. Limits can be specified for the minimal and maximal electric power, and for the maximum rate at which the power can change.
Extends from Modelica.Blocks.Icons.Block (Basic graphical layout of input/output block).
Parameters
Type | Name | Default | Description |
---|---|---|---|
Power | PEleMax | Maximum power output [W] | |
Power | PEleMin | Minimum power output [W] | |
Boolean | use_powerRateLimit | If true, the rate at which net power output can change is limited | |
Real | dPEleMax | dPEleMax(final unit="W/s") | Maximum rate at which net power output can change [W/s] |
Connectors
Type | Name | Description |
---|---|---|
input RealInput | PEleDem | Electric power demand [W] |
Modelica definition
Buildings.Fluid.CHPs.BaseClasses.AssertWaterFlow
Assert if water flow is outside boundaries
Information
The model sends a warning message if the water mass flow rate is lower than the minimum defined by the manufacturer.
Extends from Modelica.Blocks.Icons.Block (Basic graphical layout of input/output block).
Parameters
Type | Name | Default | Description |
---|---|---|---|
MassFlowRate | mWatMin_flow | Minimum cooling water mass flow rate [kg/s] |
Connectors
Type | Name | Description |
---|---|---|
input BooleanInput | runSig | True when electricity or heat demand is larger than zero |
input RealInput | mWat_flow | Water mass flow rate [kg/s] |
Modelica definition
Buildings.Fluid.CHPs.BaseClasses.AssertWaterTemperature
Assert if water outlet temperature is outside boundaries
Information
The model sends a warning message if the water outlet temperature is higher than the maximum defined by the manufacturer.
Extends from Modelica.Blocks.Icons.Block (Basic graphical layout of input/output block).
Parameters
Type | Name | Default | Description |
---|---|---|---|
Temperature | TWatMax | Maximum cooling water temperature [K] | |
Advanced | |||
TemperatureDifference | THys | 0.5 | Hysteresis value to check temperature difference [K] |
Connectors
Type | Name | Description |
---|---|---|
input RealInput | TWat | Water outlet temperature [K] |
Modelica definition
Buildings.Fluid.CHPs.BaseClasses.Controller
Define current operation mode
Information
The CHP plant switches between six possible operating modes depending on the current mode, control signals and plant boundary conditions. The regular transition between them is as follows:
- off
- stand-by mode
- pump-on mode
- warm-up mode
- normal operation
- cool-down mode
- off or stand-by mode
Switching between operating modes
From the off mode:
-
The transition from the off to the stand-by mode will occur when the plant availability
signal
avaSig
becomes true.
From the stand-by mode:
-
The transition from the stand-by to the pump-on mode will occur when the plant
running signal
runSig
becomes true. -
If
avaSig
becomes false, the CHP will automatically change to the off mode.
From the pump-on mode:
-
The transition from the pump-on to stand-by mode will occur after the specified
time delay and if the water flow rate
mWat_flow
is greater than the minimummWatMin_flow
. -
If
runSig
becomes false, the CHP will automatically change to the off mode.
From the warm-up mode:
-
The transition from the warm-up mode to the normal operation will occur after the
specified time delay (if
warmUpByTimeDelay
is true) or when the engine temperatureTEng
becomes higher than the nominal temperatureTEngNom
(ifwarmUpByTimeDelay
is false). -
If
runSig
becomes false or if the water flow ratemWat_flow
becomes less than the minimummWatMin_flow
, the CHP will automatically change to the cool-down mode.
From the normal mode:
-
The transition from the normal operation to the cool-down mode will occur when
runSig
becomes false or if the water flow ratemWat_flow
becomes less than the minimummWatMin_flow
.
From the cool-down mode:
-
The transition from the cool-down mode will occur after the specified time delay.
If
avaSig
is true, the CHP will change to the stand-by mode; else, it will change to the off mode. -
If the CHP has the mandatory cool-down configuration (if
coolDownOptional
is false), the plant has to complete the cool-down period before it can be reactivated. If the CHP has the optional cool-down configuration (ifcoolDownOptional
is true), the plant may imediatelly change to the warm-up mode if it gets reactivated (runSig= true
).
Extends from Modelica.Blocks.Icons.Block (Basic graphical layout of input/output block).
Parameters
Type | Name | Default | Description |
---|---|---|---|
Generic | per | redeclare parameter Building... | Performance data |
Dynamics | |||
Time | waitTime | 60 | Wait time before transition from pump-on mode fires [s] |
Connectors
Type | Name | Description |
---|---|---|
input BooleanInput | avaSig | True when the plant is available |
input BooleanInput | runSig | True when plant should run |
input RealInput | mWat_flow | Cooling water mass flow rate [kg/s] |
input RealInput | TEng | Engine temperature [K] |
input RealInput | PEleNet | Net power output [W] |
input RealInput | PEle | Power demand [W] |
output ModeTypeOutput | opeMod | Type of operating mode |
Modelica definition
Buildings.Fluid.CHPs.BaseClasses.EfficiencyCurve
Efficiency curve described by a fifth order polynomial,
function of three input variables
Information
The block computes the efficiency as a polynomial function of three input variables. The polynomial has the form
y = a1
+ a2 x12
+ a3 x1
+ a4 x22
+ a5 x2
+ a6 x32
+ a7 x3
+ a8 x12 x22
+ a9 x1 x2
+ a10 x1 x22
+ a11 x12 x2
+ a12 x12 x32
+ a13 x1 x3
+ a14 x1 x32
+ a15 x12 x3
+ a16 x22 x32
+ a17 x2 x3
+ a18 x2 x32
+ a19 x22 x3
+ a20 x12 x22 x32
+ a21 x12 x22 x3
+ a22 x12 x2 x32
+ a23 x1 x22 x32
+ a24 x12 x2 x3
+ a25 x1 x22 x3
+ a26 x1 x2 x32
+ a27 x1 x2 x3
where x1 is the net power output, x2 is the water mass flow rate, x3 is the water inlet temperature.
Extends from Modelica.Blocks.Icons.Block (Basic graphical layout of input/output block).
Parameters
Type | Name | Default | Description |
---|---|---|---|
Real | a[27] | Polynomial coefficients |
Connectors
Type | Name | Description |
---|---|---|
input RealInput | PNet | Electric power [W] |
input RealInput | mWat_flow | Water mass flow rate [kg/s] |
input RealInput | TWatIn | Water inlet temperature [K] |
output RealOutput | eta | Efficiency [1] |
Modelica definition
Buildings.Fluid.CHPs.BaseClasses.EnergyConversion
Energy conversion control volume
Information
The model defines energy conversion that occurs during the normal mode and warm-up mode. The model Buildings.Fluid.CHPs.BaseClasses.EnergyConversionWarmUp is used only for the warm-up mode dependent on the engine temperature (case of Stirling engines). The model Buildings.Fluid.CHPs.BaseClasses.EnergyConversionNormal is used for all other cases, i.e. the normal mode, and the warm-up mode based on a time delay (case of internal combustion engines).
Extends from Modelica.Blocks.Icons.Block (Basic graphical layout of input/output block).
Parameters
Type | Name | Default | Description |
---|---|---|---|
Generic | per | redeclare parameter Building... | Performance data |
Connectors
Type | Name | Description |
---|---|---|
input RealInput | PEle | Power demand [W] |
input ModeTypeInput | opeMod | Operation mode |
input RealInput | mWat_flow | Water mass flow rate [kg/s] |
input RealInput | TWatIn | Water inlet temperature [K] |
input RealInput | TRoo | Room temperature [K] |
input RealInput | TEng | Engine temperature [K] |
output RealOutput | PEleNet | Net power output [W] |
output RealOutput | mFue_flow | Fuel mass flow rate [kg/s] |
output RealOutput | mAir_flow | Air mass flow rate [kg/s] |
output RealOutput | QGen_flow | Heat generation rate [W] |
Modelica definition
Buildings.Fluid.CHPs.BaseClasses.EnergyConversionNormal
Energy conversion for typical CHP operation either in normal mode or warm-up mode based on time delay
Information
The model defines energy conversion for a typical CHP operation that includes the normal mode and warm-up mode based on the time delay (CHPs with internal combustion engines). Energy conversion from fuel to the electric power and heat is modeled using system's part-load electrical and thermal efficiencies, based on the empirical data from the manufacturer. The curves are described by a fifth order polynomial, a function of the electric power, water flow rate and water inlet temperature. The air flow rate is modeled using a second order polynomial, a function of the fuel flow rate.
Extends from Modelica.Blocks.Icons.Block (Basic graphical layout of input/output block).
Parameters
Type | Name | Default | Description |
---|---|---|---|
Generic | per | redeclare parameter Building... | Performance data |
Connectors
Type | Name | Description |
---|---|---|
input RealInput | PEle | Electric power [W] |
input RealInput | mWat_flow | Water mass flow rate [kg/s] |
input RealInput | TWatIn | Water inlet temperature [K] |
output RealOutput | mFue_flow | Fuel mass flow rate [kg/s] |
output RealOutput | mAir_flow | Air mass flow rate [kg/s] |
output RealOutput | QGen_flow | Heat generation rate within the engine [W] |
Modelica definition
Buildings.Fluid.CHPs.BaseClasses.EnergyConversionWarmUp
Energy conversion during warm-up mode based on engine temperature
Information
The model defines energy conversion for the warm-up mode that is dependent on the engine temperature (e.g. CHPs with Stirling engines). The engine fuel flow rate is a function of the fuel flow rate at the maximum power output, as well as the difference between the nominal engine temperature and the actual engine temperature. Energy conversion from fuel to the electric power and heat is modeled using system's part-load electrical and thermal efficiencies, based on the empirical data from the manufacturer. The curves are described by a fifth order polynomial, a function of the electric power, water flow rate and water inlet temperature. The air flow rate is modeled using a second order polynomial, a function of the fuel flow rate.
Extends from Modelica.Blocks.Icons.Block (Basic graphical layout of input/output block).
Parameters
Type | Name | Default | Description |
---|---|---|---|
Generic | per | redeclare parameter Building... | Performance data |
Connectors
Type | Name | Description |
---|---|---|
input RealInput | mWat_flow | Water mass flow rate [kg/s] |
input RealInput | TWatIn | Water inlet temperature [K] |
input RealInput | TRoo | Room temperature [K] |
input RealInput | TEng | Engine temperature [K] |
output RealOutput | PEleNet | Electric power generation [W] |
output RealOutput | mFue_flow | Fuel mass flow rate [kg/s] |
output RealOutput | mAir_flow | Air mass flow rate [kg/s] |
output RealOutput | QGen_flow | Heat generation rate within the engine [W] |
Modelica definition
Buildings.Fluid.CHPs.BaseClasses.EngineTemperature
Heat exchange within the engine control volume
Information
The model defines the dynamic behavior of the CHP thermal mass (i.e. engine block,
encapsulated working fluid, and internal heat exchange equipment) using a single,
engine control volume.
The thermal energy stored within this volume is quantified using an aggregate
thermal capacitance capEng
and an equivalent average engine temperature
TEng
.
The heat transfer between the engine and the cooling water control volume is
quantified using the overall thermal conductance UAHex
,
while the heat loss to the surroundings is quantified using the overall thermal
conductance UALos
.
Extends from Modelica.Blocks.Icons.Block (Basic graphical layout of input/output block).
Parameters
Type | Name | Default | Description |
---|---|---|---|
ThermalConductance | UAHex | Thermal conductance between the engine and cooling water [W/K] | |
ThermalConductance | UALos | Thermal conductance between the engine and surroundings [W/K] | |
HeatCapacity | capEng | Thermal capacitance of the engine control volume [J/K] | |
Temperature | TEngIni | Initial engine temperature [K] |
Connectors
Type | Name | Description |
---|---|---|
HeatPort_a | TRoo | Heat port for room temperature |
input RealInput | QGen_flow | Heat generation rate within the engine [W] |
HeatPort_a | TWat | Heat port for water volume temperature |
output RealOutput | TEng | Engine temperature [K] |
Modelica definition
Buildings.Fluid.CHPs.BaseClasses.FilterPower
Constraints for electric power
Information
The model checks if the electric power and power rate are within the boundaries specified by the manufacturer. The constraints are applied and a warning message is sent if the electric power is outside the boundaries.
Extends from Modelica.Blocks.Icons.Block (Basic graphical layout of input/output block).
Parameters
Type | Name | Default | Description |
---|---|---|---|
Power | PEleMax | Maximum power output [W] | |
Power | PEleMin | Minimum power output [W] | |
Boolean | use_powerRateLimit | If true, the rate at which net power output can change is limited | |
Real | dPEleMax | dPEleMax(final unit="W/s") | Maximum rate at which net power output can change [W/s] |
Connectors
Type | Name | Description |
---|---|---|
input RealInput | PEleDem | Electric power demand [W] |
output RealOutput | PEle | Electric power demand after applied constraints [W] |
Modelica definition
Buildings.Fluid.CHPs.BaseClasses.PowerConsumption
Power consumption during stand-by and cool-down modes
Information
The model calculates the power consumption during the stand-by and cool-down modes of operation.
Extends from Modelica.Blocks.Icons.Block (Basic graphical layout of input/output block).
Parameters
Type | Name | Default | Description |
---|---|---|---|
Power | PStaBy | Standby electric power [W] | |
Power | PCooDow | Cooldown electric power [W] |
Connectors
Type | Name | Description |
---|---|---|
input ModeTypeInput | opeMod | Operation mode |
output RealOutput | PCon | Power consumption during stand-by and cool-down modes [W] |
Modelica definition
Buildings.Fluid.CHPs.BaseClasses.WarmUpLeaving
Model evaluating the condition for transitioning from warm-up to normal mode
Information
The model computes a boolean variable which is true when warm-up is over. CHP will transition from the warm-up mode to the normal mode
-
after the specified time delay if
warmUpByTimeDelay
is true, or -
when the engine temperature exceeds the nominal value or the net power produced
exceeds that requested by the controller if
warmUpByTimeDelay
is false.
Extends from Modelica.Blocks.Icons.Block (Basic graphical layout of input/output block).
Parameters
Type | Name | Default | Description |
---|---|---|---|
Time | timeDelayStart | Time delay between activation and power generation [s] | |
Temperature | TEngNom | Nominal engine operating temperature [K] | |
Power | PEleMax | 0 | Maximum power output [W] |
Boolean | warmUpByTimeDelay | If true, the plant will be in warm-up mode depending on the delay time, otherwise depending on engine temperature |
Connectors
Type | Name | Description |
---|---|---|
input RealInput | TEng | Engine temperature [K] |
output BooleanOutput | y | Transition signal |
input BooleanInput | actWarUp | Warm-up state active signal |
input RealInput | PEle | Power demand [W] |
input RealInput | PEleNet | Net power output [W] |
Modelica definition
Buildings.Fluid.CHPs.BaseClasses.WaterFlowControl
Internal controller for water flow rate
Information
The model calculates the water mass flow rate that is determined by the internal controller. In CHPs that use this type of internal control the cooling water mass flow rate is controlled to optimize engine performance and heat recovery. In the main model of the CHP unit Buildings.Fluid.CHPs.ThermalElectricalFollowing, this optimum water mass flow rate is specified as the set point signal for the external pump controller.
Implementation
The mass flow rate is computed as a biquadratic function of the net power output of the system and the water inlet temperature. Note that this implementation is a truncated version of the empirical correlation proposed in Beausoleil-Morrison (2007) which includes terms of higher order (up to four).
References
Beausoleil-Morrison, Ian and Kelly, Nick, 2007. Specifications for modelling fuel cell and combustion-based residential cogeneration device within whole-building simulation programs, Section III. [Report]
Extends from Modelica.Blocks.Icons.Block (Basic graphical layout of input/output block).
Parameters
Type | Name | Default | Description |
---|---|---|---|
Generic | per | redeclare parameter Building... | Performance data |
Connectors
Type | Name | Description |
---|---|---|
input ModeTypeInput | opeMod | Operation mode |
input RealInput | PEle | Electric power [W] |
input RealInput | TWatIn | Water inlet temperature [K] |
output RealOutput | mWatSet_flow | Water mass flow rate set point [kg/s] |