[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
20030613: Grid definition? query in GEMPAK
- Subject: 20030613: Grid definition? query in GEMPAK
- Date: Fri, 13 Jun 2003 13:22:36 -0600
John,
Your problem lies in your syntax. To produce the magnitude
of the wind as you wrote:
sqrt(avn_urel**2+avn_vrel**2)
The GEMPAK syntax would be:
sqrt(sum(mul(avn_urel,avn_urel),mul(avn_vrel,avn_vrel)))
Luckily, this is more easily done by taking the magnitude
of the constituted vector from avn_urel and avn_vrel:
mag(vecr(avn_urel,avn_vrel))
Steve Chiswell
>From: John Merrill <address@hidden>
>Organization: UCAR/Unidata
>Keywords: 200306131814.h5DIEbLd001292
>This is a multi-part message in MIME format.
>--------------030700040704020404080503
>Content-Type: text/plain; charset=us-ascii; format=flowed
>Content-Transfer-Encoding: 7bit
>
>Hello,
> I'm using .gem files prepared from the Reanlaysis CD-ROM, monthly
>average fields. The variable names differ from
>the usual ones, of course, but I encounter a difficulty in calculating
>even a simple scalar. At glevel=200 I want to plot
>iostachs; the components of the wind here are avn_urel, avn_vrel (avn
>for 'average,' I suppose). I tried to compute a new
>quantity by setting gfunc=sqrt(avn_urel**2+avn_vrel**2)//avn_s, was
>dismayed to get the response that "requested grid
>avn_urel**2 in (specifications) cannot be found"; then, of course "The
>requested scalar/vector cannot be computed." You'd
>be correct assuming I've not defined/computed grids previously....
>Thanks. John
>
>--------------030700040704020404080503
>Content-Type: text/plain; x-mac-type="0"; x-mac-creator="0";
> name="200ZSrestore"
>Content-Transfer-Encoding: 7bit
>Content-Disposition: inline;
> filename="200ZSrestore"
>
>!
>! Restore File : 200 Height and Isotachs
>!
>! Log:
>! J. Merrill 7/02 Initial creation as 500_msl composite
>! J. Merrill 6/32 Revise for height/isotach only
>!
>garea 20;85;60;150
>LATLON 8/2/2//15;15
>MAP 8/1/2
>GVCORD= pres !pres
>GLEVEL 200 !200
>SKIP 0 !0
>SCALE -1 !0
>gfunc avn_urel//urel !avn_vrel//vrel
>gfunc hght !sped
>TYPE c !c
>CONTUR 2/2 !2/2
>CINT 6 !10
>LINE 32/1/3 !32/2/2
>TITLE 32/-1/~ 200 hPa Height and Isotachs, April 2001 Mean
>TEXT 2/1/3/sw
>border //3
>CLEAR yes
>
>--------------030700040704020404080503--
>