[Thread Prev][Thread Next][Index]

Re: [ferret_users] after scat2gridlaplace some values are obsolote (data origins of lambert grid)



Hi Ansley and Others,
i succeeded in producing a rectilinear grid with the following (corrected) script using CURV_TO_RECT and SCAT2GRIDGAUSS_XY. Variables precip1 and precip2 should be the same. If we look closer, we can find (not that) slight difference between these two. If i compare them it seems to me that these differences are in connection with the surface.
Curv_to_rect somehow makes the "picture" more rounded, not that sharp and not that extreme.
Can it be because of the last argument of the "curv_to_rect_map ( lons,lats,lonlatout,0.5)"?

Which method should i use to get the correct values (as they look pretty the same though there is a small difference) ?

Thank You.

-------script starts here
def axis/x=11.78:25.22/np=97 xx
def axis/y=44.63:50.20/np=61 yy
def grid/x=xx/y=yy latlon
SET DATA/EZ/VARIABLES="lon   lat"/grid=latlon "ASCII_koord"
let lons=lon[d=1]
let lats=lat[d=1]
def axis/t="1-JAN-1961 12:00":"31-DEC-1990 12:00":1/t0="31-DEC-1960 12:00"/units=days time
def grid/t=time/x=lons/y=lats gridxyt
SET DATA/EZ/VARIABLES="prec"/grid=gridxyt "predaily.txt"

!Here is use the CURV_TO_RECT function

def axis/x=12.5:24.6:0.1/modulo/units=degrees xax
def axis/y=44.9:49.9:0.1/units=degrees yax
let lonlatout = y[gy=yax] + x[gx=xax]
let map = curv_to_rect_map ( lons,lats,lonlatout,0.5)
let precip1 = curv_to_rect(prec[d=2], map)

!Now, i create this variable in an other way using the SCAT2GRIDGAUSS_XY function

let xx1D = XSEQUENCE(lons)
let yy1D = XSEQUENCE(lats)
def axis/x=12.5:24.6:0.1 xax
def axis/y=44.9:49.9:0.1 yax
let precip2=scat2gridgauss_xy(xx1d,yy1d,prec[d=2],x[gx=xax],y[gy=yax],0.01,0.01,10,0)
---------script ends here

On Wed, Feb 25, 2009 at 12:02 PM, Peter Szabo <szabpet83@xxxxxxxxx> wrote:
Dear Ansley and Edward,

I tried using SCAT2GRIDLAPLACE_XY with 5-5 for the last two arguments (instead of 100-100), but the results were almost the same (negative values still appeared among precipitation values).
I also tried using 0 for CAY (=Laplacian interpolation is used) and 5 (the default) for NRNG arguments, but the results got worse (see attached AA.0caymin.gif).

As for the CURVE_TO_RECT function: the results made with the below commands were not satisfying. I dont have a clue what is wrong with this.

SET DATA/EZ/VARIABLES="lon,lat" "ASCII_koord.txt"
let lons=lon[d=1]
let lats=lat[d=1]
def axis/t="1-JAN-1961 12:00":"31-DEC-1990 12:00":1/t0="31-DEC-1960 12:00"/units=days time
def grid/t=time/x=xlon/y=ylat gridxyt

SET DATA/EZ/VARIABLES="precip"/grid=gridxyt "predaily.txt"

def axis/x=12.42:24.6/np=97/modulo xax
def axis/y=44.9:49.92/np=61 yax
let lonlatout = y[gy=yax] + x[gx=xax]
let map = curv_to_rect_map ( lons,lats,lonlatout,0.5)
let pre = curv_to_rect(precip[d=2], map)

So i might use the GAUSSian grid-changing function to have my lambert (curvilinear) data on lat-lon, rectilinear grid.

Peter


On Tue, Feb 24, 2009 at 11:54 PM, E. D. (Ned) Cokelet <Edward.D.Cokelet@xxxxxxxx> wrote:
FYI, mathematically if a function satisfies Laplace's equation: del-squared F = 0, then its maxima and minima must lie on the boundary of its domain and nowhere else.  It is like a rubber sheet stretched over a drumhead with highs and lows on the rim of the drumhead.  The rubber sheet will conform to the boundary and values out in the domain will be an average of (and always less extreme than) those on the edge.  So if the Ferret Laplacian gridding is working correctly, this property must hold (within numerical rounding error and loss of significant figures).  

------------------------------------------------------------------------------------------
Edward D. (Ned) Cokelet, Ph.D. Oceanographer
NOAA/PMEL                         off:  (206) 526-6820
7600 Sand Point Way NE     fax: (206) 526-6485
Seattle, WA 98115-6349


The contents of this message are mine personally and do not necessarily reflect any position of the Government or the National Oceanic and Atmospheric Administration.





[Thread Prev][Thread Next][Index]

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

Privacy Policy | Disclaimer | Accessibility Statement