diff options
author | simon | 2009-08-24 09:20:03 +0000 |
---|---|---|
committer | simon | 2009-08-24 09:20:03 +0000 |
commit | a2c6ed14519f019b157eac1aac66d9528dd9208a (patch) | |
tree | e6f48a413cdafa1efe94ab8ec723d013cc55ae3a /src/c/auxiliaryFunctions/includes | |
parent | 839d659e6b1c25be20bd556aba6386eaceb1245f (diff) | |
download | scilab2c-a2c6ed14519f019b157eac1aac66d9528dd9208a.tar.gz scilab2c-a2c6ed14519f019b157eac1aac66d9528dd9208a.tar.bz2 scilab2c-a2c6ed14519f019b157eac1aac66d9528dd9208a.zip |
updating *find2d for loops order in order to have the result in the same result than scilab
updating *find* prototype , adding to all a argument "int max" , in order to avoid useless
computation when only a limited number of results is requested
Diffstat (limited to 'src/c/auxiliaryFunctions/includes')
-rw-r--r-- | src/c/auxiliaryFunctions/includes/find.h | 12 | ||||
-rw-r--r-- | src/c/auxiliaryFunctions/includes/find2d.h | 12 |
2 files changed, 16 insertions, 8 deletions
diff --git a/src/c/auxiliaryFunctions/includes/find.h b/src/c/auxiliaryFunctions/includes/find.h index 202219c8..7cc876e9 100644 --- a/src/c/auxiliaryFunctions/includes/find.h +++ b/src/c/auxiliaryFunctions/includes/find.h @@ -22,23 +22,27 @@ extern "C" { #endif /* ** \brief Float Find function +** max is an integer giving the maximum number of indices to return. (use -1 to search them all) */ -EXTERN_AUXFUNCT void sfinda(float* x, int size, float *out, int *sizeOut); +EXTERN_AUXFUNCT void sfinda(float* x, int size, float *out, int *sizeOut,int max); /* ** \brief Double Find function +** max is an integer giving the maximum number of indices to return. (use -1 to search them all) */ -EXTERN_AUXFUNCT void dfinda(double*x, int size, double *out, int *sizeOut); +EXTERN_AUXFUNCT void dfinda(double*x, int size, double *out, int *sizeOut,int max); /* ** \brief Float Complex Find function +** max is an integer giving the maximum number of indices to return. (use -1 to search them all) */ -EXTERN_AUXFUNCT void cfinda(floatComplex* z, int size, float *out, int *sizeOut); +EXTERN_AUXFUNCT void cfinda(floatComplex* z, int size, float *out, int *sizeOut,int max); /* ** \brief Double Complex Find function +** max is an integer giving the maximum number of indices to return. (use -1 to search them all) */ -EXTERN_AUXFUNCT void zfinda(doubleComplex* z, int size, double *out, int *sizeOut); +EXTERN_AUXFUNCT void zfinda(doubleComplex* z, int size, double *out, int *sizeOut,int max); #ifdef __cplusplus } /* extern "C" */ diff --git a/src/c/auxiliaryFunctions/includes/find2d.h b/src/c/auxiliaryFunctions/includes/find2d.h index 72c036d5..6e365107 100644 --- a/src/c/auxiliaryFunctions/includes/find2d.h +++ b/src/c/auxiliaryFunctions/includes/find2d.h @@ -22,23 +22,27 @@ extern "C" { #endif /* ** \brief Float Find function +** max is an integer giving the maximum number of indices to return. (use -1 to search them all) */ -EXTERN_AUXFUNCT void sfind2da(float* x, int rows, int columns, float* out1, int* sizeOut1, float* out2, int* sizeOut2); +EXTERN_AUXFUNCT void sfind2da(float* x, int rows, int columns, float* out1, int* sizeOut1, float* out2, int* sizeOut2,int max); /* ** \brief Double Find function +** max is an integer giving the maximum number of indices to return. (use -1 to search them all) */ -EXTERN_AUXFUNCT void dfind2da(double* x, int rows, int columns, double* out1, int* sizeOut1, double* out2, int* sizeOut2); +EXTERN_AUXFUNCT void dfind2da(double* x, int rows, int columns, double* out1, int* sizeOut1, double* out2, int* sizeOut2,int max); /* ** \brief Float Complex Find function +** max is an integer giving the maximum number of indices to return. (use -1 to search them all) */ -EXTERN_AUXFUNCT void cfind2da(floatComplex* z, int rows, int columns, float* out1, int* sizeOut1, float* out2, int* sizeOut2); +EXTERN_AUXFUNCT void cfind2da(floatComplex* z, int rows, int columns, float* out1, int* sizeOut1, float* out2, int* sizeOut2,int max); /* ** \brief Double Complex Find function +** max is an integer giving the maximum number of indices to return. (use -1 to search them all) */ -EXTERN_AUXFUNCT void zfind2da(doubleComplex* z, int rows, int columns, double* out1, int* sizeOut1, double* out2, int* sizeOut2); +EXTERN_AUXFUNCT void zfind2da(doubleComplex* z, int rows, int columns, double* out1, int* sizeOut1, double* out2, int* sizeOut2,int max); #ifdef __cplusplus } /* extern "C" */ |