Buildings.Fluid.BaseClasses.FlowModels
Flow models for pressure drop calculations
Information
This package contains basic flow models that are used by the various models that compute pressure drop.
Assumption and limitations
Because the density does not change signficantly in heating, ventilation and air conditioning systems for buildings, the flow models compute the pressure drop based on the mass flow rate and not the volume flow rate. This typically leads to simpler equations because it does not require the mass density, which changes when the flow is reversed. Although, for conceptual design of building energy system, there is in general not enough information available that would warrant a more detailed pressure drop calculation. If a more detailed computation of the flow resistance is needed, then a user can use models from the Modelica.Fluid library.
All functions have an argument m_flow_turbulent that determines where the
flow transitions to fully turbulent flow. For smaller mass flow rates,
the power-law relation is replaced by a function that has a finite slope
near zero pressure drop. This is done for numerical reasons, and to approximate
laminar flow, although the implementation does not use a linear function.
Implementation
The four main functions are
- Buildings.Fluid.BaseClasses.FlowModels.basicFlowFunction_dp,
- Buildings.Fluid.BaseClasses.FlowModels.basicFlowFunction_m_flow,
- Buildings.Fluid.BaseClasses.FlowModels.powerLaw_dp, and
- Buildings.Fluid.BaseClasses.FlowModels.powerLaw_m_flow.
These functions compute the mass flow rate or the pressure drop, respectively.
The first two functions assume that the flow resistance is quadratic in the mass flow rate,
and the other two functions allow for a flow exponent between 1 and 2.
All these functions are two times continuously differentiable.
First and second order derivatives are provided
in the function that have the suffix _der and _der2.
For the powerLaw functions, the coefficients that are an argument to the
functions can be computed using the function
Buildings.Fluid.BaseClasses.FlowModels.powerLawData.
This computation is done outside the above functions because the arguments generally
are all parameters, and hence precomputing them avoid repetitive evaluation.
Extends from Modelica.Icons.BasesPackage (Icon for packages containing base classes).
Package Content
| Name | Description |
|---|---|
| Function that computes mass flow rate for given pressure drop | |
| 1st derivative of function that computes mass flow rate for given pressure drop | |
| 2nd derivative of function that computes mass flow rate for given pressure drop | |
| Function that computes pressure drop for given mass flow rate | |
| 1st derivative of function that computes pressure drop for given mass flow rate | |
| 2nd derivative of function that computes pressure drop for given mass flow rate | |
| Function that computes the coefficients used by powerLaw_dp and powerLaw_m_flow | |
| Power law used in pressure drop equations when the flow exponent is constant and may be different from 2 | |
| 1st derivative of function that computes mass flow rate for given pressure drop | |
| 2nd derivative of function that computes mass flow rate for given pressure drop | |
| Inverse of power law used in pressure drop equations when the flow exponent is constant and may be different from 2 | |
| 1st derivative of function that computes pressure drop for given mass flow rate | |
| 2nd derivative of function that computes pressure drop for given mass flow rate | |
| Collection of validation models |
Buildings.Fluid.BaseClasses.FlowModels.basicFlowFunction_dp
Function that computes mass flow rate for given pressure drop
Information
Function that computes the pressure drop of flow elements as
ṁ = sign(Δp) k √ Δp
with regularization near the origin. Therefore, the flow coefficient is
k = ṁ ⁄ √ Δp
The input m_flow_turbulent determines the location of the regularization.
Inputs
| Type | Name | Default | Description |
|---|---|---|---|
| PressureDifference | dp | Pressure difference between port_a and port_b (= port_a.p - port_b.p) [Pa] | |
| Real | k | Flow coefficient, k=m_flow/sqrt(dp), with unit=(kg.m)^(1/2) | |
| MassFlowRate | m_flow_turbulent | Mass flow rate where transition to turbulent flow occurs [kg/s] |
Outputs
| Type | Name | Description |
|---|---|---|
| MassFlowRate | m_flow | Mass flow rate in design flow direction [kg/s] |
Modelica definition
Buildings.Fluid.BaseClasses.FlowModels.basicFlowFunction_dp_der
1st derivative of function that computes mass flow rate for given pressure drop
Information
Function that implements the first order derivative of Buildings.Fluid.BaseClasses.FlowModels.basicFlowFunction_dp, assuming a constant flow coefficient.
When called with dp_der=der(dp), this function returns
the time derivative of m_flow.
When called with dp_der=1, this function returns
the derivative of m_flow with respect to dp.
Extends from Modelica.Icons.Function (Icon for functions).
Inputs
| Type | Name | Default | Description |
|---|---|---|---|
| PressureDifference | dp | Pressure difference between port_a and port_b (= port_a.p - port_b.p) [Pa] | |
| Real | k | Flow coefficient, k=m_flow/sqrt(dp), with unit=(kg.m)^(1/2) | |
| MassFlowRate | m_flow_turbulent | Mass flow rate where transition to turbulent flow occurs [kg/s] | |
| Real | dp_der | Derivative of pressure difference between port_a and port_b (= port_a.p - port_b.p) |
Outputs
| Type | Name | Description |
|---|---|---|
| Real | m_flow_der | Derivative of mass flow rate in design flow direction |
Modelica definition
Buildings.Fluid.BaseClasses.FlowModels.basicFlowFunction_dp_der2
2nd derivative of function that computes mass flow rate for given pressure drop
Information
Function that implements the second order derivative of Buildings.Fluid.BaseClasses.FlowModels.basicFlowFunction_dp, assuming a constant flow coefficient.
When called with dp_der=der(dp) and dp_der2=der(dp_der),
this function returns the second order derivative of m_flow
with respect to time.
When called with dp_der=1 and dp_der2=0,
this function returns the second order derivative of m_flow
with respect to dp.
Extends from Modelica.Icons.Function (Icon for functions).
Inputs
| Type | Name | Default | Description |
|---|---|---|---|
| PressureDifference | dp | Pressure difference between port_a and port_b (= port_a.p - port_b.p) [Pa] | |
| Real | k | Flow coefficient, k=m_flow/sqrt(dp), with unit=(kg.m)^(1/2) | |
| MassFlowRate | m_flow_turbulent | Mass flow rate where transition to turbulent flow occurs [kg/s] | |
| Real | dp_der | 1st derivative of pressure difference between port_a and port_b (= port_a.p - port_b.p) | |
| Real | dp_der2 | 2nd derivative of pressure difference between port_a and port_b (= port_a.p - port_b.p) |
Outputs
| Type | Name | Description |
|---|---|---|
| Real | m_flow_der2 | 2nd derivative of mass flow rate in design flow direction |
Modelica definition
Buildings.Fluid.BaseClasses.FlowModels.basicFlowFunction_m_flow
Function that computes pressure drop for given mass flow rate
Information
Function that computes the pressure drop of flow elements as
Δp = sign(ṁ) (ṁ ⁄ k)2
with regularization near the origin. Therefore, the flow coefficient is
k = ṁ ⁄ √ Δp
The input m_flow_turbulent determines the location of the regularization.
Inputs
| Type | Name | Default | Description |
|---|---|---|---|
| MassFlowRate | m_flow | Mass flow rate in design flow direction [kg/s] | |
| Real | k | Flow coefficient, k=m_flow/sqrt(dp), with unit=(kg.m)^(1/2) | |
| MassFlowRate | m_flow_turbulent | Mass flow rate where transition to turbulent flow occurs [kg/s] |
Outputs
| Type | Name | Description |
|---|---|---|
| PressureDifference | dp | Pressure difference between port_a and port_b (= port_a.p - port_b.p) [Pa] |
Modelica definition
Buildings.Fluid.BaseClasses.FlowModels.basicFlowFunction_m_flow_der
1st derivative of function that computes pressure drop for given mass flow rate
Information
Function that implements the first order derivative of Buildings.Fluid.BaseClasses.FlowModels.basicFlowFunction_m_flow, assuming a constant flow coefficient.
When called with m_flow_der=der(m_flow), this function returns
the time derivative of dp.
When called with m_flow_der=1, this function returns
the derivative of dp with respect to m_flow.
Extends from Modelica.Icons.Function (Icon for functions).
Inputs
| Type | Name | Default | Description |
|---|---|---|---|
| MassFlowRate | m_flow | Mass flow rate in design flow direction [kg/s] | |
| Real | k | Flow coefficient, k=m_flow/sqrt(dp), with unit=(kg.m)^(1/2) | |
| MassFlowRate | m_flow_turbulent | Mass flow rate where transition to turbulent flow occurs [kg/s] | |
| Real | m_flow_der | Derivative of mass flow rate in design flow direction |
Outputs
| Type | Name | Description |
|---|---|---|
| Real | dp_der | Derivative of pressure difference between port_a and port_b (= port_a.p - port_b.p) |
Modelica definition
Buildings.Fluid.BaseClasses.FlowModels.basicFlowFunction_m_flow_der2
2nd derivative of function that computes pressure drop for given mass flow rate
Information
Function that implements the second order derivative of Buildings.Fluid.BaseClasses.FlowModels.basicFlowFunction_m_flow, assuming a constant flow coefficient.
When called with m_flow_der=der(m_flow) and m_flow_der2=der(m_flow_der),
this function returns the second order derivative of dp
with respect to time.
When called with m_flow_der=1 and m_flow_der2=0,
this function returns the second order derivative of dp
with respect to m_flow.
Extends from Modelica.Icons.Function (Icon for functions).
Inputs
| Type | Name | Default | Description |
|---|---|---|---|
| MassFlowRate | m_flow | Mass flow rate in design flow direction [kg/s] | |
| Real | k | Flow coefficient, k=m_flow/sqrt(dp), with unit=(kg.m)^(1/2) | |
| MassFlowRate | m_flow_turbulent | Mass flow rate where transition to turbulent flow occurs [kg/s] | |
| Real | m_flow_der | 1st derivative of mass flow rate in design flow direction | |
| Real | m_flow_der2 | 2nd derivative of mass flow rate in design flow direction |
Outputs
| Type | Name | Description |
|---|---|---|
| Real | dp_der2 | 2nd derivative of pressure difference between port_a and port_b (= port_a.p - port_b.p) |
Modelica definition
Buildings.Fluid.BaseClasses.FlowModels.powerLawData
Function that computes the coefficients used by powerLaw_dp and powerLaw_m_flow
Information
This function computes the coefficients that are used by the functions Buildings.Fluid.BaseClasses.FlowModels.powerLaw_dp and Buildings.Fluid.BaseClasses.FlowModels.powerLaw_m_flow.
The coefficients dp_turbulent, m, a1,
a3 and a5 are used by
Buildings.Fluid.BaseClasses.FlowModels.powerLaw_dp,
while the coefficients C, b1, b3 and
b5 are used by
Buildings.Fluid.BaseClasses.FlowModels.powerLaw_m_flow.
The coefficients only depend on the k, n
and m_flow_turbulent which often are parameters in a model.
In this case, this function allows to compute the coefficients only once as
parameters and then pass them to the above functions,
which avoids recomputing them during the time step simulation.
Inputs
| Type | Name | Default | Description |
|---|---|---|---|
| Real | k | Flow coefficient, k = m_flow/ dp^(1/n) | |
| Real | n | Flow exponent, n=1 for laminar, n=2 for turbulent | |
| MassFlowRate | m_flow_turbulent | Mass flow rate where transition to turbulent flow occurs [kg/s] |
Outputs
| Type | Name | Description |
|---|---|---|
| PressureDifference | dp_turbulent | Pressure difference where turbulent flow occurs [Pa] |
| Real | m | Flow exponent for the pressure drop |
| Real | a1 | Polynomial coefficient for regularized implementation of flow resistance |
| Real | a3 | Polynomial coefficient for regularized implementation of flow resistance |
| Real | a5 | Polynomial coefficient for regularized implementation of flow resistance |
| Real | C | Coefficient 1/k^n, based on the definition k = m_flow / dp^(1/n) |
| Real | b1 | Polynomial coefficient for regularized implementation of flow resistance |
| Real | b3 | Polynomial coefficient for regularized implementation of flow resistance |
| Real | b5 | Polynomial coefficient for regularized implementation of flow resistance |
Modelica definition
Buildings.Fluid.BaseClasses.FlowModels.powerLaw_dp
Power law used in pressure drop equations when the flow exponent is constant and may be different from 2
Information
This model describes the mass flow rate and pressure difference relation of a flow resistance in the form
ṁ = k sign(Δp) |Δp|1/n
where
ṁ is the mass flow rate,
k > 0 is a flow coefficient
Δ p is the pressure drop and
n ∈ [1, 2] is a flow exponent.
The equation is regularized for
|Δp| < Δpt, where
Δpt is a parameter that is computed from the input m_flow_turbulent.
For laminar flow, set n=1 and
for turbulent flow, set n=2.
The polynomial coefficients a1, a3 and a5,
the flow exponent m and the pressure difference
dp_turbulent are computed by the function
Buildings.Fluid.BaseClasses.FlowModels.powerLawData
and passed as inputs. As these quantities only depend on the parameters
k, n and m_flow_turbulent, they
can be computed once as parameters rather than at each function evaluation.
The model is used for the fluid flow models that are neither fully laminar nor fully turbulent. It is identical to Buildings.Airflow.Multizone.BaseClasses.powerLawFixedM except that it is formulated for mass flow rate rather than volume flow rate.
Note regarding arguments
This function takes as inputs not only the coefficients
dp_turbulent, m, a1, a3 and a5
that are used in its own implementation,
but also the coefficients C, b1, b3 and b5
that are used by its inverse function
Buildings.Fluid.BaseClasses.FlowModels.powerLaw_m_flow.
These additional arguments are needed so that the inverse annotation
can pass the input arguments of this function directly to its inverse function.
Therefore, this function and its inverse function
Buildings.Fluid.BaseClasses.FlowModels.powerLaw_m_flow
have the same input arguments, except that this function takes the pressure difference
dp as the first argument while its inverse takes the mass flow rate
m_flow as the first argument.
The coefficients C, b1, b3 and b5
are computed by the function
Buildings.Fluid.BaseClasses.FlowModels.powerLawData.
Implementation
For |Δp| < Δpt, the equation is regularized so that it is twice continuously differentiable in Δp, and that it has an infinite number of continuous derivatives in n and in k.
Inputs
| Type | Name | Default | Description |
|---|---|---|---|
| PressureDifference | dp | Pressure difference [Pa] | |
| Real | k | Flow coefficient, k = m_flow/ dp^(1/n) | |
| Real | n | Flow exponent, n=1 for laminar, n=2 for turbulent | |
| MassFlowRate | m_flow_turbulent | Mass flow rate where transition to turbulent flow occurs [kg/s] | |
| PressureDifference | dp_turbulent | Pressure difference where turbulent flow occurs [Pa] | |
| Real | m | Flow exponent for the pressure drop | |
| Real | a1 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | a3 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | a5 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | C | Coefficient 1/k^n, based on the definition k = m_flow / dp^(1/n) | |
| Real | b1 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | b3 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | b5 | Polynomial coefficient for regularized implementation of flow resistance |
Outputs
| Type | Name | Description |
|---|---|---|
| MassFlowRate | m_flow | Mass flow rate [kg/s] |
Modelica definition
Buildings.Fluid.BaseClasses.FlowModels.powerLaw_dp_der
1st derivative of function that computes mass flow rate for given pressure drop
Information
Function that implements the first order derivative of
Buildings.Fluid.BaseClasses.FlowModels.powerLaw_dp
with respect to the pressure difference dp,
assuming constant flow coefficients.
When called with dp_der=der(dp), this function returns
the time derivative of m_flow.
When called with dp_der=1, this function returns
the derivative of m_flow with respect to dp.
Extends from Modelica.Icons.Function (Icon for functions).
Inputs
| Type | Name | Default | Description |
|---|---|---|---|
| PressureDifference | dp | Pressure difference [Pa] | |
| Real | k | Flow coefficient, k = m_flow/ dp^(1/n) | |
| Real | n | Flow exponent, n=1 for laminar, n=2 for turbulent | |
| MassFlowRate | m_flow_turbulent | Mass flow rate where transition to turbulent flow occurs [kg/s] | |
| PressureDifference | dp_turbulent | Pressure difference where turbulent flow occurs [Pa] | |
| Real | m | Flow exponent for the pressure drop | |
| Real | a1 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | a3 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | a5 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | C | Coefficient 1/k^n, based on the definition k = m_flow / dp^(1/n) | |
| Real | b1 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | b3 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | b5 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | dp_der | Derivative of pressure difference |
Outputs
| Type | Name | Description |
|---|---|---|
| Real | m_flow_der | Derivative of mass flow rate in design flow direction |
Modelica definition
Buildings.Fluid.BaseClasses.FlowModels.powerLaw_dp_der2
2nd derivative of function that computes mass flow rate for given pressure drop
Information
Function that implements the second order derivative of
Buildings.Fluid.BaseClasses.FlowModels.powerLaw_dp
with respect to the pressure difference dp,
assuming constant flow coefficients.
When called with dp_der=der(dp) and dp_der2=der(dp_der),
this function returns the second order derivative of m_flow
with respect to time.
When called with dp_der=1 and dp_der2=0,
this function returns the second order derivative of m_flow
with respect to dp.
Extends from Modelica.Icons.Function (Icon for functions).
Inputs
| Type | Name | Default | Description |
|---|---|---|---|
| PressureDifference | dp | Pressure difference [Pa] | |
| Real | k | Flow coefficient, k = m_flow/ dp^(1/n) | |
| Real | n | Flow exponent, n=1 for laminar, n=2 for turbulent | |
| MassFlowRate | m_flow_turbulent | Mass flow rate where transition to turbulent flow occurs [kg/s] | |
| PressureDifference | dp_turbulent | Pressure difference where turbulent flow occurs [Pa] | |
| Real | m | Flow exponent for the pressure drop | |
| Real | a1 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | a3 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | a5 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | C | Coefficient 1/k^n, based on the definition k = m_flow / dp^(1/n) | |
| Real | b1 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | b3 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | b5 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | dp_der | 1st derivative of pressure difference | |
| Real | dp_der2 | 2nd derivative of pressure difference |
Outputs
| Type | Name | Description |
|---|---|---|
| Real | m_flow_der2 | 2nd derivative of mass flow rate in design flow direction |
Modelica definition
Buildings.Fluid.BaseClasses.FlowModels.powerLaw_m_flow
Inverse of power law used in pressure drop equations when the flow exponent is constant and may be different from 2
Information
This model describes the pressure difference and mass flow rate relation of a flow resistance in the form
Δp = sign(ṁ) (ṁ ⁄ k)n
where Δp is the pressure drop, k > 0 is a flow coefficient, ṁ is the mass flow rate, and n ∈ [1, 2] is a flow exponent. The equation is regularized for |ṁ| < ṁt, where ṁt is a parameter. For laminar flow, set n=1 and for turbulent flow, set n=2.
The coefficient C and the polynomial coefficients
b1, b3 and b5 are computed by the function
Buildings.Fluid.BaseClasses.FlowModels.powerLawData
and passed as inputs. As these quantities only depend on the parameters
k, n and m_flow_turbulent, they
can be computed once as parameters rather than at each function evaluation.
The model is used for the fluid flow models that are neither fully laminar nor fully turbulent.
Note regarding arguments
This function takes as inputs not only the coefficients
C, b1, b3 and b5
that are used in its own implementation,
but also the coefficients dp_turbulent, m,
a1, a3 and a5
that are used by its inverse function
Buildings.Fluid.BaseClasses.FlowModels.powerLaw_dp.
These additional arguments are needed so that the inverse annotation
can pass the input arguments of this function directly to its inverse function.
Therefore, this function and its inverse function
Buildings.Fluid.BaseClasses.FlowModels.powerLaw_dp
have the same input arguments, except that this function takes the mass flow rate
m_flow as the first argument while its inverse takes the pressure difference
dp as the first argument.
The coefficients dp_turbulent, m, a1,
a3 and a5 are computed by the function
Buildings.Fluid.BaseClasses.FlowModels.powerLawData.
Implementation
For |ṁ| < ṁt, the equation is regularized so that it is twice continuously differentiable in ṁ, and that it has an infinite number of continuous derivatives in n and in k.
Inputs
| Type | Name | Default | Description |
|---|---|---|---|
| MassFlowRate | m_flow | Mass flow rate [kg/s] | |
| Real | k | Flow coefficient, k = m_flow/ dp^(1/n) | |
| Real | n | Flow exponent, n=1 for laminar, n=2 for turbulent | |
| MassFlowRate | m_flow_turbulent | Mass flow rate where transition to turbulent flow occurs [kg/s] | |
| PressureDifference | dp_turbulent | Pressure difference where turbulent flow occurs [Pa] | |
| Real | m | Flow exponent for the pressure drop | |
| Real | a1 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | a3 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | a5 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | C | Coefficient 1/k^n, based on the definition k = m_flow / dp^(1/n) | |
| Real | b1 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | b3 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | b5 | Polynomial coefficient for regularized implementation of flow resistance |
Outputs
| Type | Name | Description |
|---|---|---|
| PressureDifference | dp | Pressure difference [Pa] |
Modelica definition
Buildings.Fluid.BaseClasses.FlowModels.powerLaw_m_flow_der
1st derivative of function that computes pressure drop for given mass flow rate
Information
Function that implements the first order derivative of
Buildings.Fluid.BaseClasses.FlowModels.powerLaw_m_flow
with respect to the mass flow rate m_flow,
assuming constant flow coefficients.
When called with m_flow_der=der(m_flow), this function returns
the time derivative of dp.
When called with m_flow_der=1, this function returns
the derivative of dp with respect to m_flow.
Extends from Modelica.Icons.Function (Icon for functions).
Inputs
| Type | Name | Default | Description |
|---|---|---|---|
| MassFlowRate | m_flow | Mass flow rate [kg/s] | |
| Real | k | Flow coefficient, k = m_flow/ dp^(1/n) | |
| Real | n | Flow exponent, n=1 for laminar, n=2 for turbulent | |
| MassFlowRate | m_flow_turbulent | Mass flow rate where transition to turbulent flow occurs [kg/s] | |
| PressureDifference | dp_turbulent | Pressure difference where turbulent flow occurs [Pa] | |
| Real | m | Flow exponent for the pressure drop | |
| Real | a1 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | a3 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | a5 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | C | Coefficient 1/k^n, based on the definition k = m_flow / dp^(1/n) | |
| Real | b1 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | b3 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | b5 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | m_flow_der | Derivative of mass flow rate in design flow direction |
Outputs
| Type | Name | Description |
|---|---|---|
| Real | dp_der | Derivative of pressure difference |
Modelica definition
Buildings.Fluid.BaseClasses.FlowModels.powerLaw_m_flow_der2
2nd derivative of function that computes pressure drop for given mass flow rate
Information
Function that implements the second order derivative of
Buildings.Fluid.BaseClasses.FlowModels.powerLaw_m_flow
with respect to the mass flow rate m_flow,
assuming constant flow coefficients.
When called with m_flow_der=der(m_flow) and m_flow_der2=der(m_flow_der),
this function returns the second order derivative of dp
with respect to time.
When called with m_flow_der=1 and m_flow_der2=0,
this function returns the second order derivative of dp
with respect to m_flow.
Extends from Modelica.Icons.Function (Icon for functions).
Inputs
| Type | Name | Default | Description |
|---|---|---|---|
| MassFlowRate | m_flow | Mass flow rate [kg/s] | |
| Real | k | Flow coefficient, k = m_flow/ dp^(1/n) | |
| Real | n | Flow exponent, n=1 for laminar, n=2 for turbulent | |
| MassFlowRate | m_flow_turbulent | Mass flow rate where transition to turbulent flow occurs [kg/s] | |
| PressureDifference | dp_turbulent | Pressure difference where turbulent flow occurs [Pa] | |
| Real | m | Flow exponent for the pressure drop | |
| Real | a1 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | a3 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | a5 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | C | Coefficient 1/k^n, based on the definition k = m_flow / dp^(1/n) | |
| Real | b1 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | b3 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | b5 | Polynomial coefficient for regularized implementation of flow resistance | |
| Real | m_flow_der | 1st derivative of mass flow rate in design flow direction | |
| Real | m_flow_der2 | 2nd derivative of mass flow rate in design flow direction |
Outputs
| Type | Name | Description |
|---|---|---|
| Real | dp_der2 | 2nd derivative of pressure difference |