0.3.0 => https://www.wpc.ncep.noaa.gov/html/heatindex_equation.shtml previous https://en.wikipedia.org/wiki/Heat_index TC = temp in Celsius RH = relative humidity in %
| 123 | // TC = temp in Celsius |
| 124 | // RH = relative humidity in % |
| 125 | float heatIndexC(float TC, float RH) |
| 126 | { |
| 127 | if ( (TC < 27) || (RH < 40)) return TC; |
| 128 | float TF = Fahrenheit(TC); |
| 129 | return Celsius(heatIndex(TF, RH)); |
| 130 | |
| 131 | /* |
| 132 | const float c1 = -8.78469475556; |
| 133 | const float c2 = 1.61139411; |
| 134 | const float c3 = 2.33854883889; |
| 135 | const float c4 = -0.14611605; |
| 136 | const float c5 = -0.012308094; |
| 137 | const float c6 = -0.0164248277778; |
| 138 | const float c7 = 0.002211732; |
| 139 | const float c8 = 0.00072546; |
| 140 | const float c9 = -0.000003582; |
| 141 | |
| 142 | float A = (( c5 * Celsius) + c2) * Celsius + c1; |
| 143 | float B = (((c7 * Celsius) + c4) * Celsius + c3) * humidity; |
| 144 | float C = (((c9 * Celsius) + c8) * Celsius + c6) * humidity * humidity; |
| 145 | |
| 146 | return A + B + C; |
| 147 | */ |
| 148 | } |
| 149 | |
| 150 | |
| 151 | // https://en.wikipedia.org/wiki/Wind_chill |