>I am a ferret user, but I just started using NCL from today because
>I need to compute the velocity potential from the monthly ncep
>reanalysis. I just did that using "wind_4.ncl" (which can be
>downloaded from the ncl webpage). The wind_4.ncl script uses
>the follwing four ncl routines:
>
>uv2dvG(u,v) for divergence
>ilapsG(div,0) for velocity potential
>dv2uvg(div,ud,vd) divergent wind
>
>But, the computed velocity potential is very different from that
>provided from CDC (velocity potential is included if you download
>ncep reanalysis from CDC). Furthermore, the divergent wind is not
>perpendicular to the velocity potential.
>
>Does it mean that the velocity potential computaion using NCL
>is not reliable? Or am I doing something wrong? Only modification
>I made to wind_4.ncl is the file reading statement (I am reading
>grib data).
The example you refer to is just that... an example.
The example was for data on a gaussian grid. I don't think you
want to use functions for gaussian grids on data that
are not gaussian :-)
[1] GRIB data from NCEP or ECMWF is typically ordered
North-to-South. NCL's spherical harmonic routines
require that the data be ordered from South-to-North.
Note the documentation for the functions variables u/v
stares that " input values must be in ascending latitude order"
^^^^^^^^^^^^^^^^^^^^^^^^
http://ngwww.ucar.edu/ngdoc/ng/ref/ncl/functions/uv2dvF.html
This can readily be accomplished via NCL's array syntax [like f90].
Consider: u(lat,lon) and v(lat,lon) ordered N->S
u = u(::-1,:) ; reorder the latitudes
v = v(::-1,:)
printVarSummary(u) ; verify that the latitudes are S->N
[2] The functions the example [and you] are using are for
data on a Gaussian grid.
Most [all?] ranalysis data are on 2.5 degree grids. In NCL
parlance, this means a "Fixed" grid.
Thus, you want to use functions appropriate for a "Fixed" grid
not a Gaussian grid.
div = uv2dvF(u,v) ; divergence
chi = ilapsF(div , 0) ; inverse laplacian ==> vel. potential
dv2uvf(div,ud,vd) ; div ==> divergent wind components
[3] Also, for plotting, the use of
res@vcGlyphStyle = "CurlyVector" ; turn on curly vectors
may not be the best choice here. Just comment it out (using ;)
to get classic straight vectors.
====
good luck
_______________________________________________
ncl-talk mailing list
ncl-talk AT ucar.edu
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
This archive was generated by hypermail 2b29 : Thu Apr 22 2004 - 07:40:12 MDT