Sie sind auf Seite 1von 14

Signal Processing 14 (1988) 313-326 313

North-Holland

A S I M P L E A P P R O A C H T O T H E D E S I G N O F L I N E A R P H A S E FIR D I G I T A L
FILTERS W I T H V A R I A B L E C H A R A C T E R I S T I C S *

Petri JARSKE and Yrj6 NEUVO (Member EURASIP)


Department of Electrical Engineering, Tampere Universi O, of Technology, P.O. Box 527, 33101 Tampere, Finland

Sanjit K. MITRA (Member EURAS1P)


Department of Electrical and Computer Engineering, University t~f California at Santa Barbara, Santa Barbara,
CA 93106, U.S.A.

Received 18 August 1987


Revised 30 November 1987

Abstract. A class of linear phase digital filters is discussed for which the filter coefficients are simple functions of the parameters
determining the desired frequency response. In the case of lowpass or highpass flters, the 6 dB cutoff frequency is the
parameter considered here. Bandpass and bandstop filters are characterized by the center frequency and the bandwidth
measured from the 6 dB cutoff frequencies. Notch filters with a first-order zero at the notch frequency are also discussed.
The filters are variable over nearly the whole frequency range from zero to half the sampling frequency. Due to direct control
of filter coefficients, the length of the filter does not change when it is made variable.

Zusammenfassung. Eine Klasse linearphasiger Filter wird behandelt, deren Koeffizienten in einfacher Weise von den Para-
metern des Wunschfrequenzgangs abh~ingen. Im Falle von Tief- und Hochpal3filtern ist die 6 dB-Grenzfrequenz der betretIende
Parameter. Bandpaf3- und Bandsperr-Filter werden durch die Mittenfrequenz und die Breite des Bandes zwischen den
6 dB-Eckfrequenzen beschrieben. Kerbfilter mit einer einfachen Nullstelle bei der Kerbfrequenz werden ebenfalls diskutiert.
Die Filter k5nnen nahezu im gesamten Frequenzbereich zwischen 0 und der halben Abtastfrequenz eingestellt werden.
Aufgrund der unmittelbaren Steuerung der Filterkoeffizienten/indert sich der Filtergrad nicht dadurch, dab die Filter einstellbar
gemacht werden.

R6sum6. On 6tudie une classe des filtres fl phase lin6aire pour laquelle les coefficients du filtre sont des fonctions simples
des param~tres d6terminant la r6ponse fr6quentielle d6sir6e. Dans le cas des filtres passe-bas ou passe-haut, le param~tre
consid6r6 iciest la fr6quence de coupure fi 6 dB. Les filtres coupe-bande ou passe-hande sont caract6ris6s par les fr6quences
centrales et les largeurs de bandes mesur6es fi partir des fr6quences de coupure/~ 6 dB. Les filtres coupe-bande fi bande tr~s
6troite ('notch') avec un z6ro d'orde un /t la fr6quence de coupure sont 6galement discut6s. Les filtres sont variables sur
presque toute la bande de fr6quence de z6ro ~ la moiti6 de la fr6quence d'6chantillonnage. A cause du contr61e direct des
coefficients du filtre, la Iongueur du filtre ne change pas quand il est rendu variable.

Keywords. Variable filter, finite impulse response filter.

I. Introduction during its operation. Especially in real time filter-


ing this requires that the filter coeiticients can
In many practical applications of digital filter- be updated without computationally intensive
ing, it is desirable to change the filter characteristics optimization procedures. Oppenheim et al. [13]
proposed a transformation method for linear phase
* This work was supported in part by the Academy of Fin- variable cutoff digital filters. The transformation
land, the Cultural Foundation of Finland, and in part by a
University of California M I C R O Grant with matching support applied to the zero phase response of the filter
from the lntel Corporation and Rockwell Corporation. varies the cutoff frequency by distorting the

0165-1684/88/$3.50 (~ 1988, Elsevier Science Publishers B.V. (North-Holland)


314 P. Jarske, Y. Neuvo, S.K. Mitra / Variable FIR filters

frequency axis, while preserving the frequency Any linear phase causal FIR filter of length
characteristics. This approach has been further 2 N + 1 can be expressed as
developed [2, 3] and extended to bandpass filters
h ( n ) = ho(n - N ) , (1)
[ 1, 5]. Transformation methods generally increase
the filter length, except in the case of the first-order where h ( n ) is the impulse response of the causal
transformation. Furthermore, these methods lead filter and ho(n) is the impulse response of a zero
to special filter structures which are, of course, phase FIR filter which is symmetric with respect
acceptable in some applications. There are situ- to n = 0. The transfer function of the linear phase
ations where a direct form implementation is filter can be expressed in the form [14]
desired. Although it is possible to represent the
H ( z ) = z NHo(z), (2)
transformed filter in the direct form, it is generally
a difficult task. where Ho(z) is the transfer function of the zero
In this paper, we take another approach which phase filter and the frequency response Ho(e j'°) is
is also mentioned in the introduction of [13]. a real-valued function.
Oppenheim et al. state that one possible approach If HLPo(ej~°) is the frequency response of a zero
is to vary all of the filter coefficients in such a way phase lowpass filter, a symmetric bandpass
that the frequency characteristics vary in the response can be obtained, using the well-known
desired manner. They also point out that the filter modulation scheme [15], as
coefficients are generally a complicated function
of the filter cutoff frequency. This is true, generally. HBpo(ej'°) = Hcpo(eJ¢'°-'%~)
However, for a certain restricted but useful class + Hcpo(eJ('°+'%)). (3)
of linear phase digital filters, the coefficients are
The impulse response of the bandpass filter can
actually a very simple function of the cutoff
be expressed as [15]
frequency. Consequently, the approach of con-
trolling the filter coefficients directly is practical hBpo(n) = (e j°~°"+ e-J'%")hLpo(n)
for these filters also in real time applications.
= 2 cos(won ) hLPo(n ), (4)
In the next section, we review some simple
methods with which different response types (high- where Wo is the desired center frequency of the
pass, bandpass, notch, etc.) can be obtained from bandpass filter. Assuming that the center frequency
a lowpass prototype. In Section 3, we first consider w0 is chosen larger than the stopband edge ws of
window-based design methods from the point of the lowpass filter and less than 7r - w~, the resulting
view of variable filter design. The properties of bandpass filter has the worst case maximum error
optimal lowpass filters are then studied, and a 6p+6s in the passband and 26s in the stopband,
design method is proposed for approximately where 6p and 6s are the peak errors of the lowpass
optimal variable lowpass filters. The possibility to filter in the passband and stopband, respectively.
obtain unequal ripples in the passband and stop- The error is the deviation of the actual filter
band is considered in detail. The implementation response magnitude from the desired ideal value.
of the proposed filters is also discussed and illustra- A variable center bandpass filter can be imple-
tive examples are given. mented using equation (4) directly. If the lowpass
filter cutoff frequency can be controlled through
2. Filter type transformations one parameter, the cutoff frequencies of a band-
pass filter can be controlled through only two
In this section, we review some simple filter parameters.
transformations which are useful in the context of From a zero phase lowpass filter HLPo(z), a zero
variable band selective FIR filters. phase highpass filter HHPo(Z) having equal 6 dB
Signal Processing
P. Jarske, Y. Neuvo, S.K. Mitra / Variable FIR filters 315

cutoff frequency can be obtained as the amplitude Using both equation (4) and (8), a notch filter can
complementary of the prototype lowpass filter [ 16] be designed having a first-order zero at two sepa-
rate frequencies.
HHP0(2') = 1 -- H k p o ( Z ). (5) As an example of the use of equations (6) and
The impulse response of the zero phase highpass (8), a lowpass prototype filter of length 21 was
filter is thus given as designed. The passband edge is 0.4~r and the stop-
band edge 0.5~r. The filter was designed to have
hLpo( n ) for n = O, equal, and relatively large, ripples on both bands.
hupo(n) = f1 (6) The frequency response of the prototype filter and
(-h~o(n) for 1 <~[nl~< N.
the highpass filter obtained using equation (6) are
presented in Fig. l(a). Fig. l(b) shows the response
The passband error of the highpass filter is equal
of the notch filter resulting from equation (8).
to the stopband error of the prototype lowpass
filter, and vice versa.
By combining equations (4) and (6), a band- . . . . I . . . . [ . . . . I . . . . I . . . .

stop filter can easily be designed using a lowpass


prototype.
Notch filters having a first order zero at the notch
frequency can also be designed from a lowpass -20 /
prototype filter. One approach to this is to rep-
resent the filter as the difference between the
prototype lowpass filter and its amplitude -40

complementary
o

HNo(Z) = HLP0(Z )- (1 - HLpo(Z)) -60

= 2HLPo(Z) -- 1. (7) . . . . I . . . . . . . . I . . . . I . . . .

o
This way the 6 dB cutoff frequency of the lowpass
filter is m a p p e d to the notch frequency of the
o
resulting notch filter. Another approach is to apply "0 -20
a simple linear transformation to the amplitude .,.¢

axis of the frequency response such that the stop-


band of the lowpass filter is mapped to - 1 while -40
the passband remains at +1. The result is the same b
2
as in equation (7). It is easy to see from equation
-60 .... ' .... I , , I . . . . I . . . .

(7) that the errors in the lower and upper passband


0.0 0.I 0.2 0.3 0.4 0.5
of the notch filter are exactly twice the errors in
frequency, w/2~
the passband and stopband, respectively, of the
Fig. 1. (a) A lowpass prototype filter and its complementary.
prototype filter. The width of the notch is equal to
(b) Difference of the responses in (a).
the transition bandwidth of the prototype filter
since the frequency axis is not distorted. The
impulse response of the notch filter can be given as For filters of length 2N, the transformations are
not quite as straightforward. In this case, a causal
2hLpo(n) - 1 for n = 0, filter can be expressed as
hNo(n) = (2hLpo(n)
(s)
for 1 ~]n[<~ N. h(n) = h o ( n - N +½). (9)
Vol. 14, No. 4, June 1988
316 P. Jarske, Y. Neuvo, S.K. Mitra / Variable FIR filters

A bandpass impulse response can be derived in H,D(e j~)


the same way as equation (4) and the result is given
by
hiD(n) = (1/2'n) e j~" dw
hBpo(n) = 2 cos(wo(n --½))hLPo(n), (10) -- c

where ~oo is the desired center frequency and = sin(toon)/(wn)


- N + 1 ~< n <~ N. A highpass impulse response is
obtained from a causal lowpass prototype as = (Wc/Tr) sinc(to~n/~r), (13)

hnp(n) = eJ"=hLp(n)
where sinc(x) = sin(~x)/('rrx) and sinc(0) is equal
= cos(n~)hLp(n), (ll) to 1.
If we look at equation (13) from the point of
where 0 ~< n <~2 N - 1. This is equal to inverting the view of our problem, which is to vary the filter
sign of every other filter coefficient which makes coefficients such that the cutoff frequency of the
the filter symmetry odd. The resulting highpass filter varies in the desired manner, we notice that
filter is not the complementary of the prototype the center coefficient (n = 0) is a linear function of
lowpass filter. the cutoff frequency and the other coefficients are
of the form h i D ( n ) = c(n) sin(tocn), Inl ~> 1, where
c(n) is constant for each n and c ( - n ) = - c ( n ) .
So, in the ideal case, the coefficients, or the impulse
3. V a r i a b l e cutoff l o w p a s s filters
response values, are actually a very simple function
of the cutoff frequency.
In the previous section we showed that various
The length of the ideal lowpass filter is, naturally,
response types can be derived from a lowpass
infinite, and a finite impulse response filter can
prototype filter in a simple manner. Thus, the prob-
only approximate the ideal response. Nevertheless,
lem of designing a variable band selective filter is
we define the filter class considered in this section
reduced to the design of a variable cutoff lowpass
such that the coefficients of the filter are of the
filter. In the following discussion, we introduce
same form as in the ideal case, that is to say,
linear phase lowpass digital filters whose coeffi-
cients can be calculated from a simple func-
c(n)to¢+d for n = 0 ,

f
tion of the 6 dB cutoff frequency. The approach is
based on the very basic and well known properties
of lowpass digital filters and traditional F I R filter
ho( n ) =
~ (n)sin(tocn) for l~<lnl<~ N, (14)
otherwise,
design methods.
The ideal Iowpass digital filter frequency where toc is the variable 6 dB cutoff frequency, d
response can be defined as is a constant and c ( - n ) = - c ( n ) for [n[>~l. It
should be noted that if a iowpass prototype filter
HiD(eJ°') = { 10 f°r 0~< t° <~ we' (12) has the impulse response of this form, the
for We< W ~<~r, responses resulting from equations (4), (6), and
(8) also have the same form.
where toe is the cutoff frequency. HiD(e j'°) is peri- Any given fixed lowpass filter, designed with any
odic with period 2~r a n d symmetric with respect method, can be expressed in the form of equation
to w = 0. The ideal impulse response can be derived (14). The use of equation (14) with varying cutoff
as the inverse discrete Fourier transform of frequency is discussed next.
Signal Processing
P. darske, }I. Neuvo, S.K. Mitra / Variable FIR filters 317

3.1. Window-based designs 3.2. Optimal designs


Windowing is a traditional method used in the The window method is fast and easy to use, and
design of FIR filters. The impulse response of the therefore widely used. However, the resulting
filter obtained with the window-based design is filters are not optimal even if the window itself is
optimal in some sense. In order to investigate if
ho(n) = w(n)h,o(n), (15) optimal (minimax) filters can be implemented or
at least approximated using equation (14), an
where w ( n ) = w ( - n ) and w ( n ) > 0 for Inl~N.
extensive number of lowpass designs was made
For a review of the window design method and
using the Remez exchange algorithm [8]. For
different windows, see [14], for example.
example, Fig. 3 shows some of the coefficients of
Clearly, the impulse response of a lowpass FIR
a length 51 optimal lowpass filter, designed to have
filter designed using any symmetric window can
the transition bandwidth equal to 0.04~r, as a func-
be expressed in the form of equation (14). In other
tion of the 6 dB cutoff frequency.
words, it is relatively easy to implement a variable
cutoff linear phase lowpass filter using a window.
The other response types follow from equations (4),
1.o . . . . , .... , . . . . , . . . . j
(6), and (8). As an example we consider a lowpass

I
filter of length 51 designed using the Hamming
window [14]. The frequency response of the vari- 0.6
able filter with several different cutoff frequencies 0.4
is presented in Fig. 2. The cutoff frequency is 0.2
variable over nearly the whole frequency band. 0.0 '

The only limiting factor is that it is not reasonable 0.4 'b''' .... ' .... ' ........
to make the 6 dB cutoff frequency smaller than
2~Ato or greater than w-½Aw, where Ato is the
0.2
transition bandwidth of the filter.
0.1
0.0 . . . . . . . . . . . . . . . . .
.... I .... I .... I .... I 0 . 2 1 . . . . . I . . . . I . . . . I . . . . I . . . . 4
0
~ 0.1
"~ 0.0
8 -o.1
° -0.2 ................ I, , 1
-50 - 0 . 0 4 . . . . , . . . . , . . . . , . . . . I . . . .

0.00
-0.02
-0.04
-100 ' ' 0.0 0.1 0.2 0.3 0.4 0.5
0.0 0.1 0.2 0.3 0.4 0.5 cutoff frequency. ~/2~
frequency, ~/2~
Fig. 3. Coefficients of an o p t i m a l l o w p a s s filter of length 51 as
Fig. 2. A v a r i a b l e cutoff l o w p a s s filter d e s i g n e d using the H a m - a function of the cutoff frequency. (a) n = 0 (center). (b) n = 1.
ming window. (c) n =2. (d) n = 10.
Vol. 14, No 4. June 1988
318 P. Jarske, Y. Neuvo, S.K. Mitra / Variable FIR filters

Based on large number of designs with different As an example, a variable cutoff lowpass filter
filter lengths and transition bandwidths, the fol- of length 51 was designed with two different transi-
lowing conclusions are drawn. For optimal low- tion bandwidths and equal weights in both bands
pass filters of odd length and equal peak errors on of the model filter. The results are presented in
both passband and stopband, the filter coefficients Fig. 4. The filters are exactly equiripple at the cut-
follow equations (14) very closely. Note that, also off frequency of the model filter, and approxi-
in the window designs, the maximum errors are mate optimal filters quite well at other cutoff
equal on both bands. frequencies.
Also in filters of even length, the coefficients
behave in a simple manner as a function of the
. . . . I . . . . I . . . . I . . . . I . . . .

cutoff frequency. In this case, the relation is a

ho(n) = c(n) sin(toc(n -½)), (16)


-20
where - N + 1 ~< n <~ N and c ( - n + 1) = -c(n). For
designs with considerably different weights in each -40
band, the coefficients are a complicated function
of the cutoff frequency, although an underlying
sinusoidal trend can be observed also in these -60
cases.
These observations lead to a relatively simple -80 ,

design method for approximately optimal variable


FIR filters with equal maximum errors in the pass-
. . . . I . . . . I . . . . I . . . . I . . . .

band and stopband. First, an optimal lowpass filter


0
hMo(n) is designed having the desired transition
bandwidth and the 6dB cutoff frequency Woo
chosen such that all the coefficients of the filter -20
are nonzero. Our choice is
-40

0.5 )
Wco= 2"rr 0 . 2 5 + 2 N + 1
E -60
for filters of length 2 N + 1 , and Wco=0.5,r for
length 2N. Other choices are possible. The -flO
0.0 0.1 0.2 0.3 0.4 0.5
coefficients c(n) in equation (14) or (16) can now frequency, ~/2~
be calculated from
Fig. 4. A variable cutoff Iowpass filter approximating optimal
filters, length = 51, transition bandwidth. (a) 0.10w, (b) 0.02w.
=
[ hMO(n)
~sin(wcon)
for
odd length and n # 0,
c(n) ] hMo(n) (17) The following examples illustrate variable linear
lsin(wco(n - ½)) for even length. phase bandpass and notch filters obtained using
the equations derived above. A variable center
The center coefficient c(0), for filter length 2 N + 1, bandpass filter can be implemented using a low-
is equal to 1/~r and d = 0 according to equation pass prototype and equation (4) or (10). Fig. 5
(13), in the lowpass case. The variable cutoff filter presents the frequency responses of a length-50
is then implemented using equation (14) or (16). variable center bandpass filter resulting from an
Signal Processing
P. Jarske, Y. Neuvo, S.K. Mitra / Variable FIR .filters 319

The cutoff frequencies of a bandpass filter can


0 be controlled independently with only two pa-
rameters by use of equations (4) and (14), or (10)
and (16). If toc~ and toe2 are the lower and upper
cutoff frequencies of the bandpass filter, respec-
tively, too in (4) and (10) can be replaced
with ½(wcl+toc2),and w~ in (14) and (16) with
I~ -5o ½(wc2-wcj). By combining equations (4) and
(14), the variable cutoff bandpass impulse
response can be rewritten as

f½c(n)(wc~-wc,)+d for n =0,


-100 ho(n)=lc(n)(sin(wcen)-sin(wcln))
for 1 ~<lnl ~<N.
(18)
0.0 0.1 0.2 0.3 0.4 0.5
f r e q u e n c y , ~//27r
Similarly, from equations (10) and (16) the
Fig. 5. A variable center frequency b a n d p a s s filter.
equation

ho(n) = c(n)(sin(wc2(n-½))
optimal prototype and equation (10). The center
frequency is controlled with one parameter. - sin(wc~(n -½))) (19)
A variable bandwidth bandpass filter is realized is obtained. As an example, the responses of a
with a bandpass prototype and equation (14) or variable cutoff bandpass filter of length 50 are
(16). The bandpass prototype filter can be designed presented in Fig. 7.
using equation (4) or (10). The frequency A variable notch filter of odd length is easily
responses of a variable bandwidth bandpass filter implemented using a prototype obtained with
of length 50 are shown in Fig. 6. The bandwidth equation (8). The variable filter is then realized
of the filter is controlled with one parameter.

I .... I .... I' o


0

~ -5o
-5o ,

-loo I .... I, ,h r l ,,, II -loo


0.0 0.1 0.2 0.3 0.4 0.5
0.0 O. 1 0.2 0.3 0.4 0.5 f r e q u e n c y , ~/21r
f r e q u e n c y , ~/2~r
Fig. 7. A b a n d p a s s filter with variable bandwidth and center
Fig. 6. A b a n d p a s s filter with variable bandwidth, frequency.
vol. 14, No. 4, June 1988
320 P. Jarske, Y. Neuvo, S.K. Mitra / Variable FIR filters

according to equation (14). Fig. 8 illustrates a (15) where hiD(n) is calculated from equation (13).
notch filter of length 51 and notch width 0.1"rr. The window function w(n), in this case, is also a
function of the cutoff frequency, while in the win-
dow design methods, w(n) is constant for each n
and all cutoff frequencies. As an example, some
of the window values of an optimal lowpass filter
of length 51 are presented in Fig. 9. The design is
weighted such that the passband ripple of the filter
is ten times the stopband ripple. For simplicity,
btl the cutoff frequency toc is defined to be the
-50 frequency half-way between the passband and
stopband edges. For designs with considerably
differing weights, this is not exactly the 6 dB
frequency.

1.2 . . . . I . . . . I . . . .

-i00
0.0 0.1 0.2 0.3 0.4 0.5
frequency, ~/2rr 1.O .

Fig. 8. A variable notch filter. 0.9


0.8 .... I .... • • • , i

1.2 . . . . i . . . . i . . . .
3.3. Unequal ripples in passband and stopband
Earlier, we pointed out that window design
1.O -
methods produce approximately equal maximum
ripples in the passband and stopband of a lowpass 0.9
filter. Also, optimal lowpass filters can be success- 0.8 i . . . .
.... , bt
fully approximated with equation (14) or (16) only
' " ' I . . . . !
if the prototype filter is designed to have equal =:1 1.4

ripples in both bands. In some cases, however, it ..id, 1.2


is desirable to have different maximum ripples in 1.0
each band since the resulting filter is generally 0.8
shorter than a filter meeting the strictest ripple 0
0.6
0
requirements in all bands. In the following, we
study the properties of optimal lowpass filters
having different weights in passband and stop- 1.2
band, and propose an approximation of these 1.0
filters which is somewhat more complicated than O.B
equations (14) and (16), but still a relatively simple 0.6
function of the cutoff frequency.
0.0 0.1 0.2 0.3 0.4 0.5
In order to study the behavior of optimal low-
frequency. ~/2~
pass impulse responses, optimal filters were
designed with various different weights, cutoff Fig. 9. Coefficientsw(n) of equation (15) for an optimal filter
of length 51, error weights in design 1/ 10 in the passband/stop-
frequencies and filter lengths. The resulting impulse band (solid line); coefficientsfrom equation (20) (dashed line).
responses were expressed in the form of equation (a) n=0.(b) n=l.(c) n=3.(d) n=6.
Signal Processing
P. Jarske, Y. Neuvo, S.K. Mitra / Variable FIR filters 321

The results of numerous optimal designs (for where R and Q are polynomials. HLp0 can be
example, the curves of Fig. 9 are extracted from approximated with P( to - toe) and S( w - co~.) which
230 different designs) indicate that w(n) can be are truncated series expansions of the ideal
very well approximated, in a wide range of cutoff response, in other words polynomials in to. Thus,
frequencies, with functions of the form

[
{P(to-to~) f°r0~to<~Wc' (26)
c'(n)+d'(n)/to~ for n =0, HLp°(eJ~')'~ S ( t o - t o c ) forto~<to<~r.
w(n)= c'(n)+d'(n)cot(tocn) (20)
As HLpo is symmetric with respect to to = 0 and
for 1 <~[nl<~ N.
periodic with period 2qv, the ideal impulse response
can be derived as
For comparison, the coefficients calculated from
equation (20) are also shown in Fig. 9 (dashed
line). The coefficients c'(n) and d'(n) are obtained
with the design method described later in this
hLr,o(n) = --
1
71"
j'( -rr

1
HLPo(e j'°) cos(ton) dw

section. Similarly, if an optimal impulse response


~-- P(to -toc) cos(ton) dto
of length 2 N is rewritten as Ti" 0

sin(toc(n -½)) +- S(to -toc) cos(ton) dw.


ho(n) = w(n) ~(n-l) ,
(21) 'IT

(27)
where - N + 1 <~ n <~ N, the window function can
If we solve the integrals in equation (27) by
be approximated with
parts, we can see that the resulting impulse
w(n) = c'(n)+ d'(n) cot(toc(n -~)). (22) response is of the form of equation (23) except
for the terms + P " ) ( - t o c ) and +S(~)(~r-to¢),
Using equations (15), (20), (21), and (22), the i = 1, 3, 5 , . . . , where
expression for approximately optimal variable cut-
dip(to)
off zero phase lowpass filter impulse response is
P(')(to)- dw' " (28)

fc(n)toc+d(n) for n =0, However, since HLeo is a function of cos to, and
ho(n) = ~ c ( n ) s i n ( t o c n ) + d ( n ) cos(tocn) (23) p(i)(_to~)~, rJ(') ~ o,~
/ • J LP0~e ,I
( for l<~lnl<~ N,
and
when the filter length is 2 N + 1, and
S(il(.rr- toc)= ~(i)
s l L P O I~oJ~
~, j,

ho( n ) = c( n ) sin(to~(n -½))


these terms are approximately zero.
+ d(n) cos(toc(n -½)) (24) When using equation (23) or (24) to realize a
variable FIR filter, the coefficients c(n) and d ( n )
for length 2 N ( - N + 1 ~< n <~ N). have to be determined. The following procedure
In order to explain this relationship, let us is proposed for the design of variable cutoff low-
assume that the optimal lowpass frequency pass filters having different maximum ripples in
response can be expressed as the passband and stopband. First, two optimal
lowpass filters are designed having different cutoff
=~R(costo) for0~<to~<toc, (25) frequencies and the desired ripples in passband
HL~(ei'°) (Q(costo) fortoc<to~, and stopband. Assuming that the resulting impulse
Vol. 14, No. 4, J u n e 1988
322 P. Jarske, Y. Neuvo, S.K. Mitra / Variable FIR filters

responses represent equation (23) or (24) at the 0


chosen cutoff frequencies, the coefficients can be
calculated from a set of linear equation pairs
-50
including two unknowns each. Based mainly on
practical experience, we have chosen the prototype
cutoff frequencies -100

to¢o/2~r = 0.1 ± 0.25/2N o

if the desired stopband ripples are smaller than


-50
passband ripples and

toco/2rr = 0.4+ 0.25/2N -100


ii ...................
' '

if the desired passband ripples are smaller. 0

As an example, a lowpass filter of length 51 was


designed using the method described above with -50
four different weightings in the model filters. The
transition bandwidth is 0. l'rr in all cases. The result- o
-100
ing frequency responses are presented in Fig. 10.
The tuning range of a filter designed with this
method is somewhat limited which can be seen
also from the curves of Fig. 9. For instance, very
narrowband filters with small ripple in the stop-
band, or wideband filters with small ripple in the
passband, cannot be successfully approximated -100 ' • "'
0.0 0.1 0.2 0.3 0.4 0.5
using equation (23) or (24). However, narrowband
frequency, ~/2rr
tunable filters can be implemented by combining
this method and the IFIR filter concept introduced Fig. 10. A variable cutoff lowpass filter of length 51, transition
bandwidth 0.1~r, passband/stopband weights (a) 1/1, (b) 1/10,
by Neuvo et al. [12]. Wideband filters are obtained (c) l/lO0, (d) Ulooo.
as complementary filters [ 16] of narrowband filters.
In this case, the filter is the cascade of a sparse
tunable model filter and a fixed interpolator. Let different stages in this IFIR filter are presented in
us assume, for instance, that a lowpass filter is
Fig. 11.
desired to be variable in the range ~'rr < toc < 25"rr
with the transition bandwidth ~ r . 50 dB attenu-
ation in the stopband is desired, but the ripples in 4. Extensions of the method
the passband may be five times the stopband
ripples, at the most. A linear phase filter meeting
4.1. Polynomialpassband shapes
these requirements can be designed as a cascade
of a sparse tunable model filter having 25 In the previous sections, the ideal frequency
coefficients and a fixed interpolator of length 13. response was assumed to be constant in the pass-
The model filter is obtained by designing a variable band. With the tuning method introduced, variable
filter of length 25 with transition bandwidth l~r. frequency responses can be approximated whose
Every delay in the model filter is then replaced passband shape is a polynomial of to. For example,
with three delays. The frequency responses of the the desired ideal frequency response may be of
Signal Processing
P. Jarske, Y. Neuvo, S.K. Mitra / Variable FIR filters 323

If this impulse response is truncated with a Kaiser


window of length 101, the result of Fig. 12(a) is
obtained. This kind of filter can be used, for in-
-50
stance, as an equalizer in a two-stage structure. Let
us assume that a variable lowpass response is
-100 desired with a fixed zero at a certain frequency.
The fixed zero is realized with a F I R filter of length
3 and the filter of the e x a m p l e above is used as an
equalizer. Fig. 12(b) shows the frequency response
-50 of the fixed filter and Fig. 12(c) is the overall
response of the two-stage filter.

~
-100

Q} 1" ' a '


0

C
-so -
-50

°~ -I00 .... I .... i... l, a... J .... t AAAAAMnAt~


0 ~ . . . . . . . . . . . . . . . . . . .~. ~ -i00 , , , . I , , !tlllllv[lIl[I!rllllII{lll
'{
._. . . . I . . . . I . . . . I . . . . I . . . .
0
-,50
.,-4
-100
-50
0.0 0.I 0.2 0.3 0.4 0.5
frequency, ~o/2Tr
O
,--i
Fig. 11. A tunable IFIR filter: (a) tunable model filter of length b
25. (b) Thinned model filter (shaping filter). (c) Fixed interpol-
ator of length 13. (d) The overall response.
-100 .... I .... r ....

....'cJ
i .... J ....

the form

HH)(eJ'°)={lo+a°92 f°r 0~< to ~< we' (29)


for toc < to <~ ~r.
The corresponding ideal impulse response is
-I00 .... i.
hiD(n) =--1 [ ( 1 4 ceto~. 2 ~ ) sin(tocn ) 0.0 0.1 0.2 0.3 0.4 0.5
'IT n
Fig. 12. Application of the generalized variable lowpass filter:
2c~to~ ] (a) Variable equalizer. (b) Fixed stage. (c) Overall response.
+ n2 cos(tocn) (30)
4.2. Variable two-dimensional F I R filters
for n # 0, and
Two dimensional (2-D) digital filters have an
h,D(O) = 1 (law 3 + to~). (31) increasing n u m b e r o f applications, especially in
"iT the field o f digital image processing. Variable 2-D
Vol.14,No.4,June1988
324 P. Jarske, Y. Neuvo, S.K. Mitra / Variable FIR filters

filters are useful, for instance, in the areas of image by the transformation function T. As an example,
coding and pattern recognition. a variable 2-D filter was designed using a variable
A simple and straightforward approach to vari- 1-D prototype of length 21 and the original
able 2-D filters is the use of separable FIR filters. McClellan transformation. The prototype filter was
A separable 2-D frequency response can be designed using the method described in Section 3.
expressed as a product of two one-dimensional The frequency responses of the resulting filter with
responses two different cutoff frequencies are presented in
Fig. 13. The shape of the passband, in this case,
H ( e j%, e j'°2) = Ht(eJ'°') H2(eJ~2). (32) follows the contours of the original McClellan
Similarly, the impulse response of such a filter can transformation function [9], as expected.
be expressed as a product The IFIR concept can be readily extended to
two-dimensional filters [17]. Using this approach,
h(n, m) = h~(n)h2(m). (33) tunable 2-D narrowband or wideband filters can
be realized with considerably reduced number of
A variable 2-D filter results if one or both of the variable coefficients.
1-D filters are variable. A separable frequency
response has always approximately rectangular
symmetry, and the bandwidth of such a filter can
be controlled individually in each direction.
McClellan [7] introduced a transformation
method for the design of 2-D FIR filters having
approximately circular symmetry. This, so-called
McClellan transformation, was generalized by
Mersereau et al. [9]. In this method, the 2-D
response is obtained from a 1-D filter with a substi-
tution of variables. The 1-D response of length
2 N + 1 is first expressed in the form
N
H ( e j'°) = ~ b(n)[cos to]". (34) a
n=0

This filter is then converted into a 2-D filter by


means of the substitution

cos to = T(cos tol, cos to2), (35)

where T is a relatively simple 2-D response. The


original transformation, proposed by McClellan, is
T(cos to,, cos to9

= ½(cos tom cos w2 + cos to1 + cos to2 - 1).


(36)

If a variable 2-D FIR filter is implemented using b


the McClellan transformation, the bandwidth of
Fig. 13. A 2-D lowpass filter obtained, using the McCfellan
the filter can be controlled by a single parameter, transformation, from a variable 1-D prototype of length 21;
whereas the shape of the passband is determined prototype cutoff frequency. (a) 0.47r, (b) 0.87r.
Signal Processing
P. Jarske, Y. Neuvo, S.K. Mitra / Variable FIR filters 325

5. Implementation and applications cosine functions can be approximated with the first
terms of their Taylor series expansions, and the
There are several arguments which support the filter coefficients for different frequencies can be
direct form implementation of digital filters, calculated from the linear equations
especially FIR filters, in microprocessor-based sys-
tems. The theory and properties of these structures h0(n) = c ( n ) [ s i n ( w m n )
are thoroughly studied. With modern special pur-
pose signal processors and other high speed VLSI + 6wn cos(comn)]. (38)
devices it is not necessary to minimize the number
of multiplications in all cases since multiplication The width of the usable tuning range, in this
can be performed as fast as addition. Furthermore, case, is inversely proportional to the length of the
the instruction set of a microprocessor designed filter.
for high speed signal processing is usually such The most obvious applications of variable
that a direct form filter can be implemented very digital filters are in laboratory instruments,
efficiently. In many cases, a FIR filter of length M communications and audio signal processing.
can be realized with M instructions. Also, with Here, we review shortly two special applications
devices designed for vector operations, the direct of variable FIR filters which are currently being
form FIR is a natural structure as the filter is the studied.
scalar product of the coefficient vector and a vector In the design of digital filter banks, one of the
of signal samples. The above arguments are valid decisions to be made is the degree of overlapping
also for variable FIR filters which, as we have of the responses of different channels. There are
shown in the previous sections, can be readily applications where completely nonoverlapping
implemented by directly controlling the coeffi- designs are required, such as T D M - F D M trans-
cients of a direct form filter. multiplexers for communication systems. In many
The major problem in the implementation is the applications, however, a certain degree of overlap-
function sin x. Standard methods for obtaining the ping is accepted or even desired. Uniform filter
sine function values are table lookup and series banks are usually realized using a single model
expansions. The values of a sinusoid can also be filter which is then modulated to different channels.
calculated recursively using a digital sinewave gen- If the model filter is variable, the degree of overlap-
erator which is essentially a second order recursive ping between channels can easily be adjusted, dur-
digital filter with poles on the unit circle [4]. If the ing the filter operation if necessary. Nonuniform
second-order section is in coupled form, both the filter banks can also be readily implemented with
sine and cosine functions are available simul- variable FIR filters. Efficient DFT algorithms can
taneously [ 11 ]. be applied especially to uniform but also to non-
In some applications, the filter is required to be uniform filter banks [6].
tunable only within a narrow range around a Half-band filters are commonly used in subband
certain selected frequency CO m . A very efficient coding of one- and two-dimensional signals. The
implementation results if the filter coefficients are coding of images is usually done using separable
represented in terms of filters. The application of nonseparable filters, with
approximately circular band shapes, to subband
sin((COm + 6 w ) ) n = sin(COmn) cos(6COn) coding of images, and frequency domain
+ cos(comn) sin(6COn), (37) pseudocoloring of graylevel images are being
studied [10]. With tunable 2-D filters, suitable
where 6CO is the deviation from the selected band edges can be selected for each image
frequency. For small values of 6CO, the sine and separately.
V o l . 14, N~) 4, J u n e 19~8
326 P. Jarske, Y. Neuvo, S.K. Mitra / Variable FIR filters

[4] K. Furuno, S.K. Mitra, K. Hirano and Y. Ito, "Design of


6. Concluding remarks
digital sinusoidal oscillators with absolute periodicity",
1EEE Trans. Aerospace & Electronic Systems, Vol. AES- 11,
We have presented a class of linear phase low- November 1975, pp. 1286-1299.
pass digital filters for which the filter coefficients [5] S.N. Hazra, "Linear phase bandpass digital filters with
variable cutoff frequencies", IEEE Trans. Circuits & Sys-
are a simple function of the 6 dB cutoff frequency.
tems, Vol. CAS-31, July 1984, pp. 661-663.
Using simple transformations which can be imple- [6] B. Jeren, "An efficient nonuniform filter bank realization
mented as constant factors in the filter coefficients, using reduced FFT and sine transform", Proc. 1986
European Signal Processing Conf., The Hague, The Nether-
different response types can be realized such as
lands, 1986, pp. 227-229.
highpass, bandpass and notch filters having vari- [7] J.H. McClellan, "The design of two-dimensional digital
able cutoff frequencies. These variable filters can filters by transformations", Proc. 7th Ann. Princeton
most easily be obtained from window designed Conf. on Information Sciences and Systems, 1973, pp.
247-251.
lowpass prototype filters. However, optimal vari- [8] J.H. McClellan, T.W. Parks and R.L. Rabiner, "A com-
able filters can also be approximated successfully puter program for designing linear phase FIR filters",
IEEE Trans. Audio Electroacoust., Vol. AU-21, December
by using an optimal prototype. The approximate
1973, pp. 506-526.
expressions derived for optimal linear phase filters [9] R.M. Mersereau, W.G.F. Mecklenbr/iuker and T.F.
give an intuitive description on the behavior of the Quatieri, "McClellan transformations for two-
filter coefficients when the passband width is dimensional digital filtering, Part I: Design", IEEE Trans.
Circuits & Systems, Vol. CAS-23, July 1976, pp. 405-414.
varied. The tuning method can also be used to [103 S.K. Mitra and J. Baumgartner, "Application of tunable
provide good initial values for optimization nearly circularly symmetric two-dimensional filters to
routines. image processing", in preparation.
[117 S.K. Mitra, K. Furuno and K. Hirano, "Design of sine-
cosine generator", Proc. 1975 Florence Conf. on Digital
Signal Processing, 1975, pp. 142-149.
[123 Y. Neuvo, C. Dong and S.K. Mitra, "Interpolated finite
impulse response filters", IEEE Trans. Acoust. Speech,
Signal Process., Vol. ASSP-32, No. 3, June 1984, pp. 563-
570.
References
[133 A.V. Oppenheim, W.F.G. Mecklenbr~iuker and R.M.
Mersereau, "Variable cutoff linear phase digital filters",
[1] S.S. Ahuja and S.C. Dutta Roy, "Linear phase variable IEEE Trans. Circuits & Systems, Vol. CAS-23, April 1976,
digital bandpass filters", Proc. IEEE, Vol. 67, January pp. 199-203.
1979, pp. 173-174. [14] A.V. Oppenheim and R.W. Schafer, Digital Signal Pro-
[2] R.E. Crochiere and R.L. Rabiner, "On the properties of cessing, Prentice-Hall, New York, 1975.
frequency transformations for variable cutoff linear phase [15] A.V. Oppenheim, A.S. Willsky and I.T. Young, Signals
digital filters", IEEE Trans. Circuits & Systems, Vol. CAS- and Systems, Prentice-Hall, New York, 1983.
23, November 1976, pp. 684-686. [163 G.C. Temes and S.K. Mitra, Modern Filter Theory and
[3] S.C. Dutta Roy and S.S. Ahuja, "Frequency transforma- Design, Wiley-lnterscience, New York, 1973.
tions for linear-phase variable-cutoff digital filters", IEEE [173 M.V. Thomas, Y. Neuvo and S.K. Mitra, "Two-
Trans. Circuits & Systems, Vol. CAS-26, January 1979, pp. dimensional interpolated finite impulse response filters",
73-75. Proc. ISCAS-83, 1983, pp. 904-906.

Das könnte Ihnen auch gefallen