flowtube.flow_calc
Conversion functions for flow rates and concentrations in flowtube package.
Functions
|
Calculate Knudsen number - eq. |
|
Convert mixing ratio in ppb to molecules cm-3. |
|
Calculate the effective Sherwood number - eq. |
|
Calculate buoyancy parameters. |
|
Convert cm3 per min to sccm |
|
Calculate conductance through cylinder - eq. |
|
Entrance length (cm) - length to achieve laminar profile - Bird et al., 2002, page 52. |
|
Calculate mixing time (s) - Hanson and Lovejoy, Geophys. |
|
Calculate thermal molecular velocity. |
|
Calculate pressure gradient - eqs. |
|
Calculate Reynolds number for a gas flowing through a cylinder. |
|
Calculate Reynolds number for a gas flowing through a cylinder. |
|
Convert sccm to cm3 per min. |
|
Calculate flow velocity. |
Classes
|
|
|
|
|
- class flowtube.flow_calc.basic_attrs(*args, **kwargs)[source]
-
P:
float
-
T:
float
- __init__(*args, **kwargs)
-
P:
- class flowtube.flow_calc.carrier_attrs(*args, **kwargs)[source]
-
carrier_dynamic_viscosity:
float
-
carrier_density:
float
-
carrier_dynamic_viscosity:
- class flowtube.flow_calc.full_attrs(*args, **kwargs)[source]
-
reactant_diffusion_rate:
float
-
reactant_molec_velocity:
float
-
reactant_diffusion_rate:
- flowtube.flow_calc.sccm_to_ccm(obj, FR)[source]
Convert sccm to cm3 per min.
- Parameters:
obj (basic_attrs) – Object with basic attributes (P in Pa, T in K).
FR (float) – Flow rate in sccm.
- Returns:
Flow rate in cm3 min-1
- Return type:
float
- flowtube.flow_calc.ccm_to_sccm(obj, FR)[source]
Convert cm3 per min to sccm
- Parameters:
obj (basic_attrs) – Object with basic attributes (P in Pa, T in K).
FR (float) – Flow rate in cm3 min-1.
- Returns:
Flow rate to sccm.
- Return type:
float
- flowtube.flow_calc.sccm_to_velocity(obj, FR, diameter)[source]
Calculate flow velocity.
- Parameters:
obj (basic_attrs) – Object with basic attributes (P in Pa, T in K).
FR (float) – Flow rate in sccm.
diameter (float) – Diameter in cm.
- Returns:
Flow velocity in cm s-1.
- Return type:
float
- flowtube.flow_calc.MR_to_molec(obj, conc)[source]
Convert mixing ratio in ppb to molecules cm-3.
- Parameters:
obj (basic_attrs) – Object with basic attributes (P in Pa, T in K).
conc (float) – Mixing ratio (ppb - mol mol-1).
- Returns:
Concentration in molec. cm-3.
- Return type:
float
- flowtube.flow_calc.molec_velocity(obj, molar_mass)[source]
Calculate thermal molecular velocity. Formula matched to values from Knopf et al., Anal. Chem., 2015
- Parameters:
obj (basic_attrs) – Object with basic attributes (P in Pa, T in K).
molar_mass (float) – Molar mass of the gas (g mol-1).
- Returns:
Thermal molecular velocity in cm s-1.
- Return type:
float
- flowtube.flow_calc.reynolds_number(obj, FR, diameter)[source]
Calculate Reynolds number for a gas flowing through a cylinder.
- Parameters:
obj (carrier_attrs) – Object with full attributes (P in Pa, T in K, carrier_dynamic_viscosity in kg m-1 s-1, carrier_density in kg m-3).
FR (float) – Total flow rate in sccm.
diameter (float) – Diameter of the cylinder (cm).
- Returns:
Reynolds number.
- Return type:
float
- flowtube.flow_calc.reynolds_number_irregular(obj, cross_sectional_area, wetted_perimeter, FR)[source]
Calculate Reynolds number for a gas flowing through a cylinder. Formula 6-14 from Holman and Bhattacharyya 2011.
- Parameters:
obj (carrier_attrs) – Object with full attributes (P in Pa, T in K, carrier_dynamic_viscosity in kg m-1 s-1, carrier_density in kg m-3).
cross_sectional_area (float) – Cross sectional area of the flow passage (cm2).
wetted_perimeter (float) – Wetted perimeter of the flow passage (cm).
FR (float) – Total flow rate in sccm.
- Returns:
Reynolds number.
- Return type:
float
- flowtube.flow_calc.conductance(obj, diameter, length)[source]
Calculate conductance through cylinder - eq. 3.17 from Moore et al., 2009.
- Parameters:
obj (carrier_attrs) – Object with full attributes (P in Pa, T in K, carrier_dynamic_viscosity in kg m-1 s-1, carrier_density in kg m-3).
diameter (float) – Inner diameter (cm).
length (float) – Length (cm).
- Returns:
Conductance in L s-1.
- Return type:
float
- flowtube.flow_calc.pressure_gradient(obj, conductance, FR)[source]
Calculate pressure gradient - eqs. 3.9 & 3.10 from Moore et al., 2009.
- Parameters:
obj (basic_attrs) – Object with basic attributes (P in Pa, T in K).
conductance (float) – Conductance in L s-1.
flow_rate (float) – Flow rate in sccm.
FR (float)
- Returns:
Pressure gradient ratio.
- Return type:
float
- flowtube.flow_calc.buoyancy_parameters(obj, delta_T, distance, Re)[source]
Calculate buoyancy parameters.
- Parameters:
obj (carrier_attrs) – Object with full attributes (P in Pa, T in K, carrier_dynamic_viscosity in kg m-1 s-1, carrier_density in kg m-3).
delta_T (float) – Temperature difference (K).
distance (float) – Distance over which the temperature difference is measured (cm) (typically axial or radial).
Re (float) – Reynolds number of the flow tube.
- Returns:
- Buoyancy parameter (>1 indicates the flow being driven by
buoyancy).
- Return type:
float
- flowtube.flow_calc.length_to_laminar(diameter, Re)[source]
Entrance length (cm) - length to achieve laminar profile - Bird et al., 2002, page 52. Note that the scalar term can vary depending on the source. Keyser, 1994 gives a value of 0.0565 for 99% attainment of parabolic profile while Hanson and Kosciuch, 2003 provide a value of 0.05 for 95% attainment. Using an exponential fit of the values, it seems that the 0.035 figure that Bird et al., 2002 gives is for a 85% attainment. Choose whichever value is most appropriate for your purposes.
- Parameters:
diameter (float) – Diameter of the cylinder (cm).
Re (float) – Reynolds number of the flow tube.
- Returns:
Length to laminar profile (cm).
- Return type:
float
- flowtube.flow_calc.mixing_time(obj, diameter)[source]
Calculate mixing time (s) - Hanson and Lovejoy, Geophys. Res. Lett., 1994.
- Parameters:
obj (full_attrs) – Object with full attributes (P in Pa, T in K, reactant_diffusion_rate in cm2 s-1, carrier_dynamic_viscosity in kg m-1 s-1, carrier_density in kg m-3).
diameter (float) – Diameter of the cylinder (cm).
- Returns:
Mixing time in seconds.
- Return type:
float
- flowtube.flow_calc.N_eff_Shw(obj, length, FR)[source]
Calculate the effective Sherwood number - eq. 11 from Knopf et al., 2015.
- Parameters:
obj (full_attrs) – Object with full attributes (P in Pa, T in K, reactant_diffusion_rate in cm2 s-1, carrier_dynamic_viscosity in kg m-1 s-1, carrier_density in kg m-3).
length (float) – Length of the flow tube (cm).
FR (float) – Total flow rate in cm3 min-1.
- Returns:
Effective Sherwood number.
- Return type:
float
- flowtube.flow_calc.Kn(mean_free_path, char_length)[source]
Calculate Knudsen number - eq. 8 from Knopf et al., 2015.
- Parameters:
mean_free_path (float) – Mean free path of the reactant (cm).
char_length (float) – Characteristic length: diameter of cylinder for a coated wall reactor (cm).
- Returns:
Knudsen number.
- Return type:
float