Re: rectilinear grids to curvilinear grids

From: Sha Feng <sfeng_at_nyahnyahspammersnyahnyah>
Date: Thu May 22 2014 - 16:28:49 MDT

Dennis,

Sorry for typos. I did use "rgrid2rcm_Wrap". Also, I tried to use ESMF
regrid functions, but I don't have weights for interpolation. Could you
help me out, please?

Thanks,
Sha

On Thu, May 22, 2014 at 3:23 PM, Dennis Shea <shea@ucar.edu> wrote:

> You should use: rgrid2rcm or, better, rgrid2rcm_Wrap
>
> https://www.ncl.ucar.edu/Document/Functions/Built-in/rgrid2rcm.shtml
>
> https://www.ncl.ucar.edu/Document/Functions/Contributed/rgrid2rcm_Wrap.
> shtml
>
> The 0.1deg x 0.1deg is a rectilinear grid ('rgrid(
> The WRF is curvilinear.
> ========
>
> It would be must faster to use the ESMF regrid functions.
>
> https://www.ncl.ucar.edu/Applications/ESMF.shtml
>
> Example 29 (Part B) shows how to interpolate the
> rectilinear grid to a WRF grid.
>
>
>
>
> On 5/22/14, 4:12 PM, Sha Feng wrote:
>
>> Hi Mary,
>>
>> I was trying to regrid data on 0.1deg x 0.1deg to a 12km x 12 km WRF
>> domain
>> using the function of "rcm2rgrid." The description of this function looks
>> good match for this purpose. But after interpolation, the output doesn't
>> look good to use (assuming nothing wrong in interpolation). After ncdump
>> the variable, it shows a lot of
>>
>> ---- _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _,
>> _,
>> _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _,
>> _,
>> _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _,
>> _,
>> _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _,
>> _,
>> _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _,
>> _,
>> _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _,
>> _,
>> _, _, _, _, _, _, _, _, _, _, _,
>> _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _,
>> ---
>>
>> and ncview can't even run through. I attached my ncl codes as follows, and
>> a plot for the source data that is carbon emission (I guess, rcm2rgrid
>> might not be a good option for such scattering data). Could you take a
>> look
>> and help me for interpolation?
>>
>> ....
>> f = addfile(dir+fname,"r")
>> xin = f->E_Carbon
>> latin = f->lat
>> lonin = f->lon
>> printMinMax(lonin,True)
>> printMinMax(xin,True)
>>
>> a = addfile(dir+"wrfout_d"+dm+".nc","r")
>> lat = wrf_user_getvar(a,"lat",0)
>> lon = wrf_user_getvar(a,"lon",0)
>> printMinMax(lon,True)
>> data = rgrid2rcm_Wrap(latin,lonin,xin,lat,lon,0)
>> printVarSummary(data)
>> printMinMax(data,True)
>> .....
>>
>> Many thanks!
>> Sha
>>
>>
>>
>> _______________________________________________
>> ncl-talk mailing list
>> List instructions, subscriber options, unsubscribe:
>> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>>
>>

_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Thu May 22 16:29:02 2014

This archive was generated by hypermail 2.1.8 : Tue May 27 2014 - 15:45:08 MDT