updated
This commit is contained in:
parent
62ffcca286
commit
66177c97da
|
@ -162,7 +162,7 @@ void localMean(void) {
|
||||||
|
|
||||||
|
|
||||||
for (xCount = 1; xCount < NUMBER_OF_SAMPLES; xCount++) { // first value will not get predicted
|
for (xCount = 1; xCount < NUMBER_OF_SAMPLES; xCount++) { // first value will not get predicted
|
||||||
double xPartArray[xCount]; //includes all values at the size of runtime var
|
//double xPartArray[1000]; //includes all values at the size of runtime var
|
||||||
//int _sourceIndex = (xCount > WINDOWSIZE) ? xCount - WINDOWSIZE : xCount;
|
//int _sourceIndex = (xCount > WINDOWSIZE) ? xCount - WINDOWSIZE : xCount;
|
||||||
int _arrayLength = (xCount > WINDOWSIZE) ? WINDOWSIZE + 1 : xCount;
|
int _arrayLength = (xCount > WINDOWSIZE) ? WINDOWSIZE + 1 : xCount;
|
||||||
//printf("xCount:%d, length:%d\n", xCount, _arrayLength);
|
//printf("xCount:%d, length:%d\n", xCount, _arrayLength);
|
||||||
|
@ -247,7 +247,7 @@ void directPredecessor(void) {
|
||||||
fprintf(fp3, "\n=====================================DirectPredecessor=====================================\n");
|
fprintf(fp3, "\n=====================================DirectPredecessor=====================================\n");
|
||||||
|
|
||||||
for (xCount = 1; xCount < NUMBER_OF_SAMPLES + 1; xCount++) {
|
for (xCount = 1; xCount < NUMBER_OF_SAMPLES + 1; xCount++) {
|
||||||
double xPartArray[xCount]; //includes all values at the size of runtime var
|
//double xPartArray[xCount]; //includes all values at the size of runtime var
|
||||||
//int _sourceIndex = (xCount > WINDOWSIZE) ? xCount - WINDOWSIZE : xCount;
|
//int _sourceIndex = (xCount > WINDOWSIZE) ? xCount - WINDOWSIZE : xCount;
|
||||||
int _arrayLength = (xCount > WINDOWSIZE) ? WINDOWSIZE + 1 : xCount;
|
int _arrayLength = (xCount > WINDOWSIZE) ? WINDOWSIZE + 1 : xCount;
|
||||||
printf("xCount:%d, length:%d\n", xCount, _arrayLength);
|
printf("xCount:%d, length:%d\n", xCount, _arrayLength);
|
||||||
|
@ -473,7 +473,8 @@ double sum_array(double x[], int xlength) {
|
||||||
|
|
||||||
double *popNAN(double *xError, int xErrorLength) {
|
double *popNAN(double *xError, int xErrorLength) {
|
||||||
int i, counter;
|
int i, counter;
|
||||||
double noNAN [xErrorLength];
|
double noNAN[10];
|
||||||
|
realloc(noNAN, xErrorLength);
|
||||||
|
|
||||||
for (i = 0; i < xErrorLength; i++) {
|
for (i = 0; i < xErrorLength; i++) {
|
||||||
if (!isnan(xError[i])) {
|
if (!isnan(xError[i])) {
|
||||||
|
|
Loading…
Reference in New Issue