numerical math with functional languages?

Quote:

>Subject: numerical math with functional languages?

>Date: Tue, 13 Aug 1996 09:20:01 -0500

>I know close to nothing about functional languages. Are they suited to

>numerical math? If so, which language has the most extensive set of

>numerical routines stored in an ftp or http site? By numerical math I am

>thinking of things like random number generation (uniform, normal),

>nonlinear optimization (e.g. BFGS quasi-Newton with numerical

>derivatives), matrix inversion (in doing maximum likelihood estimation,

>after using BFGS, need to do sqrt(diagonal(invert(-hessian))), statistical

>stuff like cumulative density functions and inverse cumulative density

>functions for various distributions.

Whew! This is a lot of question, and I'm sure you're going to get a lot of

answer. Let me try.

First, yes, definitely, runctional languages are well suited to any kind

of math. APL has all sorts of built-in math capabilities, mostly linear

algebra, as far as I know. Its performance is not high, due to its being

an interpreted rather than compiled language. Most functional languages

lend themselves well to the expression of numerical programs. I've had

numerous comments from mathematicians about how easy it is to program

such stuff in Sisal. We've done lots of math and phycics related work

in it, although more whole applications than libraries. It started out

as a parallel language, but we soon found out that it's good for quickly

coding up efficient, readable, sequential code, as well. We've done

numerous applications, a lot of FFT work, a parallel random number

generator, and somebody did a Gaussian Elimination system solver, but

I don't know about the other stuff you mention. This is certainly the

right place to ask about it.

Rather than give you a whole pitch for Sisal, here, why don't you check

out the Sisal web pages, at http://www.llnl.gov/sisal and maybe the

on-line tutorial that's anchored there? You'll soon see whether this

language is what you want.

Quote:

>Is there a functional language equivalent to netlib (which mostly has

>FORTRAN and some C and C++ code)?

I don't know netlib, but Sisal does allow interfacing Sisal with C

and Fortran. This is a sensible way to parallelize existing codes, namely

pick the parts where the parallelism exists, and recode them, leaving

the other stuff in the original language. It's also a good way to use

sequential solvers and kernels in parallel programs, by calling them

in parallel.

Quote:

>If one wants to use other people's code, it helps to use a popular

>language. Which functional language would be most popular for numerical

>math?

Well, I've already said what my favorite is, and we've published several

papers with mathematicians and other scientific types. Check it out,

and see for yourself.

Quote:

>Thanks for any help.

You're welcome.

Quote:

>Bill Simpson

Tom DeBoni

PS I forgot to mention, Sisal's free, it runs under Unix, and you can

get and install it pretty easily on most any uniprocessor or shared-

memory multiprocessor system. Pointers to the ftp site are in the web

pages.