summaryrefslogtreecommitdiff
path: root/lib/Numeric/LinearAlgebra/LAPACK/lapack-aux.c
diff options
context:
space:
mode:
authorVivian McPhail <haskell.vivian.mcphail@gmail.com>2010-06-29 09:03:19 +0000
committerVivian McPhail <haskell.vivian.mcphail@gmail.com>2010-06-29 09:03:19 +0000
commit4957cff8af91cbb23c12382e25f5373fe96acb95 (patch)
tree2f2968d5ca88f7d76e208982b8938c4dfc46ce8a /lib/Numeric/LinearAlgebra/LAPACK/lapack-aux.c
parentd18a86d37d55a39d4ec9b16397dd59f35aa13688 (diff)
add-vector-float
Diffstat (limited to 'lib/Numeric/LinearAlgebra/LAPACK/lapack-aux.c')
-rw-r--r--lib/Numeric/LinearAlgebra/LAPACK/lapack-aux.c22
1 files changed, 22 insertions, 0 deletions
diff --git a/lib/Numeric/LinearAlgebra/LAPACK/lapack-aux.c b/lib/Numeric/LinearAlgebra/LAPACK/lapack-aux.c
index fd840e3..b9c2572 100644
--- a/lib/Numeric/LinearAlgebra/LAPACK/lapack-aux.c
+++ b/lib/Numeric/LinearAlgebra/LAPACK/lapack-aux.c
@@ -1039,6 +1039,18 @@ int multiplyC(int ta, int tb, KCMAT(a),KCMAT(b),CMAT(r)) {
1039 1039
1040//////////////////// transpose ///////////////////////// 1040//////////////////// transpose /////////////////////////
1041 1041
1042int transF(KFMAT(x),FMAT(t)) {
1043 REQUIRES(xr==tc && xc==tr,BAD_SIZE);
1044 DEBUGMSG("transF");
1045 int i,j;
1046 for (i=0; i<tr; i++) {
1047 for (j=0; j<tc; j++) {
1048 tp[i*tc+j] = xp[j*xc+i];
1049 }
1050 }
1051 OK
1052}
1053
1042int transR(KDMAT(x),DMAT(t)) { 1054int transR(KDMAT(x),DMAT(t)) {
1043 REQUIRES(xr==tc && xc==tr,BAD_SIZE); 1055 REQUIRES(xr==tc && xc==tr,BAD_SIZE);
1044 DEBUGMSG("transR"); 1056 DEBUGMSG("transR");
@@ -1065,6 +1077,16 @@ int transC(KCMAT(x),CMAT(t)) {
1065 1077
1066//////////////////// constant ///////////////////////// 1078//////////////////// constant /////////////////////////
1067 1079
1080int constantF(float * pval, FVEC(r)) {
1081 DEBUGMSG("constantF")
1082 int k;
1083 double val = *pval;
1084 for(k=0;k<rn;k++) {
1085 rp[k]=val;
1086 }
1087 OK
1088}
1089
1068int constantR(double * pval, DVEC(r)) { 1090int constantR(double * pval, DVEC(r)) {
1069 DEBUGMSG("constantR") 1091 DEBUGMSG("constantR")
1070 int k; 1092 int k;