IIR Echo Demo

This demo shows the convolution of an input signal \(x[k]\) (audio) with an Infinite Impulse Response (IIR) filter $$h[k] = \sum_{i=0}^{\infty}a^{i}\delta[k-i\cdot K]=a^{\frac k K}\varepsilon\left[\frac k K\right],\quad H(z)=\frac{1}{1-az^{-K}}.$$ The resulting output signal is calculated as \(y[k] = \sum_{i=0}^{\infty}a^{i}x[k-i\cdot K]\). Adjust the delay \(K\) and attenuation \(a\) of the echo and plot the input \(x[k]\), impulse response \(h[k]\), and output \(y[k]\).

Input:
Output: