Transformations for FIR and IIR Filters’ Design

In this paper, the transfer functions related to one-dimensional (1-D) and two-dimensional (2-D) filters have been theoretically and numerically investigated. The finite impulse response (FIR), as well as the infinite impulse response (IIR) are the main 2-D filters which have been investigated. More specifically, methods like the Windows method, the bilinear transformation method, the design of 2-D filters from appropriate 1-D functions and the design of 2-D filters using optimization techniques have been presented.

In the non-recursive filter structures the output depends only on the input, and in the recursive filter structures the output depends both on the input and on the previous outputs. The Recursive filters have been employed in science and technology for issues like signal processing, control signals, radar signals, astronomy signals, medical image processing and x-ray enhancements, among others. The Non-Recursive filters are almost everywhere in applications where phase linearity has to be ensured. FIR filters are the best choice for applications like adaptive filters, averaging filters, speech analysis, spatial beamforming (spatial filtering), and multirate signal processing, among others.
In this paper, methods like the Windows and the Bilinear Transformation method have been used to design FIR and IIR digital filters. The design approaches for the case of 2-D IIR filters are based on (a) appropriate 1-D filters and on (b) appropriate optimization techniques [6][7][8][9][10][11].

Finite Impulse Response Filters and Infinite Impulse Response Filters
Finite impulse response (FIR) filters and infinite impulse response (IIR) filters are broadly used in signal processing studies and industrial applications. The FIR filter is a filter whose impulse response has a finite duration as a result of settling to zero in finite time. On the other hand, the impulse response of the IIR filter has aninfinite duration due to the existence of a feedback in the filter [1,2].
The aforementioned filters can be categorized with respect to the frequency range which can pass through them (lowpass, highpass, bandpass and bandstop filters). The ideal frequency response D(ω) for the cases of lowpass, highpass, bandpass and bandstop filters is presented in Figure 1. In the next sections, we describe methods used to design FIR and IIR filters. More specifically, the transfer functions for some filters of special importance e.g., highpass filters and lowpass filters have been studied and have shown their dependence on system parameters (frequency and attenuation, among others). etry 2021, 13, x FOR PEER REVIEW 2 of 10 design FIR and IIR filters. More specifically, the transfer functions for some filters of special importance e.g., highpass filters and lowpass filters have been studied and have shown their dependence on system parameters (frequency and attenuation, among others).

FIR Filters
The Window method, the Kaiser Window method, the Frequency Sampling method, the Weighted least squares design and the Parks-McClellan method, among other methods [1,2], are the most commonly used methods to design digital FIR filters. The Window methods (Ideal filters, Rectangular Window and Hamming Window [1]) are the simplest methods for designing FIR digital filters. Here, the design of FIR with simple frequency response shapes filters is presented. The ideal frequency response ) ( D ω is periodic in ω with period π 2 as shown in Figure 1. The Discrete-Time Fourier Transform (DTFT) and the inverse DTFT relationships are used to estimate the impulse response After some algebra, the final form of the impulse response is and, as a result, the impulse responses for the ideal FIR filters are given as

FIR Filters
The Window method, the Kaiser Window method, the Frequency Sampling method, the Weighted least squares design and the Parks-McClellan method, among other methods [1,2], are the most commonly used methods to design digital FIR filters. The Window methods (Ideal filters, Rectangular Window and Hamming Window [1]) are the simplest methods for designing FIR digital filters. Here, the design of FIR with simple frequency response shapes filters is presented. The ideal frequency response D(ω) is periodic in ω with period 2π as shown in Figure 1. The Discrete-Time Fourier Transform (DTFT) and the inverse DTFT relationships are used to estimate the impulse response d = (k) as After some algebra, the final form of the impulse response is and, as a result, the impulse responses for the ideal FIR filters are given as It is worth mentioning that for the same cutoff frequencies the lowpass/highpass filters and bandpass/bandstop filters are complementary [1], which can be useful for graphic equalizers and loudspeaker cross-over networks.

IIR Filters
The bilinear transformation method is commonly used to design IIR digital filters. This method maps the digital filter into an equivalent analog filter, which can be designed by using one of the well-developed analog filter design methods, such as Butterworth, Chebyshev, or elliptic filter designs. Considering a map of the form where "s" and "z" present the planes of analog filter and digital filter, respectively, the bilinear transformation can be written as with s = jΩ and z = e jω (ω and Ω are the digital frequency and the equivalent analog frequency, respectively). The digital frequency and the analog frequency are connected via the following relation Here, we present the transfer function of the first-order lowpass filter. The general form of the transfer function is written as The final form of the transfer function for a first-order lowpass filter and the appropriate coefficients are given as For the case of first-order highpass digital filters, the transfer function is given as Using the bilinear transformation [1] the transfer function gets the form where the coefficients have the form Example 1. Let us consider a lowpass filter operating at 10 kHz, with G 2 c = 0.5 (3-dB frequency is 1 kHz).
The other coefficients in Equation (8) Following the same procedure, for the case of G 2 c = 0.9, the transfer function is given by the following form The magnitude response of the designed filters (lowpass and highpass filters) are presented in Figures 2 and 3, respectively. As it is shown, the transfer function for both the first-order lowpass and the first-order highpass filters depends strongly on the parameters ω c and G 2 c .

Example 2.
Let us consider a digital highpass filter operating at 10 kHz, with G 2 c = 0.5 (3-dB frequency is 1 kHz). Using the Equations (11) and (12) and the considering ω c = 0.2π, the transfer function is given as The transfer function for the case of G 2 c = 0.9 is written as In Figure 4, we present the frequency dependence of the transfer function for lowpass and highpass digital filters for different cutoff frequencies and G 2 c . It seems that the transfer function changes drastically by increasing the factor G 2 c .
Symmetry 2021, 13, x FOR PEER REVIEW 6 of 10 In Figure 4, we present the frequency dependence of the transfer function for lowpass and highpass digital filters for different cutoff frequencies and
Using the trigonometric property sin 2 (ϕ) = 1−cos(ϕ) 2 and considering a zero-phase filter, the transfer function can be written as Finally, the function gets the form The Bounded Input Bounded Output Filter (BIBO) stability of the last function can be proven easily by taking into account that the 2-D system is a non-casual system. As a result, the necessary and sufficient condition is The function B(z −1 1 , z −1 2 ) can be proven to be different from zero. Considering z −1 i = e jθ i with i = 1, 2, we get the following form which is always different from zero. Equations (15) and (18) could be extended to where ε > 0.

Design of 2-D Filters Using Optimization Techniques
Considering the 2-D IIR filter, the transfer function could get the following form The filter design demands the minimization of the following function M d (ω 1 , ω 2 ) is the desired amplitude response of the designed 2-D filter and ω 1 = π N 1 n 1 , ω 2 = π N 2 n 2 with p = 2 or 4. In order to design the filter, we have to minimize the following function subject to the constraints.
In the last decades, many methods have been proposed for constraint optimization problems related to engineering applications. Among others, techniques based on genetic algorithms [6][7][8][9][10], Particle Swarm Optimization simulated annealing [11], Ant Colony Optimization [12] or even methods that utilize Artificial Neural Networks [13] are some of the most commonly used methods which have been employed to solve constraint optimization problems. Furthermore, software packages (such as PyOpt, a Python-based Object-Oriented Framework for Nonlinear Constrained Optimization [14], the Grey Wolf Optimizer (GWO) algorithm [15], which mimics the leadership hierarchy and hunting mechanism of grey wolves in nature, etc.) have been developed for solving constraint optimization problems.

Conclusions
In this paper, transformations for designing FIR and IIR digital filters have been presented. Some of the most commonly used methods to describe the lowpass/highpass 1-D and 2-D filters have been employed. Some numerical examples illustrate the validity and usefulness of the proposed transformations for the transfer functions of the aforementioned filters.Furthermore, using a direct design of 2-D filters from appropriate 1-D functions can be used to derive the transfer functions of highpass, bandstop and bandpass noncausal 2-D IIR filters. Lastly, we summarize some of the most commonly used constraint optimization methods to provide general transformations for designing 2-D IIR filters.