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

20011129: Computing the standard deviation



Andy,

I cannot duplicate your problem here using GEMPAK 5.6.E.1 on my SGI
with the 00Z ensemble grids on the 1x1 degree output today.
What platform combination are you using?.

Where is your "example of output" coming from? GDLIST? GDPLOT2?

Steve Chiswell



>From: "Siffert, Andy" <address@hidden>
>Organization: UCAR/Unidata
>Keywords: 200111291537.fATFbvN06225

>
>Steve
>I Think?
>
>I'm not sure how large or small my problem is. However, I hope I made my
>problem clear below.
>What I'm trying to do in gempak is take the square of small number and store
>it in a .gem file using GDDIAG. 
>
>What I'm trying to do is compute the standard deviation in 2 m temperature
>from the MRF ensembles 
>
>here is the part of interest.
>
>#converts member to degrees F
>gddiag<<EOF
>GDFILE   = /home/met-user/andy/$file
>GDOUTF   = /home/met-user/andy/$file
>GFUNC    = add(mul(sub(TMPKC001,273),1.8),32)))
>GDATTIM  = $YY$MM$DD/${cycle}00F$zero$fff
>GLEVEL   = 2
>GVCORD   = hght
>GRDNAM  = a
>GPACK    = 
>run
>
>EOF
>
>#Subtract avg from a member of the ensembles
>gddiag<<EOF
>GDFILE   = /home/met-user/andy/$file
>GDOUTF   = /home/met-user/andy/$file
>GFUNC    = sub(avg,a)
>GDATTIM  = $YY$MM$DD/${cycle}00F$zero$fff
>GLEVEL   = 2
>GVCORD   = hght
>GRDNAM   = b
>GPACK    =
>run
>
>EOF
>
>gddiag<<EOF
>GDFILE   = /home/met-user/andy/$file
>GDOUTF   = /home/met-user/andy/$file
>GFUNC    = expi(b,2)
>GDATTIM  = $YY$MM$DD/${cycle}00F$zero$fff
>GLEVEL   = 2
>GVCORD   = hght
>GRDNAM   = c
>GPACK    =
>run
>
>EOF
>
>This is where the problem is: I want to take the square of b (b^2).
>The output is wrong. 
>
>I have even try doing
>    GFUNC = mul (b,b) 
>which should be the same as b^2?
>If I use 
>   GFUNC = EXP(b,2)  
>I get -9999 or the wrong answer also.
>
>Example of output
>  Avg -  a     =    b^2  =    c       The output I recive from C in gempak
>43.31-42.82 = .49 ^2 = .2401      .27
>53.56-53.54 = .02 ^2 = .0004      -9999
>
>Thanks for your help.
>Andy 
>
>
>
>****************************************
>               Andy Siffert                  
>        Aquila Weather Desk           
>     Research and Development     
>  1100 Walnut Street, Suite 3300  
>      Kansas City, MO 64106         
>             816-527-1247                 
>          Fax: 816-527-4247            
>****************************************
>