What is the maximum output of an IIR filter?

I am implementing an IIR filter in an embedded device based on ARM. It is implemented as a cascaded biquad structure (series of second order filters put back to back). The filter can be considered stable as all the second order sections in the cascaded structure have their poles and zeros inside the unit circle(ROC) in the Z-domain.

Now, given that the filter is asymptotically stable and its output can't grow unboundedly, how to know the maximum output that the filter can grow to, asssuming that the input to the filter can be any noise or any random waveform?

On the device, the filter is implemented with floats, which reduces the chance of any overflow during computation. But after the computation the results have to be stored into fixed points as it is required by the application to do so. Hence,it is very important to know the output limits to avoid any overflow and saturation while storing into fixed points.

I would like to know,if there is any way to estitmate what could be the maximum limits of the output,so as to avoid clipping or unnecessarily use more bits for the fixed point?

And also it would be useful to know which type of input waveforms could produce the worst output possible?

• Do you know the maximum/minimum float that can be used to be converted into an int/short/whatever? Is it possible to test? Commented Mar 10, 2022 at 11:28

I would like to know,if there is any way to estitmate what could be the maximum limits of the output

Yes. It's

$$y_{max} = x_{max} \cdot \sum_{n = 0}^{\infty} |h[n]|$$

I.e. the maximum gain is the absolute sum of the impulse response

which type of input waveforms could produce the worst output possible?

$$x_{worst}[n] = x_{max} \cdot \text{sign}(h[-n])$$

It's the signum function of the time-flipped impulse response. In most cases this is an extremely unlikely signal to occur in the real world so it's overly conservative to assume worst case scaling. A different approach would be to do a statistical analysis of "real world" signals plus some sine waves, square waves and noise signals.

• Then I misunderstood. I thought it's about float <-> int conversion. Commented Mar 10, 2022 at 16:45
• I think you do not necessarily have an a priori knowledge of what $x_{\rm max}$ is. Commented Mar 10, 2022 at 22:48
• x_max is actually known already. The input is bound and so is the output of the filter. But the problem is to know the highest output the filter will produce from our input which is basically in the range [4 -4]. Will the output grow more than the input. If so by how much? Commented Mar 11, 2022 at 3:44
• Okay, then my comment doesn’t apply. Commented Mar 11, 2022 at 6:01