[Thread Prev][Thread Next][Index]

Re: Derivatives



Hi everyone,
passing on an answer to this query which was answered off-line,
but a useful bit of information for the Users Group.

Did you use proper units in your grid definition? In the
following simple example @ddc seems to work as expected.

def axis/x=0:360:1/units=degrees_east xax
def axis/y=-90:90:1/units=degrees_north yax
def grid/x=xax/y=yax grd
let v=x[g=grd]+y[g=grd]
list/x=179:181/y=44:46 v
             X[G=GRD]+Y[G=GRD]
               179E    180E  179W
               180    181    182
 46N   / 137:  225.0  226.0  227.0
 45N   / 136:  224.0  225.0  226.0
 44N   / 135:  223.0  224.0  225.0

list/x=180/y=45 v[x=@ddc],v[y=@ddc]
             LONGITUDE: 180E
             LATITUDE: 45N
 Column  1: V[X=@DDC] is X[G=GRD]+Y[G=GRD]
 Column  2: V[Y=@DDC] is X[G=GRD]+Y[G=GRD]
                 V          V
I / *:    1.272E-05  8.993E-06
The ratio of v[y=@ddc]/v[x=@ddc] is cosine 45 as expected.  The units
of the derivatives are "per meter".

On the other hand without the appropriate units in the grid definition
you would get the flat earth values.

def axis/x=0:360:1 xax ; def axis/y=-90:90:1 yax
def grid/x=xax/y=yax grd
list/x=180/y=45 v[x=@ddc],v[y=@ddc]
...
I / *:    1.000  1.000

Mick Spillane


-----------------------------------------------------------
 Steve Cocks wrote:

Hello,

I am having a hard time understanding how Ferret calculates the center
difference (@ddc) derivatives for data with lat/lon grids.  For example,
as a test I created a solid body wind field cdf file for ferret to
ingest (solid body w.r.t a spherical earth).  I then hand caluclated
vertical vorticity at 20s to ensure the field was truly solid body  by
using the centered diff formula for spherical coordinates:

-1/[r*cos(v)*[U(v-1)*cos(v-1)-U(v+1)*cos(v+1)]/[(v-1)-(v+1)]

where r is the radius of the earth

v is the latitude of angle, in this case 20s (except converted to
radians via pi/180)

U(v-1) is the zonal velocity at the v-1, or 19s latitude etc.

This matched the answer given by theory: f=2*omega*sin(v)

When I ingest the data into ferret, I get constant vorticity at each
latitude line which is expected.  However, it appears Ferret leaves off
the cos factors on the zonal velocity.  Why does ferret do this?  Does
it depend on how you display the fields onto a background map, ie if use
a curvi-linear display of data it will add the cosines in but if in a
"map flat" display" it won't??  Would greatly appreciate any comments on
this problem (hopefully, you understand what I am even talking about).


Scocks
Texas A&M University



--
Ansley Manke  Pacific Marine Environmental Laboratory  Seattle WA  (206)526-6246




[Thread Prev][Thread Next][Index]

Dept of Commerce / NOAA / OAR / PMEL / TMAP

Contact Us | Privacy Policy | Disclaimer | Accessibility Statement