Skip to content

Air

Air

CIGRE air models.

dynamic_viscosity staticmethod

dynamic_viscosity(
    air_temperature: floatArrayLike,
    altitude: floatArrayLike = 0.0,
) -> floatArrayLike

Compute air dynamic viscosity.

If both inputs are numpy arrays, they should have the same size.

Parameters:

Name Type Description Default

air_temperature

float | ndarray

Air temperature (in Celsius)

required

altitude

float | ndarray

Altitude above sea-level. The default is 0.

0.0

Returns:

Type Description
floatArrayLike

float | numpy.ndarray: Dynamic viscosity in kg·m⁻¹·s⁻¹.

Source code in src/thermohl/power/cigre/air.py
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
@staticmethod
def dynamic_viscosity(
    air_temperature: floatArrayLike, altitude: floatArrayLike = 0.0
) -> floatArrayLike:
    r"""Compute air dynamic viscosity.

    If both inputs are numpy arrays, they should have the same size.

    Args:
        air_temperature (float | numpy.ndarray): Air temperature (in Celsius)
        altitude (float | numpy.ndarray, optional): Altitude above sea-level. The default is 0.

    Returns:
        float | numpy.ndarray: Dynamic viscosity in kg·m⁻¹·s⁻¹.

    """
    return Air.kinematic_viscosity(air_temperature) * Air.volumic_mass(
        air_temperature, altitude
    )

kinematic_viscosity staticmethod

kinematic_viscosity(
    air_temperature: floatArrayLike,
) -> floatArrayLike

Compute air kinematic viscosity.

Parameters:

Name Type Description Default

air_temperature

float | ndarray

Air temperature (in Celsius)

required

Returns:

Type Description
floatArrayLike

float | numpy.ndarray: Kinematic viscosity in m²·s⁻¹.

Source code in src/thermohl/power/cigre/air.py
56
57
58
59
60
61
62
63
64
65
66
67
@staticmethod
def kinematic_viscosity(air_temperature: floatArrayLike) -> floatArrayLike:
    r"""Compute air kinematic viscosity.

    Args:
        air_temperature (float | numpy.ndarray): Air temperature (in Celsius)

    Returns:
        float | numpy.ndarray: Kinematic viscosity in m²·s⁻¹.

    """
    return 1.32e-05 + 9.5e-08 * air_temperature

prandtl staticmethod

prandtl(air_temperature: floatArrayLike) -> floatArrayLike

Compute Prandtl number.

The Prandtl number (Pr) is a dimensionless number, named after the German physicist Ludwig Prandtl, defined as the ratio of momentum diffusivity to thermal diffusivity.

Parameters:

Name Type Description Default

air_temperature

float | ndarray

Air temperature (in Celsius)

required

Returns:

Type Description
floatArrayLike

float | numpy.ndarray: Prandtl number (—)

Source code in src/thermohl/power/cigre/air.py
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
@staticmethod
def prandtl(air_temperature: floatArrayLike) -> floatArrayLike:
    """Compute Prandtl number.

    The Prandtl number (Pr) is a dimensionless number, named after the German
    physicist Ludwig Prandtl, defined as the ratio of momentum diffusivity to
    thermal diffusivity.

    Args:
        air_temperature (float | numpy.ndarray): Air temperature (in Celsius)

    Returns:
        float | numpy.ndarray: Prandtl number (—)

    """
    return 0.715 - 2.5e-04 * air_temperature

relative_density staticmethod

relative_density(
    air_temperature: floatArrayLike,
    altitude: floatArrayLike = 0.0,
) -> floatArrayLike

Compute relative density, ie density ratio regarding density at zero altitude.

This function has temperature and altitude as input for consistency regarding other functions in the module, but the temperature has no influence, only the altitude for this model.

If both inputs are numpy arrays, they should have the same size.

Parameters:

Name Type Description Default

air_temperature

float | ndarray

Air temperature (in Celsius).

required

altitude

float | ndarray

Altitude above sea-level. The default is 0.

0.0

Returns:

Type Description
floatArrayLike

float | numpy.ndarray: Relative density of air.

Source code in src/thermohl/power/cigre/air.py
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
@staticmethod
def relative_density(
    air_temperature: floatArrayLike, altitude: floatArrayLike = 0.0
) -> floatArrayLike:
    """Compute relative density, ie density ratio regarding density at zero altitude.

    This function has temperature and altitude as input for consistency
    regarding other functions in the module, but the temperature has no
    influence, only the altitude for this model.

    If both inputs are numpy arrays, they should have the same size.

    Args:
        air_temperature (float | numpy.ndarray): Air temperature (in Celsius).
        altitude (float | numpy.ndarray, optional): Altitude above sea-level. The default is 0.

    Returns:
        float | numpy.ndarray: Relative density of air.

    """
    return np.exp(-1.16e-04 * altitude) * np.ones_like(air_temperature)

thermal_conductivity staticmethod

thermal_conductivity(
    air_temperature: floatArrayLike,
) -> floatArrayLike

Compute air thermal conductivity.

Parameters:

Name Type Description Default

air_temperature

float | ndarray

Air temperature (in Celsius)

required

Returns:

Type Description
floatArrayLike

float | numpy.ndarray: Thermal conductivity in W·m⁻¹·K⁻¹.

Source code in src/thermohl/power/cigre/air.py
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
@staticmethod
def thermal_conductivity(air_temperature: floatArrayLike) -> floatArrayLike:
    r"""Compute air thermal conductivity.

    Args:
        air_temperature (float | numpy.ndarray): Air temperature (in Celsius)

    Returns:
        float | numpy.ndarray: Thermal conductivity in W·m⁻¹·K⁻¹.

    """
    return 2.42e-02 + 7.2e-05 * air_temperature

volumic_mass staticmethod

volumic_mass(
    air_temperature: floatArrayLike,
    altitude: floatArrayLike = 0.0,
) -> floatArrayLike

Compute air volumic mass.

If both inputs are numpy arrays, they should have the same size.

Parameters:

Name Type Description Default

air_temperature

float | ndarray

Air temperature (in Celsius).

required

altitude

float | ndarray

Altitude above sea-level. The default is 0.

0.0

Returns:

Type Description
floatArrayLike

float | numpy.ndarray: Volumic mass in kg·m⁻³.

Source code in src/thermohl/power/cigre/air.py
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
@staticmethod
def volumic_mass(
    air_temperature: floatArrayLike, altitude: floatArrayLike = 0.0
) -> floatArrayLike:
    r"""Compute air volumic mass.

    If both inputs are numpy arrays, they should have the same size.

    Args:
        air_temperature (float | numpy.ndarray): Air temperature (in Celsius).
        altitude (float | numpy.ndarray, optional): Altitude above sea-level. The default is 0.

    Returns:
        float | numpy.ndarray: Volumic mass in kg·m⁻³.

    """
    return 1.2925 * Air.relative_density(air_temperature, altitude)