jaxprop.components.nozzle_model_core module#
- jaxprop.components.nozzle_model_core.get_friction_factor_haaland(Reynolds, roughness, diameter)[source]#
Computes the Darcy-Weisbach friction factor using the Haaland equation.
The Haaland equation provides an explicit formulation for the friction factor that is simpler to use than the Colebrook equation, with an acceptable level of accuracy for most engineering applications. This function implements the Haaland equation as it is presented in many fluid mechanics textbooks, such as “Fluid Mechanics Fundamentals and Applications” by Cengel and Cimbala (equation 12-93).
- Parameters:
- reynoldsfloat
The Reynolds number, dimensionless, indicating the flow regime.
- roughnessfloat
The absolute roughness of the pipe’s internal surface (m).
- diameterfloat
The inner diameter of the pipe (m).
- Returns:
- ffloat
The computed friction factor, dimensionless.
- jaxprop.components.nozzle_model_core.get_heat_transfer_coefficient(velocity, density, heat_capacity, darcy_friction_factor)[source]#
Estimates the heat transfer using the Reynolds analogy.
This function is an adaptation of the Reynolds analogy which relates the heat transfer coefficient to the product of the Fanning friction factor, velocity, density, and heat capacity of the fluid. The Fanning friction factor one fourth of the Darcy friction factor.
- Parameters:
- velocityfloat
Velocity of the fluid (m/s).
- densityfloat
Density of the fluid (kg/m^3).
- heat_capacityfloat
Specific heat capacity of the fluid at constant pressure (J/kg·K).
- darcy_friction_factorfloat
Darcy friction factor, dimensionless.
- Returns:
- float
Estimated heat transfer coefficient (W/m^2·K).
- jaxprop.components.nozzle_model_core.get_wall_viscous_stress(darcy_friction_factor, density, velocity)[source]#
Wall shear stress from Darcy-Weisbach friction factor.
- Parameters:
- darcy_friction_factorfloat
Darcy-Weisbach friction factor (dimensionless).
- densityfloat
Fluid density (kg/m^3).
- velocityfloat
Fluid velocity (m/s).
- Returns:
- float
Wall shear stress (Pa).
- jaxprop.components.nozzle_model_core.nozzle_single_phase_autonomous(tau, Y, args)[source]#
- Autonomous formulation of the nozzle equations:
dx/dt = det(A) dy_i/dt = det(A with column i replaced by b)
State vector: Y = [x, v, rho, p]