[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: a plea for more reliable mathematical routines
On Tue, 14 Sep 1999, Theo Brauers wrote:
> Liam Gumley wrote:
> > Richard G. French <firstname.lastname@example.org> wrote in message
> > 37D82EA9.BA62A369@wellesley.edu">news:37D82EA9.BA62A369@wellesley.edu...
> > > I have the same uneasiness about the implementation of mathematics
> > > routines in IDL, having [previous bad experiences ...]
> > I believe there is a market for either an add-on Mathematical Toolbox, or
> > preferably built-in access to a selection of routines from a well-respected
> > mathematical library like BLAS, LAPACK, CMLIB, NAG etc. For example, NAG
> > developed an add-on library for Matlab:
> > http://www.nag.co.uk/nagware/NN.html
> > I think many people would be more than willing to either upgrade their IDL
> > version, or buy an add-on toolbox, if it gave them access to a set of
> > high-quality numerical routines. A user survey would no doubt tell RSI very
> > quickly which routines people would like to see (Bessel functions and random
> > numbers have been mentioned).
> > Cheers,
> > Liam.
> > http://cimss.ssec.wisc.edu/~gumley/
Add-ons are one thing, but first the basic math functions should be
implemented properly. It is interesting to read Cleve Moler's comments
See Appendix 3 of the June 7th, 1999 "Recent Progress of the Java Grande
Numerics Working Group". Moler notes that although the Java specification
calls for numeric functions that agree with Sun's "freely distributable
math library" (FDLIBM), in fact both Sun and Microsoft use the Microsoft
Visual C++ numerical library in their Java implementations for Win32. A
"The exponential, sine, and cosine functions from Microsoft's math
library are so innaccurate for large arguments that the library is
unsuitable for general-purpose use."
Matlab uses FDLIBM to help insure the same results on all platforms.
What does IDL use?
> In our group we do rely on a number of the built-in math routines of
> IDL and I would really appreciate if this group could assemble a
> warning list of bugs in the math routines of IDL. IMO most of the IDL
> user/programmers do simple checks for the correctness of their code
> but they might never check the math routines in detail.
> I would also prefer to have access to a full set of IMSL or NAG or ...
If performance is not an issue, numerical routines can be
implemented in IDL. Thus I assume that the interest in libraries
is largely driven by problems where performance is a major issue.
I don't know the current state of IMSL or NAG. A few years ago, the
Slatec libraries (available on Netlib, and provided by some vendors,
e.g., SGI at no cost). The Slatec libraries weren't written for
current hardware (where CPU speed has outrun memory speed and the
IEEE f.p. std. is supported in the hardware), so it makes some sense
that SGI now provides their own library, but many functions we use
are missing from the SGI library. It appears that a) hardware
becomes obsolete in the time it would take to implement a high quality
numerical library and b) the "market" doesn't support a big effort
to develop scientific libraries on the part of vendors.
Users of packages like IDL need to adopt a skeptical view of the
numerical routines and be aware of the situations where widely used
libraries (such as MS Visual C++) don't work properly. Numerical
analysts have a great tradition of making high quality code freely
available, but they don't advertise!
George White <email@example.com> tel: 902.426.8509
Bedford Inst. of Oceanography, Nova Scotia, Canada.