From: weber@young.ece.cmu.edu (Dave Weber)
Newsgroups: comp.os.linux.announce
Subject: LAPACK numerical library for Linux available
Date: 29 Jan 1994 23:49:05 +0200
Approved: linux-announce@tc.cornell.edu (Lars Wirzenius)
Message-ID: <2ielkh$hsm@klaava.Helsinki.FI>


                  LAPACK Libraries for Linux
                  ==========================
 

For those that do not know, LAPACK is a library of numerical methods
for matrix manipulation. The library is very complete and is considered
to be one of the best around. If you live in a world with eigenvalues,
QR decomposition, LS, SVD etc., this is for you. 

I have compiled the LAPACK v1.1 FORTRAN libraries for Linux using
f2c and some head scratching. The distribution includes support
for all the data types (single, double, complex and zcomplex) as
well as the BLAS routines that LAPACK needs to do its stuff. These
routines are callable from C and C++ but I have not provided 
prototypes. There is a CLAPACK available but I have not ported
it yet as it is not yet up to speed with LAPACK. It is basically
a machine (f2c?) translation so matrices are still stored column
wise (yuk).

You can get the library at the following sites:

 tsx-11.mit.edu:  /pub/linux/binaries/libs/linux-lapack-1.1.tar.gz
 sunsite.unc.edu: /pub/Linux/devel/fortran/linux-lapack-1.1.tar.gz

I used f2c ( f2c-1993.04.28.tar.gz from any FSF site), gcc 2.4.5 and
Linux 0.99pl13r to do all this. There is very little reason for this
not to work on other systems with reasonably current f2c's and gcc's.
Make sure that you have a current version of the f2c library. There 
is a binary on sunsite (/pub/Linux/devel/fortran/libf2c-0.9.tar.gz).
Note that I have not tested the LAPACK library with this version of
libf2c as I compiled it myself (no pain here) so be warned. The 
library works fine with gcc 2.5.7, libc 4.5.8 and Linux 0.99pl14.

Send comments to me (Dave Weber) at weber@young.ece.cmu.edu.  Please
take a look at the file INSTALL/install.ps in the lapack distribution
(careful, it is 150 pages long) for more information. You must buy
(don't freak, its quite cheap) from SIAM. More info can be obtained from
the INSTALL/install.ps file.

The bottom line:
================

The good news: Most of the tests pass. The libraries appear to
               work fine for me.
  
The bad news: The BLAS checks out fine in the tests except the test for
              double precision complex level 2 BLAS test chokes with a 
              segmentation error. A few LAPACK tests and timings fail with
              segmentation errors and floating point exception errors.


Notes on the port:

1) I have used a script called fc (which I linked to f77) supplied with f2c
   which does a good job of emulating the f77 that FORTRAN fans are fond of.
   This had the advantage that most of the make files can be used out of
   the box. Just be aware that you need to link in the two libraries to
   support FORTRAN (-lF77 -lI77 in this order) to anything executable. You
   will also need the standard C math library (-lm) 

2) I have used the optimizer only where it was used by the developers.
   I don't know why they switched it of on one or two files but they went
   to some trouble to do it. I acted dumb and followed the leaders.

3) I did run the timings but they don't mean much because I used the FORTRAN
   BLAS in the distribution which are apparently not well optimized so 
   benchmarks will be a bit iffy. The results would also not mean much to 
   anyone who did not have a 50Mhz 486DX setup running Linux.

4) I have used a version of the  "ETIME" function called by the LAPACK 
   testing and timing routines that was supplied by David Klein. This 
   routine is supplied by f2c because it is not standard FORTRAN or
   something.

5) All the tests compile and most run fine. There are a few floating
   point exceptions and some irritating segmentation errors.

Have fun
--Dave Weber
Dept. Electrical and Computer Engineering
Carnegie Mellon University
Pittsburgh PA 15213
USA

--
Mail submissions for comp.os.linux.announce to: linux-announce@tc.cornell.edu
PLEASE remember Keywords: and a short description of the software.
