diff options
author | torset | 2009-01-30 15:43:04 +0000 |
---|---|---|
committer | torset | 2009-01-30 15:43:04 +0000 |
commit | aebff0246ad51ce6d15a5b819047d9d6bcf0bc02 (patch) | |
tree | 0c32b55cc8af0e1e3feb9283a52ca446d5a3f929 /src | |
parent | 1c6e73424919452af3e5e45d3d9871465ffd2c29 (diff) | |
download | scilab2c-aebff0246ad51ce6d15a5b819047d9d6bcf0bc02.tar.gz scilab2c-aebff0246ad51ce6d15a5b819047d9d6bcf0bc02.tar.bz2 scilab2c-aebff0246ad51ce6d15a5b819047d9d6bcf0bc02.zip |
Update fill
Diffstat (limited to 'src')
-rw-r--r-- | src/matrixOperations/fill/Makefile.am | 4 | ||||
-rw-r--r-- | src/matrixOperations/fill/Makefile.in | 4 | ||||
-rw-r--r-- | src/matrixOperations/fill/cfilla.c | 7 | ||||
-rw-r--r-- | src/matrixOperations/fill/dfilla.c | 4 | ||||
-rw-r--r-- | src/matrixOperations/fill/sfilla.c | 4 | ||||
-rw-r--r-- | src/matrixOperations/fill/testDoubleFill.c | 1 | ||||
-rw-r--r-- | src/matrixOperations/fill/zfilla.c | 8 |
7 files changed, 8 insertions, 24 deletions
diff --git a/src/matrixOperations/fill/Makefile.am b/src/matrixOperations/fill/Makefile.am index 9033e138..29329a53 100644 --- a/src/matrixOperations/fill/Makefile.am +++ b/src/matrixOperations/fill/Makefile.am @@ -11,7 +11,6 @@ ## libMatrixFill_la_CFLAGS = -I $(top_builddir)/type \ - -I $(top_builddir)/operations/includes \ -I $(top_builddir)/matrixOperations/includes instdir = $(top_builddir)/lib @@ -36,12 +35,9 @@ check_PROGRAMS = testDoubleFill testFloatFill check_LDADD = $(top_builddir)/type/libDoubleComplex.la \ $(top_builddir)/type/libFloatComplex.la \ - $(top_builddir)/operations/multiplication/libMultiplication.la \ - $(top_builddir)/matrixOperations/ones/libMatrixOnes.la \ libMatrixFill.la check_INCLUDES = -I $(top_builddir)/type \ - -I $(top_builddir)/operations/includes \ -I $(top_builddir)/matrixOperations/includes testDoubleFill_SOURCES = testDoubleFill.c diff --git a/src/matrixOperations/fill/Makefile.in b/src/matrixOperations/fill/Makefile.in index d5ef215a..532391b6 100644 --- a/src/matrixOperations/fill/Makefile.in +++ b/src/matrixOperations/fill/Makefile.in @@ -203,7 +203,6 @@ target_alias = @target_alias@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ libMatrixFill_la_CFLAGS = -I $(top_builddir)/type \ - -I $(top_builddir)/operations/includes \ -I $(top_builddir)/matrixOperations/includes instdir = $(top_builddir)/lib @@ -217,12 +216,9 @@ libMatrixFill_la_SOURCES = $(HEAD) \ check_LDADD = $(top_builddir)/type/libDoubleComplex.la \ $(top_builddir)/type/libFloatComplex.la \ - $(top_builddir)/operations/multiplication/libMultiplication.la \ - $(top_builddir)/matrixOperations/ones/libMatrixOnes.la \ libMatrixFill.la check_INCLUDES = -I $(top_builddir)/type \ - -I $(top_builddir)/operations/includes \ -I $(top_builddir)/matrixOperations/includes testDoubleFill_SOURCES = testDoubleFill.c diff --git a/src/matrixOperations/fill/cfilla.c b/src/matrixOperations/fill/cfilla.c index e73213f1..0c591047 100644 --- a/src/matrixOperations/fill/cfilla.c +++ b/src/matrixOperations/fill/cfilla.c @@ -13,12 +13,9 @@ #include "fill.h" -#include "ones.h" -#include "multiplication.h" void cfilla (floatComplex* in, int rows, int cols, floatComplex constant){ int i; - - conesa(in,rows,cols); - for (i=0;i<rows*cols;i++) in[i]=cmuls(in[i],constant); + + for (i=0;i<rows*cols;i++) in[i]=FloatComplex(creals(constant),cimags(constant)); } diff --git a/src/matrixOperations/fill/dfilla.c b/src/matrixOperations/fill/dfilla.c index f021f33a..69870fd6 100644 --- a/src/matrixOperations/fill/dfilla.c +++ b/src/matrixOperations/fill/dfilla.c @@ -13,12 +13,10 @@ #include "fill.h" -#include "ones.h" void dfilla (double* in, int rows, int cols, double constant){ int i; - donesa(in,rows,cols); - for (i=0;i<rows*cols;i++) in[i]*=constant; + for (i=0;i<rows*cols;i++) in[i]=constant; } diff --git a/src/matrixOperations/fill/sfilla.c b/src/matrixOperations/fill/sfilla.c index fb5b0271..8201e40f 100644 --- a/src/matrixOperations/fill/sfilla.c +++ b/src/matrixOperations/fill/sfilla.c @@ -13,12 +13,10 @@ #include "fill.h" -#include "ones.h" void sfilla (float* in, int rows, int cols, float constant){ int i; - sonesa(in,rows,cols); - for (i=0;i<rows*cols;i++) in[i]*=constant; + for (i=0;i<rows*cols;i++) in[i]=constant; } diff --git a/src/matrixOperations/fill/testDoubleFill.c b/src/matrixOperations/fill/testDoubleFill.c index 10b85182..0b5a88c2 100644 --- a/src/matrixOperations/fill/testDoubleFill.c +++ b/src/matrixOperations/fill/testDoubleFill.c @@ -28,6 +28,7 @@ static void zfillaTest(){ doubleComplex in[9]; doubleComplex constant=DoubleComplex(1,1); int i; + zfilla(in, 3, 3, constant); for (i=0;i<9;i++) printf("indice : %d -- valeur : %f+%f *i\n",i,zreals(in[i]),zimags(in[i])); diff --git a/src/matrixOperations/fill/zfilla.c b/src/matrixOperations/fill/zfilla.c index a4a8ac9b..2936cc59 100644 --- a/src/matrixOperations/fill/zfilla.c +++ b/src/matrixOperations/fill/zfilla.c @@ -13,12 +13,10 @@ #include "fill.h" -#include "ones.h" -#include "multiplication.h" + void zfilla (doubleComplex* in, int rows, int cols, doubleComplex constant){ int i; - - zonesa(in,rows,cols); - for (i=0;i<rows*cols;i++) in[i]=zmuls(in[i],constant); + + for (i=0;i<rows*cols;i++) in[i]=DoubleComplex(zreals(constant),zimags(constant)); } |