Just wanted to confirm a small detail whilst sanity checking my results and understanding.
So I've ran an RMS vs Iir RMS approximation side by side and found the Iir version needed twice the "window size" to give an equivalent step response and curve when using the following calculations.
Code: Select all
iirPole = exp(log(0.01) / (windowSize * sampleRate));
meanSquared = sampleSquared + iirPole * (meanSquared - sampleSquared);
So first of all, is my calculation off? and is this normal? Secondly, what is the meaning of this.
Edit: it seems, given my description, that the step response for an RMS would be windowSize, while the formula for the iirPole to give a step response based on desired windowSize should in fact be:
Code: Select all
iirPole = exp(log(0.1) / (windowSize * sampleRate));