# Numerical Linear Algebra in arbitrary precision

Discussion in 'Python' started by Ken, Feb 15, 2012.

1. ### KenGuest

Brand new Python user and a bit overwhelmed with the variety of
packages available. Any recommendation for performing numerical
linear algebra (specifically least squares and generalized least
squares using QR or SVD) in arbitrary precision? I've been looking at
mpmath but can't seem to find much info on built in functions except
for LU decomposition/solve.

Ken

Ken, Feb 15, 2012

2. ### Robert KernGuest

On 2/17/12 6:09 AM, Tim Roberts wrote:
> Ken<> wrote:
>>
>> Brand new Python user and a bit overwhelmed with the variety of
>> packages available. Any recommendation for performing numerical
>> linear algebra (specifically least squares and generalized least
>> squares using QR or SVD) in arbitrary precision? I've been looking at
>> mpmath but can't seem to find much info on built in functions except
>> for LU decomposition/solve.

>
> It is been my experience that numpy is the best place to start with
> requests like this, although I don't know whether it will actually solve
>
> http://docs.scipy.org/doc/numpy/reference/routines.linalg.html

This will not do arbitrary-precision, though. We use the double- and
single-precision routines from LAPACK.

--
Robert Kern

"I have come to believe that the whole world is an enigma, a harmless enigma
an underlying truth."
-- Umberto Eco

Robert Kern, Feb 17, 2012

3. ### Albert van der HorstGuest

In article <>,
Ken <> wrote:
>Brand new Python user and a bit overwhelmed with the variety of
>packages available. Any recommendation for performing numerical
>linear algebra (specifically least squares and generalized least
>squares using QR or SVD) in arbitrary precision? I've been looking at
>mpmath but can't seem to find much info on built in functions except
>for LU decomposition/solve.

Arbitrary precision? As in automatically increasing precision to
stay exact? You will find this impractical as the number of decimals
will explode, or you will find it not at all.

If you mean that you want to be able to select something with larger
precision than single or double floats, numpy is the starting point.

>
>
>Ken

Groetjes Albert

--
--
Albert van der Horst, UTRECHT,THE NETHERLANDS
Economic growth -- being exponential -- ultimately falters.
albert@spe&ar&c.xs4all.nl &=n http://home.hccnet.nl/a.w.m.van.der.horst

Albert van der Horst, Feb 27, 2012