Open jacobwilliams opened 2 years ago
I'd be happy to contribute this fix. Biggest obstacle I see is that fpm doesn't yet have first class LAPACK or BLAS support (see https://github.com/fortran-lang/fpm/issues/368).
Upon further inspection, the reference version of DGTSV
only makes call to the external routine XERBLA
for error reports. So you could probably just add it to this repository and forget about linking with linpack/lapack.
If you know the tridiagonal system is diagonally dominant, we could also just replace it with an implementation of the Thomas algorithm without pivoting.
Maybe there could be options, depend on some preprocessor flags?
dgtsv
procedure we add to the module (with refactoring)I can see that as a temporary solution until fpm has native support for locating if lapack is installed and what is the name of the library.
Consider replacing linpack
DGTSL
with lapackDGTSV
. This was done in the SciPy version. See: https://github.com/scipy/scipy/commit/361468a6b08e731936d761f5130799fca962acaf#diff-3bc2ad4ff04dcd0fd46bde7b0a273a6b453177a8494cbc77f08009db5cb8ad93