[ncl-talk] I might find some bugs about calculation of wet-bulb temperature
Mr.J
shengxuan_ji at sina.com
Tue Dec 23 00:26:54 MST 2014
Dear Sir / Madam Thank you for your hard working on the development of NCL software. I can easily manipulate the met data and professional plots now.
During my usage of wrf related functions, I found a bug, which is about calculation of wet-bulb temperature. I noticed that after the version6.2.0, the Wet bulb temperature is available to be calculated in one step by wrf_user_getvar(file,"tw",time). However, when I used the wayto get it, I got a error massage:
fatal:["Execute.c":6321]:variable (tw) is not in file (nc_file)
I think it means the function "wrf_user_getvar" is trying to get the "tw" variable from the wrfout file instead of calculating the diagnostics "we-t bulb temperature".
Secondly, I tried to use the other way to calculate the "Tw" by using the function " wrf_wetbulb ", I also found some incorrect stuffs.On the description page of the "wrf_wetbulb", it shows that we need to put argument "p" in mb (hPa). However in the given example 1, the scriptuses "p = wrf_user_getvar(a,"p",0)" to get the pressure. It may be wrong, because the unit is Pa calculating in this way. All in all, what unitshould I use for the pressure. (Please refer to test_scrpit1.ncl)
Thirdly, in the description page of function "wrf_wetbulb", the unit of return value is [C]. When I get the results, these values are larger than250. So, I am confused about the return value unit. Is it [C] or [K]? (Please refer to test_script2.ncl)
The attachments are my test scripts, please check them. The wrfout file is too large to put it on a website, you may findanother one to try the scripts.
My system details:ncl version: 6.2.0( I also tried the vesion 6.2.1, the results are the same.)
uname -a Linux nowcast 2.6.32-358.el6.x86_64 #1 SMP Tue Jan 29 11:47:41 EST 2013 x86_64 x86_64 x86_64 GNU/Linux
gcc --versiongcc (GCC) 4.4.7 20120313 (Red Hat 4.4.7-3)Copyright (C) 2010 Free Software Foundation, Inc.
cat /etc/redhat-releaseRed Hat Enterprise Linux Server release 6.4 (Santiago)
To be honest, I am not sure whether these are bugs or not. Please help me to deal with these questions. Hope your reply ASAP. Thank you very very much!
Yours sincerely,Shengxuan JI--------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20141223/2488954f/attachment.html
-------------- next part --------------
A non-text attachment was scrubbed...
Name: test_script1.ncl
Type: application/octet-stream
Size: 424 bytes
Desc: not available
Url : http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20141223/2488954f/attachment.obj
-------------- next part --------------
A non-text attachment was scrubbed...
Name: test_script2.ncl
Type: application/octet-stream
Size: 539 bytes
Desc: not available
Url : http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20141223/2488954f/attachment-0001.obj
More information about the ncl-talk
mailing list