Skip to content

Commit

Permalink
Improved on algorithm
Browse files Browse the repository at this point in the history
  • Loading branch information
pjpei committed Oct 10, 2024
1 parent f442e79 commit acfb125
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/main/common/lulu.c
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,9 @@ FAST_CODE float fixRoad(float *series, float *seriesB, int index, int filterN, i
indexPos++;
}
}
int finalIndex = (index + windowSize - filterN) % windowSize;
curVal = series[finalIndex];
curValB = seriesB[finalIndex];
return (curVal - curValB) / 2;
}

Expand Down

0 comments on commit acfb125

Please sign in to comment.