.BuildingSystems.Fluid.FixedResistances.HydraulicDiameter

Information

This is a model of a flow resistance with a fixed flow coefficient. The mass flow rate is computed as

ṁ = k √Δp,

where k is a constant and Δp is the pressure drop. The constant k is equal to k=m_flow_nominal/sqrt(dp_nominal), where m_flow_nominal is a parameter.

Assumptions

In the region abs(m_flow) < m_flow_turbulent, the square root is replaced by a differentiable function with finite slope. The value of m_flow_turbulent is computed as m_flow_turbulent = eta_nominal*dh/4*π*ReC, where eta_nominal is the dynamic viscosity, obtained from the medium model. The parameter dh is the hydraulic diameter and ReC=4000 is the critical Reynolds number, which both can be set by the user.

Important parameters

By default, the pressure drop at nominal flow rate is computed as

dp_nominal = fac * dpStraightPipe_nominal,

where dpStraightPipe_nominal is a parameter that is automatically computed based on the nominal mass flow rate, hydraulic diameter, pipe roughness and medium properties. The hydraulic diameter dh is by default computed based on the flow velocity v_nominal and the nominal mass flow rate m_flow_nominal. Hence, users should change the default values of dh or v_nominal if they are not applicable for their model.

The factor fac takes into account additional resistances such as for bends. The default value of 2 can be changed by the user.

The parameter from_dp is used to determine whether the mass flow rate is computed as a function of the pressure drop (if from_dp=true), or vice versa. This setting can affect the size of the nonlinear system of equations.

If the parameter linearized is set to true, then the pressure drop is computed as a linear function of the mass flow rate.

Setting allowFlowReversal=false can lead to simpler equations. However, this should only be set to false if one can guarantee that the flow never reverses its direction. This can be difficult to guarantee, as pressure imbalance after the initialization, or due to medium expansion and contraction, can lead to reverse flow.

If the parameter show_T is set to true, then the model will compute the temperature at its ports. Note that this can lead to state events when the mass flow rate approaches zero, which can increase computing time.

Notes

For more detailed models that compute the actual flow friction, models from the package Modelica.Fluid can be used and combined with models from the BuildingSystems library.

For a model that uses dp_nominal as a parameter rather than geoemetric data, use BuildingSystems.Fluid.FixedResistances.PressureDrop.

Implementation

The pressure drop is computed by calling a function in the package BuildingSystems.Fluid.BaseClasses.FlowModels, This package contains regularized implementations of the equation

ṁ = sign(Δp) k √ Δp  

and its inverse function.

To decouple the energy equation from the mass equations, the pressure drop is a function of the mass flow rate, and not the volume flow rate. This leads to simpler equations.

Revisions


Generated at 2024-11-22T19:25:38Z by OpenModelicaOpenModelica 1.24.2 using GenerateDoc.mos