Are there any quad-double arithmetic sparse matrix package?

I am working on some ill-conditioned large sparse linear system of equations. I want to use double-double arithmetic or quad-double arithmetic to solve them. I know that there is a package named MPACK developed by Nakata, Maho, which can perform numerical linear algebraic computations under quad-double arithmetic. However, it is designed for dense matrix, not sparse matrix. Do you know whether there is any quad-double arithmetic sparse matrix package?

• What kind of matrices are you working with? Is it symmetrc, Hermitian, positive definite? Do you want to do a sparse LU, or use iterative methods? – Victor Liu Aug 23 '13 at 19:45

As of version 3.2, PETSc supports sparse quad-precision computations on gcc/gfortran 4.6 and newer.

You'll need a quad-precision BLAS and LAPACK, which PETSc can provide to you (along with quad support) with the following (partial) configure command:

./configure --with-precision=__float128 --download-f2cblaslapack


Also, I agree with nOOb, if at all possible, try to regularize the system before switching out to quad-precision.

• This is quad precision (128-bit reals), not quad-double (256-bit reals). That said, quad precision is usually plenty to understand stability issues encountered with double precision, and usually you want to scale the system and discretize so that double precision is enough for production. – Jed Brown Aug 23 '13 at 21:49

Ill-conditioned systems are better solved by regularisation than by increasing the numerical precision. Search for "regularisation ill-posed" for the gory details.

I might give the Trilinos library a try. They have templated sparse matrix libraries under Tpetra (which is supposed to replace Epetra, their original sparse matrix library). You can template double, complex, quad, etc, and they have possibly the largest selection of solvers (both direct and iterative) next to PETSc.

Edit: after reading the comments, the immediate usefulness of Tpetra seems to be a bit questionable w.r.t quad precision...

• The majority of solvers don't yet work with Tpetra, unfortunately :-( – Wolfgang Bangerth Aug 10 '13 at 19:41
• That's unfortunate. I was hopeful but unsure of how far Tpetra development has gone (hence the "supposed to replace Epetra" :P). I thought at least the Belos library (i.e. Trilinos solvers not based on wrappers around third party codes) supported Tpetra though? – Jesse Chan Aug 11 '13 at 7:13
• I think there's a Belos2. For sure, the Trilinos project is putting their resources behind Tpetra and it will be the standard package in the future. I think they're not quite there yet, though. – Wolfgang Bangerth Aug 11 '13 at 14:45
• I'm not aware of even __float128 being supported by Tpetra, let alone quad-double. Tpetra is not stand-alone and not all-header, and even if it was, things like std::complex only work with float and double. – Jed Brown Aug 23 '13 at 21:56

Multiprecision computing toolbox for MATLAB has support for sparse matrices and specifically optimized for computations with quadruple precision.

Here is timing details for quad-precision sparse solvers: Direct Solvers for Sparse Matrices

(I am the author of the toolbox).