Re: Another GFUNC Question

Jeremy,

You can use one or more of the logical functions that I mentioned last time: LT, LE, GT, or GE. The GEMPAK functions can get long and look cumbersome even for a relatively simple looking mathematical formula. You may even have to break up the formula if it gets too long (80 characters I believe). But this is something we have to live with in GEMPAK.

LT (S1,S2) Returns 1 if S1 < S2; otherwise 0
LE (S1,S2) Returns 1 if S1 <= S2; otherwise 0
GT (S1,S2) Returns 1 if S1 > S2; otherwise 0
GE (S1,S2) Returns 1 if S1 >= S2; otherwise 0

Kwan

On Tue, 17 Oct 2006 18:11:56 +0100
 Jeremy.Martin@xxxxxxxx wrote:
List,

Sorry to keep bothering everyone with these minor questions. I am practicing with creating grids with gddiag and I have ran into a problem. I saw an example for calculating the Showalter Index and I managed to get all the compnents calculated correctly. However...the example I saw said you could use one value if the lcl press was less than 500 mb and another if the lcl pressure is less than 500mb (moist lapse rate versus dry lapse rate). Anyway...how do you tell GFUNC to use one parameter if certain condition is met...but use another if it is not. Do IF/THEN/ELSE statements work or is there another function that needs to be called.

Thanks for any help,

Jeremy Martin
WFO GLD





  • 2006 messages navigation, sorted by:
    1. Thread
    2. Subject
    3. Author
    4. Date
    5. ↑ Table Of Contents
  • Search the gembud archives: