[gradsusr] prolems with nested global area using const and atot

Andrew Friedman andfried at berkeley.edu
Sat Oct 12 00:03:53 EDT 2013


Oops, forgot to attach the file. Here it is
-------------- next part --------------
A non-text attachment was scrubbed...
Name: sst_timeslice.nc
Type: application/octet-stream
Size: 12760 bytes
Desc: not available
Url : http://gradsusr.org/pipermail/gradsusr/attachments/20131011/0990d1cd/attachment-0001.obj 
-------------- next part --------------



On Oct 11, 2013, at 9:02 PM, Andrew Friedman <andfried at berkeley.edu> wrote:

> Hi GrADS users,
> 
> I'm getting different answers in a global area calculation combining const with atot after setting x-values. This difference seems to depend on whether I do the calculation in 1 or 2 steps.
> 
> Following example 1 from atot (http://www.iges.org/grads/gadoc/gradfuncatot.html),
> I have a SST dataset (attached) with longitude dimensions of -180 to 180.
> 
> METHOD 1: one-step calculation
> ga-> sdfopen sst_timeslice.nc
> ga-> set lon -180 180
> ga-> d atot(const(sst,1,-a),g)
> Result value = 12.5664
> 
> METHOD 2: 2-step caclulation
> ga-> sdfopen sst_timeslice.nc
> ga-> set lon -180 180
> ga-> sst1=const(sst,1,-a)
> ga-> d atot(sst1,g)
> Result value = 6.45772
> 
> Can anyone explain what is going on? Is this the intended behavior?
> 
> Thanks,
> Andrew
> 
> ---------------------------------------------------------------------
> Andrew Friedman
> Graduate student, UC Berkeley Geography
> andfried at berkeley.edu



More information about the gradsusr mailing list