IIR Filter order vs group delay

From what I understand FIR filter order is same as it's group delay because of the linear phase and every frequency being delayed by same amount.

For IIR filter, filter order only tells that filter needs that number of past samples to compute a new value. But IIR filter order doesn't translate to output delay or group delay. Is the experiment the only way to find out the group delay for IIR filter or there are other ways to predict that?

In general, group delay is a function of frequency. Only linear phase FIR filters have a constant group delay. For causal linear phase FIR filters (with the first filter tap at $$n=0$$ not equal to zero), the group delay equals half the filter order. Note however that not all FIR filters have a linear phase and hence a constant group delay. FIR filter are just the only realizable filters that can have a linear phase.

Realizable IIR filters cannot have a linear phase. Hence, their group delay is frequency dependent. So there is no way to just estimate the group delay from the filter order. You can of course compute the group delay for any given filter. A corresponding function is usually implemented in signal processing toolboxes. E.g., in Matlab/Octave you have the function grpdelay() which computes the group delay from the filter coefficients.

• This answer is essentially correct. There are small details to consider to make it entirely correct. A realizable linear-phase FIR filter with no pre-delay has a delay of half of the order. The order would be the number of taps minus one. But if an N-tap linear-phase FIR is cascaded with a pure delay, the overall delay would be the sum of the pure delay plus half of the order of the N-tap linear-phase FIR. Like, just a pure delay all by itself has a delay of M, the number of samples of delay. But the order of the "filter" is M. So the delay is M, not M/2. Feb 12, 2023 at 17:42
• @robertbristow-johnson: Ok, fair enough. I think I fixed it. Feb 12, 2023 at 18:12