Package with base classes for Buildings.Fluid.Movers
This package contains base classes that are used to construct the models in Buildings.Fluid.Movers.
Extends from Modelica.Icons.BasesPackage (Icon for packages containing base classes).
Name | Description |
---|---|
FlowControlled | Partial model for fan or pump with ideally controlled mass flow rate or head as input signal |
FlowMachineInterface | Partial model with performance curves for fans or pumps |
IdealSource | Base class for pressure and mass flow source with optional power input |
PartialFlowMachine | Partial model to interface fan or pump models with the medium |
PowerInterface | Partial model to compute power draw and heat dissipation of fans and pumps |
SpeedControlled | Partial model for fan or pump with speed (y or Nrpm) as input signal |
Characteristics | Functions for fan or pump characteristics |
Partial model for fan or pump with ideally controlled mass flow rate or head as input signal
This model describes a fan or pump that takes as an input the head or the mass flow rate.
Extends from Buildings.Fluid.Movers.BaseClasses.PartialFlowMachine (Partial model to interface fan or pump models with the medium), Buildings.Fluid.Movers.BaseClasses.PowerInterface (Partial model to compute power draw and heat dissipation of fans and pumps).
Type | Name | Default | Description |
---|---|---|---|
replaceable package Medium | PartialMedium | Medium in the component | |
Boolean | addPowerToMedium | true | Set to false to avoid any power (=heat and flow work) being added to medium (may give simpler equations) |
Density | rho_default | Medium.density(sta_default) | Fluid density at medium default state [kg/m3] |
Boolean | control_m_flow | = false to control head instead of m_flow | |
FlowControlled | per | redeclare parameter Data.Flo... | Record with performance data |
Nominal condition | |||
MassFlowRate | m_flow_nominal | Nominal mass flow rate [kg/s] | |
Initialization | |||
MassFlowRate | m_flow.start | 0 | Mass flow rate from port_a to port_b (m_flow > 0 is design flow direction) [kg/s] |
Pressure | dp.start | 0 | Pressure difference between port_a and port_b [Pa] |
Characteristics | |||
Boolean | use_powerCharacteristic | false | Use powerCharacteristic (vs. efficiencyCharacteristic) |
Boolean | motorCooledByFluid | true | If true (and if addPowerToMedium = true), then motor heat is added to fluid stream |
Dynamics | |||
Equations | |||
Dynamics | energyDynamics | Modelica.Fluid.Types.Dynamic... | Formulation of energy balance |
Dynamics | massDynamics | energyDynamics | Formulation of mass balance |
Boolean | dynamicBalance | true | Set to true to use a dynamic balance, which often leads to smaller systems of equations |
Nominal condition | |||
Time | tau | 1 | Time constant of fluid volume for nominal flow, used if dynamicBalance=true [s] |
Initialization | |||
AbsolutePressure | p_start | Medium.p_default | Start value of pressure [Pa] |
Temperature | T_start | Medium.T_default | Start value of temperature [K] |
MassFraction | X_start[Medium.nX] | Medium.X_default | Start value of mass fractions m_i/m [kg/kg] |
ExtraProperty | C_start[Medium.nC] | fill(0, Medium.nC) | Start value of trace substances |
ExtraProperty | C_nominal[Medium.nC] | fill(1E-2, Medium.nC) | Nominal value of trace substances. (Set to typical order of magnitude.) |
Assumptions | |||
Boolean | allowFlowReversal | true | = true to allow flow reversal, false restricts to design direction (port_a -> port_b) |
Advanced | |||
MassFlowRate | m_flow_small | 1E-4*abs(m_flow_nominal) | Small mass flow rate for regularization of zero flow [kg/s] |
Boolean | homotopyInitialization | true | = true, use homotopy method |
Diagnostics | |||
Boolean | show_T | false | = true, if actual temperature at port is computed |
Type | Name | Description |
---|---|---|
FluidPort_a | port_a | Fluid connector a (positive design flow direction is from port_a to port_b) |
FluidPort_b | port_b | Fluid connector b (positive design flow direction is from port_a to port_b) |
HeatPort_a | heatPort | Heat dissipation to environment |
output RealOutput | P | Electrical power consumed [W] |
Partial model with performance curves for fans or pumps
This is an interface that implements the functions to compute the head, power draw and efficiency of fans and pumps. It is used by the model FlowControlledMachine.
The nominal hydraulic characteristic (volume flow rate versus total pressure) is given by a set of data points
using the data record data
, which is an instance of
Buildings.Fluid.Movers.Data.Generic.
A cubic hermite spline with linear extrapolation is used to compute the performance at other
operating points.
The fan or pump energy balance can be specified in two alternative ways:
_per_y.use_powerCharacteristic = false
, then the data points for
normalized volume flow rate versus efficiency is used to determine the efficiency,
and then the power consumption. The default is a constant efficiency of 0.7.
_per_y.use_powerCharacteristic = true
, then the data points for
normalized volume flow rate versus power consumption
is used to determine the power consumption, and then the efficiency
is computed based on the actual power consumption and the flow work.
For numerical reasons, the user-provided data points for volume flow rate versus pressure rise are modified to add a fan internal flow resistance. Because this flow resistance is subtracted during the simulation when computing the fan pressure rise, the model reproduces the exact points that were provided by the user.
Also for numerical reasons, the pressure rise at zero flow rate and
the flow rate at zero pressure rise is added to the user-provided data,
unless the user already provides these data points.
Since Modelica 3.2 does not allow dynamic memory allocation, this
implementation required the use of three different arrays for the
situation where no additional point is added, where one additional
point is added and where two additional points are added.
The parameter curve
causes the correct data record
to be used during the simulation.
Extends from Buildings.Fluid.Movers.BaseClasses.PowerInterface (Partial model to compute power draw and heat dissipation of fans and pumps).
Type | Name | Default | Description |
---|---|---|---|
Density | rho_default | Fluid density at medium default state [kg/m3] | |
Characteristics | |||
Boolean | use_powerCharacteristic | false | Use powerCharacteristic (vs. efficiencyCharacteristic) |
Boolean | motorCooledByFluid | true | If true (and if addPowerToMedium = true), then motor heat is added to fluid stream |
Advanced | |||
Boolean | homotopyInitialization | true | = true, use homotopy method |
Dynamics | |||
Filtered speed | |||
Boolean | filteredSpeed | true | = true, if speed is filtered with a 2nd order CriticalDamping filter |
Time | riseTime | 30 | Rise time of the filter (time to reach 99.6 % of the speed) [s] |
Init | init | Modelica.Blocks.Types.Init.I... | Type of initialization (no init/steady state/initial state/initial output) |
Real | y_start | 0 | Initial value of speed [1] |
Type | Name | Description |
---|---|---|
output RealOutput | P | Electrical power consumed [W] |
output RealOutput | y_actual | [1] |
Base class for pressure and mass flow source with optional power input
Model of a fictious pipe that is used as a base class for a pressure source or to prescribe a mass flow rate.
Note that for fans and pumps with dynamic balance, both the heat and the flow work are added to the volume of air or water. This simplifies the equations compared to adding heat to the volume, and flow work to this model.
Extends from Buildings.Fluid.Interfaces.PartialTwoPortTransport (Partial element transporting fluid between two ports without storage of mass or energy).
Type | Name | Default | Description |
---|---|---|---|
replaceable package Medium | PartialMedium | Medium in the component | |
Boolean | control_m_flow | = false to control dp instead of m_flow | |
Assumptions | |||
Boolean | allowFlowReversal | true | = true to allow flow reversal, false restricts to design direction (port_a -> port_b) |
Advanced | |||
AbsolutePressure | dp_start | 0 | Guess value of dp = port_a.p - port_b.p [Pa] |
MassFlowRate | m_flow_start | 0 | Guess value of m_flow = port_a.m_flow [kg/s] |
MassFlowRate | m_flow_small | Small mass flow rate for regularization of zero flow [kg/s] | |
Diagnostics | |||
Boolean | show_T | false | = true, if temperatures at port_a and port_b are computed |
Boolean | show_V_flow | true | = true, if volume flow rate at inflowing port is computed |
Type | Name | Description |
---|---|---|
FluidPort_a | port_a | Fluid connector a (positive design flow direction is from port_a to port_b) |
FluidPort_b | port_b | Fluid connector b (positive design flow direction is from port_a to port_b) |
input RealInput | m_flow_in | Prescribed mass flow rate |
input RealInput | dp_in | Prescribed outlet pressure |
Partial model to interface fan or pump models with the medium
This is the base model for fans and pumps. It provides an interface between the equations that compute head and power consumption, and the implementation of the energy and pressure balance of the fluid.
Depending on the value of
the parameter dynamicBalance
, the fluid volume
is computed using a dynamic balance or a steady-state balance.
The parameter addPowerToMedium
determines whether
any power is added to the fluid. The default is addPowerToMedium=true
,
and hence the outlet enthalpy is higher than the inlet enthalpy if the
flow device is operating.
The setting addPowerToMedium=false
is physically incorrect
(since the flow work, the flow friction and the fan heat do not increase
the enthalpy of the medium), but this setting does in some cases lead to simpler equations
and more robust simulation, in particular if the mass flow is equal to zero.
Extends from Buildings.Fluid.Interfaces.LumpedVolumeDeclarations (Declarations for lumped volumes), Buildings.Fluid.Interfaces.PartialTwoPortInterface (Partial model transporting fluid between two ports without storing mass or energy).
Type | Name | Default | Description |
---|---|---|---|
replaceable package Medium | PartialMedium | Medium in the component | |
Boolean | addPowerToMedium | true | Set to false to avoid any power (=heat and flow work) being added to medium (may give simpler equations) |
Nominal condition | |||
MassFlowRate | m_flow_nominal | Nominal mass flow rate [kg/s] | |
Initialization | |||
MassFlowRate | m_flow.start | 0 | Mass flow rate from port_a to port_b (m_flow > 0 is design flow direction) [kg/s] |
Pressure | dp.start | 0 | Pressure difference between port_a and port_b [Pa] |
Dynamics | |||
Equations | |||
Dynamics | energyDynamics | Modelica.Fluid.Types.Dynamic... | Formulation of energy balance |
Dynamics | massDynamics | energyDynamics | Formulation of mass balance |
Boolean | dynamicBalance | true | Set to true to use a dynamic balance, which often leads to smaller systems of equations |
Real | mSenFac | 1 | Factor for scaling the sensible thermal mass of the volume |
Nominal condition | |||
Time | tau | 1 | Time constant of fluid volume for nominal flow, used if dynamicBalance=true [s] |
Initialization | |||
AbsolutePressure | p_start | Medium.p_default | Start value of pressure [Pa] |
Temperature | T_start | Medium.T_default | Start value of temperature [K] |
MassFraction | X_start[Medium.nX] | Medium.X_default | Start value of mass fractions m_i/m [kg/kg] |
ExtraProperty | C_start[Medium.nC] | fill(0, Medium.nC) | Start value of trace substances |
ExtraProperty | C_nominal[Medium.nC] | fill(1E-2, Medium.nC) | Nominal value of trace substances. (Set to typical order of magnitude.) |
Assumptions | |||
Boolean | allowFlowReversal | true | = true to allow flow reversal, false restricts to design direction (port_a -> port_b) |
Advanced | |||
MassFlowRate | m_flow_small | 1E-4*abs(m_flow_nominal) | Small mass flow rate for regularization of zero flow [kg/s] |
Diagnostics | |||
Boolean | show_T | false | = true, if actual temperature at port is computed |
Type | Name | Description |
---|---|---|
HeatPort_a | heatPort | Heat dissipation to environment |
Partial model to compute power draw and heat dissipation of fans and pumps
This is an interface that implements the functions to compute the power draw and the heat dissipation of fans and pumps. It is used by the model Buildings.Fluid.Movers.BaseClasses.FlowMachineInterface.
Models that extend this model need to provide an implementation of
WFlo = eta * P
.
This equation is not implemented in this model to allow other models
to properly guard against division by zero.
Type | Name | Default | Description |
---|---|---|---|
Density | rho_default | Fluid density at medium default state [kg/m3] | |
Characteristics | |||
Boolean | use_powerCharacteristic | false | Use powerCharacteristic (vs. efficiencyCharacteristic) |
Boolean | motorCooledByFluid | true | If true (and if addPowerToMedium = true), then motor heat is added to fluid stream |
Advanced | |||
Boolean | homotopyInitialization | true | = true, use homotopy method |
Type | Name | Description |
---|---|---|
output RealOutput | P | Electrical power consumed [W] |
Partial model for fan or pump with speed (y or Nrpm) as input signal
This is the base model for fans and pumps that take as
input a control signal in the form of the pump speed Nrpm
or the normalized pump speed y=Nrpm/per.N_nominal
.
Extends from Buildings.Fluid.Movers.BaseClasses.PartialFlowMachine (Partial model to interface fan or pump models with the medium), Buildings.Fluid.Movers.BaseClasses.FlowMachineInterface (Partial model with performance curves for fans or pumps).
Type | Name | Default | Description |
---|---|---|---|
replaceable package Medium | PartialMedium | Medium in the component | |
Boolean | addPowerToMedium | true | Set to false to avoid any power (=heat and flow work) being added to medium (may give simpler equations) |
Density | rho_default | Medium.density_pTX(p=Medium.... | Fluid density at medium default state [kg/m3] |
Nominal condition | |||
MassFlowRate | m_flow_nominal | max(_per_y.pressure.V_flow)*... | Nominal mass flow rate [kg/s] |
Initialization | |||
MassFlowRate | m_flow.start | 0 | Mass flow rate from port_a to port_b (m_flow > 0 is design flow direction) [kg/s] |
Pressure | dp.start | 0 | Pressure difference between port_a and port_b [Pa] |
Real | r_V.start | 1 | Ratio V_flow/V_flow_max [1] |
Characteristics | |||
Boolean | use_powerCharacteristic | false | Use powerCharacteristic (vs. efficiencyCharacteristic) |
Boolean | motorCooledByFluid | true | If true (and if addPowerToMedium = true), then motor heat is added to fluid stream |
Dynamics | |||
Equations | |||
Dynamics | energyDynamics | Modelica.Fluid.Types.Dynamic... | Formulation of energy balance |
Dynamics | massDynamics | energyDynamics | Formulation of mass balance |
Boolean | dynamicBalance | true | Set to true to use a dynamic balance, which often leads to smaller systems of equations |
Nominal condition | |||
Time | tau | 1 | Time constant of fluid volume for nominal flow, used if dynamicBalance=true [s] |
Filtered speed | |||
Boolean | filteredSpeed | true | = true, if speed is filtered with a 2nd order CriticalDamping filter |
Time | riseTime | 30 | Rise time of the filter (time to reach 99.6 % of the speed) [s] |
Init | init | Modelica.Blocks.Types.Init.I... | Type of initialization (no init/steady state/initial state/initial output) |
Real | y_start | 0 | Initial value of speed [1] |
Initialization | |||
AbsolutePressure | p_start | Medium.p_default | Start value of pressure [Pa] |
Temperature | T_start | Medium.T_default | Start value of temperature [K] |
MassFraction | X_start[Medium.nX] | Medium.X_default | Start value of mass fractions m_i/m [kg/kg] |
ExtraProperty | C_start[Medium.nC] | fill(0, Medium.nC) | Start value of trace substances |
ExtraProperty | C_nominal[Medium.nC] | fill(1E-2, Medium.nC) | Nominal value of trace substances. (Set to typical order of magnitude.) |
Assumptions | |||
Boolean | allowFlowReversal | true | = true to allow flow reversal, false restricts to design direction (port_a -> port_b) |
Advanced | |||
MassFlowRate | m_flow_small | 1E-4*abs(m_flow_nominal) | Small mass flow rate for regularization of zero flow [kg/s] |
Boolean | homotopyInitialization | true | = true, use homotopy method |
Diagnostics | |||
Boolean | show_T | false | = true, if actual temperature at port is computed |
Type | Name | Description |
---|---|---|
FluidPort_a | port_a | Fluid connector a (positive design flow direction is from port_a to port_b) |
FluidPort_b | port_b | Fluid connector b (positive design flow direction is from port_a to port_b) |
HeatPort_a | heatPort | Heat dissipation to environment |
output RealOutput | P | Electrical power consumed [W] |
output RealOutput | y_actual | [1] |