Is there a C interface to LAPACK routines like the one for the regular BLAS?
No, there is no such convenience available for the LAPACK routines. As LAPACK routines are Fortran-style, when calling them from C-language programs, make sure that you follow the Fortran-style calling conventions:
- Pass variables by 'address' as opposed to pass by 'value'. Refer to User Guide to get more information about this with an example
- Store your data Fortran-style, that is, in column-major rather than row-major order. With row-major order, adopted in C, the last array index changes most quickly and the first one changes most slowly when traversing the memory segment where the array is stored. With Fortran-style column-major order, the last index changes most slowly whereas the first one changes most quickly.
Is there any case sensitivity issue in calling LAPACK routines
No, LAPACK routine names can be both upper-case or lower-case, with trailing underscore or not. For example, these names are equivalent: dgetrf, DGETRF, dgetrf_, DGETRF_.
Which matrix comes first (P or Q) in making consecutive calls to SORGBR using the same matrix A in the parameter list?
When using SORGBR to extract P or Q, the original matrix holding some of the information necessary to construct P and Q is overwritten to return the P or Q requested. If both P and Q are required, the input matrix A must first be copied (to B, for example); then matrix A can be used to extract P or Q and the matrix B can be used to extract the other.