Flange
- class pypbomb.Flange
Methods pertaining to flange class and max pressure calculations
For a list of available materials see
Flange.available_materials
- static get_class(max_pressure, temperature, material, unit_registry=<pint.registry.UnitRegistry object>)
Finds the minimum allowable flange class per ASME B16.5 for a given flange temperature and tube pressure.
- Parameters:
max_pressure (pint.Quantity or Tuple[float, str]) – Maximum pressure within the system as a quantity or tuple of
(magnitude, "units")
temperature (pint.Quantity or Tuple[float, str]) – Flange temperature as a quantity or tuple of
(magnitude, "units")
material (str) – Flange material (see
Flange.available_materials
)unit_registry (pint.UnitRegistry, optional) – Pint unit registry, if output within a particular registry is desired
- Returns:
Minimum allowable flange class
- Return type:
str
- static get_max_pressure(flange_class, temperature, material)
Finds the max allowable pressure for a flange of a given material and class at the desired temperature.
- Parameters:
flange_class (str) – Class of the flange to evaluate, e.g.
"900"
temperature (pint.Quantity or Tuple[float, str]) – Flange temperature
material (str) – Flange material (see
Flange.available_materials
)
- Returns:
Maximum allowable pressure
- Return type:
pint.Quantity
- static get_max_temperature(flange_class, pressure, material)
Finds the max allowable temperature for a flange of a given material and class at the desired pressure.
- Parameters:
flange_class (str) – Class of the flange to evaluate, e.g.
"900"
pressure (pint.Quantity or Tuple[float, str]) – System pressure
material (str) – Flange material (see
Flange.available_materials
)
- Returns:
Max allowable flange temperature
- Return type:
pint.Quantity