4
IWSSIP 2010 - 17th International Conference on Systems, Signals and Image Processing 53 Novel Design of Equiripple Half-Band FIR Filters Pavel Zahradnik, Miroslav Vlcek, Boris Simak Dept. of Communication Engineering, Dept. of Transportation Sciences Czech Technical University in Prague Prague, Czech Republic [email protected], [email protected], [email protected] Abstract—A novel design procedure of equiripple half- band FIR filters is developed. Solution of the approximation problem in terms of generating function and zero phase transfer function for the equiripple half- band FIR filter is presented. The equiripple half-band FIR filters are optimal in the Chebyshev sense. The generating function for the equiripple half-band FIR filter is presented. The closed form solution provides an efficient computation of the impulse response of the filter. One example is included. Keywords-FIR filter, half-band filter, equiripple approximation, optimal filter. I. INTRODUCTION Half-band (HB) filters are fundamental building blocks in multirate signal processing. They are used e.g. in filter banks and in compression techniques. The only available method for designing of equiripple (ER) HB FIR filters is based on the numerical McClellan - Parks program [1]. It is usually combined with a clever "Trick" [2]. Besides this, some design methods are available for almost ER HB FIR filters, e.g. [3], [4]. No general non- numerical design of an ER HB FIR filter was found in the references. In our paper we are primarily concerned with the ER approximation of HB FIR filters and with the related non-numerical design procedure suitable for practical design of ER HB FIR filters. We present the generating function and the zero phase transfer function of the ER HB FIR filter. These functions give an insight into the nature of this approximation problem. Based on the differential equation for the Chebyshev polynomials of the second kind, we have derived formulas for an effective evaluation of the coefficients of the impulse response. We present an approximating degree equation that is useful in practical filter design. The advantage of the proposed approach over the numerical design procedures consists in the fact that the coefficients of the impulse response are evaluated by formulas. Hence the speed of the design is deterministic. II. IMPULSE RESPONSE, TRANSFER FUNCTION AND ZERO PHASE TRANSFER FUNCTION An HB filter is specified by the minimal passband frequency T p ω (or maximal stopband frequency T s ω ) and by the minimal attenuation in the stopband s a [dB] (or maximal attenuation in the passband p a [dB]). The antisymmetric behavior of its frequency response implies the relations T T p s ω π ω - = and 1 10 10 05 . 0 05 . 0 = + s p a a . The goal in the filter design is to get the minimum filter length N satisfying the filter specification and to evaluate the coefficients of the impulse response of the filter. We assume the impulse response ) (k h with odd length 1 ) 1 2 ( 2 + + = n N coefficients and with even symmetry ) 1 ( ) ( k N h k h - - = . The impulse response of the HB FIR filter contains n 2 zero coefficients as follows . ... 0 ), 1 2 ( )) 1 2 ( 1 2 ( 2 ... 1 , 0 ) 2 ( ) 2 1 2 ( 2 5 . 0 ) 0 ( ) 1 2 ( n k k a k n h n k k a k n h a n h = + = + ± + = = = ± + = = + (1) The transfer function of the HB FIR filter is + + = = + + - n k k n T k a z z H 0 1 2 ) 1 2 ( ) ( ) 1 2 ( 2 1 ) ( ω (2) where ) ( w T k is Chebyshev polynomials of the first kind. The frequency response ) ( T j e H ω of the HB FIR filter is ) (cos ) ( ) 1 2 ( T Q e e H T n j T j ω ω ω + - = (3) where ) ( w Q is a polynomial in the variable 2 / ) ( 1 - + = z z w which on the unit circle reduces to a real valued zero phase transfer function ) ( w Q of the real argument ) cos( T w ω = . III. GENERATING POLYNOMIAL AND ZERO PHASE TRANSFER FUNCTION OF AN ER HB FIR FILTER The generating polynomial of an ER HB FIR filter is related to the generating polynomial of the almost ER HB FIR filter presented in [4]. Based on our experiments conducted in [4], we have found that the generating polynomial ) ( w G (Fig.1) of the ER HB FIR filter is obtained by weighting of Chebyshev polynomials in the generating polynomial of the almost ER HB FIR filter, namely

Novel Design of Equiripple Half-Band FIR Filters

  • Upload
    others

  • View
    5

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Novel Design of Equiripple Half-Band FIR Filters

IWSSIP 2010 - 17th International Conference on Systems, Signals and Image Processing

53

Novel Design of Equiripple Half-Band FIR

Filters

Pavel Zahradnik, Miroslav Vlcek, Boris Simak

Dept. of Communication Engineering, Dept. of Transportation Sciences

Czech Technical University in Prague

Prague, Czech Republic

[email protected], [email protected], [email protected]

Abstract—A novel design procedure of equiripple half-

band FIR filters is developed. Solution of the

approximation problem in terms of generating function

and zero phase transfer function for the equiripple half-

band FIR filter is presented. The equiripple half-band

FIR filters are optimal in the Chebyshev sense. The

generating function for the equiripple half-band FIR

filter is presented. The closed form solution provides an

efficient computation of the impulse response of the

filter. One example is included.

Keywords-FIR filter, half-band filter, equiripple

approximation, optimal filter.

I. INTRODUCTION

Half-band (HB) filters are fundamental building blocks in multirate signal processing. They are used e.g. in filter banks and in compression techniques. The only available method for designing of equiripple (ER) HB FIR filters is based on the numerical McClellan - Parks program [1]. It is usually combined with a clever "Trick" [2]. Besides this, some design methods are available for almost ER HB FIR filters, e.g. [3], [4]. No general non-numerical design of an ER HB FIR filter was found in the references. In our paper we are primarily concerned with the ER approximation of HB FIR filters and with the related non-numerical design procedure suitable for practical design of ER HB FIR filters. We present the generating function and the zero phase transfer function of the ER HB FIR filter. These functions give an insight into the nature of this approximation problem. Based on the differential equation for the Chebyshev polynomials of the second kind, we have derived formulas for an effective evaluation of the coefficients of the impulse response. We present an approximating degree equation that is useful in practical filter design. The advantage of the proposed approach over the numerical design procedures consists in the fact that the coefficients of the impulse response are evaluated by formulas. Hence the speed of the design is deterministic.

II. IMPULSE RESPONSE, TRANSFER FUNCTION AND

ZERO PHASE TRANSFER FUNCTION

An HB filter is specified by the minimal passband

frequency Tpω (or maximal stopband frequency Tsω )

and by the minimal attenuation in the stopband sa [dB]

(or maximal attenuation in the passband pa [dB]). The

antisymmetric behavior of its frequency response implies

the relations TT ps ωπω −= and 1101005.005.0

=+ sp aa . The

goal in the filter design is to get the minimum filter

length N satisfying the filter specification and to

evaluate the coefficients of the impulse response of the filter. We assume the impulse response )(kh with odd

length 1)12(2 ++= nN coefficients and with even

symmetry )1()( kNhkh −−= . The impulse response of

the HB FIR filter contains n2 zero coefficients as

follows

....0),12())12(12(2

...1,0)2()212(2

5.0)0()12(

nkkaknh

nkkaknh

anh

=+=+±+

===±+

==+

(1)

The transfer function of the HB FIR filter is

++= ∑

=

+

+−n

k

k

n TkazzH0

12

)12( )()12(2

1)( ω (2)

where )(wTk is Chebyshev polynomials of the first kind.

The frequency response )( TjeH

ω of the HB FIR filter is

)(cos)( )12( TQeeH TnjTj ωωω +−= (3)

where )(wQ is a polynomial in the variable

2/)( 1−+= zzw which on the unit circle reduces to a

real valued zero phase transfer function )(wQ of the real

argument )cos( Tw ω= .

III. GENERATING POLYNOMIAL AND ZERO PHASE

TRANSFER FUNCTION OF AN ER HB FIR FILTER

The generating polynomial of an ER HB FIR filter is

related to the generating polynomial of the almost ER

HB FIR filter presented in [4]. Based on our

experiments conducted in [4], we have found that the

generating polynomial )(wG (Fig.1) of the ER HB FIR

filter is obtained by weighting of Chebyshev

polynomials in the generating polynomial of the almost

ER HB FIR filter, namely

Page 2: Novel Design of Equiripple Half-Band FIR Filters

IWSSIP 2010 - 17th International Conference on Systems, Signals and Image Processing

54

Figure 1. Generating polynomial )(wG for n=20,

03922835.0=′κ , A=1.08532371 and B=0.95360863

Figure 2. Zero phase transfer function )(wQ for n=20,

03922835.0=′κ , A=1.08532371, B=0.95360863 and 55091994.0~

′−

′−−+

′−

′−−= − 2

22

12

22

1

12

1

12)(

κ

κ

κ

κ wBU

wAUwG nn

(4)

where )(xUnand )(1 xU n−

are Chebyshev polynomials of

the second kind and A, B, κ ′ are real numbers. The

zero phase transfer function )(wQ (Fig. 2) is related to

the generating polynomial

∫Ν+= dwwGwQ )(~

1

2

1)( (5)

where the norming factor Ν~ is given by (17). Both the

generating polynomial )(wG and the zero phase transfer

function )(wQ show the nature of the approximation of

an ER HB FIR filter.

IV. DIFFERENTIAL EQUATION AND IMPULSE

RESPONSE OF AN ER HB FIR FILTER

The Chebyshev polynomial of the second kind

)(wU xfulfils the differential equation

.0)()2()(

3)(

)1(2

22 =++−− xUnn

dx

xdUx

dx

xUdx n

nn (6)

Using substitution

′−

′−−=

2

22

1

12

κ

κwx (7)

we get the differential equation (6) in the form

[ ]

.0)()2(4

)()1(2)1(

)(3

)()1()(

3

2222

2

2222

=++

−+−′+

−−′−

wUnnw

dw

wdUwww

dw

wdUw

dw

wUdwww

n

n

nn

κ

κ

(8)

Based on the differential equation (8), we have derived the non-numerical procedure for the evaluation of the

impulse response )(khk corresponding to polynomial

corresponding to polynomial )(~

wU n

.1

12)(

~2

22

dww

UwU nn

′−

′−−= ∫ κ

κ (9)

This procedure is summarized in Tab.1. The impulse

response )(kh of the ER HB FIR filter is

).(~)(~2

1)( 1 kh

Bkh

Akh nn −

Ν+

Ν+= (10)

The non-numerical evaluation of the impulse response

)(kh is essential in the practical filter design.

V. DEGREE OF AN ER HB FIR FILTER

The exact degree formula is not available. In the

practical filter design, the degree n can be obtained

with excellent accuracy from the specified minimal

passband frequency Tpω and from the minimal

attenuation in the stopband sa [dB] using the

approximating degree formula

.13196871.2954155181.18

64775300.3318840664.18][

+−≥

T

TdBan

p

ps

ω

ω (11)

Figure 3. Emperical dependence of sa [dB] on πω /Tpand n

Page 3: Novel Design of Equiripple Half-Band FIR Filters

IWSSIP 2010 - 17th International Conference on Systems, Signals and Image Processing

55

TABLE I. ALGORITHM FOR THE EVALUATION OF THE COEFFICIENTS )(khn

The exact relation between the minimal attenuation in

the stopband sa [dB], the minimal passband frequency

Tpω and the degree n were obtained experimentally.

It is shown in Fig.3. Equation (11) was obtained by the

approximation of exact experimental values in Fig.3.

VI. SECONDARY VALUES OF THE ER HB FIR FILTER

The secondary real values κ ′ , A and B can be

obtained from the specified passband frequency Tpω

and from the degree n of the generating polynomial. In

practical filter design, the approximating formulas

37221484.001927560.1

00665857.057111377.1

+−

+−=′

n

nTn pωκ (12)

n

nnA

73512298.001701407.1

24760314.9036823440.001525753.0

++

++= κ

(13)

n

nnB

72759508.002999650.1

75145813.535418408.100233667.0

−+

+−= κ

(14)

obtained experimentally provide excellent accuracy.

Further, the exact values κ ′ , A and B can be obtained

numerically (e.g. using the Matlab function fminsearch)

by satisfying the equality (see Fig.4)

=.)(

)1(

)(

01 evenisnifwQ

oddisnifQ

wQ p (15)

The value

12cos)1(

222

01+

′−+′=n

κκ (16)

was introduced in [4]. Relation (15) guarantees the

equiriple behaviour of the generating polynomial )(wQ .

VII. DESIGN OF THE ER HB FIR FILTER

The design procedure is as follows:

• Specify the ER HB FIR filter by the minimal

passband frequency Tpω and by the minimal

attenuation in the stopband sa [dB].

• Calculate the integer degree n of the generating

polynomial (11).

• Calculate the real values κ ′ (12), A (13) and B (14).

• Evaluate the partial impulse responses )(khnand

)(1 khn− (Tab.1).

• Evaluate the final impulse response )(kh (10)

where the real norming factor Ν~ is

[ ]

[ ]

+

+

.)(~

)(~

2

)1(~

)1(~

2~

01101

1

oddisnifUBUA

evenisnifUBUA

nn

nn

ωω

(17)

VIII. EXAMPLE

Design the ER HB FIR filter specified by the minimal

passband frequency πω 45.0=Tp and by the minimal

attenuation in the stopband dBas 120−= .

We get 393856.38 →=n (11), 15571103.0=′κ

(12), A = 1.17117396 (13), B = 0.83763199 (14) and Ν~ =

-2747.96038544 (17). The impulse response )(kh

(Tab.2) with the length N=159 coefficients is evaluated using Tab.1 and (10). The actual values

πω 4502.0=Tactp and 91.120−=acta dB satisfy the filter

specification. The amplitude frequency response

)(log20 jwTeH [dB] of the filter is shown in Fig.5. The

detailed view of its passband is shown in Fig.6. For the

specified values πω 45.0=Tp and N=159, the compa-

rative numerical design based on the "Trick" [2]

Page 4: Novel Design of Equiripple Half-Band FIR Filters

IWSSIP 2010 - 17th International Conference on Systems, Signals and Image Processing

56

TABLE II. COEFFICIENTS OF THE IMPULSE RESPONSE

Figure 4. )(ωQ for odd and even n

combined with the Remez algorithm using the Matlab function firpm results in the slightly unsatisfactory min-

imal passband frequency ππω 45.044922001.0 <=Tactp

and consequently in a slightly better minimal attenuation

in the stopband 29066608.123−=acta [dB].

Figure 5. Amplitude frequency response )(log20jwT

eH

Figure 6. Passband of the filter

IX. CONCLUSIONS

This paper has presented the equiripple approximation of halfband FIR filters and a novel efficient non-numerical method for their design.

ACKNOWLEDGEMENTS

This work was supported by the grant No.

MSM6840770014, Ministry of Education, Czech

Republic.

REFERENCES

[1] J.H. McClellan, T. W. Parks, L. R. Rabiner, A Computer Program for Designing Optimum FIR Linear Phase Digital Filters, IEEE Trans. Audio Electroacoust, Vol. AU - 21, Dec. 1973, pp. 506 - 526.

[2] P. P. Vaidyanathan, T. Q. Nguyen, A "TRICK" for the Design of FIR Half-Band Filters, IEEE Transactions on Circuits and Systems, Vol. CAS - 34, No. 3, March 1987, pp. 297 - 300.

[3] P. N. Wilson, H. J. Orchard, A Design Method for Half-Band FIR Filters, IEEE Transactions on Circuits and Systems - I: Fundamental Theory and Applications, Vol. CAS - 46, No. 1, January 1999, pp. 95 - 101.

[4] P. Zahradnik, M. Vlcek, R. Unbehauen, Almost Equiripple FIR Half-Band Filters, IEEE Transactions on Circuits and Systems - I: Fundamental Theory and Applications, Vol. CAS - 46, No. 6, June 1999, pp. 744 – 748.