[gradsusr] grads2.1.a1 bug?
Jennifer Adams
jma at cola.iges.org
Tue Nov 25 10:48:01 EST 2014
Yes, I know there are still some lingering precision issues. I have been accumulating emails and examples of things that don’t work quite right. The delay in fixing them all is because other things with a higher priority keep nudging this off the top of my to-do list, and some dedicated learning is required on my part to make sure I understand the underlying computer science well enough. There are a lot of places in the GrADS code where fuzzy tests of equality or smallness are in place, some more obvious than others, and tracking them all down and making them consistent is turning out to take more time than I thought.
—Jennifer
On Nov 25, 2014, at 10:28 AM, Semyon Grodsky <senya at atmos.umd.edu> wrote:
> Doug,
> thanks for coming back on that.
>
> I found that replacing 1/1e-8 by pow(1e-8,-1) gives correct result. But,
> I am a bit surprised that developers still keep silence.
> Best,
> --Senya
>
> On 11/25/2014 4:22 AM, Clark, Douglas B. wrote:
>> Semyon,
>>
>> I think you are getting the missing (undefined) data value of -9.99e+08 and I assume that GrADS is avoiding dividing by a small number that could potentially cause the result to overflow. But 1e-8 is a rather conservative choice for a threshold beyond which the calculation is aborted.
>>
>> I think GrADS started behaving in this more conservative way sometime around v2.0 (roughly). I have got used to scaling any expressions with small divisors, e.g. scaling your example by 1e6 gives:
>>
>> ga-> d 1e6/(1e-8*1e6)
>> Result value = 1e+08
>>
>> Unless there's a good reason for the relatively high threshold perhaps we can persuade the developers to use a smaller value in future....?
>>
>> Doug
>>
>> -----Original Message-----
>> From: Semyon Grodsky [mailto:senya at atmos.umd.edu]
>> Sent: 24 November 2014 18:49
>> To: GrADS Users Forum
>> Subject: [gradsusr] grads2.1.a1 bug?
>>
>> Dear colleagues,
>> it seems that GRADS2.1.a1 has a bug related to small values, which is illustrated below
>> ga-> d 1/1e-6
>> Result value = 1e+06
>> ga-> d 1/1e-7
>> Result value = 1e+07
>> ga-> d 1/1e-8
>> Result value = -9.99e+08
>>
>> Any idea what might be causing that?
>> Thanks,
>> --Senya
>> ---------------------------------------
>> ga-> q config
>> Config: v2.1.a1 little-endian readline grib2 netcdf hdf4-sds hdf5 opendap-grids,stn geotiff shapefile cairo Grid Analysis and Display System (GrADS) Version 2.1.a1 Copyright (c) 1988-2013 by the Institute for Global Environment and Society (IGES) This program is distributed WITHOUT ANY WARRANTY See file COPYRIGHT for more information.
>>
>> Built Sun Dec 15 10:03:18 EST 2013 for x86_64-unknown-linux-gnu
>>
>> This version of GrADS has been configured with the following options:
>> o Built on a LITTLE ENDIAN machine
>> o Athena Widget GUI DISABLED
>> o Command line editing ENABLED
>> http://tiswww.case.edu/php/chet/readline/rltop.html
>> o GRIB2 interface ENABLED
>> http://www.ijg.org
>> http://www.ece.uvic.ca/~mdadams/jasper
>> http://www.nco.ncep.noaa.gov/pmb/codes/GRIB2
>> g2clib-1.4.0
>> o NetCDF interface ENABLED
>> http://www.unidata.ucar.edu/software/netcdf
>> netcdf 4.2.1.1 of Nov 15 2013 08:44:30 $
>> o OPeNDAP gridded data interface ENABLED
>> o OPeNDAP station data interface ENABLED
>> http://iges.org/grads/gadoc/supplibs.html
>> libgadap 2.0
>> o HDF4 and HDF5 interfaces ENABLED
>> http://hdfgroup.org
>> HDF 4.2r3
>> HDF5 1.8.11
>> o GeoTIFF and KML/TIFF output ENABLED
>> http://www.libtiff.org
>> http://geotiff.osgeo.org
>> o KML contour output ENABLED
>> o Shapefile interface ENABLED
>> http://shapelib.maptools.org
>> o Cairo graphics interface ENABLED
>> http://cairographics.org
>> http://cgit.freedesktop.org/pixman
>> http://www.freetype.org/index2.html
>> http://www.freedesktop.org/wiki/Software/fontconfig
>> Cairo 1.12.16
>> Pixman 0.28.0
>> Freetype 2.4.10
>> Fontconfig 2.9.0
>>
>> For additional information please consult http://iges.org/grads
>>
>>
>> -----------------------------------------------------------
>> Semyon Grodsky
>> Computer and Space Science Building (Bldg. #224), Room 2409 Department of Atmospheric and Oceanic Science University of Maryland College Park, MD 20742
>>
>> Phone: 301-405-5330
>> Fax: 301-314-9482
>> E-mail: senya at atmos.umd.edu
>> _______________________________________________
>> gradsusr mailing list
>> gradsusr at gradsusr.org
>> http://gradsusr.org/mailman/listinfo/gradsusr
>> ________________________________
>> This message (and any attachments) is for the recipient only. NERC is subject to the Freedom of Information Act 2000 and the contents of this email and any reply you make may be disclosed by NERC unless it is exempt from release under the Act. Any material supplied to NERC may be stored in an electronic records management system.
>> ________________________________
>>
>> _______________________________________________
>> gradsusr mailing list
>> gradsusr at gradsusr.org
>> http://gradsusr.org/mailman/listinfo/gradsusr
>
> --
> -----------------------------------------------------------
> Semyon Grodsky
> Computer and Space Science Building (Bldg. #224), Room 2409
> Department of Atmospheric and Oceanic Science
> University of Maryland
> College Park, MD 20742
>
> Phone: 301-405-5330
> Fax: 301-314-9482
> E-mail: senya at atmos.umd.edu
>
> _______________________________________________
> gradsusr mailing list
> gradsusr at gradsusr.org
> http://gradsusr.org/mailman/listinfo/gradsusr
--
Jennifer M. Adams
Center for Ocean-Land-Atmosphere Studies (COLA)
111 Research Hall, Mail Stop 2B3
George Mason University
4400 University Drive
Fairfax, VA 22030
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20141125/26003719/attachment-0001.html
More information about the gradsusr
mailing list