# Linear-Phase FIR filters

I understand the four different type os FIR filters however i don´t understand why do linear-phase FIR filters offer opportunities for efficient realization.

Linear phase FIR filters should have some sort of symmetry (even or odd) in their coefficients which will reduce the number of independent multiplications by about two yielding an efficient realization compared to a nonsymmetric FIR filter of the same length.

However, linear phase FIR filters are important not because of their computational efficiency but for their linear phase property.

Here are two graphics specifically showing the efficiency that Fat32 mentions in his answer by comparing the initial FIR realization from the convolution summation and then showing how the number of coefficient multiplications required is reduced due to the requirement that linear phase filter coefficients be symmetric or asymmetric.

We desire Linear Phase filters because they have no group delay distortion (see Why is a linear phase important?) and then it is mighty convenient for us that they are also more efficient to implement (win win!).

See below the plots a simple mathematical explanation as to why the coefficients need to be symmetric or asymmetric in order to have linear phase.

So we see in the top structure for general FIR filter implementations, $$M$$ multipliers are required for each of the coefficients $$h[0], h[1] ... h[M-1]$$ while in the lower structure for linear phase filters, due to the symmetric in the coefficients, only $$(M+1)/2$$ multipliers are required.

Why the symmetry?

The Frequency Response, both magnitude and phase is derived directly from the z-transform by restricting z to be the unit circle as in $$z = e^{j\omega}$$ where $$\omega$$ is from $$0$$ to $$2\pi$$. (So we call the unit circle the frequency axis, just like on the s-plane in continuous time systems, using Laplace, the $$j\omega$$ axis is the frequency axis).

So this is super easy for FIR filters since the z-transform is just the coefficients in increasing inverse powers of $$z$$ (hence all the $$z^{-1}$$'s we see for the unit delays in implementation). So to get the phase response, we find the z-transform, replace $$z$$ with $$e^{j\omega}$$ and solve for the angle.

Consider then the z-transform for a simple symmetric odd length (Type 1) FIR Filter with coefficients as:

$$[c_1, c_2, c_3, c_2, c_1]$$

The z-transform would be:

$$H(z) = c_1 + c_2z^{-1}+ c_3z^{-2}+ c_2z^{-3}+ c_1z^{-4}$$

And the frequency response would then be:

$$H(z= e^{j\omega}) = c_1 + c_2e^{-j\omega}+ c_3e^{-2j\omega}+ c_2e^{-3j\omega}+ c_1e^{-4j\omega}$$

Where $$\omega = 0 ...2\pi$$

Due to the symmetric (or asymmetric) coefficients, a single exponential can be factored out such that the above expression has conjugate symmetric coefficients - which means that part of the equation can be completely converted to sinusoidal functions using Euler's Identity (which are all real or all imaginary and therefore do not contribute to the phase other than a constant 0 or $$\pi/2$$)! We can only do this if the coefficients are symmetric or asymmetric.

$$H(z= e^{j\omega}) = e^{-2j\omega} \big(c_1e^{2j\omega} + c_2e^{j\omega}+ c_3+ c_2e^{-j\omega}+ c_1e^{-2j\omega}\big)$$

$$= e^{-2j\omega} \bigg(2c_1\frac{(e^{2j\omega} +e^{-2j\omega})}{2} + 2c_2\frac{(e^{j\omega}+ e^{-j\omega})}{2}+ c_3 \bigg)$$

$$= e^{-2j\omega} \bigg(2c_1\cos(2\omega) + 2c_2\cos(\omega) + c_3 \bigg)$$

To then see this clearly consider the phase versus frequency of the two components above; the $$e^{-2j\omega}$$ and the rest of the equation consising of cosines and a constant. The rest of the equation is real so the phase is always $$0$$, while the phase of the exponential is linearly increasing in the negative direction versus $$\omega$$ so will go from $$0$$ to $$-4\pi$$ as we go over the full digital spectrum with the normalized angular frequency going from $$0$$ to $$2\pi$$ radians/sample. This is the 2 sample delay of the filter ($$z^{-2}$$) associated with the middle tap. Due to this balance, the delay of all linear phase FIR filters will always be $$(N-1)/2$$ samples as it was in this case.