[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

20030103: Composing GFUNC with WND and inline conditions



Patrick,

Scott Jacobs answered your question to the gembud email list and
you (according to the email header). I have pasted in his explanation
below. Since you are using the inline conditions, you
need to compose the vector from the components uwnd and vwnd (urel, vrel).
This is because when you specify wnd@850%pres+2, you are stateing that you are
using the grid wnd from grid file 2 at 850mb. But, this doesn't exist.
An alternative to Scott's solution is to rearrange your GFUNC, GVCORD,
GLEVEL and GDFILE specifications so that GLEVEL=850, GVCORD=pres,
then you can use "wnd" without the inline modifiers, and then
go ahead and specify the surface @0%none+2 modifiers to Ts and Tds etc.
Both are OK.

Steve Chiswell



-------------------------------------------------------------------
Patrick,

There is a character limit for GEMPAK input parameters, but you are well within
that limit of 128 characters.

The problem is that the parameter WND is not stored in the grid file. If you
have the components UWND and VWND, then replace

knts[mag[wnd@850%pres+2]]

with

knts[mag[vecr[uwnd@850%pres+2,vwnd@850%pres+2]]]

The automatic calculation of WND will not work with the in-line conditions such
as level and vertical coordinate. However, the above change will get the
components from the file at the specified level, and create a vector from those
components.

Hope this works out,

Scott


On Tue, 7 Jan 2003, Patrick O'Reilly wrote:

> Steve,
>
> Since I have your attention, I wrote a few days back to the gembud list
> about a calculation I am doing, and having no success with.  The text of the
> original e-mail follows:
>
> I am calculating a parameter using GFUNC and am having a bit of trouble, all
> I can think of right off is that maybe the GEMPAK equation is too long and
> is being truncated....though I don't remember off hand if there is a maximum
> length for a GFUNC.  What I have is 79 characters long  (brace yourself):
>
> GFUNC =
> add[sub[mul[4,tmpc],mul[2,add[tmpc@850%pres+2,dwpc]]],knts[mag[wnd@850%pres+
> 2]]]
>
> I am using 2 grid files (hence the +2's).  When I run using this I get:
>
>  GEMPAK-GDPLOT>r
>  [DG -7]  Input grid WND ^030103/1200F024 @850 %PRES in MAG cannot be found.
>  [GDPLOT 2]  The requested scalar/vector cannot be computed.
>
> Aah, but when I chop off the end and run alone:
>
> knts[mag[wnd@850%pres+2]]
>
> I get a contoured plot that verifies.  Anyone think why I can't get it to
> plot in the long version, or see syntax errors in my equation?  The original
> equation is:
>
> FSI = 4 * Ts - 2 * ( T850 + Tds ) + W850
>
> where Ts is surface temp, T850 is 850mb temp in C, Tds is surface dewpoint,
> W850 is magnitude of 850 wind in knots. Any glimmers of hope would be
> appreciated.
>
> The strange part is that I can chop the equation in two, and get plots, but
> when I try to add the first part with W850, I get that it cannot be
> computed.  I have tried many things to get this plot, do you have any wisdom
> that could help?
>
> Thanks!
>
> Patrick
>
> ----- Original Message -----
> From: "Steve Chiswell" <address@hidden>
> To: "Patrick O'Reilly" <address@hidden>
> Cc: <address@hidden>; <address@hidden>
> Sent: Friday, January 03, 2003 4:57 PM
> Subject: 20030103: GEMPAK: plotting forecast visibilities
>
>
> > Patrick,
> >
> > The RUC2 grids on the Unidata IDD (HRS feed of NOAAPORT, grid 236)
> > provide VSBY (in meters) on gvcord=none, glevel=0. Use gdinfo
> > to see what grids are in your grid files.
> >
> > If you are running the dcnmos decoder for NGM, you will see
> > FVIS as one of the parameters (use SFPARM=dset in SFLIST to
> > see all parameters being decoder, or the packing file
> > $GEMTBL/pack/ngmmos.pack) for sfgram.
> >
> > Steve Chiswell
> >
> > On Fri, 3 Jan 2003, Patrick O'Reilly wrote:
> >
> > > Has anyone had a try at this?  I would like to plot visibility as either
> a
> > > plan view contoured plot or even as a forecast meteogram.  The only
> place I
> > > know I have visibility information is in the MOS files, but I see
> forecast
> > > meteograms on the web plotting visibility using NGM and Eta.  I can find
> > > VSBK/VSBY in SFPARM, but cannot find any visibility parameter either in
> the
> > > grids or as a GEMPAK parameter for grid data.  Thanks for any direction
> you
> > > may be able to point me in.
> > >
> > > Patrick
> > > _______________________________________
> > > Patrick O'Reilly
> > > Meteorological Decision Support Scientist
> > > The STORM Project - University of Northern Iowa
> > > address@hidden  ~  ph: 319-273-3789
> > > http://www.uni.edu/storm
> > >
> >
>