[ncl-talk] WRF interpolating (amendment)
Barry Lynn
barry.h.lynn at gmail.com
Wed Sep 11 12:21:32 MDT 2019
Hello:
Have you considered to use get_ij.f
It will give 1 or end of domain values for values outside the domain.
i_loc := new(num_obs,integer)
j_loc := new(num_obs,integer)
ii_loc = 0
jj_loc = 0
do i_sta = 0,num_obs-1
GET_IJ::get_ij
(xlat2d,xlon2d,lat_o(i_sta),lon_o(i_sta),ii_loc,jj_loc,dims2d(0),dims2d(1))
i_loc(i_sta) = ii_loc-1
j_loc(i_sta) = jj_loc-1
end do
On Wed, Sep 11, 2019 at 7:32 PM Ehsan Taghizadeh via ncl-talk <
ncl-talk at ucar.edu> wrote:
> Yes, exactly.
> I want to interpolate WRF data on station locations, which have been
> included in "stations.dat" file.
> The problem is that some of the stations in this file don't locate in WRF
> domain, but most of them get values. If the station doesn't locate in the
> domain, how it could get interpolated values. For example, 40899 and 40890
> are out of domain 2, and they got bad value "
> 9969209968386869046778552952102584320.0", correctly. On the other hand,
> 40745, also is out of domain 2, but it got value! Logically, It must have "
> 9969209968386869046778552952102584320.0", too.
>
> *Sincerely*
> *Ehsan*
> On Wednesday, September 11, 2019, 07:16:56 PM GMT+4:30, Barry Lynn <
> barry.h.lynn at gmail.com> wrote:
>
>
> Hello:
>
> DId you mean that you want to interpolate WRF data to station locations?
>
> On Wed, Sep 11, 2019 at 3:08 PM Ehsan Taghizadeh via ncl-talk <
> ncl-talk at ucar.edu> wrote:
>
> (Pardon me for incomplete previous email)
> Dears,
> I hope this email finds you well.
> I have a script for interpolating WRF data on some stations, using
> "rcm2points". The input file for stations includes stations which some of
> them don't locate on wrf out domain 2. I thought these stations must get
> missing value or so. But all stations, except a few ones, got values!
> May I ask you how it could possible?
> I've attached the script (wrfncl.ncl), the input file for stations
> (stations.dat), an image showing domain 2 (wrfd2.png), also an image
> showing all stations locations (stations.png). The wrfout file is about 2G.
> Should I put this file in ftp?
> Some information of my system is as below:
> $ uname -a
> Linux localhost.localdomain 3.10.0-514.2.2.el7.x86_64 #1 SMP Tue Dec 6
> 23:06:41 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux
> $ ncl -V
> 6.6.2
>
> Also, about some variables:
> Variable: wlat
> Type: float
> Total Size: 383616 bytes
> 95904 values
> Number of Dimensions: 2
> Dimensions and sizes: [south_north | 333] x [west_east | 288]
> Coordinates:
> Number Of Attributes: 6
> FieldType : 104
> MemoryOrder : XY
> description : LATITUDE, SOUTH IS NEGATIVE
> units : degree_north
> stagger :
> coordinates : XLONG XLAT
> (0) LATITUDE, SOUTH IS NEGATIVE (degree_north) : min=31.2974
> max=40.4085
> (0) LONGITUDE, WEST IS NEGATIVE (degree_east) : min=43.4514
> max=53.5448
>
> Variable: TC2
> Type: float
> Total Size: 8055936 bytes
> 2013984 values
> Number of Dimensions: 3
> Dimensions and sizes: [21] x [333] x [288]
> Coordinates:
> Number Of Attributes: 1
> units : C
>
> Variable: TC2_st
> Type: float
> Total Size: 32172 bytes
> 8043 values
> Number of Dimensions: 2
> Dimensions and sizes: [21] x [383]
> Coordinates:
> Number Of Attributes: 1
> _FillValue : 9.96921e+36
>
> Variable: SM
> Type: float
> Total Size: 8055936 bytes
> 2013984 values
> Number of Dimensions: 3
> Dimensions and sizes: [Time | 21] x [south_north | 333] x [west_east |
> 288]
> Coordinates:
> Number Of Attributes: 6
> FieldType : 104
> MemoryOrder : XYZ
> description : SOIL MOISTURE
> units : m3 m-3
> stagger : Z
> coordinates : XLONG XLAT XTIME
>
> Variable: SM_st
> Type: float
> Total Size: 32172 bytes
> 8043 values
> Number of Dimensions: 2
> Dimensions and sizes: [21] x [383]
> Coordinates:
> Number Of Attributes: 1
> _FillValue : 9.96921e+36
>
> I'll be thankful if I hear from you.
>
> *Sincerely*
> *Ehsan*
>
> _______________________________________________
> ncl-talk mailing list
> ncl-talk at ucar.edu
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
>
>
> --
> Barry H. Lynn, Ph.D
> Senior Associate Scientist, Lecturer,
> The Institute of the Earth Science,
> The Hebrew University of Jerusalem,
> Givat Ram, Jerusalem 91904, Israel
> Tel: 972 547 231 170
> Fax: (972)-25662581
>
> C.E.O, Weather It Is, LTD
> Weather and Climate Focus
> http://weather-it-is.com
> Jerusalem, Israel
> Local: 02 930 9525
> Cell: 054 7 231 170
> Int-IS: x972 2 930 9525
>
> _______________________________________________
> ncl-talk mailing list
> ncl-talk at ucar.edu
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
--
Barry H. Lynn, Ph.D
Senior Associate Scientist, Lecturer,
The Institute of the Earth Science,
The Hebrew University of Jerusalem,
Givat Ram, Jerusalem 91904, Israel
Tel: 972 547 231 170
Fax: (972)-25662581
C.E.O, Weather It Is, LTD
Weather and Climate Focus
http://weather-it-is.com
Jerusalem, Israel
Local: 02 930 9525
Cell: 054 7 231 170
Int-IS: x972 2 930 9525
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20190911/80a86efc/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: get_ij.f
Type: application/octet-stream
Size: 933 bytes
Desc: not available
URL: <http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20190911/80a86efc/attachment.obj>
More information about the ncl-talk
mailing list