[ncl-talk] rcm2rgrid to interpolates WRF output

Dennis Shea shea at ucar.edu
Wed Nov 12 09:26:39 MST 2014


If you are new to NCL, please read the Mini-Language Manual
   http://www.ncl.ucar.edu/Document/Manuals/

===

[1]   This is not NCL syntax. Again read the manual, please
             rain_exp(it, nlat, nlon)==>rain_exp_xgrd
              rain_con(it, nlat, nlon)==>rain_con_xgrd

[2] Further, on all the WRF files we know of there are no variables named
'xlat or 'xlon'.
     Rather ....

       float XLAT(Time, south_north, west_east) ;
                XLAT:FieldType = 104 ;
                XLAT:MemoryOrder = "XY " ;
                XLAT:description = "LATITUDE, SOUTH IS NEGATIVE" ;
                XLAT:units = "degree_north" ;
                XLAT:stagger = "" ;

        float XLONG(Time, south_north, west_east) ;
                XLONG:FieldType = 104 ;
                XLONG:MemoryOrder = "XY " ;
                XLONG:description = "LONGITUDE, WEST IS NEGATIVE" ;
                XLONG:units = "degree_east" ;
                XLONG:stagger = "" ;

[3] Also, XLAT and XLONG are *three* dimensional.

               lat2d=a->XLAT(0,:,:)
              lon2d=a->XLONG(0,:,:)

[4] Why are you doung this?     lon=fspan(0,nlon,1)
     Try    print(lon)
     You are gettind 1,2,3,,,,63,64 for longitudes.
     Maybe you want

         lon = *lonGlobeF*(mlon, "lon", "longitude", "degrees_east")

Please use 'print or 'printVarSummary' often





'



On Wed, Nov 12, 2014 at 12:55 AM, 易路 <dg1225033 at smail.nju.edu.cn> wrote:

> Hi all,
>
>  I try to use rcm2grid to interpolates WRF output data on a curvilinear
> grid  to a rectilinear grid. But the teminal showed erros as follows:
>
> fatal:syntax error: line 80 in file 2gridPrecipitation.ncl before or near
> =>rain_exp_xgrd
>         rain_exp(it, nlat, nlon)==>rain_exp_xgrd
> -----------------------------------------------^
>
> fatal:syntax error: line 81 in file 2gridPrecipitation.ncl before or near
> =>rain_con_xgrd
>         rain_con(it, nlat, nlon)==>rain_con_xgrd
> -----------------------------------------------^
>
> fatal:Syntax Error in block, block not executed
> fatal:error at line 177 in file 2gridPrecipitation.ncl
>
> And my parts of scripts are as follows, would you please help me check it?
>
>     rain_exp = wrf_user_getvar(a,"RAINNC",it)
>     rain_con = wrf_user_getvar(a,"RAINC",it)
>
>
> ; rcm2rgrid  **********************************************
>         nlat=48
>         nlon=64
>         lat=latGau(nlat,"lat","latitude", "degrees_north")
>         lon=fspan(0,nlon,1)
>         lat2d=a->xlat
>         lon2d=a->xlon
>
>         rain_exp_xgrd =rcm2rgrid(lat2d,lon2d,rain_exp,lat,lon,0)
>         ;rain_con_xgrd =rcm2rgrid(lat2d,lon2d,rain_con,lat,lon,0)
>
>         rain_exp(it, nlat, nlon)==>rain_exp_xgrd(it,64,128)
>         ;rain_con(it, nlat, nlon)==>rain_con_xgrd(it,64,128)
>        ; rain_tot = rain_exp + rain_con
> ;*******************************************************************
> _______________________________________________
> ncl-talk mailing list
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20141112/0808070f/attachment.html 


More information about the ncl-talk mailing list