berndporr / iir1

DSP IIR realtime filter library written in C++

Home Page:http://berndporr.github.io/iir1/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Setting filter initial state

ftapajos opened this issue · comments

Is there a possibility of setting the filter initial state? The trouble is I need to set a low pass chebychev in order to calculate the offset of a signal, but I need it to have a fast response only after it is reset and the traditional "slow" response during normal operation

There is no easy way of setting it to an initial state. An IIR filter remembers its past and needs to settle on its input signal it receives. So even if you send it 10,000 samples DC in there to fake settling then the actual signal will then start abruptly and will cause again the filter to settle. If you know you are going to use a filter with different parameters then better you create more than one filter and then switch their outputs