# Gas viscosity¶

Gas viscosity as a function of temperature can be calculated from the following equation:

$\mu_{gas} = A + B\,T + C\,T^2 + D\,T^3$

where coefficients A, B, C, and D are obtained from tables in the Yaws’ Handbook for inorganic and organic compounds. The Chemics function supports 372 inorganic gas species and 7,031 organic gas species. At a minimum, the function requires the formula name and temperature as input parameters; however, the CAS number may be needed as an input if more than one form of a species exists.

Viscosity of a gas mixture can be estimated as a weighted mean using the mixture function. Note that for a gas mixture, the sum of the components must equal 1.

## Nomenclature¶

$$\mu_{gas}$$ - Viscosity of gas ($$\mu P$$)
$$A, B, C, D$$ - Coefficients from Yaws’ Handbook (-)
$$T$$ - Temperature (K)

## Source code¶

chemics.gas_viscosity.mu_gas(formula, temp, cas=None, full=False)[source]

Viscosity of gas as a function of temperature. Results calculated from coefficients in Yaws’ Critical Property Data for Chemical Engineers and Chemists 1. CAS (Chemical Abstracts Service) number may be required for some species.

Parameters
• formula (str) – Molecular formula of the gas.

• temp (float) – Temperature of the gas [K]

• cas (str, optional) – CAS number of the gas, required for some species [-]

• full (bool, optional) – When set to False (default) just gas viscosity is returned. When set to True then return gas viscosity and other information.

Returns

• mu_gas (float) – Viscosity of gas [micropoise]

• mu_gas, cas, tmin, tmax, a, b, c, d (tuple) – Additional values are only returned when keyword full=True.

mu_gas - Viscosity of gas [micropoise]
cas - CAS number [-]
tmin, tmax - Temperature range at which results are applicable [K]
a, b, c, d - Values for regression coefficients [-]

Raises
• ValueError – If gas formula is not found in csv data file.

• ValueError – If gas temperature is not in range between tmin and tmax.

Examples

>>> mu_gas('CH4', 810)
234.21

>>> mu_gas('C2Cl2F4', 900, cas='374-07-2')
314.90

>>> mu_gas('H2', 404)
113.18

>>> mu_gas('N2', 773)
363.82

>>> mu_gas('N2', 773, full=True)
(363.82, '7727-37-9', 63.15, 1970.0, 4.46, 0.63, -0.00026, 5.41e-08)


References

1

Carl L. Yaws. Viscosity Gas Tables 80 and 81 in Yaws’ Critical Property Data for Chemical Engineers and Chemists. Published by Knovel, 2014.

chemics.gas_viscosity.mu_graham(mus, xs)[source]

Calculate viscosity of a gas mixture using Graham’s method 2. Formula presented here is based on Equation 1 from the Davidson report 3.

$\mu_{mix} = \sum (x_i \cdot \mu_i)$

where $$\mu_{mix}$$ is viscosity of the gas mixture, $$x_i$$ is mole fraction [-] of each component, and $$\mu_i$$ is gas viscosity of each component.

Parameters
• mus (list, tuple, or array) – Viscosity of each gas component.

• xs (list, tuple, or array) – Mole fraction of each gas component [-]

Returns

mu (float) – Gas viscosity of the mixture. Units are same as input viscosity.

Raises

ValueError – If sum of mole fractions does not equal 1.0

Example

>>> mu_h2 = cm.mu_gas('H2', 773.15)
... mu_n2 = cm.mu_gas('N2', 773.15)
... mu_graham([mu_h2, mu_n2], [0.85, 0.15])
207.37


References

2

Thomas Graham. On the Motion of Gases. Philosophical Transactions of the Royal Society of London, vol. 136, pp. 573-631, 1846.

3

Thomas Davidson. A Simple and Accurate Method for Calculating Viscosity of Gaseous Mixtures. United States Department of the Interior: Report of Investigations 9456, 1993.

chemics.gas_viscosity.mu_herning(mus, mws, xs)[source]

Calculate viscosity of a gas mixture using the approach by Herning and Zipperer 4. Formula presented here is based on Equation 1 from the Davidson report 5.

$\mu_{mix} = \frac{\sum (\mu_i \cdot x_i \cdot \sqrt{MW_i})}{\sum (x_i \cdot \sqrt{MW_i})}$

where $$\mu_{mix}$$ is viscosity of the gas mixture, $$x_i$$ is mole fraction [-] of each component, $$\mu_i$$ is gas viscosity of each component, and $$MW_i$$ is the molecular weight [g/mol] of each component.

Parameters
• mus (list, tuple, or array) – Viscosity of each gas component.

• mws (list, tuple, or array) – Molecular weight of each gas component [g/mol]

• xs (list, tuple, or array) – Mole fraction of each gas component [-]

Returns

mu (float) – Gas viscosity of the mixture. Units are same as input viscosity.

Raises

ValueError – If sum of mole fractions does not equal 1.0

Example

>>> mu_h2 = cm.mu_gas('H2', 773.15)
... mu_n2 = cm.mu_gas('N2', 773.15)
... mw_h2 = cm.mw('H2')
... mw_n2 = cm.mw('N2')
... mu_herning([mu_h2, mu_n2], [mw_h2, mw_n2], [0.85, 0.15])
252.81


References

4

F. Herning and L. Zipperer. Calculation of the Viscosity of Technical Gas Mixtures From the Viscosity of the Individual Gases. Gas-und Wasserfach, vol. 79, pp. 69-73, 1936.

5

Thomas Davidson. A Simple and Accurate Method for Calculating Viscosity of Gaseous Mixtures. United States Department of the Interior: Report of Investigations 9456, 1993.