[Thread Prev][Thread Next][Index]

[ferret_users] Changed behaviour in regridding one point axes

I am trying to regrid a variable defined at a single point with two dimensions. From one file I read a 2d-field "wet" that is 1 at ocean points and 0 otherwise.
I define a new grid (for short notation)

define grid/like=wet[d=1] rgrid

Read the river data
use "with_coordinates/angola.nc"

rivers data are time series with a single latitude and longitude coordinate and a time axis

let runoff= RIVER_BENGO[gx=rgrid@sum,gy=rgrid@sum]

I would expect, that ferret searches, in which grid cell the river is and sets runoff to the data value.
Otherwise runoff should be zero.

This does not work, the river appears to be spread over an area. The sum over all grid
points is the correct data value.

I was playing around with the examples in the manual. For example:

yes? define axis/x=163e/npoints=1 x1pt
yes? let var_1pt = randu(x[gx=x1pt]) ! a random value at a single coordinate
yes? list var_1pt
            VARIABLE : RANDU(X[GX=X1PT])
            LONGITUDE: 163E
yes? define axis/x=161e:165e:1 x5pt
yes? list var_1pt[gx=x5pt@max] ! same value embedded within 5 point axis
            VARIABLE : RANDU(X[GX=X1PT])
                       regrid: 1 deg on X@MAX
            SUBSET   : 5 points (LONGITUDE)
161E   / 1:     ....
162E   / 2:     ....
163E   / 3:  0.04804
164E   / 4:     ....
165E   / 5:     ....

This differes from the example in the manual and is wrong. The number should be .4914. I am using ferret 6.03. An old version (5.41 for AIX gives the correct result,
but does not work too for the river example. 5.7 and 5.8 are wrong too.

What I am doing wrong with the river example?
Seems there is a bug in ferret 6. Version 6.01 gives the same result.


[Thread Prev][Thread Next][Index]

Contact Us
Dept of Commerce / NOAA / OAR / PMEL / TMAP

Privacy Policy | Disclaimer | Accessibility Statement