# What is used to initialise difference equations that require data from the output?

Given some difference equation for a filter like

$$y[k] = ax[k] + bx[k-1]+ cy[k-1]$$,

how would you initialize it? Since it needs an old output value (feedback) to calculate the new output value, it seems like the equation will keep on chasing its own tail. I would be tempted to just let

$$y[k-1] = x[k-1]$$

initially to calculate a value for $$y[k]$$ after which we could just use that for $$y[k-1]$$. There might be a better technique for this problem or even a really obvious solution to it, but I am at a loss on how. Most of the digital filter books/papers that I have read have done a great job on explaining how the filter gets derived, but the practical implementation requirements seem to be absent.

This is also my first time posting on Stack Exchange, so any comments on etiquette or style would be appreciated. Just be gentle ;)

• Set unknown parameters to zero. This is equivalent to the original input signal. – Alexey K Mar 19 at 8:11

If there is no good reason to choose otherwise, you would initialize with zeros, so in your case $$y[-1]=0$$. Other initializations may be useful in certain situations, e.g., when processing blocks of data to avoid transients between blocks.