Fwd: Error in WRF winds rotated to Earth coordinates

From: Dennis Shea <shea_at_nyahnyahspammersnyahnyah>
Date: Mon Jan 09 2012 - 06:54:00 MST

Hi Andrea,

WRFUserARW.ncl was crated by WRF.
This bug has been forwarded to wrfhelp@ucar.edu

Happy New Year
D

-------- Original Message --------
Subject: [ncl-talk] Error in WRF winds rotated to Earth coordinates
Date: Mon, 9 Jan 2012 13:51:10 +0100
From: Andrea N. Hahmann <ahah@dtu.dk>
To: ncl-talk@ucar.edu <ncl-talk@ucar.edu>

I think I have found a bug in the calculation of the cone used for the
calculation of the winds rotated to the Earth coordinates in a Lambert
Conformal projection. The error is only for the Lambert Conformal
projection. As far as I know, alog10 (i.e. log10) is not the same as 10^…

In WRFUserARW.ncl:

if( map_projection .eq. 1) then ; Lambert Conformal mapping
if( (fabs(true_lat1 - true_lat2) .gt. 0.1) .and. \
(fabs(true_lat2 - 90. ) .gt. 0.1) ) then
cone = 10^(cos(true_lat1*radians_per_degree)) \
-10^(cos(true_lat2*radians_per_degree))
cone = cone/(10^(tan(45. -fabs(true_lat1/2.)*radians_per_degree)) - \
10^(tan(45. -fabs(true_lat2/2.)*radians_per_degree)) )
else
cone = sin(fabs(true_lat1)*radians_per_degree)
end if

In WRF (fortran; subroutine lc_cone in share/module_llxy.f90):

IF (ABS(truelat1-truelat2) .GT. 0.1) THEN
cone = ALOG10(COS(truelat1*rad_per_deg)) - &
ALOG10(COS(truelat2*rad_per_deg))
cone = cone /(ALOG10(TAN((45.0 - ABS(truelat1)/2.0) * rad_per_deg)) - &
ALOG10(TAN((45.0 - ABS(truelat2)/2.0) * rad_per_deg)))
ELSE
cone = SIN(ABS(truelat1)*rad_per_deg )
ENDIF

Furthermore, when doing the calculation in NCL it does not match the
values of COSALPHA and SINALPHA in the wrfout file.

Regards, Andrea

--
Andrea N. Hahmann
Senior Scientist
DTU Wind Energy
Technical University of Denmark
	
Department of Wind Energy
Risø Campus Frederiksborgvej 399
Building 118
4000 Roskilde
Direct +45 46775471
Mobile +45 2133 0550
ahah@risoe.dtu.dk <mailto:ahah@risoe.dtu.dk>
www.dtu.dk <http://www.dtu.dk>
Learn more about DTU Wind Energy on www.vindenergi.dtu.dk
<http://www.vindenergi.dtu.dk/>.
_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Mon Jan 9 06:54:12 2012

This archive was generated by hypermail 2.1.8 : Wed Jan 18 2012 - 09:21:55 MST