summaryrefslogtreecommitdiff
path: root/lib/Numeric/LinearAlgebra/LAPACK/lapack-aux.c
diff options
context:
space:
mode:
authorAlberto Ruiz <aruiz@um.es>2007-10-02 18:59:50 +0000
committerAlberto Ruiz <aruiz@um.es>2007-10-02 18:59:50 +0000
commit42bec1ac9911131b552f66779203eb599a86563d (patch)
treec4aefaedb21730644fcd4d2f85d830fe4d4daf07 /lib/Numeric/LinearAlgebra/LAPACK/lapack-aux.c
parentd925bada507562250a75587c409bdb35bbbc6ed8 (diff)
lapack real and complex unpacked QR
Diffstat (limited to 'lib/Numeric/LinearAlgebra/LAPACK/lapack-aux.c')
-rw-r--r--lib/Numeric/LinearAlgebra/LAPACK/lapack-aux.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/Numeric/LinearAlgebra/LAPACK/lapack-aux.c b/lib/Numeric/LinearAlgebra/LAPACK/lapack-aux.c
index 4ef9a6e..bf0cfba 100644
--- a/lib/Numeric/LinearAlgebra/LAPACK/lapack-aux.c
+++ b/lib/Numeric/LinearAlgebra/LAPACK/lapack-aux.c
@@ -621,7 +621,6 @@ int chol_l_S(KDMAT(a),DMAT(l)) {
621} 621}
622 622
623//////////////////// QR factorization ///////////////////////// 623//////////////////// QR factorization /////////////////////////
624// TO DO: unpack
625 624
626int qr_l_R(KDMAT(a), DVEC(tau), DMAT(r)) { 625int qr_l_R(KDMAT(a), DVEC(tau), DMAT(r)) {
627 integer m = ar; 626 integer m = ar;
@@ -629,7 +628,7 @@ int qr_l_R(KDMAT(a), DVEC(tau), DMAT(r)) {
629 integer mn = MIN(m,n); 628 integer mn = MIN(m,n);
630 REQUIRES(m>=1 && n >=1 && rr== m && rc == n && taun == mn, BAD_SIZE); 629 REQUIRES(m>=1 && n >=1 && rr== m && rc == n && taun == mn, BAD_SIZE);
631 DEBUGMSG("qr_l_R"); 630 DEBUGMSG("qr_l_R");
632 double *WORK = (double*)malloc(m*sizeof(double)); 631 double *WORK = (double*)malloc(n*sizeof(double));
633 CHECK(!WORK,MEM); 632 CHECK(!WORK,MEM);
634 memcpy(rp,ap,m*n*sizeof(double)); 633 memcpy(rp,ap,m*n*sizeof(double));
635 integer res; 634 integer res;
@@ -645,7 +644,7 @@ int qr_l_C(KCMAT(a), CVEC(tau), CMAT(r)) {
645 integer mn = MIN(m,n); 644 integer mn = MIN(m,n);
646 REQUIRES(m>=1 && n >=1 && rr== m && rc == n && taun == mn, BAD_SIZE); 645 REQUIRES(m>=1 && n >=1 && rr== m && rc == n && taun == mn, BAD_SIZE);
647 DEBUGMSG("qr_l_C"); 646 DEBUGMSG("qr_l_C");
648 doublecomplex *WORK = (doublecomplex*)malloc(m*sizeof(doublecomplex)); 647 doublecomplex *WORK = (doublecomplex*)malloc(n*sizeof(doublecomplex));
649 CHECK(!WORK,MEM); 648 CHECK(!WORK,MEM);
650 memcpy(rp,ap,m*n*sizeof(doublecomplex)); 649 memcpy(rp,ap,m*n*sizeof(doublecomplex));
651 integer res; 650 integer res;