CN117200746A - Linear phase IIR digital filter design method - Google Patents

Linear phase IIR digital filter design method Download PDF

Info

Publication number
CN117200746A
CN117200746A CN202311036435.7A CN202311036435A CN117200746A CN 117200746 A CN117200746 A CN 117200746A CN 202311036435 A CN202311036435 A CN 202311036435A CN 117200746 A CN117200746 A CN 117200746A
Authority
CN
China
Prior art keywords
filter
analog
digital filter
low
linear
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202311036435.7A
Other languages
Chinese (zh)
Inventor
刘连胜
谷广宇
彭宇
刘大同
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Harbin Institute of Technology
Original Assignee
Harbin Institute of Technology
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Harbin Institute of Technology filed Critical Harbin Institute of Technology
Priority to CN202311036435.7A priority Critical patent/CN117200746A/en
Publication of CN117200746A publication Critical patent/CN117200746A/en
Pending legal-status Critical Current

Links

Abstract

A design method of an IIR digital filter with a linear phase relates to the technical field of filters. In order to solve the technical problems that in the prior art, although the MATLAB software platform provides library functions which are realized in a related way, the MATLAB software platform cannot be directly transplanted, and the cross-platform or software use of a user is inconvenient, the technical scheme provided by the invention is as follows: a design method of an IIR digital filter with linear phase, the method comprises the following steps: collecting an analog low-pass filter; performing frequency conversion on the low-pass filter to obtain an analog filter with expected frequency characteristics; in the analog filter, the continuous time variable of the s plane is converted into the discrete variable of the z plane, so as to obtain the digital filter. And converting the analog filter into a digital filter to obtain coefficients of the digital filter, and determining a transfer function of the digital filter according to the coefficients of the filter. The method is suitable for the work with low resource utilization rate requirements, and the filtered signals are not distorted.

Description

Linear phase IIR digital filter design method
Technical Field
Relates to the technical field of filters.
Background
To ensure high fidelity and stability of the input signal under test, a filter is typically required to filter out noise and to ensure that the output signal source is not distorted. For filter selection, key considerations include linear phase characteristics, filter type (IIR or FIR), stability, frequency selection characteristics, delay, and computation speed, among others.
The filters can be classified into a IIR (Infinite Impulse Response) filter and a FIR (Finite Impulse Response) filter according to whether the impulse response length is limited. The FIR filter has linear phase characteristics, and the unit impulse response length is limited, so that the FIR filter is of a non-recursive structure, has high stability and is suitable for occasions where distortion of a filtered signal is not expected. The IIR filter adopts a recursive structure and is unstable, but the frequency selection characteristic of the IIR filter is relatively higher, so that the IIR filter is suitable for application of miniaturized design. In the case of the same design index, the required order of the FIR filter is 5 to 10 times that of the IIR filter, i.e., more memory cells and a larger signal delay are required. However, the IIR filter is fast in calculation speed and can operate in real time. The IIR digital filter is selected to filter out interfering signals in view of reduced system usage resources and low complexity of implementation.
Common IIR digital filters include Butterworth (Butterworth) filters, chebyshev (Chebyshev) filters, elliptic (Elliptical) filters, and Bessel (Bessel) filters. The Bessel filter has a maximum flat group delay and linear phase characteristics within the passband, and slowly drops in the transition band, relative to other IIR filters. Furthermore, the step response of the Bessel filter has little overshoot and is therefore widely used in audio equipment to ensure the stability and accuracy of the signal source.
The design method of the IIR digital filter commonly used at present is mainly realized by an analog filter. The analog filter has very mature realization technology and simple and strict design formula and tabular design parameters, so the design is convenient and accurate. However, compared to other IIR digital filters, relatively little literature and literature is available about the design methods of Bessel digital filters. Lack of systematic and complete elucidation makes it difficult for researchers to implement the design of Bessel digital filters.
To achieve this objective, a filter may be optionally used to filter out noise and ensure that the output signal source is not distorted. In selecting the filter, it is conceivable to use an IIR digital filter, of which Bessel filter is a common choice. However, the literature and teaching materials on the design method of the Bessel filter are relatively small, and more research is required to perfect the design method. In general, the characteristics and requirements of different filter types need to be fully considered to meet the requirements in practical applications.
While MATLAB software platforms provide library functions for related implementations, it is not straightforward for C/c++ and FPGA designers to migrate, and it is inconvenient for users to use across platforms or software.
Disclosure of Invention
In order to solve the technical problems that in the prior art, although MATLAB software platforms provide library functions which are realized in a related way, C/C++ and FPGA designers cannot be transplanted directly, and cross-platform or software use of users is inconvenient, the technical scheme provided by the invention is as follows:
a method of designing a linear-phase IIR digital filter, the method comprising:
collecting an analog low-pass filter;
a step of performing frequency conversion on the low-pass filter to obtain an analog filter having a desired frequency characteristic;
and converting the continuous time variable of the s plane into the discrete variable of the z plane in the analog filter to obtain a digital filter.
Further, a preferred embodiment is provided, wherein the low pass filter is obtained by simulating a prototype filter.
Further, a preferred embodiment is provided wherein the analog prototype filter is a frequency normalized Bessel low pass filter.
Further, a preferred embodiment is provided, wherein the analog prototype filter is a low pass filter with a cut-off frequency of 1 rad/s.
Further, there is provided a preferred embodiment, the low pass filter specifically passing:
determining coefficients of the analog prototype filter from the filter order and the cutoff frequency index parameter;
a step of frequency-transforming the transfer function of the analog prototype filter to obtain coefficients of the analog low-pass filter;
obtained.
Further, a preferred embodiment is provided wherein the conversion of the discrete variable is achieved by a bilinear transformation method.
Further, there is provided a preferred embodiment in which the analog filter is converted into the digital filter by using a bilinear transformation method to obtain coefficients of the digital filter, and the transfer function of the digital filter is determined based on the coefficients of the filter.
Based on the same inventive concept, the invention also provides a linear-phase IIR digital filter design device, which comprises:
a module for collecting an analog low pass filter;
a module for performing frequency conversion on the low-pass filter to obtain an analog filter with expected frequency characteristics;
and converting the continuous time variable of the s plane into the discrete variable of the z plane in the analog filter to obtain a module of the digital filter.
Based on the same inventive concept, the present invention also provides a computer storage medium for storing a computer program, which when read by a computer, performs the method.
Based on the same inventive concept, the present invention also provides a computer comprising a processor and a storage medium, the computer performing the method when the processor reads a computer program stored in the storage medium.
Compared with the prior art, the technical scheme provided by the invention has the following advantages:
the invention provides a design method of an IIR digital filter with a linear phase, provides design steps and implementation methods of the IIR digital filter with the linear phase, and has good portability;
the design method of the linear-phase IIR digital filter provided by the invention can realize the Bessel digital low-pass filter with linear phase characteristics;
the design method of the linear-phase IIR digital filter provided by the invention is convenient for developers to realize the function on other platforms, and has portability and feasibility;
the design method of the linear-phase IIR digital filter is suitable for being applied to the work with low resource utilization rate requirements, wherein the work does not distort the filtered signal.
Drawings
Fig. 1 is a block flow diagram of a method for designing a linear-phase IIR digital filter according to a first embodiment;
fig. 2 is a flowchart of a method for designing a linear-phase IIR digital filter according to a first embodiment.
Detailed Description
In order to make the advantages and benefits of the technical solution provided by the present invention more apparent, the technical solution provided by the present invention will now be described in further detail with reference to the accompanying drawings, in which:
an embodiment one, which will be described with reference to fig. 1 and 2, provides a method for designing an IIR digital filter with a linear phase, the method including:
collecting an analog low-pass filter;
a step of performing frequency conversion on the low-pass filter to obtain an analog filter having a desired frequency characteristic;
and converting the continuous time variable of the s plane into the discrete variable of the z plane in the analog filter to obtain a digital filter.
In particular, the method comprises the steps of,
the method provided by the embodiment comprises the following steps:
determining coefficient a of the analog prototype filter by filter order and cutoff frequency index parameters s And b s
Frequency transforming the transfer function of the analog prototype filter to obtain the coefficient a of the analog low-pass filter sk And b sk
Converting the analog filter into a digital filter by using a bilinear transformation method to obtain a coefficient a of the digital filter z And b z
The transfer function H (z) of the digital filter is determined according to the coefficients of the filter, and the design is finished.
The whole flow is as follows:
the method consists of three parts, namely an analog prototype filter, an analog frequency conversion and a filter mapping. Designing an analogue prototype filter according to the Bessel filter design criteria, i.e. designing a frequency-normalised analogue prototype filter with a transfer function of H a (s). The analog prototype filter is then frequency transformed into an analog filter having the desired frequency characteristics, resulting in a transfer function H(s). And finally, converting the s plane into the z plane by using a filter mapping method to obtain the transfer function H (z) of the digital filter.
Bessel filter performance index is usually two index parameters of the order and the cut-off frequency of a filter, which are different from other IIR filters, the order of the filter cannot be calculated through a formula, and the filter can be obtained only through searching according to the existing design curve through a given performance index.
Analog prototype filter
In order to meet the amplitude transfer function distortion free at low frequency band, the general expression of the Bessel low pass filter is:
wherein F is n (s) is a Bessel function with a recursive series, b 0 The coefficients representing the filter numerator, a representing the coefficients of the filter denominator, and s representing the laplace operator.
F n The expression of(s) is shown in formula (2):
F n (s)=(2n-1)F n-1 (s)+s 2 F n-2 (s) (2)
wherein n represents the filter order, F n-1 (s) represents an n-1 order Bessel polynomial, F n-2 (s) represents an n-2 order bezier polynomial;
F 0 (s)=1,F 1 (s)=s+1,b 0 =a 0
then the numerator and denominator coefficients of the formula (1) are normalized, i.e. divided by the coefficient b 0 Reuse ofInstead of Laplace operator s, the transfer function H of the simulated prototype filter is obtained a (s)。
Analog low pass filter
The analog prototype filter is a low-pass filter having a cut-off frequency of 1rad/s, and frequency conversion can be performed in the analog domain to obtain an analog filter having arbitrary frequency characteristics (low-pass, high-pass, band-pass, and band-stop). The usual analog frequency conversion is shown in table 1.
Table 1 common analog frequency conversion
Wherein Ω 0 Representing the passband center frequency of the filter, B is the bandwidth of the filter. And their expression is shown in formula (4).
The low-pass filter is the basis of other frequency filters, so the invention mainly deals with the implementation of the low-pass filter. Expression for frequency conversion of low pass filter in table 1Replacement H a The variable s in(s) allows the transfer function H(s) of the analog low-pass filter to be obtained.
Digital low pass filter
Since analog filters can only process analog signals, most of the transmitted and processed signals of current systems or instruments are discrete. It is therefore also necessary to design a digital filter. Whereas the Bessel digital low pass filter may be implemented by an analog low pass filter map. There are two main mapping methods in common use: impulse response invariant and bilinear transformation. The impulse response invariant method obtains the unit impulse response of the corresponding digital filter by equally sampling the unit impulse response of the analog filter. Which strives to keep the envelope of the unit impulse response of the digital filter the same as the unit impulse response of the analog filter. However, the frequency response of the analog filter is strictly limited, otherwise, the frequency response of the digital filter has a certain degree of aliasing, and the bilinear transformation method can overcome the frequency spectrum aliasing phenomenon of the impulse response invariant method. The bilinear transformation method is a method of mapping a function on the complex plane of a certain variable onto the complex plane of another variable, i.e. converting the continuous time variable s of the s-plane into a discrete variable z on the z-plane. The conversion relationship between the two planes is shown in formula (5).
Where T represents the sampling period and z represents the complex variable.
And the relationship between the analog frequency Ω and the digital frequency w is shown in expression (6).
Substituting the formula (5) into H(s) to obtain the transfer function H (z) of the digital filter.
Let z=e jw Substituting into H (z) to obtain the amplitude-frequency response |H (e) jw ) Phase-frequency response and phase-frequency responseThe best feature of the Bessel filter is that it has a maximum flat group delay in the passband, i.e. the group delay is constant. The group delay τ (w) is represented by formula (7).
Wherein d represents a derivative.
The group delay is a negative value of the slope of the phase frequency characteristic. If the group delay is a constant, the phase-frequency response is linear with frequency. Therefore, the phase of the output signal and the phase of the input signal passing through the filter are kept unchanged, and no distortion occurs.
The present embodiment is a design for realizing an IIR digital filter having a linear phase. Library functions of MATLAB software are not directly called, and a researcher can conveniently transplant design codes.
The method provided by the embodiment designs the digital filter by utilizing the theory of the analog filter, designs the corresponding analog filter according to the performance index of the given filter, and then carries out analog-digital frequency conversion on the analog filter to obtain the system function of the required digital filter.
The second embodiment and the present embodiment are further defined on the method for designing a linear-phase IIR digital filter according to the first embodiment, wherein the low-pass filter is obtained by simulating a prototype filter.
The third embodiment and the present embodiment are further defined on the method for designing a linear-phase IIR digital filter provided in the second embodiment, where the analog prototype filter is a Bessel low-pass filter subjected to frequency normalization.
The fourth embodiment is a further limitation of the method for designing a linear-phase IIR digital filter according to the second embodiment, wherein the analog prototype filter is a low-pass filter having a cut-off frequency of 1 rad/s.
The fifth embodiment is a further limitation of the method for designing a linear-phase IIR digital filter provided in the first embodiment, where the low-pass filter specifically includes:
determining coefficients of the analog prototype filter from the filter order and the cutoff frequency index parameter;
a step of frequency-transforming the transfer function of the analog prototype filter to obtain coefficients of the analog low-pass filter;
obtained.
The sixth embodiment is a further limitation of the method for designing a linear-phase IIR digital filter provided in the first embodiment, wherein the discrete variable conversion is implemented by a bilinear transformation method.
In the seventh embodiment, the present embodiment is further defined on the method for designing a linear-phase IIR digital filter provided in the sixth embodiment, wherein the analog filter is converted into the digital filter by using a bilinear transformation method, coefficients of the digital filter are obtained, and the transfer function of the digital filter is determined based on the coefficients of the filter.
An eighth embodiment provides a linear-phase IIR digital filter design apparatus, including:
a module for collecting an analog low pass filter;
a module for performing frequency conversion on the low-pass filter to obtain an analog filter with expected frequency characteristics;
and converting the continuous time variable of the s plane into the discrete variable of the z plane in the analog filter to obtain a module of the digital filter.
Embodiment nine, the present embodiment provides a computer storage medium storing a computer program that when read by a computer performs the method provided in any one of embodiments one to seven.
An embodiment ten provides a computer including a processor and a storage medium, the computer executing the method provided in any one of embodiments one to seven when the processor reads a computer program stored in the storage medium.
The technical solution provided by the present invention is described in further detail through several specific embodiments, so as to highlight the advantages and benefits of the technical solution provided by the present invention, however, the above specific embodiments are not intended to be limiting, and any reasonable modification and improvement, combination of embodiments, equivalent substitution, etc. of the present invention based on the spirit and principle of the present invention should be included in the scope of protection of the present invention.
In the description of the present invention, only the preferred embodiments of the present invention are described, and the scope of the claims of the present invention should not be limited thereby; furthermore, the descriptions of the terms "one embodiment," "some embodiments," "example," "specific example," or "some examples," etc., mean that a particular feature, structure, material, or characteristic described in connection with the embodiment or example is included in at least one embodiment or example of the present invention. In this specification, schematic representations of the above terms are not necessarily directed to the same embodiment or example. Furthermore, the particular features, structures, materials, or characteristics described may be combined in any suitable manner in any one or N embodiments or examples. Furthermore, the different embodiments or examples described in this specification and the features of the different embodiments or examples may be combined and combined by those skilled in the art without contradiction. Furthermore, the terms "first," "second," and the like, are used for descriptive purposes only and are not to be construed as indicating or implying a relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defining "a first" or "a second" may explicitly or implicitly include at least one such feature. In the description of the present invention, "N" means at least two, for example, two, three, etc., unless specifically defined otherwise. Any process or method descriptions in flow charts or otherwise described herein may be understood as representing modules, segments, or portions of code which include one or more N executable instructions for implementing specific logical functions or steps of the process, and further implementations are included within the scope of the preferred embodiment of the present invention in which functions may be executed out of order from that shown or discussed, including substantially concurrently or in reverse order, depending on the functionality involved, as would be understood by those reasonably skilled in the art of the embodiments of the present invention. Logic and/or steps represented in the flowcharts or otherwise described herein, e.g., a ordered listing of executable instructions for implementing logical functions, can be embodied in any computer-readable medium for use by or in connection with an instruction execution system, apparatus, or device, such as a computer-based system, processor-containing system, or other system that can fetch the instructions from the instruction execution system, apparatus, or device and execute the instructions. For the purposes of this description, a "computer-readable medium" can be any means that can contain, store, communicate, propagate, or transport the program for use by or in connection with the instruction execution system, apparatus, or device. More specific examples (a non-exhaustive list) of the computer-readable medium would include the following: an electrical connection (electronic device) having one or N wires, a portable computer cartridge (magnetic device), a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber device, and a portable compact disc read-only memory (CDROM). In addition, the computer readable medium may even be paper or other suitable medium on which the program is printed, as the program may be electronically captured, via, for instance, optical scanning of the paper or other medium, then compiled, interpreted or otherwise processed in a suitable manner, if necessary, and then stored in a computer memory. It is to be understood that portions of the present invention may be implemented in hardware, software, firmware, or a combination thereof. In the above-described embodiments, the N steps or methods may be implemented in software or firmware stored in a memory and executed by a suitable instruction execution system. As with the other embodiments, if implemented in hardware, may be implemented using any one or combination of the following techniques, as is well known in the art: discrete logic circuits having logic gates for implementing logic functions on data signals, application specific integrated circuits having suitable combinational logic gates, programmable Gate Arrays (PGAs), field Programmable Gate Arrays (FPGAs), and the like.
Those of ordinary skill in the art will appreciate that all or a portion of the steps carried out in the method of the above-described embodiments may be implemented by a program to instruct related hardware, where the program may be stored in a computer readable storage medium, and where the program, when executed, includes one or a combination of the steps of the method embodiments. In addition, each functional unit in the embodiments of the present invention may be integrated in one processing module, or each unit may exist alone physically, or two or more units may be integrated in one module. The integrated modules may be implemented in hardware or in software functional modules. The integrated modules may also be stored in a computer readable storage medium if implemented in the form of software functional modules and sold or used as a stand-alone product.

Claims (10)

1. A method for designing a linear-phase IIR digital filter, the method comprising:
collecting an analog low-pass filter;
a step of performing frequency conversion on the low-pass filter to obtain an analog filter having a desired frequency characteristic;
and converting the continuous time variable of the s plane into the discrete variable of the z plane in the analog filter to obtain a digital filter.
2. The method for designing a linear-phase IIR digital filter according to claim 1, wherein the low-pass filter is obtained by simulating a prototype filter.
3. The method for designing a linear-phase IIR digital filter according to claim 2, wherein the analog prototype filter is a frequency normalized Bessel low-pass filter.
4. The method for designing a linear-phase IIR digital filter according to claim 2, wherein the analog prototype filter is a low-pass filter with a cut-off frequency of 1 rad/s.
5. The method for designing a linear-phase IIR digital filter according to claim 1, wherein the low-pass filter is specifically configured by:
determining coefficients of the analog prototype filter from the filter order and the cutoff frequency index parameter;
a step of frequency-transforming the transfer function of the analog prototype filter to obtain coefficients of the analog low-pass filter;
obtained.
6. The method for designing the linear-phase IIR digital filter according to claim 1, wherein the conversion of the discrete variable is realized by a bilinear transformation method.
7. The method for designing a linear-phase IIR digital filter according to claim 6, wherein the analog filter is converted into the digital filter by using a bilinear transform method to obtain coefficients of the digital filter, and the transfer function of the digital filter is determined based on the coefficients of the filter.
8. An IIR digital filter design apparatus of linear phase, the apparatus comprising:
a module for collecting an analog low pass filter;
a module for performing frequency conversion on the low-pass filter to obtain an analog filter with expected frequency characteristics;
and converting the continuous time variable of the s plane into the discrete variable of the z plane in the analog filter to obtain a module of the digital filter.
9. Computer storage medium for storing a computer program, characterized in that, when the program is read by a computer, the computer performs the method according to any one of claims 1-7.
10. Computer comprising a processor and a storage medium, characterized in that the computer performs the method according to any of claims 1-7 when the processor reads a computer program stored in the storage medium.
CN202311036435.7A 2023-08-16 2023-08-16 Linear phase IIR digital filter design method Pending CN117200746A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311036435.7A CN117200746A (en) 2023-08-16 2023-08-16 Linear phase IIR digital filter design method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311036435.7A CN117200746A (en) 2023-08-16 2023-08-16 Linear phase IIR digital filter design method

Publications (1)

Publication Number Publication Date
CN117200746A true CN117200746A (en) 2023-12-08

Family

ID=88986026

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311036435.7A Pending CN117200746A (en) 2023-08-16 2023-08-16 Linear phase IIR digital filter design method

Country Status (1)

Country Link
CN (1) CN117200746A (en)

Similar Documents

Publication Publication Date Title
Donadio CIC filter introduction
JP2002374150A (en) Digital filter and digital-signal filtering method
CN108011615A (en) A kind of method and apparatus of signal processing
US7529788B2 (en) Digital filter design method and device, digital filter design program, and digital filter
JP2002026690A (en) Sampling speed converter and its method
JP3066241B2 (en) Digital filter and oversampling type analog / digital converter using the digital filter
Badajos et al. Reduction of audio noise with lowpass Chebyshev Type II filter simulated using GNU octave
CN117200746A (en) Linear phase IIR digital filter design method
JP2010041311A (en) Filter, and configuration system and configuration method of filter
WO2003047097A1 (en) Digital filter designing method, designing apparatus, digital filter designing program, digital filter
Vainio et al. A class of predictive analog filters for sensor signal processing and control instrumentation
Russell et al. Efficient arbitrary sampling rate conversion with recursive calculation of coefficients
EP2651033B1 (en) Filter system
Litovski et al. IIR Digital Filter Synthesis Based on Bilinear Transformation of Analog Prototypes
Mirković et al. Design of IIR digital filters with critical monotonic passband amplitude characteristic-A case study
CN102868385B (en) Digital filter capable of configuring coefficient and implementation method
Hacihabiboglu et al. Analysis of root displacement interpolation method for tunable allpass fractional-delay filters
ONYEMA et al. Deployment of A Programmed Graphic User Interface (GUI) For Analysing Digital Filters Using Matlab-Algorithm
CN114079440A (en) Smooth and fast updating method, system, medium and device of filter array
Aung et al. Design and Simulation of IIR Digital Filter Using NI LabVIEW
Jensen A new principle for an all-digital preamplifier and equalizer
Hacihabiboglu et al. Interpolated allpass fractional-delay filters using root displacement
Prokopenko et al. Usage of numerical methods for differential equations solving in digital filters synthesis
JPH10308650A (en) Filter design method and digital filter
CN107453732B (en) Signal sampling rate conversion method and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination