summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authortorset2009-02-04 14:30:43 +0000
committertorset2009-02-04 14:30:43 +0000
commitd3620448a8d9ca5931a0b27eb7b87f71915b638a (patch)
treed757fddb307606579209cdb329749d7adda76f6e /src
parent3401bb910b068bc0e0c83637d995ed5a68e3ff4f (diff)
downloadscilab2c-d3620448a8d9ca5931a0b27eb7b87f71915b638a.tar.gz
scilab2c-d3620448a8d9ca5931a0b27eb7b87f71915b638a.tar.bz2
scilab2c-d3620448a8d9ca5931a0b27eb7b87f71915b638a.zip
Update powm
Diffstat (limited to 'src')
-rw-r--r--src/matrixOperations/powm/Makefile.in13
-rw-r--r--src/matrixOperations/powm/spowma.c33
2 files changed, 13 insertions, 33 deletions
diff --git a/src/matrixOperations/powm/Makefile.in b/src/matrixOperations/powm/Makefile.in
index 1d738627..9f4da1fa 100644
--- a/src/matrixOperations/powm/Makefile.in
+++ b/src/matrixOperations/powm/Makefile.in
@@ -55,7 +55,7 @@ LTLIBRARIES = $(pkglib_LTLIBRARIES)
libMatrixPow_la_LIBADD =
am__objects_1 =
am_libMatrixPow_la_OBJECTS = $(am__objects_1) \
- libMatrixPow_la-dpowma.lo
+ libMatrixPow_la-dpowma.lo libMatrixPow_la-spowma.lo
libMatrixPow_la_OBJECTS = $(am_libMatrixPow_la_OBJECTS)
libMatrixPow_la_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) \
$(LIBTOOLFLAGS) --mode=link $(CCLD) $(libMatrixPow_la_CFLAGS) \
@@ -205,7 +205,8 @@ instdir = $(top_builddir)/lib
pkglib_LTLIBRARIES = libMatrixPow.la
HEAD = ../includes/matrixPow.h
libMatrixPow_la_SOURCES = $(HEAD) \
- dpowma.c
+ dpowma.c\
+ spowma.c
check_LDADD = $(top_builddir)/type/libDoubleComplex.la \
$(top_builddir)/type/libFloatComplex.la \
@@ -306,6 +307,7 @@ distclean-compile:
-rm -f *.tab.c
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libMatrixPow_la-dpowma.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libMatrixPow_la-spowma.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/testDoubleMatrixPow-testDoublePowm.Po@am__quote@
.c.o:
@@ -336,6 +338,13 @@ libMatrixPow_la-dpowma.lo: dpowma.c
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libMatrixPow_la_CFLAGS) $(CFLAGS) -c -o libMatrixPow_la-dpowma.lo `test -f 'dpowma.c' || echo '$(srcdir)/'`dpowma.c
+libMatrixPow_la-spowma.lo: spowma.c
+@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libMatrixPow_la_CFLAGS) $(CFLAGS) -MT libMatrixPow_la-spowma.lo -MD -MP -MF $(DEPDIR)/libMatrixPow_la-spowma.Tpo -c -o libMatrixPow_la-spowma.lo `test -f 'spowma.c' || echo '$(srcdir)/'`spowma.c
+@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/libMatrixPow_la-spowma.Tpo $(DEPDIR)/libMatrixPow_la-spowma.Plo
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='spowma.c' object='libMatrixPow_la-spowma.lo' libtool=yes @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libMatrixPow_la_CFLAGS) $(CFLAGS) -c -o libMatrixPow_la-spowma.lo `test -f 'spowma.c' || echo '$(srcdir)/'`spowma.c
+
testDoubleMatrixPow-testDoublePowm.o: testDoublePowm.c
@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(testDoubleMatrixPow_CFLAGS) $(CFLAGS) -MT testDoubleMatrixPow-testDoublePowm.o -MD -MP -MF $(DEPDIR)/testDoubleMatrixPow-testDoublePowm.Tpo -c -o testDoubleMatrixPow-testDoublePowm.o `test -f 'testDoublePowm.c' || echo '$(srcdir)/'`testDoublePowm.c
@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/testDoubleMatrixPow-testDoublePowm.Tpo $(DEPDIR)/testDoubleMatrixPow-testDoublePowm.Po
diff --git a/src/matrixOperations/powm/spowma.c b/src/matrixOperations/powm/spowma.c
index 65bfb74f..aa0f7043 100644
--- a/src/matrixOperations/powm/spowma.c
+++ b/src/matrixOperations/powm/spowma.c
@@ -11,39 +11,13 @@
*/
#include "matrixPow.h"
-#include "lapack.h"
#include "eye.h"
#include "matrixMultiplication.h"
void spowma(float* in, int size, float expand, float* out){
-#ifndef WITHOUT_BLAS
- switch ((int)expand){
- case 0 :
- seyea(out,size,size);
- break;
- case 1 :
- {
- int i;
- for (i=0;i<size*size;i++) out[i]=in[i];
- }
- break;
- default :
- {
- int i=0,j=0,k=0;
- int One=1;
- for (i=1; i<expand; i++){
- for (j=0;j<size;j++) /*column*/ {
- for (k=0;k<size;k++)/*row*/{
- out[k+j*size]=ddot_(&size,in+k,&size,in+j*size,&One);
- }
- }
- }
- }
- break;
- }
-#else
+
switch ((int)expand){
case 0 :
seyea(out,size,size);
@@ -67,8 +41,5 @@ void spowma(float* in, int size, float expand, float* out){
}
break;
}
-
-
-#endif
-
+
}