SIGNAL
PROCESSING
ELSEVIER Signal Processing 42 (1995) 261-271
Symmetric properties of 2-D sequences and their applications for
designing linear-phase 2-D FIR digital filters
Soo-Chang Pei”,*, Jong-Jy Shyub
“Department of Electrical Engineering, National Taiwan lJniversi&, Taipei, Taiwan, ROC “Department of Computer Science and Engineering, Tatung Institute of Technology, Taipei, Taiwan. ROC
Received 22 April 1994
Abstract
Besides the design of quadrantally symmetric linear-phase 2-D filters, various linear-phase 2-D filter designs are proposed in this paper. We will start from the discussion of the symmetric properties of 2-D sequences to disclose their applications for designing linear-phase 2-D FIR digital filters. It is shown that there are 16 types of cases to be considered according to the symmetry/antisymmetry of 2-D sequences in both directions and their filter lengths (even or odd). The corresponding types of amplitude responses are tabulated into a complete table if these 2-D sequences are used to realize 2-D FIR filters. Also, the definition of quadrantal-plane, half-plane and full-plane filters are described along with numerical examples designed by the eigenfilter approach.
Zusammenfassung
Neben dem Entwurf von linearphasigen, beziiglich der Quadranten symmetrischen 2D-Filtern werden in dieser Arbeit verschiedene Entwiirfe linearphasiger 2D-Filter vorgeschlagen. Wir beginnen mit der Diskussion der Symmetrie-Eigen- schaften von 2D-Folgen, urn ihre Anwendung zum Entwurf von 2-D-FIR-Filtern zu verdeutlichen. Es wird gezeigt, daR sechzehn verschiedene FHlle beziiglich der Symmetrie/Antimetrie von 2D-Folgen in beide Richtungen und beziiglich ihrer Filterhingen (gerade oder ungerade) zu betrachten sind. Die zugehorigen Typen von Frequenzgiingen bei Nutzung der ZD-Folgen zum Entwurf von 2D-Filtern werden tabellarisch dargestellt. Weiterhin werden die Definitionen von Quadranten-, Halb- und Vollebenen-Filtem angegeben und durch numerische Beispiele anhand von Eigenhlter-Losungen voranschaulicht.
Dans cet article, outre la conception de filtres 2D a phase lineaire symetriques par quadrant, on propose plusieurs conceptions de filtres 2D a phase lineaire. Nous commencerons par discuter les proprittes de symetrie des sequences 2D pour reveler leurs applications dans la conception de filtres numeriques FIR 2D a phase lintaire. On montre qu’il existe 16 cas-types a considerer, d’aprts la symetrie/disymttrie des sequences 2D dans les deux directions et la longueur de leurs filtres (pair ou impair). Les types de reponse d’amplitude correspondants sont places dans un tableau complet si ces sequences 2D sont utilisees pour rialiser des filtres FIR 2D. De m&me, on trouvera les definitions des filtres quadrant, demi-plan et plan, accompagnts d’exemples numtriques calcules par l’approche des filtres propres.
Keywords: Filter symmetry; 2-D FIR filter; Filter design
*Corresponding author.
0165-1684/95/$9.50 0 1995 Elsevier Science B.V. All rights reserved
262 S.-C. Pei, J.-J. Shyu J Signal Processing 42 (1995) 261-271
1. Introduction
Conventionally, the design of linear-phase 2-D FIR digital filters is concentrated on the class of quadrantally symmetric filters, such as circular fil- ters, fan-type filters, etc. [ 11. A 2-D sequence, which is symmetric in both directions, is required to real- ize such quadrantally symmetric filters.
In this paper, we will start from the discussion of the symmetric properties of 2-D sequences to dis- close their applications for designing linear-phase 2-D FIR digital filters by the eigenfilter approach, which has been used successfully to design linear- phase 1-D filters [2,3] and 2-D quadrantally sym- metric filters [4]. It is shown that there are 16 types of cases to be considered according to the sym- metry/antisymmetry of 2-D sequences in both di- rections and their filter lengths (even or odd). The corresponding types of amplitude responses are tabulated into a complete table if these 2-D se- quences are used to realize 2-D FIR filters. Also, the definitions of quadrantal-plane, half-plane and full-plane filters are described along with several numerical design examples.
2. Symmetric properties of 2-D sequences
Let X represent an N 1 x Nz 2-D sequence in matrix form with its elements being denoted by x(nl,nz), nl = O,l, . . . ) N1 - 1, n2 = O,l, . . . , N2 - 1, i.e.
x(0,1) .*. 4O,N2 - 1)
x(1,1)
: ...
... x(LN2 - 1)!
(1)x(N, - 1,O) x(N1 - 1,l) ... x(N1 - 1,N2 - 1)
the sequence is called an odd-symmetric 2-D se- quence in the n,-direction; similarly for the n2-direction. Then symmetric or antisymmetric 2-D sequences can be divided into four major types.
Type I: Even symmetry in both the nl- and n2-directions, i.e.
~(~1~~112) = x(N, - I - nl,n2) = x(nl, N2 - 1 - n,),
O<nl<N1-1,0<n2<N2-1. (4)
Such an even-even sequence is denoted by X,,. Type ZZ: Even symmetry in the nl-direction and odd symmetry in the n2-direction, i.e.
x(nl,n2) = x(N, - 1 - n1,n2)
= -x(n1,N2- 1 -n2),
0 < nl < N1 - 1, 0 < n2 < N2 - 1. (5) We denote such an even-odd sequence by X,,.
Type ZZZ: Odd symmetry in the nl-direction and even symmetry in the n2-direction, i.e.
x(nl,n2) = - x(N1 - 1 - n1,n2) = x(n,, N2 - 1 - n2),
0 < n, < N1 - 1, 0 < n2 < N2 - 1. (6) We denote such an odd-even sequence by X0,.
If
x(nl,n2) = x(N1 - 1 - n1,n2), 0 < nl < N1 - 1,
0 < n2 < N2 - 1, (2)
we call X an even-symmetric 2-D sequence in the nl-direction, and if
x(nl, n2) = - x(N, - 1 - nl, n2),
0 < nl < N1 - 1, 0 < n2 Q N, - 1, (3)
Type IV: Odd symrfletry in both the nl- and n,-directions, i.e.
x(nl,n2) = - x(N1 - 1 - nl,n2) =- x(n1,N2 - 1 - nz),
0 < n, < N, - 1, 0 d n2 d N2 - 1. (7) We denote such an odd-odd sequence by X0,.
S.-C. Pei, J.-J Shp / Signal Processing 42 (1995) 261-271 263
For any N1 x Nz 2-D sequence X, it can always be decomposed into the above four types of 2-D sequences, i.e.
X = X,, + X,0 + X0, + X00, (8)
and X,,, X,,, X0, and X0, can be calculated from Xby x.&,,nz) = +Cx(n~,nz) + x(N1 - 1 - n~,nz) + x(n,, N2 - 1 - nz) +x(Nl-l-nl,Nz-l-nz)], O<nldN,-1, Odna<N2-1, (9) .x,,(nr, nz) = $Cx(n~> nz) + ~(NI - 1 - no, Q) - x(n~,N, - 1 - ~2) - x(N, - 1 - n,,N, - 1 - n2)], 0 d n1 < N, - 1, 0 < n2 6 N2 - 1, (10) x,,(nI, nd = $lIxh, 4 - ~(NI - 1 - nl, n2)
+x(n,,N,- 1 -nz) - x(N, - 1 - n,,N, - 1 - n2)], Odnl<NN,-I, Odn2<N2-1 (11) and .xoo(nl, n2) =
bCx(nr
,
n2) - x(Nr - 1 - n,, n2) -x(nr,NZ-1-n2) + x(N1 - 1 - nl,N2 - 1 - n2)], 0 G n, 6 Nl - 1, 0 G n, < N2 - 1, (12)where x,&r,, nd, x,,h, nd,
x,,h ,
n2) andx,,(nl,nz) are the elements of X,,, X,,, X0, and
X,,,, respectively. We can also find that
X, = X,, + X00 (13)
and
X0 = X,0 + X0,, (14)
where X, is a centro even-symmetric 2-D sequence whose elements satisfy
x,(nI,nz) = ~,(NI - 1 - nl,N2 - 1 - n2),
0 < n, 6 N1 - 1, 0 < n2 < N2 - 1, (15)
and where X0 is a centro odd-symmetric 2-D
sequence whose elements satisfy
x,(nl,n2) = - x,(N, - 1 - nl, N2 - 1 - n2),
O<n,dN,-1, Odn2<N2-1. (16)
For example, if X is given by
n2 r 8 0 8 0
1
3 6-10-5 X= n, 11 -8 -8 7 ’ (17) then -2 -6 10 21 n2 2 3 32 4 -5 -5 4 X,, = nl 2 3 32 n2 -6 6-l X,, = nl -6 6-l X0, = nl n2 2 1 1 2 -5 3 3 -5 5 -3 -3 5 -2 -1 -1 -2 n2 (18) (19)I
2(20)
r 3 2 -2 -31 1 4-4-l X0, = nl -1-4 4 1’ (21)1
-3 -2 2 31264 S.-C. Pei, J.-J. Shyu / Signal Processing 42 (1992) 261-271 and
x, =
n1 X0 = n, n2 5 5 l-l 5 -1-9 3 3 -9-l 5 -1 1 5 5 n2 3 -5 7 1 -2 7 -1 -8 8 l-7 2 -1 -7 5 -33. Properties of frequency responses of 2-D
sequences for designing linear-phase FIR digital filters
Type I and Type IV sequences, and are imaginary- valued functions for Type II and Type III se- quences. For example, if h(q) n2) is a Type I 2-D sequence and Ni, N2 are odd integers, then
The frequency response of a 2-D FIR digital filter with its impulse response h(nl,n2), nl = 0, 1, . . . , N1 - 1, n2 = O,l, . . . , N2 - 1, can be characterized as
N,-1 N,-1
H(ol, 02) = 1 1 h(nl, n2)e-j”‘ole-jn~w2 .
n,=O n2=0
(24)
If h(nl, n2) is one of the four types of 2-D sequences, Eq. (24) can be rewritten as
f(N,-1) fW-1)
= .Co .zo 4nl, n2) cos(n~dcos(n2~2)9 I
(27)
(23)
which is a real-valued function and a(nl, n2) are related to h(nl,n2) by
where
A(co,,w~), (25)
i
0, Type 1,
M = 1, Type II and Type III, 2, Type IV,
(26)
and
fi(w, ,
w2) is a real-valued function. Notice that by excluding the linear-phase part in (25), the fre- quency responses are real-valued functions forN2 - 1 n,=l, . . ..- 7 ’
(28)
N, - 1 nl = 1, . . . ,- 2 ’ N2 - 1 19 ~- 2 Nl - 1 nl = 1, . . . ,- N2 - 1 2 , n2 = 1, . . . ,- 2 . Therefore, according to the four types of 2-D se-quences discussed above and their even/odd
lengths (N, x N,), there are 16 different kinds of fi(o,, 02) which are tabulated in Table 1. The rela- tionships between the coefficients a(nl,n2)‘s in fi(ol, w2) and h(nl, n2) are listed in Table 2.
As in the spatial-domain case, any magnitude response
fi(o, ,
w2) can be similarly decomposed into four parts in frequency domain as below: fi(Wl, 02) = &,(w 9 w2) + fL(w 3 02)+ Rx(w42) + &(~1,~2), (29)
where
fiee(%,~2) = %(-%,~2) = fL(% -w2)
S.-C. Pei. J.-J Shyu / Signal Processing 42 (1995) 261-271 265
Table 1
h(w,,~+) of 2-D sequences with length N1 x N2 (Li = 4 (Ni - 1) for odd Ni and Li = 4 Ni for even Ni, i = 1,2)
Type Sub-type I 1 2 3 4 III 1 N, : odd, N2: odd IV N, : odd, Nz: odd N,: odd, NZ: even N, : even, NZ: odd N,: even, N,: even N,: odd, Nz: even
N,: even, Na: odd
N, : even, N2 : even N, : odd, N2: odd N,: odd, Nz: even N, : even, N2: odd N, : even, NZ: even NI : odd, N,: odd N1: odd, N2: even N, : even, N2: odd N, : even, N2 : even
1 2 ah, n2)cos((n, - f)w )cos(n202)
n,=, n,=ll L, L, C C 4n,,ndcos(h - fh)cos((n2 - h2) L, Li 1 C a(n,,n2)cos(n,w,)sin(n202) n,=on,=, L, L, 1 C a(n,,n2)cos(n,o,)sin((n2 - t)02) “,=I e=, fjj 5 a(n,,n,)cos((n, - +)wl)sin((nz - +)wz) n, = 1 n,= L 1 C a(n,.n2)sin(n,w,)cos((n, - ikd C C ah,n2)sin(h - th)cos(n2w2) n,=, n,=o
? z a(nl, n,)sin((n, - +)ol)cos((n2 - f)W2) I, = 1 “>= L L, L2 C C ah, n,)sin(n,w,)sin(n,o,) nl=* “,=I
.$,
jl
a(n,,n,)sin(n,o,)sin((n, - ib2).z,
jl
ah,n2bin(h-
thbin(n2~2)“i,“!,
a n,,n2)sin((n1(
- +)ol)sin((nz - +)w,)I 1
266 S.-C. Pei, J.-J. Shyu 1 Signal Processing 42 (1995) 261-271
Table 2
Relationship between a(nl, n2) in fi(o,, co*) and h(n,, nz) in H(o,, 02)
Type Relationship between a(n, , n2) and h(n, , n2)
I-l I-2 I-3 I-4 11-l II-2 II-3 II-4 III-1 III-2 III-3 III-4 IV-1 VI-2 IV-3 IV-4 440) = h&U a(0, n2) = 2h(Ll,Lz - n2), n2 = 1, . . , L2 a(nI,O) = 2h(L1 - nl,L,), n, = 1, , L1 a(n,,nJ = 4h(L1 - q,L, - nl), n, = 1, . . . ,L1, n2 = 1, . . . ,L1 a(O,nJ = 2h(L,,Lz - n2), n2 = 1, . , L2 a(n,,nl) = 4h(L, - nI,L, - n2), nI = 1, . . . .L1, n2 = 1, . ,Lz a(n,,O) = 2h(L, - nI,L2), nI = 1, .L1 a(n,,n2) = 4h(LI - n,,L, - n2), nI = 1, ,L1, n2 = 1, . . . ,L2 a(n1,n2) = 4h(L1 - n,,L, - n2), n, = 1, . . . ,L1, n2 = 1, . ,Lz h(nl,Lt) = 0, n, = 0, . . . ,N1 - 1 a(O,n*) = 2h(L,,Lz - n2), n2 = 1, . ,Lz a(nt,n2) = 4h(LI - n,,L, - n2), n, = 1, ,L1, n2 = 1, . . ,Lz a(O,n,) = 2h(LI,L2 - n2), n2 = 1, . , L2 a(n,,n*) = 4h(L1 - n,,L, - n2), nI = 1, . . . ,L,, nz = 1, , L2 h(n,,L,)=O,nI =0, . . . . N1 - 1 a(nl,n2) = 4h(L1 - nl, L, - nl), n, = 1, . . . .L1, n2 = 1, . . . , L2 a(n,,n*) = 4h(L1 - nI, L, - n2), nl = 1, . . . , L1, nz = 1, . . . , L2 h(LI,nz)=O,nz=O ,..., N2-1 a(nI,O) = 2h(L1 - nl, L2), nl = 1, . . , L1
a(nI,n2) = 4h(L, - nI, L, - n2), nI = 1, . . . , LI, n2 = 1, . . . , Lz h(LI,nl)=O,nz=O ,..., N1--1
a(n,,nl) = 4h(L, - nl, L, - n2), nl = 1, . ,LI, n2 = 1, . , L2 a(n,,O) = 2h(LI - q,L,), n, = 1, . . . ,LI
a(nI,n2) = 4h(L1 - nI, L, - nz), n, = 1, . . . , L1, n2 = 1, . . , L2 a(nl,n,) = 4h(L1 - n,, L, - n2), n, = 1, , L1, n2 = 1, , Lz h(LI,n,)=O,n,=O ,..., N2-1 h(nl,Lz)=O,nI =O, . . . . N1 - 1 a(nl,n,)=4h(LI-nI,L,-n2),n,=1 ,..., L,,n*=l,..., L2 h(L,,nl)=O,nz=O ,..., Nf-1
a(nI,n2) = 4h(LI - nI,L2 - nz), n, = 1, . .L,, n2 = 1, . . . , L2 h(nIrL2)=0, n, =0, . . . . N1 - 1
a(nl.nz) = 4h(LI - nl, L2 - nz), nI = 1, . . . , LI, n2 = 1, . . . , Lz a(nl,nl) = 4h(L1 - nI, Lz - n2), nI = 1, . . , L1, n2 = 1, . , L2
Also,
fiee(ol,
4,&&t~
0~1,fi,,h,
~2)and
fi,,(ol, 02) can be found from Z?(o,, 02) by&(%~2) =dC&wz) + fiwh~,) (35)
fioe(%W2) =aCfih,QJ2) - m-w42)
+ fih, -02) + fib% -0211, + fib, -02) -m-m, -02)l
S.-C. Pei, J.-J. Shyu J Signal Processing 42 (1995) 261-271 261
-
m%
3 -w2) +l+Ol,
-02)].(37) It is noted that fi,,(01,m2), E?,,(ol,oJ, &,,(ol,~J and Z?,,&U~, w2) can be realized by Type I, II, III and IV 2-D sequences, respectively. Hence given a desired magnitude response, we can realize it by either a single type 2-D sequence or several mixed type 2-D sequences. In this paper, the linear-phase 2-D FIR filters are divided into three classes as below.
Quadrantal-plane jilter: The filters which can be realized by only a single type of 2-D sequence. Half-plane jilter: The filters which can be realized by synthesizing two types of 2-D sequences. Full-plane jilter: The filters which can be realized by synthesizing three or four types of 2-D sequences. In the remainder of this paper, we will focus on the applications of four major types of 2-D se- quences for designing linear-phase 2-D FIR digital filters using the eigen-filter approach, which has successfully been used to design linear-phase 1-D filters and quadrantally symmetric 2-D filters [2-41.
4. Design of quadrantal-plane linear-phase 2-D FIR
filters
When the desired frequency response, by exclud- ing the linear-phase part, is a real-valued function, it can be realized by Type I or Type IV 2-D se- quences. On the contrary, if the desired frequency response is an imaginary-valued function, Type II and Type III 2-D sequences are suitable for these designs. For example, the typical 2-D circular filters and fan-type filters can be realized by Type I 2-D sequences, which has been discussed in [4].
Example 1. In this example, we want to design
a filter with the desired magnitude response
D(w 3 w2) =
i
1, W1’02 > 0,
- 1 01’02
<o.
(38)Fig. 1. Example 1: Amplitude response of a 23 x 23 2-D lin- ear-phase filter designed by a Type IV-1 2-D sequence.
Fig. 2. Example 2: Amplitude response of a 27 x 26 2-D lin- ear-phase filter designed by a Type II-2 2-D sequence.
268 S.-C. Pei, J.-J Shyu 1 Signal Processing 42 (1995) 261-271
Here, we use a 23 x 23 Type IV-l 2-D sequence to design it, and the eigenfilter approach in [4] can be applied after slight modification. The resultant am- plitude response is shown in Fig. 1 in which the cutoff frequencies are 0.1~ and 0.9n in both the wl- and ml-axis.
Example 2. A third-order partial differentiator is designed in this example. Excluding the part of linear phase, the desired frequency response is
D(wl,oZ) = -jo102, --x < 01,02 GR. (39)
When a 27 x 26 Type II-2 2-D sequence is used, the amplitude response is shown in Fig. 2.
5. Design of half- and full-plane linear-phase 2-D FIR filters
The half-plane filters can be divided into two categories, i.e. ‘non-neighbor symmetric/antisym- metric half-plane filters’ and ‘neighbor symmet- ric/antisymmetric half-plane filters’. Four typical
half-plane filter examples are given in Fig. 3. Fig. 3(a) presents a non-neighbor symmetric half- plane filter, and the realized sequence is organized by a Type I sequence and a Type IV sequence. The example of a non-neighbor antisymmetric half- plane filter is shown in Fig. 3(b) which can be implemented by combining a Type II sequence and a Type III sequence, so the filter coefficients are pure imaginary. Fig. 3(c) presents the example of a neighbor symmetric half-plane filter, and Type I sequence plus a Type III sequence can realize it, so the filter coefficients are complex. Fig. 3(d) shows a neighbor antisymmetric half-plane filter which can be implemented by using a Type II sequence and a Type IV sequence, hence the filter coefficients are also complex.
Example 3 (Design of a non-neighbor symmetric
half-plane Jilter). This example deals with the design of a filter with the desired magnitude response
W)
Fig. 3. Illustrated examples to explain the type of half-plane 2-D filters: (a) non-neighbor symmetric half-plane filter, (b) non-neighbor antisymmetric half-plane filter.
S.-C. Pei. J.-J. Shyu / Signal Processing 42 (1995) 261-271 269
Fig. 3. (c) Neighbor symmetric half-plane filter, (d) neighbor antisymmetric half-plane filter.
By Eq. (29), D(oi , w2) can be obtained by summing the four parts as
+ R&l 9 4 + nmh, %I, and from (34)-(37) we can get
De&i, ~2) = 0.5, (41) and Doo(~, ~2) = i 0.5, W1’02 > 0, - 0.5, wi ‘02 < 0.
Hence, two types of 2-D sequences are needed, i.e. Type I sequence realizes D,, and Type IV sequence realizes D,,. Since Dee(q) 02) corresponds to a unit
impulse response in the spatial domain and
Doo(wl,w2) is similar to Example 1, we only add a unit impulse to the origin of the resultant impulse response in Example 1, and then normalize the amplitude response to unit. The overall amplitude response is shown in Fig. 4.
Fig. 4. Example 3: Amplitude response of a 23 x 23 non-neigh- bor symmetric half-plane filter.
270 S.-C. Pei, J.-J. Shyu 1 Signal Processing 42 (1995) 261-271
Fig. 5. Example 4: (a) Desired amplitude response and its ingredients, (b) the act ual amplitude response.
S.-C. Pei, J.-J. Shyu J Signal Processing 42 (1995) 261-271 271
As to the design of full-plane filters, the four types of 2-D sequences are required. For simplicity, an example is presented to demonstrate the design procedures.
Example 4. This example presents the design of a full-plane filter with the desired response and its ingredients as shown in Fig. 5(a). D,, and D,, can be synthesized by using Type I and Type IV 2-D sequences, respectively, and D,, and D,, can be approached by using Type II and Type III 2-D sequences. Fig. 5(b) shows the resultant amplitude response with filter length 27 x 27, if the above synthetic method is used.
6. Conclusions
In this paper, we have presented the symmetric properties of 2-D sequences and their applications for designing linear-phase 2-D FIR filters. It is shown that there are 16 types of cases to be con- sidered according to the symmetry/antisymmetry
of 2-D sequences in both directions and their filter lengths (even or odd). The corresponding types of amplitude responses are tabulated into a complete table if these 2-D sequences are used to realize 2-D filters. Also, the definitions of quadrantal-plane, half-plane and full-plane filters are described along with numerical examples designed by the eigenfilter approach. References ct1 PI c31 M
L.R. Rabiner and B. Gold, Theory and Application o/Digital
Signal Processing, Prentice-Hall, Englewood Cliffs, NJ, 1975.
SC. Pei and J.J. Shyu, “Eigenfilter design of higher order digital differentiators”, IEEE Trans. Acoust. Speech Signal
Process., Vol. 37, April 1989, pp. 505-511.
P.P. Vaidyanathan and T.Q. Nguyen, “Eigenfilter: A new approach to least-squares FIR filter design and applications including Nyquist filters”, IEEE Trans. Circuits Systems. Vol. 34, January 1987, pp. 11-23.
S.C. Pei and J.J. Shyu, “2-D FIR eigenfilters: A least squares approach”, IEEE Trans. Circuits Systems, Vol. 37, January 1990, pp. 24-34.