Spaces:
Runtime error
Runtime error
File size: 743 Bytes
98a2104 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 |
import numpy as np
def hli(irradiance : float, air_temperature : float, RH : float, wind_speed : float):
"""
Compute Heat Load Index (HLI), a thermal stress indicator for animals.
Parameters
----------
irradiance : float
Solar radiation [W.m-2]
air_temperature : float
Air temperature [°C]
RH : float
Relative humidity [%]
wind_speed : float
Wind speed [m.s-1]
Returns
-------
float
Heat Load Index value.
"""
BGT = 0.01498*irradiance + 1.184*air_temperature - 0.0789*RH - 2.739
HLI = np.where(BGT >= 25, 1.55*BGT- 0.5*wind_speed + np.exp(2.4 - wind_speed)+8.62 + 0.38*RH, 1.30*BGT - wind_speed+10.66 + 0.28*RH)
return HLI |