Backing up a little - Trying to get LAPACK to work... [SOLVED]

Bruce Labitt bruce.labitt at myfairpoint.net
Wed May 26 20:03:56 EDT 2010


bruce.labitt at autoliv.com wrote:
> gnhlug-discuss-bounces at mail.gnhlug.org wrote on 05/26/2010 09:10:29 AM:
>
>   
The good news is that I have zgesvd_ from the LAPACK library working.  
The bad news is I've wasted a lot of time (the list's and mine) finding 
the error.  Root cause: did not allocate enough memory for the RWORK 
array.  For some reason, a small problem worked, whereas the larger one 
would not.  In hind sight, this all makes sense.

The examples on the lapack-forum (that I copied shamelessly) for dgesvd 
and converted to zgesvd, were incomplete.  I eventually found the error 
by inspecting the FORTRAN source file, ZGESVD.f.  The C header files 
that I had used earlier, were not up to date in their documentation, and 
did not mention allocating anything for RWORK.

Now that I have the FORTRAN version of LAPACK zgesvd running, and I know 
how to call it (groan), I can move over to CLAPACK again.  I'm really 
not expecting too much trouble now since I will be a LOT more diligent 
reading the FORTRAN source, rather than relying on descriptions in 
header files.

"Read the source, Luke."
-Bruce

brace yourself for an epic on porting this lib to your favorite DSP...
as you were...



More information about the gnhlug-discuss mailing list