H_TWO_PHASE_METHODS
Returns the set of available two-phase tube-flow heat transfer correlations for the provided inputs. The function can optionally filter methods by validity ranges so only applicable correlations are returned.
This utility is typically used before coefficient evaluation to choose a method compatible with the supplied thermophysical and geometric inputs.
The returned structure is a single-column 2D array of method names suitable for Excel spill output.
Excel Usage
=H_TWO_PHASE_METHODS(m, x, D, Cpl, kl, rhol, rhog, mul, mu_b, mu_w, mug, L, alpha, check_ranges)
m(float, required): Mass flow rate (kg/s).x(float, required): Quality at the tube interval (-).D(float, required): Tube diameter (m).Cpl(float, required): Liquid heat capacity at constant pressure (J/kg/K).kl(float, required): Liquid thermal conductivity (W/m/K).rhol(float, optional, default: null): Liquid density (kg/m^3).rhog(float, optional, default: null): Gas density (kg/m^3).mul(float, optional, default: null): Liquid viscosity (Pa*s).mu_b(float, optional, default: null): Liquid viscosity at bulk conditions (Pa*s).mu_w(float, optional, default: null): Liquid viscosity at wall temperature (Pa*s).mug(float, optional, default: null): Gas viscosity (Pa*s).L(float, optional, default: null): Tube length (m).alpha(float, optional, default: null): Void fraction in the tube (-).check_ranges(bool, optional, default: true): Whether to return only applicable correlations (-).
Returns (list[list]): 2D array of available correlation method names.
Example 1: Methods list example
Inputs:
| m | x | D | alpha | rhol | Cpl | kl | mu_b | mu_w | L |
|---|---|---|---|---|---|---|---|---|---|
| 1 | 0.9 | 0.3 | 0.9 | 1000 | 2300 | 0.6 | 0.001 | 0.0012 | 5 |
Excel formula:
=H_TWO_PHASE_METHODS(1, 0.9, 0.3, 0.9, 1000, 2300, 0.6, 0.001, 0.0012, 5)
Expected output:
| Aggour |
|---|
| Hughmark |
Example 2: Methods without range checking
Inputs:
| m | x | D | alpha | rhol | Cpl | kl | mu_b | mu_w | L | check_ranges |
|---|---|---|---|---|---|---|---|---|---|---|
| 1 | 0.9 | 0.3 | 0.9 | 1000 | 2300 | 0.6 | 0.001 | 0.0012 | 5 | false |
Excel formula:
=H_TWO_PHASE_METHODS(1, 0.9, 0.3, 0.9, 1000, 2300, 0.6, 0.001, 0.0012, 5, FALSE)
Expected output:
| Aggour |
|---|
| Hughmark |
Example 3: Methods with gas properties
Inputs:
| m | x | D | alpha | rhol | rhog | Cpl | kl | mug | mu_b | mu_w | L | check_ranges |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 1 | 0.9 | 0.3 | 0.9 | 1000 | 1.8 | 2300 | 0.6 | 0.00002 | 0.001 | 0.0012 | 5 | false |
Excel formula:
=H_TWO_PHASE_METHODS(1, 0.9, 0.3, 0.9, 1000, 1.8, 2300, 0.6, 0.00002, 0.001, 0.0012, 5, FALSE)
Expected output:
| Knott |
|---|
| Martin_Sims |
| Kudirka_Grosh_McFadden |
| Groothuis_Hendal |
| Aggour |
| Hughmark |
| Elamvaluthi_Srinivas |
| Ravipudi_Godbold |
Example 4: Methods for low quality flow
Inputs:
| m | x | D | alpha | rhol | Cpl | kl | mu_b | mu_w | L | check_ranges |
|---|---|---|---|---|---|---|---|---|---|---|
| 1 | 0.1 | 0.3 | 0.9 | 1000 | 2300 | 0.6 | 0.001 | 0.0012 | 5 | false |
Excel formula:
=H_TWO_PHASE_METHODS(1, 0.1, 0.3, 0.9, 1000, 2300, 0.6, 0.001, 0.0012, 5, FALSE)
Expected output:
| Aggour |
|---|
| Hughmark |
Python Code
Show Code
from ht.conv_two_phase import h_two_phase_methods as ht_h_two_phase_methods
def h_two_phase_methods(m, x, D, Cpl, kl, rhol=None, rhog=None, mul=None, mu_b=None, mu_w=None, mug=None, L=None, alpha=None, check_ranges=True):
"""
List available two-phase heat transfer correlations for a tube.
See: https://ht.readthedocs.io/en/latest/ht.conv_two_phase.html
This example function is provided as-is without any representation of accuracy.
Args:
m (float): Mass flow rate (kg/s).
x (float): Quality at the tube interval (-).
D (float): Tube diameter (m).
Cpl (float): Liquid heat capacity at constant pressure (J/kg/K).
kl (float): Liquid thermal conductivity (W/m/K).
rhol (float, optional): Liquid density (kg/m^3). Default is None.
rhog (float, optional): Gas density (kg/m^3). Default is None.
mul (float, optional): Liquid viscosity (Pa*s). Default is None.
mu_b (float, optional): Liquid viscosity at bulk conditions (Pa*s). Default is None.
mu_w (float, optional): Liquid viscosity at wall temperature (Pa*s). Default is None.
mug (float, optional): Gas viscosity (Pa*s). Default is None.
L (float, optional): Tube length (m). Default is None.
alpha (float, optional): Void fraction in the tube (-). Default is None.
check_ranges (bool, optional): Whether to return only applicable correlations (-). Default is True.
Returns:
list[list]: 2D array of available correlation method names.
"""
try:
methods = ht_h_two_phase_methods(
m=m,
x=x,
D=D,
Cpl=Cpl,
kl=kl,
rhol=rhol,
rhog=rhog,
mul=mul,
mu_b=mu_b,
mu_w=mu_w,
mug=mug,
L=L,
alpha=alpha,
check_ranges=check_ranges,
)
if not methods:
return "Error: No applicable correlations found for the given parameters."
return [[method] for method in methods]
except Exception as e:
return f"Error: {str(e)}"Online Calculator
Mass flow rate (kg/s).
Quality at the tube interval (-).
Tube diameter (m).
Liquid heat capacity at constant pressure (J/kg/K).
Liquid thermal conductivity (W/m/K).
Liquid density (kg/m^3).
Gas density (kg/m^3).
Liquid viscosity (Pa*s).
Liquid viscosity at bulk conditions (Pa*s).
Liquid viscosity at wall temperature (Pa*s).
Gas viscosity (Pa*s).
Tube length (m).
Void fraction in the tube (-).
Whether to return only applicable correlations (-).