I am using mpmath for arbitrary decimal precision. I am creating large square matrices (30 x 30 and 100 x 100). For my code, I am executing singular value decomposition and matrix inversion using mpmath's built-in packages.
My problem is that mpmath is slow, even with a gmpy
back-end. I need precision up to 50 decimal points (if the solution is fast, I prefer it to scale to more decimal points).
Is there a solution to speeding up these linear algebra problems in python?
Someone asked a similar question here, but there are 2 differences:
- The answers did not address singular value decomposition
- The answers gave methods of estimating the inverse, but they did not attempt to show that approaching the true answer is faster than mpmath's method. I have tried the solution given in this post, and I have found it to be slower than mpmath's internal algorithm.