uBLAS - Calculation of Inverse and/or Least Squares
Hello All, Can anyone suggest the best way to use uBLAS to calculate the inverse of a matrix?? One of the reasons I want to do this is to solve a linear least squares problem, which I know can be done without explicitly solving for the inverse. Does anyone know if this is possible?? thanks, jon
----- Original Message -----
From: jonny5cents
Hello All,
Can anyone suggest the best way to use uBLAS to calculate the inverse of a matrix??
One of the reasons I want to do this is to solve a linear least squares problem, which I know can be done without explicitly solving for the inverse. Does anyone know if this is possible??
There are two ways to go: either you could try to port the corresponding LAPACK routine(s) to use uBLAS or you could consider to use and extend the bindings in the boost sandbox written by Toon Knapen and Kresimir Fresl. Regards Joerg
Hi Jon, jhr.walter@t-online.de wrote:
From: jonny5cents
Hello All,
Can anyone suggest the best way to use uBLAS to calculate the inverse of a matrix??
One of the reasons I want to do this is to solve a linear least squares problem, which I know can be done without explicitly solving for the inverse. Does anyone know if this is possible??
There are two ways to go: either you could try to port the corresponding LAPACK routine(s) to use uBLAS or you could consider to use and extend the bindings in the boost sandbox written by Toon Knapen and Kresimir Fresl.
I just added functions `getri()' and `potri()' to ATLAS (http://math-atlas.sourceforge.net/) bindings. `getri()' computes the inverse of a general matrix A using the LU factorization previously computed by `getrf()'. `potri()' computes the inverse of a symmetric or Hermitian positive definite matrix A using the Cholesky factorization previously computed by `potrf()'. But please note that `bindings' in boost sandbox are not updated yet. Therefore you must download `bindings_2003_01_07.zip' from `ublas-dev' mailing list file section. There's no documentation, but some simple examples of use with uBLAS matrices can be found in `libs/numeric/bindings/atlas/ublas_getri.cc' and `libs/numeric/bindings/atlas/ublas_potri.cc'. Sincerely, fres
participants (3)
-
jhr.walter@t-online.de
-
jonny5cents <jon_nichols95@hotmail.com>
-
Kresimir Fresl