I'm writing some simple c++ code that filters (i.e. smooths out) some data coming in. This line below is run every time new data comes in. The effect is that the filtered vlaue only changes very slowly.
output = new data x 2% + last output x 98%
Any body know what this kind of filter would be called? I'm sure some smart scientist somewhere has a name for this type of thing. I don't think it's a linear phase filter..
output = new data x 2% + last output x 98%
Any body know what this kind of filter would be called? I'm sure some smart scientist somewhere has a name for this type of thing. I don't think it's a linear phase filter..
-
That looks very much like a first-order low-pass filter.
The knee frequency (where the gain is -3 dB) for your specific filter (with 2% and 98% values) is approximately 0.0077 times the sampling frequency.
The knee frequency (where the gain is -3 dB) for your specific filter (with 2% and 98% values) is approximately 0.0077 times the sampling frequency.