Page 1 of 2
Apparent Temperature
Posted: Thu 07 Oct 2010 6:01 am
by captzero
Hi all,
The Australian BOM website gives the following information for Apparent Temp:
The formula for the AT used by the Bureau of Meteorology is an approximations of the value provided by a mathematical model of heat balance in the human body. It can include the effects of temperature, humidity, wind-speed and radiation. Two forms are given, one including radiation and one without. On this site we use the non-radiation version.
Version including the effects of temperature, humidity, and wind: AT = Ta + 0.33×e − 0.70×ws − 4.00
Ta = Dry bulb temperature (°C)
e = Water vapour pressure (hPa) [humidity]
ws = Wind speed (m/s) at an elevation of 10 meters
The vapour pressure can be calculated from the temperature and relative humidity using the equation:
e = rh / 100 × 6.105 × exp ( 17.27 × Ta / ( 237.7 + Ta ) )
where:
rh = Relative Humidity [%]
So with all that in mind, I was able to come up with the following javascript to formulate the AT. Entering the BOM data, it faithfully matches their official AT figures.
<script type="text/javascript">
var temp =<#temp> + 0.33;
var hum = <#hum>/100*6.105*(17.27*temp/(237.7+temp));
var wind = <#wlatest>*0.27777777;
var apptemp = Math.abs (temp+ hum)-(0.70) * (wind)-4;
document.write(apptemp.toFixed(1));
</script>
I think the BOM formula is used in the latest build but using the Cumulus webtag for AT gives me a value several (about 9C) degrees higher.
Can someone more knowledgeable than me run their eye my script and see where I have erred?
Thanks
Re: Apparent Temperature
Posted: Thu 07 Oct 2010 8:33 am
by steve
It's quite likely that I have the calculation wrong in Cumulus! I was hoping someone would check it, as they did for Cumulus 2.
One thing to note; I don't use 'latest' wind speed (which is effectively a short-term gust), I use the average.
Re: Apparent Temperature
Posted: Thu 07 Oct 2010 9:23 am
by captzero
Thanks Steve,
Avg speed would work too. It would be your average AT over the last 10 mins, I guess. Certainly a little closer to the BOM calc.
Re: Apparent Temperature
Posted: Thu 07 Oct 2010 9:40 am
by beteljuice
e = rh / 100 × 6.105 × exp ( 17.27 × Ta / ( 237.7 + Ta ) )
should be 'coded' as:
var hum = <#hum>/100*6.105*Math.exp(17.27*temp/(237.7+temp));
Re: Apparent Temperature
Posted: Thu 07 Oct 2010 9:46 am
by steve
captzero wrote:Avg speed would work too. It would be your average AT over the last 10 mins, I guess. Certainly a little closer to the BOM calc.
As with wind chill, it seems to me that it doesn't make sense to use a gust in the calculation, but a sustained speed. Using a gust speed potentially results in a rapidly changing apparent temperature or wind chill, which doesn't seem right to me, given what the figures are supposed to represent. Temperatures don't change that rapidly.
Re: Apparent Temperature
Posted: Thu 07 Oct 2010 11:39 am
by captzero
Thank Steve, I agree. Latest is not the greatest .
Bj,
JS is still new to me and I'm still learning. I’m not sure I follow the 'Math.exp.' component of the equation.
Current AT in Brisbane is 25.8 C
Temp- 22.3 C
Hum – 83 %
Wind- 2 kph
If I use
<script type="text/javascript">
var temp =22.3 + 0.33;
var hum = 83/100*6.105*(17.27*temp/(237.7+temp));
var wind = 2*0.27777777;
var apptemp = Math.abs (temp+ hum)-(0.70) * (wind)-4;
document.write(apptemp.toFixed(1));
</script>
I get 25.8 C (same as BOM)
If I use
var hum = 82/100*6.105*Math.exp(17.27*temp/(237.7+temp));
I get 40.7 C
Re: Apparent Temperature
Posted: Thu 07 Oct 2010 11:55 am
by steve
'Exp' is "e to the power" where e is the mathematical constant approximately equal to 2.718.
In your calculation, you're adding 0.33 to the temperature, when in fact it should be used as a multiplier for the saturation vapour pressure. You need to apply the rules of precedence and do multiply before addition.
And looking at this has made me realise that I've got the calculation wrong in Cumulus; I think I've omitted the part where 4 gets subtracted!
Re: Apparent Temperature
Posted: Thu 07 Oct 2010 12:41 pm
by captzero
Ah.. all good.
As a young bloke at school, I never thought I'd ever have a use for any of that useless algebra stuff. I should have listened more closely to old Mr Bovey (Nosy Bovey to most of us) . Thanks Steve.
Re: Apparent Temperature
Posted: Thu 07 Oct 2010 3:41 pm
by beteljuice
If the original precedence is correct, then I
think this is the way it should look (untested !!!)
Code: Select all
<script type="text/javascript">
/* Apparent Temperature
Version including the effects of temperature, humidity, and wind: AT = Ta + 0.33×e − 0.70×ws − 4.00
Ta = Dry bulb temperature (°C)
e = Water vapour pressure (hPa) [humidity]
ws = Wind speed (m/s) at an elevation of 10 meters
The vapour pressure can be calculated from the temperature and relative humidity using the equation:
e = rh / 100 × 6.105 × exp ( 17.27 × Ta / ( 237.7 + Ta ) )
where:
rh = Relative Humidity [%]
*/
my_Ta = <#temp>; // degrees C
my_e = <#hum> / 100 * 6.105 * Math.exp( 17.27 * my_Ta / ( 237.7 + my_Ta));
my_ws = <#wlatest> * 0.27777; // windspeed converted from km/h to m/s
my_AT = my_Ta + 0.33 * my_e - 0.7 * my_ws - 4; // precedence is my_Ta + (0.33 * my_e) - (0.7 * my_ws) - 4
// tidy up
my_AT = ( Math.round(100* my_AT)/100).toFixed(1); // rounds up to one decimal with trailing .0 if required
document.write(my_AT);
</script>
Edit: Two coding errors fixed

Re: Apparent Temperature
Posted: Sat 16 Oct 2010 8:41 am
by daj
Can I ask a dumb question please? What is "apparent temperature" ? What is it telling me?
Re: Apparent Temperature
Posted: Sat 16 Oct 2010 8:48 am
by Gina
That Australian BOM site formula is what I'm using for apparent temperature. This gives what it would "feel like" outdoors to a human being. Like another version of "wind chill" but takes more into account. I'll let someone else explain the details - I just though it seemed better than the simple "wind chill" formula.
Re: Apparent Temperature
Posted: Sat 16 Oct 2010 8:59 am
by daj
Thanks Gina
I guessed it was something similar to wind chill but was curious if there was a difference as it has appeared in cumulus 1.9.1.
So just more accurate than Windchill.
Re: Apparent Temperature
Posted: Sat 16 Oct 2010 10:20 am
by steve
It attempts to combine wind chill and heat index to give one single 'feels like' temperature over the full range of conditions.
Re: Apparent Temperature
Posted: Tue 08 Feb 2011 9:48 am
by fractonimbus
I've just coded the apparent temperature for PHP, which as a single equation is as follows:
$apptemp = round(($temp + 0.33*($hum/100)*6.105*exp(17.27*$temp/(237.7+$temp))- 0.70*$wspeed - 4.00),1);
I always use brackets (...) around anything where I don't trust the order of compuation (or don't know the language).
The round(x,1) command trims it back to one decimal place.
Here, $apptemp is the apparent temperature variable, $temp is the (dry bulb) temperature, $hum is the relative humidity, and $wspeed is the average windspeed. Seems to work OK.
I checked the BOM page at
http://www.bom.gov.au/info/thermal_stress/ which explains what it's all about, and the original paper at
http://www.bom.gov.au/amm/docs/1994/steadman.pdf (it uses hectoPascals instead of kiloPascals for the water vapour pressure, so the constants are x10) and all seems good.
fracto
Re: Apparent Temperature
Posted: Tue 08 Feb 2011 10:07 am
by steve
Does your calculated value agree with the Cumulus <#apptemp> web tag? Hopefully!