Professional Documents
Culture Documents
130
Wavelets and Filter Banks
1 2
1 2
1 2
h0[n] =
f0[n] =
1 2
1 2
0 1
h1[n] =
f1[n] =
-1 2
-1 -1 2
Analysis: 1 r0[n] = 2 (x[n] + x[n 1]) y0[n] = r0[2n] 1 y0[n] = (x[2n] + x[2n 1]) 2 Similarly 1 y1[n] = (x[2n] x[2n 1]) 2 lowpass filter downsampler -----------------j
------------------k
3
Matrix form
4 y0[0] y0[1] : : y1[0] y1[1] 4
4 3 1 3 0 1 0 0 1 0 3 1 3
0 3 1 3
: x[-1] x[0] x[1] x[2] : :
1 2
4
3 -1 1 3 0 0 4 0 -1
yo y1
L = B
x
-------------------l
Synthesis t0[n] =
&)')(
&)')(
-
y0[n/2] 0
1 2
v0[n] =
&)')(
&)')(
lowpass filter
1 2
1 2
n even n odd
Similarly v1[n] =
1 2
1 2
y1[n/2]
y1[ n + 1 ]
2
n even
n odd
(y0[n/2] + y1[n/2])
(y0[ n + 1] - y1[ n + 1 ])
2
2
n even
n odd
1 2
i.e. ^
x[2n-1] =
^ x[2n]
^ So x[n] =
1 2
1
2
4 4 1 0 1 0 3
3 3
4 4 -1 0 1 1
0 1 0 1 4 4
0 -1 -1 1 4 4
^ x
y0
LT
BT
y1
----------------m
Perfect reconstruction means that the synthesis bank is the inverse of the analysis bank.
^ = x x
LT
BT
&'(
= I
B
&'(
W-1
W Wavelet transform matrix In the Haar example, we have the special case W1 = WT orthogonal matrix So we have an orthogonal filter bank, where Synthesis bank = Transpose of Analysis bank f0[n] = h0[- n] = h1[- n] f1[n]
y0[n]
3 3
t0[n]
v0[n]
F0(z)
H1(z)
r1[n]
y1[n]
t1[n]
F1(z)
^ x[n] v1[n]
10
H0(z) and H1(z) are normally lowpass and highpass, but not ideal H1(w) 1 H1(w) H0(w)
-p
11
Lets see why: Lowpass channel has Y0(z) = {R0(z) + R0(-z)} (downsampling)
= {H0(z) X (z) + H0(-z)X(-z)} In frequency domain: X(z) X(w) X(-z) X(w + p) w X(z) X( 2 )
Y0(w) = {H0(
w ) 2
or X(eiw)
X(
w ) 2
+ H0(
w 2
+ p)X(
w 2
+ p)}
12
Suppose X(w) = 1 (input has all frequencies) Then R0(w) = H0(w), so that after downsampling we have
R0(
w 2
+ p)
R0( w )
2
R0(
w 2
+ p)
Y0(w) =
-p 0 p
aliasing
Goal is to design F0(z) and F1(z) so that the overall system is just a simple delay - with no aliasing term: V0(z) + V1(z) = z- ? X(z)
13
= F0(z){ H0(z) X(z) + H0(-z) X(-z)} V1(z) = F1(z){ H1(z) X(z) + H1(-z) X(-z)}
So we want
{F0(z) H0(z) + F1(z) H1(z) } X(z)
+ {F0(z) H0(-z) + F1(z) H1(-z) } X(-z)
14
= z- ? X(z)
Compare terms in X(z) and X(-z): 1) Condition for no distortion (terms in X (z) amount to a delay) F0(z) H0(z) + F1(z) H1(z) = 2z- ?
--------------j
2) Condition for alias cancellation (no term in X(-z)) F0(z) H0(-z) + F1(z) H1(-z) = 0
--------------k
----------------------l
15
What happens in the time domain? F0(z) = H1(-z) F0(w) = H1(w + p) = h1[n] (-z)-n
n
So the filter coefficients are f0[n] = (-1)n h1[n] f1[n] = (-1)n+1 h0[n] Example h0[n] = { a0, a1, a2}
h1[n] = { b0, b1, b2}
------------------------------m
Substitute F1(z) = -H0(-z) , H1(z) = F0(-z) in the zero distortion condition (Equation j) F0(z) H0(z) - F0(-z) H0(-z) = 2z- ? i.e. P0(z) - P0(-z) = 2z-? ----------------------------n
17
----------------------------o
P(-z) = -z? P0(-z) since ? is odd So we can rewrite Equation n as z- ? P(z) + z- ? P(-z) = 2z- ? i.e. P(z) + P(-z) = 2
---------------------------p
This is the condition on the normalized product filter for Perfect Reconstruction.
18
Design Process 1. Design P(z) to satisfy Equation p. This gives P0(z). Note: P(z) is designed to be lowpass. 2. Factor P0(z) into F0(z) H0(z). Use Equations l to find H1(z) and F1(z). Note: Equation p requires all even powers of z (except z0) to be zero: p[n]z-n + p[n](-z)-n = 2
n n
&'(
p[n] =
1 ; 0 ;
19
For odd n, p[n] and p[n] cancel. The odd coefficients, p[n], are free to be designed according to additional criteria. Example: Haar filter bank H0(z) = 2 (1 + z-1) F0(z) = H1(-z) =
1
H1(z) = 2 (1 z-1)
20
10
? = 1
1 -1 2 (1 + z)(1 + z )
21
11