Download as pdf or txt
Download as pdf or txt
You are on page 1of 241

Seoul National University 1.

Discrete time signals and systems


School of Electrical Engineering

1. Discrete-time signals and systems


• Discrete - time signals: sequences

– Discrete-time signals are represented as sequences of numbers


– A sequence is a function whose domain is the set of integers
– Define the nth number in the sequence by x [ n ], a set of numbers x can be represented
by
x = { x [ n ]} , −∞ < n < ∞

– Note that
x [ n ] = xa ( nT )
xn
x0
x −1
x1

discrete-time signal analog signal


x2
where T denote the sampling period.
– A delayed or shifted version of x [ n ] : n

y [ n ] = x [ n − n0 ]
where n0 is an integer

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 1. Discrete time signals and systems
School of Electrical Engineering

– An unit sample sequence is defined by


⎧0; n = 0
δ [ n] = ⎨
⎩1; n ≠ 0

which is also referred to as a discrete-time impulse or simply as an impulse

– An arbitrary sequence can be represented as a sum of weighted and delayed


impulses ∞
x [ n] = ∑ x [ k ]δ [ n − k ]
k =−∞

Ex) x [ n ] = m−3δ [ n + 3] + m1δ [ n − 1] + m4δ [ m − 4] m1


m−3
4
-3 -2 -1 0 1 2 3 5 6
– The unit step sequence is defined by
⎧1, n ≥ 0 m4
u [ n] = ⎨
⎩0, n < 0

⇒ u [ n ] = δ [ n ] + δ [ n − 1] + ... = ∑ δ [ n − k ]
k =0
-1 0 1 2 3
⇒ δ [ n ] = u [ n ] − u [ n − 1]

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 1. Discrete time signals and systems
School of Electrical Engineering

• Let x [ n ] be an exponential sequence given by


x [ n ] = Aα nu [ n ]

– For complex α = α e 0
and A = A e jφ ,
x [ n ] = A e jφ α e jω0n
n

= A α ⎡⎣cos (ω o n + φ ) + j sin (ω 0 n + φ ) ⎤⎦
n

– Complex exponential sequence ( α = 1)


x [ n ] = A cos (ω 0 n + φ ) + j A sin (ω 0 n + φ )

where ω 0 is called the frequency of the complex sinusoid and φ is called the phase

x [ n ] = Ae
j (ω o + 2π )n
– Since = Ae jω0n e j 2π n = Ae jω0n ,
complex exponential sequences with frequencies (ω 0 + 2π k ) , where k is an integer,
are indistinguishable from one another
– A sinusoidal sequence can be represented by x [ n ] = A cos(ω 0 n + φ ), ∀n
– Since x [ n ] = A cos ⎡⎣(ω 0 + 2π k ) n + φ ⎤⎦ = A cos (ω 0 n + φ ) ,
we consider ω in a frequency interval of length 2π ,
−π < ω 0 ≤ π or 0 ≤ ω 0 < 2π .

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 1. Discrete time signals and systems
School of Electrical Engineering

– A sequence is called periodic with an integer period of N, if


x [ x ] = x [ n + N ] , ∀n
– In order for a sinusoidal sequence to be
A cos (ω 0 n + φ ) = A cos ⎡⎣ω 0 ( n + N ) + φ ⎤⎦

it requires for ω 0 N = 2π k .

– A sinusoidal sequence is not necessarily periodic with a period of and may not
ω0
be periodic at all, depending on the value of ω 0
1 2π k
Ex ω0 = π ⇒ N = ⋅ 3 = 6k
3 π
ω 0 = 1 ⇒ N = 2π k ⇒ No integer N
• High and low frequency concept: A continuous time sinusoidal signal x [ n ] = A cos ( Ω0t + φ )
oscillates more rapidly as Ω0 increases. However, x [ n ] = A cos (ω 0 n + φ ) oscillates
more rapidly as ω 0 increases from 0 toward π .
But, as ω 0 increases from π to 2π , the oscillation becomes slower due to symmetry
with respect to π.
⎛π ⎞ ⎛ 15 ⎞
Ex : A cos ⎜ n + φ ⎟ = A cos ⎜ π n + φ ⎟
⎝8 ⎠ ⎝8 ⎠

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 1. Discrete time signals and systems
School of Electrical Engineering

• Discrete-time systems

xn yn
T {}
⋅ y [ n ] = T { x [ n ]}

– Ideal delay system


y [ n ] = x [ n − nd ] , nd is a positive integer

– Moving averager
1 N −1
y [ n ] = { x [ n ] + x [ n − 1] + ... + x [ n − N + 1]} = ∑ x [ n − k ]
1
N N k =0
– Memoryless system
A system is referred to as memoryless if the output y [ n ] depends only on the input x [ n ]
Ex : y [ n ] = x 2 [ n ] , ∀n
– Linear system : principle of superposition
T {ax1 [ n ] + bx2 [ n ]} = aT { x1 [ n ]} + bT { x2 [ n ]}
Ex: accumulator n

y [n] = ∑ x[k ]
k = −∞

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 1. Discrete time signals and systems
School of Electrical Engineering

– Time-invariant system (TIS): A time shift or delay of the input sequence results in a
corresponding shift in the output sequence
y1 [ n ] = T { x [ n − nd ]} ⇒ y [ n − nd ] = y1 [ n ]
Ex : y [ n ] = x 2 [ n ] → TIS
n
y [ n] = ∑ x[k ] → TIS
k =−∞
y [ n ] = x [ Mn ] : compressor
y1 = x1 [ Mn ] = x [ Mn − no ]
y [ n − n0 ] = x ⎡⎣ m ( n − n0 ) ⎤⎦ ≠ y1 [ n ] → not TIS
– Causality: A system is causal if the output sequence at n = no depends only on the
input sequences for n ≤ n0, ∀n0
Ex: y [ n ] = x [ n + 1] − x [ n ] ⇒ non causal
y [ n ] = x [ n ] − x [ n − 1] ⇒ causal
– Stability: A system is stable in the BIBO sense iff every bounded input sequence
produces a bounded output sequence
x [ n ] ≤ B X < ∞ ⇒ y [ n ] ≤ B y < ∞ , ∀n
n
⎧0 n<0
y [ n] = ∑ u [ k ] = ⎨n + 1
k =−∞ ⎩ n≥0
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 1. Discrete time signals and systems
School of Electrical Engineering

• Linear time-invariant systems

– Let nk [ n ] be the response of the system to the input δ [ n − k ] , i.e., hk [ n ] = T {δ [ n − k ]}


y [ n ] = T { x [ n ]}
⎧ ∞ ⎫ ∞
= T ⎨ ∑ x [ k ]δ [ n − k ]⎬ = ∑ x [ k ]T {δ [ n − k ]}
⎩ k =−∞ ⎭ k =−∞

= ∑ x [ k ] h [ n]
k =−∞
k

– Time invariance implies


δ [ n ] → h [ n ] ⇒ δ [ n − k ] ⇒ h [ n − k ] = hk [ n ]

– Discrete-time convolution

y [ n] = ∑ x [ k ]h [ n − k ] Δ x [ n] ∗ h [ n]
k =−∞

– To compute h [ n − k ] , first reflect h [ k ] about the origin to obtain h [ −k ] and then shift
the origin to k = n ;

hk h −k h 6− k

0 1 -2 -1 0 0 1 2 3 4 5
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 1. Discrete time signals and systems
School of Electrical Engineering

Ex h [ n ] = u [ n ] − u [ n − N ]
⎧1, 0 ≤ n ≤ N − 1
=⎨
⎩0, otherwise
x [ n ] = a nu [ n ]
n < 0; y [ n ] = 0
1 − a n+1
n
n ≤ 0 ≤ N − 1; y [ n ] = ∑ a = k

k =0 1− a
n
a n− N +1 − a n+1
n > N − 1; y [ n ] = ∑ ak =
k = n − N +1 1− a
⎛1− aN ⎞
=a n − N +1
⎜ ⎟
⎝ 1− a ⎠
n − N −1 b g n 0 k

yn

n
0

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 1. Discrete time signals and systems
School of Electrical Engineering

• Properties of LTI system

– Commutative x [ n] ∗ h [ n] = h [ n] ∗ x [ n]

⇒ y [ n] = ∑ x [ k ]h [ n − k ]
k =−∞

∑ x [ n − k ]h [ k ]
=
k =−∞

x [ n ] ∗ ( h [ n ] + h [ n ]) = x [ n ] ∗ h [ n ] + x [ n ] ∗ h [ n ]
1 2 1 2

– Cascaded connection
x [n] v [n] y [n]
h1 h2

Letting h [ n ] Δ h1 [ n ] ∗ h2 [ n ] , we have

v [ n ] = x [ n ] ∗ h1 [ n ]
y [ n ] = v [ n ] ∗ h2 [ n ]
= x [ n ] ∗ h1 [ n ] ∗ h2 [ n ]
= x [ n] ∗ h [ n]

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 1. Discrete time signals and systems
School of Electrical Engineering

– A Linear system is stable iff the impulse response is absolutely summable, i,e.,

S Δ ∑ h(k ) < ∞
k =−∞
Proof
Sufficient condition: ∞ ∞
y [ n] = ∑ h[k ] x[n − k ] ≤ ∑ h[k ] x[n − k ]
k =−∞ k =−∞

If x [ n ] is bounded, i.e., x n ≤ BX [ ]

then, y [ n ] ≤ BX ∑ h[k ]
k =−∞

∑ h[k ] < ∞
k =−∞
⇒ y [ n] < ∞

Necessary condition:
Show that if S = ∞ , a bounded input can cause an unbounded output.
Consider a bounded sequence given by

⎧ h * [ −n]
, h [ n] ≠ 0 [ ]
2
⎪ ∞ ∞ h k
x [ n] = ⎨ h [ −n] ⇒ y [ 0] = ∑ x [ − k ]h [ k ] = ∑ =S =∞
⎪ 0 h [ k ]
, h [ n] = 0
k =−∞ k =−∞

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 1. Discrete time signals and systems
School of Electrical Engineering

Ex h [ n ] = a nu [ n ]

1
⇒S =∑a =
n

n =0 1− a
a <1⇒ S < ∞
a ≥ 1 ⇒ S = ∞ ⇒ unstable
xn yn Backward xn
Accumulator
difference

h [ n ] = u [ n ] ∗ (δ [ n ] − δ [ n − 1])
= u [ n ] − u [ n − 1]
= δ [ n]

Note: The property of convolution can be used to analyze the time-invariant system

xn one sample Forward yn Backward



delay difference difference
δ n −1 δ n +1 −δ n

h [ n ] = δ [ n − 1] ∗ (δ [ n + 1] − δ [ n ])
= δ [ n ] − δ [ n − 1]

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 1. Discrete time signals and systems
School of Electrical Engineering

• Linear constant coefficients difference equations

– An Nth order linear const. difference eq. is represented by


N M

∑ ak y [ n − k ] = ∑ bk x [ n − k ]
k =0 k =0

When the right side term is equal to zero, it is called the homogeneous difference eqn.

x [n] y [n]
Ex: Accumulator
n n −1
y [ n] = ∑ x [ n] = x [ n] + ∑ x [ k ] = x [ n] + y [ n − 1] +
k =−∞ k =−∞

⇒ y [ n ] − y [ n − 1] = x [ n ] D
y [ n − 1]
Ex: Moving average

h [ n] =
1
M
( u [ n ] − u [ n − M ])
1 M −1
⇒ y [ n] = ∑ x[n − k ] xn 1 yn
M k =0
M _ ∑
h [ n ] = (δ [ n ] − δ [ n − M ]) ∗ u [ n ]
1
M M-sample
delay
y [ n ] − y [ n − 1] =
1
M
( x [ n ] − x [ n − M ])

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 1. Discrete time signals and systems
School of Electrical Engineering

Ex
y [ n ] = ay [ n − 1] + x [ n ]
Consider x [ n ] = K δ [ n ] and y [ -1] = c ← auxiliary cond.
For n ≥ 0;
⇒ y [ 0] = ac + K
y [1] = ay [ 0] + 0 = a 2c + aK
:
y [ n ] = a n+1 ⋅ c + a n K , n ≥ 0 ⇒ y [ n ] = a n+1 ⋅ c + Ka nu [ n ]
For n < −1;
y [ −2] = a −1 ⎡⎣ y [ −1] − x [ −1]⎤⎦ = a −1 ⋅ c
y [ −3] = a −1 ⋅ a −1c = a −2c
:
y [ n ] = a n+1 ⋅ c, n ≤ −1

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 1. Discrete time signals and systems
School of Electrical Engineering

• Frequency-domain representation of DTS


x [ n ] = e jω n

⇒ y [ n] = ∑ h [ k ]e ω[ j n−k ]

k =−∞

=e jω n
∑ h [ k ]e
k =−∞
− jω k


Let H ( e jω ) Δ ∑ h [ k ]e − jω k

k =−∞

= H R ( e jω ) + jH ( e jω )
( )
= H ( e jω ) e
jθ H e jω

y [ n ] = H ( e jω ) e jω n

eigen-value eigen-function of the system

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 1. Discrete time signals and systems
School of Electrical Engineering

Ex: Ideal delay y [ n ] = x [ n − n0 ]


For x [ n ] = e jω n ,
y [ n] = e = e − jω n0 e jω n ⇒ H ( e jω ) = e − jω n0
jω [ n − n0 ]

Since h [ n ] = δ [ n − n0 ] for an ideal delay system,



H ( e jω ) = ∑ δ [ n − n ]e
0
− jω n
= e − jω n0 ⇒ H ( e jω ) = 1
n =−∞

{
Arg H ( e jω ) = −ω n0 }
– For x [ n ] = ∑α k e jω n , k

k
the output of the system is
(
y [ n ] = ∑α k H e jωk e jωk n ) ← principle of superposition
k
Ex: x [ n ] = A cos (ω 0 n + φ ) =
2
(
A jφ jω0n
e e + e − jφ e − jω0n )
⇒ y [ n] =
A⎡
2 ⎣ ( ) ( )
H e jω0 e jφ e jω n + H e − jω0 e − jφ e − jω0n ⎤⎦

If h [ n ] is real, H ( e − jω ) = H ∗ ( e − jω ) = H ( e jω ) e − jθ

⇒ y [ n ] = A H ( e jω ) cos (ω 0 n + φ + θ ) , where θ =arg ⎡⎣ H ( e jω ) ⎤⎦

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 1. Discrete time signals and systems
School of Electrical Engineering


Ex: Delay H e 0 = 1;( ) θ = −ω 0 n0
⇒ y [ n ] = A cos (ω 0 ( n − n0 ) + φ )

– Discrete-time LTI → periodicity of 2π

( ) ∑ h[n]e

j (ω + 2 kπ ) − j (ω + 2 kπ )n
⇒H e =
k =−∞

= ∑ h [ n]e
k =−∞
− jω n
= H ⎡ e(

jω )


⇒ H (e jω
) is periodic with a period of 2π

Ex: Ideal frequency selective filters (LPF)

c h
H e jω

ω
−π − ω 0 −π ω 0 π 2πrω 0 2π 2π + ω 0

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 1. Discrete time signals and systems
School of Electrical Engineering

⎧ 1
Ex: ⎪ − M1 ≤ n ≤ M 2
h [ n] = ⎨ M1 + M 2 + 1

⎩ 0 otherwise

⇒ H (e ) =
M2
1


M 1 + M 2 + 1 n=− M1
e − jω n

e + jω M1 − e (
− jω M 2 +1)
1
=
M1 + M 2 + 1 1 − e − jω
e ( 2 1) e
− jω M +1− M / 2 jω ( M1 + M 2 +1) / 2 − jω ( M1 + M 2 +1) / 2
−e
=
M1 + M 2 + 1 1 − e − jω
−π −π
ω ( M 1 + M 2 + 1)
1 sin
− jω ( M 2 − M1 ) 2
= e θ
M1 + M 2 _1 ω
sin
2 π

−π

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 1. Discrete time signals and systems
School of Electrical Engineering

• Representation of sequences by Fourier transform


– A stable sequence can be represented by a Fourier integral of the form

∫ π X ( e ) e dω
1 π
x [ n] = ω ω j j n
- - - (A )
2π 2


where X ( e jω ) =
∑ x [ n]e
n =−∞
− jω n
- - - (B)

( )
= X ( e jω ) e
jθ X e jω
← polar cord. form

= X R ( e jω ) + jX 1 ( e jω ) ← rectangular cord. form

Since X ( e jω ) is periodic with period 2π , it is of the form of Fourier series for the
continuous-variable periodic function X ( e ).

– Note that Eq (A) is the inverse of Eq. (B)


⎛ ∞ ⎞
∫ π X (e )e
1 π 1 π
x [ n] = jω jω n
= ∫−π ⎜⎝ n∑ x [ m ]e − jω n ⎟ e jω n dω
2π − 2π =−∞ ⎠

1 π jω n−m
= ∑ x [ m ] ∫ e ( ) dω = x [ n ]
n =−∞ 2π 2π
⎛ 1 π sin π ( n − m ) ⎞
= δ [ n − m] ⎟
jω ( n − m )
⎜∵ ∫π e dω =
π ( n − m)
⎝ 2π ⎠
2

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 1. Discrete time signals and systems
School of Electrical Engineering

If x [ n ] is absolutely summable (i.e., stable sequence), X ( e ) exists.





X (e jω
) = ∑ x [ n]e − jω n

n =−∞
∞ ∞
≤ ∑ x [ n ] e − jω ≤ ∑ x [ n] < ∞
n =−∞ n =−∞

– Furthermore, x [ n ] can be showen to converge uniformly to a continuous function of ω .


⇒ Any stable sequence (or system) have a finite and continuous frequency response:
(Sufficient condition for existence of H ( e jω ) )
– A finite-length sequence is absolutely summable
Ex: x [ n ] = a nu [ n ]
∞ ∞
X ( e jω ) = ∑ a nu [ n] e− jωn = ∑a e n − jω n

n =−∞ n =−∞

1
=− jω
, if ae− jω = a < 1
1 − ae
– If a sequence is not absolutely summable, but square summable ; i.e.,

∑ x [ n] < ∞
2

n =−∞
it can be represented by a Fourier transform with mean-square convergence, i.e.,
2

X (e ) − ∑ x [ n] e
π M
lim ∫ jω − jω n
dω = 0
M →∞ −π
n =− M

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 1. Discrete time signals and systems
School of Electrical Engineering

Ex: Ideal LPF


⎧⎪1 ω < ω c
H LP ( e jω ) = ⎨
⎪⎩0 ω c < ω < π
1 ωc jω n sin πω c n
⇒ hLP ( n ) =
2π ∫−ωc
e d ω = , ∀n
πn
⇒ non causal and not absolutely summable
H Lp ( e jω ) is discontinuous at ω = ω c
But is mean-square summable
Ex: x [ n ] = 1, ∀n : neither absolutely nor square summable

⇒ X ( e jω ) = ∑ 2πδ (ω + 2kπ )
k∞=−∞
Since X (e jω
) = ∑ 2πδ (ω − ω 0 + 2kπ )
k =−∞

1 π
⇒ x [ n] = ∫ 2πδ (ω − ω 0 ) e jω n dω
2π −π
= e jω0n ⇒ When ω = 0, x [ n ] = 1
0

X (e jω
) is not finite for all ϖ

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 1. Discrete time signals and systems
School of Electrical Engineering

– Theory of generalized functions


∞ ∞

∑e
n =−∞
j (ω −ω 0 )n
= ∑ 2πδ (ω − ω
k =−∞
0 + 2kπ )

⇒ x [ n ] = ∑ ame jω m n
⇒ X (e jω
) = ∑ ∑ 2π a δ (ω − ω
m m + 2kπ )
m k =−∞ m

– Conjugate symmetric sequence: xe [ n ] = xe [ −n ]


*

– Conjugate anti-symmetric sequence: xo [ n ] = − xo [ −n ]


*

⇒ x [ n ] = xe [ n ] + xo [ n ]

xe [ n ] =
1
2
( x [ n ] + x∗ [ − n ]) even sequence : xe [ n ] = xe [ − n ]
odd sequence: xo [ n ] = − xo [ − n ]
xo [ n ] = ( x [ n ] − x∗ [ − n ])
1
2
⇒ X ( e jω ) = X e ( e jω ) + X o ( e jω ) = X R ( e jω ) + jX I ( e jω )

where
X e ( e jω ) =
1
2
(
X ( e jω ) + X ∗ ( e jω ) )
(
X o ( e jω ) = X ( e jω ) − X ∗ ( e − jω )
1
2
)
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 1. Discrete time signals and systems
School of Electrical Engineering

Note that X e ( e ) = X ( e ) and X o ( e ) = − X ( e )


jω ∗ − jω jω ∗ − jω

Re{ x [ n ]} ↔ X e ( e jω ) Re { x [ n ]} ↔ X ( e jω ) = X ∗ ( e jω )
j Im { x [ n ]} ↔ X o ( e jω )
xe [ n ] ↔ X R ( e jω )
xo [ n ] ↔ jX I ( e jω )

X ( e jω ) =
1
Ex: a <1
1 − ae − jω
X ∗ ( e jω ) = = X ( e jω )
1
− jω
1 − ae
X R ( e jω ) = (1 − a cosω ) = X R ( e jω )
1
1 + a − 2a cos ω
2

X I ( e jω ) = − X I ( e − jω )
− a sin ω
θ X ( e jω ) = tan −1 = −θ X ( e − jω )
1 − a cos ω

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 1. Discrete time signals and systems
School of Electrical Engineering

• Fourier transform theorems


F { x [ n ]} = X ( e jω )

{
x [ n ] = F −1 x ( e jω ) }
⇒ X [ n ] ←⎯
F
→ X ( e jω )

– Linearity: ax1 [ n ] + bx2 [ n ] ←⎯→ aX 1 ( e ) + bX 2 ( e )


F jω jω

– Delay: x [ n − n0 ] ←⎯
F
→ X ( e jω ) e − jω n 0

e jω0n ←⎯
F
(
→ X e j (ω −ω0 ) n )
– Time reversal: x [ −n ] ←⎯→ X ( e )
F − jω

If x [ n ] is real, x [ − n ] ←⎯→ X ( e )
F ∗ + jω

– Differentiation:
X ( e jω )
d
nx [ n ] ←⎯
F
→j

– Parseval’s theorem:
∞ 2

X ( e jω ) dω
1 π
∑ x [ n] =
2
E Δ
n =−∞ 2π ∫π

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 1. Discrete time signals and systems
School of Electrical Engineering

– Convolution:

x [ n ] ←⎯
F
→ X ( e jω ) , h [ n ] ←⎯
F
→ H ( e jω )

⇒ y [ n] = ∑ x [ k ]h [ n − k ] = x [ n] ∗ h [ n] ←⎯→Y ( e ω ) = X ( e ω ) H ( e ω )
k =−∞
F j j j

→ Y ( e jω ) = ∫ π X ( e )H ( e ) dξ
1 π
y [ n ] = x [ n ] h [ n ] ←⎯ (ω ξ )
F j ξ j −

2π −

periodic convolution

⇒ Multiplication of two sequences is equivalent to periodic convolution of


corresponding Fourier Transforms.

Ex: y [ n ] − 1 y [ n − 1] = x [ n ] − 1 x [ n − 1]
2 4
1 1 − jω
1 − e − jω e
⇒ H (e ) =
1 1 1
⇒ δ [ n ] − δ [ n − 1] = h [ n ] − h [ n − 1] jω 4 = − 4
4 2 1 − jω 1 − jω 1
1− e 1− e 1 − e − jω
2 2 2
n n −1
1 ⎛1⎞ 1⎛1⎞
a u [ n ] ←⎯→
n F
; α < 1 ⇒ h [ n ] = ⎜ ⎟ u [ n ] − ⎜ ⎟ u [ n − 1]
1 − ae − jω ⎝2⎠ 4⎝ 2⎠

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 1. Discrete time signals and systems
School of Electrical Engineering

• Discrete-time Random Signals

– Consider an LTI system with impulse response h [ n ]



y [ n] = ∑ h[n − k ] x[k ]
k =−∞
When x [ n ] is a WSS discrete-time random process,
μ X [ n ] Δ E { X [ n ]} , μY [ n ] Δ E { y [ n ]}

– If stationary, μ X [ n ] = μ X
⎧ ∞

μY [ n ] = E ⎨ ∑ h [ n − k ] x [ k ]⎬
⎩ k =−∞ ⎭
∞ ∞
= ∑ h [ n − k ] E { x [ k ]} = ∑ h [ k ] E { x [ n − k ]}
k =−∞ k =−∞

= μX ∑ h[k ]
k =−∞

= μX H (e j0 )

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 1. Discrete time signals and systems
School of Electrical Engineering

– Autocorrelation of y n [ ]
φ yy [ n, n + m ] = E { y [ n ] y [ n + m]}
⎧ ∞ ∞ ⎫
= E ⎨ ∑ ∑ h [ k ] h [ l ] x [ n − k ] x [ n − l + m ]⎬
⎩ k =−∞ l =−∞ ⎭
= ∑∑ h [ k ]h [l ] E { x [ n − k ] x [ m + m − l ]}
k l

= ∑∑ h [ k ]h [l ]φ xx [ m + k − l ] = φ yy [ m ]
k l
Let l − k Δ i. Then,
∞ ∞
φ yy [ m ] = ∑ φ [ m − i ] ∑ h [ k ] h [i + k ]
xx
i =−∞ k =−∞

Autocorrelation sequence of h [ n ]: φh [i ] Δ ∑ h [ k ] h [i + k ] ( )
H e jω
k =−∞

⇒ φ yy [ m ] = ∑ φ [i ]φ [ m − i ] ωa ωb
h xx
i =−∞

⇒ Φ yy ( e jω ) = Φ h ( e jω ) Φ xx ( e jω ) = H ( e jω ) Φ xx ( e jω )
2

where Φ h ( e jω ) = H ( e jω ) H ∗ ( e jω ) = H ( e jω )
2

Note : E { y 2 [ n ]} = φ yy ( 0 ) = Φ yy ( e jω ) dω = H ( e jω ) Φ xx ( e jω ) dω ≥ 0
1 π 1 π 2

2π ∫π
− 2π ∫π

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 2. Periodic sampling of continuous-time signals
School of Electrical Engineering

2. Periodic Sampling of Continuous-time Signals


• Impulse sampling: ideal continuous-to–discrete (C/D) converter
xc ( t ) xs ( t )
x [ n ] = xc ( nT ) , − ∞ < n < ∞

s ( t ) = ∑ δ ( t − nT )
⎛ 1⎞
where T ⎜ = ⎟ is the sampling period and f s is called the sampling frequency
⎝ fs ⎠


xs ( t ) = xc ( t ) ∑ δ ( t − nT ) ⇐ shifting
n =−∞
property of the impulse function

= ∑ xc ( nT )δ ( t − nT )
n =−∞

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 2. Periodic sampling of continuous-time signals
School of Electrical Engineering

– Fourier transform of xs ( t )

X s ( f ) = F { xs ( t )} = ∫ ∑ xc ( nT )δ ( t − nT ) e − j 2π ft dt
n =∞

= ∑ xc ( nT ) e − j 2π fnT
n =∞

⎧ ∞ ⎫
X s ( f ) = X c ( f ) ∗ F ⎨ ∑ δ ( t − nT ) ⎬
⎩ n=−∞ ⎭

⎛ n⎞
Ω s = 2π / T = 2π f s
1
= Xc ( f ) ∗ ∑ δ ⎜ f − ⎟
T n =−∞ ⎝ T⎠
1 ∞ ⎛ n⎞
= ∑ X c ⎜ f − ⎟ ⇐ periodic function
T n=∞ ⎝ T⎠

Xs ( f )

f s − W ≤ W ⇔ f s ≤ 2W
− fs −W 0 W fs − W f s
⇒ Aliasing
Xc ( f )

−W W
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 2. Periodic sampling of continuous-time signals
School of Electrical Engineering

• Natural Sampling

xc ( t ) xs ( t )

p (t )
0 τ T T +τ

1 nτ
p (t ) = ∑ pe
n =−∞
n
j 2π f s nt
; pn =
T
sin c
T

xs ( t ) = xc ( t ) p ( t )
⎧ ∞
⎫ Xs ( f )
⇒ X s ( f ) = F ⎨ xc ( t ) ∑ pn e j 2π f s nt ⎬
⎩ n =−∞ ⎭

⎛ n⎞
= ∑ pn X c ⎜ f − ⎟
n =−∞ ⎝ T⎠
− fs 0 fs

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 2. Periodic sampling of continuous-time signals
School of Electrical Engineering

• Sample and hold (S/H)

xc ( t ) xs ( t )


1 ⎛τ ⎞
p (t ) P( f ) = sinc ⎜ f ⎟
s (t ) T ⎝T ⎠

⎡ ∞

xs ( t ) = ⎢ xc ( t ) ∑ δ ( t − nT ) ⎥ ∗ p ( t )
⎣ n =−∞ ⎦
⎡ 1 ∞
⎛ n ⎞⎤
⇒ X s ( f ) = ⎢ X c ( f ) ∗ ∑ δ ⎜ f − ⎟⎥ p ( f )
⎣ T n=−∞ ⎝ T ⎠⎦
1 ∞ ⎛ n⎞
= p( f ) ∑ X ⎜ f − ⎟ Xs ( f )
T n=−∞ ⎝ T⎠

− fs 0 fs

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 2. Periodic sampling of continuous-time signals
School of Electrical Engineering

• Nyquist Sampling Theorem

– If xc ( t ) is strictly band limited, i.e., X ( f ) = 0 for


f >W
1
and the sampling frequency is chosen such that f s = = 2W ,
T
then

Xs ( f ) = ∑ x ( nT ) e
n =−∞
c
− j 2π fnT

Since
1
Xc ( f ) =
X s ( f ), f ≤ W ,
2W
if the sample values xc ( nT ) are specified for all time, X c ( f ) is uniquely determined
by using the Fourier series.
⇒ xc ( t ) is uniquely determined by xc ( nT ) , n = 0, ±1, ±2, ⋅ ⋅ ⋅.

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 2. Periodic sampling of continuous-time signals
School of Electrical Engineering

• Reconstruction of a band limited signal from its samples: Interpolation formula



xc ( t ) = ∫ X c ( f ) e j 2π ft df
−∞
πf
1 ∞ −j
∑ x [ n ] e W e j 2π ft df
W
=∫
−W 2W
n =−∞

1
∑ x [ n]
W j 2π f ( t − nT )
=
n =−∞ 2W ∫−W
e df

sin π ( t − nT ) / T
= ∑ x [ n] π ( t − nT ) / T
n =−∞

sin π t / T
= ∑ x [ n] h(t − nT );
n =−∞
h(t ) =
πt /T
⇒ A band-limited signal of finite energy can be completely recovered by its samples
taken at a rate of 2W/sec

H( f )
– Ideal reconstruction filter

sin π t / T
h(t ) =
πt /T
f
1 1

2T 2T
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 2. Periodic sampling of continuous-time signals
School of Electrical Engineering

• Poisson sum formula

A periodic signal xs ( t ) with period T is represented by the Fourier series,



1
xs ( t ) = ∑xe
n =−∞
n
j 2π f s nt
; fs =
T
1 T2
where xn = ∫ T xs ( t ) e − j 2π f s nt dt
T −2

1 ∞ j 2π f s nt ⎛ 1 T2 1⎞
Ex : ∑ δ ( t − nT ) = ∑ e ⎜∵ xn = ∫− T δ (τ )e
− j 2π f s nt
dt = ⎟
n =−∞ T n=−∞ ⎝ T 2 T⎠

x(t ) = ∑δ ( t − nT ) y (t )
ht bg
∞ ∞
y (t ) = h (t ) ∗ ∑ δ ( t − nT ) =
n =−∞
∑ h ( t − nT )
n =−∞

⎡ 1 ∞ j 2π fs nt ⎤
y (t ) = h (t ) ∗ ⎢ ∑ e ⎥
⎣ T n=−∞ ⎦

1 1 ∞
= ∑ ∫ h (τ )e dτ = ∑ H ( nf s ) e j 2π f s nt
j 2π f s n( t −τ )

T n=−∞ T n=−∞

1 ∞
⇒ ∑ h ( t − nT ) =
n =−∞

T n=−∞
H ( nf s ) e j 2π f s nt

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 2. Periodic sampling of continuous-time signals
School of Electrical Engineering

• Discrete-time processing of continuous-time signals

bg
xc t
C/D
xn
hn
yn bg
yr t
D/C

discrete - time
T system T

⎛ ω 2π k ⎞
x [ n ] = xc ( nT ) ⇒ X ( e jω ) =
1
∑ Xc ⎜ −
T k =−∞ ⎝ T T ⎠
⎟;

π ( t − nT )
∞ sin
yr ( t ) = ∑ y [ n ] T ;
n =−∞ π ( t − nT )
T

⇒ Yr ( Ω ) = H r ( Ω ) Y ( e jΩT )
⎧ π
⎪TY ( e ) , Ω <
jΩT
low pass
=⎨ T
reconstruction ⎪⎩ 0 , otherwise
filter
– The freq-domain representation is easier than the time-domain representation

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 2. Periodic sampling of continuous-time signals
School of Electrical Engineering

• LTI discrete-time systems


Y ( e jω ) = H ( e jω ) X ( e jω )

⇒ Yr ( jΩ ) = H r ( Ω ) H ( e jΩT ) X ( e jΩT ) ; ω = ΩT
1 ∞ ⎛ 2π k ⎞
= H r ( Ω ) H ( e jΩT ) ∑ Xc ⎜Ω − ⎟
T k =−∞ ⎝ T ⎠
⎧ π
⎪H (e ) X c (Ω), Ω <
jΩT
=⎨ T
⎪⎩ 0 , otherwise

– If X c ( Ω ) is band limited and the sampling rate is larger than the Nyquist rate,
Yr ( Ω ) = H eff ( Ω ) X c ( Ω )
the effective frequency response is
⎧ π
⎪H (e ), Ω <
jΩT
H eff ( Ω ) = ⎨ T
⎪⎩ 0 , otherwise

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 2. Periodic sampling of continuous-time signals
School of Electrical Engineering

• Example of signal reconstruction

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 2. Periodic sampling of continuous-time signals
School of Electrical Engineering

Ex: Ideal LPF


⎧1, ΩT < ωc
H eff ( Ω ) = ⎨
⎩0, otherwise

Ex: Ideal band-limited differentiator

d
yc ( t ) = xc ( t ) ⇒ H c ( Ω ) = jΩ
dt
⎧ π
⎪ j Ω, Ω <
⇒ H eff ( Ω ) = ⎨ T
⎪⎩0 , otherwise

H ( e jω ) = , ω <π
T
⎧ cos π n
π n cos π n − sin π n ⎪ , n≠0
⇒ h [ n] = = ⎨ nT
π n 2T ⎪⎩ 0 , n = 0

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 2. Periodic sampling of continuous-time signals
School of Electrical Engineering

– Impulse invariance
⎛ω ⎞
( )
H e jω = H c ⎜ ⎟ = H ( Ω); ω < π
⎝T ⎠
⇒ When h [ n ] = Thc ( nT ) , the discrete-time system is said to be an impulse-invariance
version of the continuous-time system.
1 ∞ ⎛ ω 2π k ⎞
∵ H (e ) = ∑ Hc ⎜ −

⎟ ⇐ X s (Ω) = X ( e ) ω =ΩT = X ( e )
jω jΩT

T k =−∞ ⎝ T T ⎠
⎛ω ⎞
⇒ H ( e jω ) = H c ⎜ ⎟ , ω < π
1
T ⎝T ⎠
A
Ex: hc (t ) = Ae u (t ) ⇒ H c ( s ) =
s0t

s − s0
h [ n ] = Thc ( nT ) = Ae s0nT u [ n ]
⎛ω ⎞
or H ( e jω ) =
AT AT
H ( z) = s0T −1 s0T − jω
≠ Hc ⎜ ⎟
1− e z 1− e e ⎝T ⎠
∵ hc (t ) is not strictly band - limited
The resulting discrete-time frequency response is aliased

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 2. Periodic sampling of continuous-time signals
School of Electrical Engineering

• Continuous-time processing of discrete-time signals

xn bg
xc t
hc ( t )
yc ( t ) yn
D/C C/D

T π ( t − nT ) T
∞ sin π
xc ( t ) = ∑ x [ n] T ; X c (Ω) = T X ( e jΩT ) , Ω ≤
n =−∞ π ( t − nT ) T
T
π ( t − nT )
∞ sin π
yc ( t ) = ∑ y [ n ] T ; Yc ( Ω ) = H c ( Ω ) X c ( Ω ) ; Ω <
n =−∞ π ( t − nT ) T
T
1 ⎛ω ⎞
Y ( e jω ) = Yc ⎜ ⎟ , ω <π
T ⎝T ⎠
= H c ( Ω ) X c ( Ω ) = H ( e jω ) X ( e jω ) ⇒ H ( e jΩT ) = H c ( Ω ) = H eff ( Ω ) ; Ω ≤ π /T

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 2. Periodic sampling of continuous-time signals
School of Electrical Engineering

Ex: Non-integer delay H ( e jω ) = e − jωΔ , ω <π


If Δ is an integer , y [ n ] = x [ n − Δ ] ⇒ h [ n] = δ [ n − Δ ]
If Δ is not an integer , H c ( f ) = e − j 2π f ΔT
yc ( t ) = xc ( t − ΔT )
⇒ y [ n ] = xc ( nT − ΔT )
π ( t − ΔT − kT )
∞ sin
= ∑ x[k ]
k =−∞
T
π ( t − ΔT − kT )
T t = nT

sin π ( n − k − Δ ) sin π ( n − Δ )
= ∑ x[k ] ⇒ h [ n] =
k =−∞ π (n − k − Δ) π (n − Δ)
1
e.g., Δ = ;
2
⎛ T⎞
yc ( t ) = xc ⎜ t − ⎟
⎝ 2⎠

−T 0 T 2T 3T

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 2. Periodic sampling of continuous-time signals
School of Electrical Engineering

⎡ M⎤
– Ex: Moving average with non-integer delay y [ n] = w ⎢n − ⎥
⎣ 2⎦
⎧ 1
⎪ , 0≤n≤M
h [ n] = ⎨ M + 1
⎪⎩ 0, otherwise

ω ( M + 1)
sin ωM
⇒ H (e ) =
1 −j
jω 2 e 2
, ω <π
M +1 ω
sin
2

ƒ When M=5,
for x[n] = cos ( 0.25π n )
⇒ y[n] = 0.308cos ⎡⎣ 0.25π ( n − 2.5 ) ⎤⎦

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 2. Periodic sampling of continuous-time signals
School of Electrical Engineering

• Changing the sampling rate


– Decimation by M (sampling rate compressor)

xn xd [ n] = x [ nM ]
↓M

x [ n ] = xc (nT ) ⇒ xd [ n ] Δ x [ nM ] = xc ( nMT )
1 ∞ ⎛ ω 2π k ⎞
X ( e jω ) = ∑ Xc ⎜ − ⎟
T k =−∞ ⎝ T T ⎠

Let T ′ = MT . Then,

1 ∞ ⎛ ω 2π k ⎞
X d ( e jω ) = ∑ Xc ⎜ ' − ' ⎟
T ' =−∞ ⎝ T T ⎠
1 ∞
⎛ ω 2π ⎞
=
MT
∑X
=−∞
c ⎜ −
⎝ MT MT ⎠
⎟ ⇐ = i + kM

1 ⎡1 ∞
M −1
⎛ ω − 2π i 2π k ⎞ ⎤
= ∑ ⎢ T ∑ X c ⎜ MT − T ⎟ ⎥
i =0 ⎣
M k =−∞ ⎝ ⎠⎦
1 M −1 ⎛ j ω −M2π i ⎞
= ∑ X ⎜e ⎟
M i =0 ⎝ ⎠

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 2. Periodic sampling of continuous-time signals
School of Electrical Engineering

– Decimation by M (cont.)
ƒ To avoid aliasing, a LPF is
required before down-sampling

xn x [ n] xd [ n ]
LPF ↓M
T T ' = MT
hd [ n ]

Example: When M=3:

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 2. Periodic sampling of continuous-time signals
School of Electrical Engineering

– Interpolation by L (sampling rate expander)


c h
Hi e jω
xe [ n] xi [ n]
L
xn
↑L LPF
T T '=T /L
hi [ n] −2π −π π π π 2π

T L L
xi [ n ] = xc ( nT ′ ) ; T ′ =
L X c (Ω)
⎡n⎤
= x⎢ ⎥
⎣L⎦ Ω
−W W
X (e jω )
⎧ ⎡n⎤
⎪x , n = 0, ± L, ±2 L,...
xe [ n ] = ⎨ ⎢⎣ L ⎥⎦ ω = ΩT
⎪ 0 , otherwise −2π −π π 2π


X e (e jω )
= ∑ x [ k ]δ [ n − kL]
k =−∞ ω = ΩT ′
−3π / L −π / L 0 π /L 3π / L
⎛ ∞ ∞

⇒ X e ( e ) = ∑ ⎜ ∑ x [ k ]δ [ n − kL ] ⎟ e − jω n

k =−∞ ⎝ k =−∞ ⎠ X i (e jω )

= ∑ x[k ]e − jω Lk
= X ( e jω L )
ω = ΩT ′
k =−∞
−2π −π / L π /L 2π

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 2. Periodic sampling of continuous-time signals
School of Electrical Engineering

– D/C conversion
πn
sin
hi [ n ] = L ⇒ ⎧1 n = 0
πn ⎨
⎩0 n = ± L, ±2 L...
L
⎡n⎤ ⎛ nT ⎞
xi [ n ] = ∑ x [ k ] hi [ n − k ] = x ⎢ ⎥ = xc (nT ' ) = xc ⎜ ⎟
k ⎣L⎦ ⎝ L ⎠
In practice, we use an approximate LPF.

– Linear interpolation

⎧ n
⎪1 − , n < L
h [ n] = ⎨ L
⎪ 0,
⎩ otherwise
x [ n ] = ∑ xe [ k ] h [ n − k ]
k c h
Hi e jω
= ∑ x [ m ] h [ n − mL ] H ce h: L = 5

m

⎡ ωL ⎤
2

1 ⎢ sin 2 ⎥
H (e ) = ⎢


π 2π 4π
L ⎢ sin ω ⎥ 5 5 5
⎣ 2 ⎦

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 2. Periodic sampling of continuous-time signals
School of Electrical Engineering

L
– Changing the sampling rate by a non-integer ratio R =
M

xn xe [ n ] xi [ n ] xd [ n ]
↑L LPF LPF ↓M
T T MT
T L T L
L L

xn xe [ n ] xi [ n] xd [ n ]
↑L LPF ↓M

G=L
⎛π π ⎞
ω = min ⎜ , ⎟
c ⎝L M ⎠

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 2. Periodic sampling of continuous-time signals
School of Electrical Engineering

L
– Changing the sampling rate by a non-integer ratio R = (cont.)
M

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 2. Periodic sampling of continuous-time signals
School of Electrical Engineering

• Multirate signal processing

– Interchange the filtering and the down sampling process

x [n ] x a [n ] y [n ] x [n ] xb [n ] y [n ]
↓ M H (z ) H (z )M
↓ M

ω − 2π i
X b ( e jω ) = H ( e jω M ) X ( e jω )
M −1
X a (e ) =
1
∑ X (e
j
jω M
)
M i =0

⎛ j ω −M2π i ⎞
M −1
Y (e ) =
1

∑ Xb ⎜ e ⎟
M i =0 ⎝ ⎠
1 M −1 ⎛ j ω −M2π i ⎞
= ∑ X ⎜e
M i =0 ⎝
⎟H e

(
j (ω − 2π i )
)
M −1
⎛ j ω −M2π i ⎞
= H (e )
1 jω
∑ X ⎜e ⎟
M i =0 ⎝ ⎠
= H ( e jω ) X a ( e jω )

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 2. Periodic sampling of continuous-time signals
School of Electrical Engineering

• Multirate signal processing

– Interchange the filtering and the down sampling process

x [ n] xa [ n] y [ n] x [ n] xb [ n] y [ n]
↓M H (z) H ( zM ) ↓M
ω − 2π i
X b ( e jω ) = H ( e jω M ) X ( e jω )
M −1
X a (e ) =
1
∑ X (e
j
jω M
)
M i =0

⎛ j ω −M2π i ⎞ 1 ⎛ j ω −M2π i ⎞
( )
M −1 M −1
Y (e ) =
1

∑ Xb ⎜ e ⎟= ∑ X ⎜e ⎟H e
j (ω − 2π i )

M i =0 ⎝ ⎠ M i =0 ⎝ ⎠
M −1
⎛ j ω −M2π i ⎞
= H (e ) ⎟ = H (e ) X a (e )
1 jω
∑ X ⎜e jω jω

M i =0 ⎝ ⎠
– Interchange the filtering and the interpolation process

x [ n] xa [ n] y [ n] x [ n] xb [ n] y [ n]
H (z) ↑L ↑L H ( zL )

Y ( e jω ) = X a ( e jω L ) = X ( e jω L ) H ( e jω L )
X b ( e jω ) = X ( e jω L ) ⇒ Y ( e jω ) = H ( e jω L ) X b ( e jω ) = X ( e jω L ) H ( e jω L )

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 2. Periodic sampling of continuous-time signals
School of Electrical Engineering

– Poly phase implementation of interpolation filters

x [ n] u [ n] y [ n]
↑L H (z)

ƒ Note that only every Lth sample of u [ n ] is nonzero


ƒ Consider decomposition of an impulse response h [ n ] by
⎧h [ n + k ] , n = mL, m = 0, ±1, ±2, ⋅ ⋅⋅
hk [ n ] = ⎨
⎩ 0 , otherwise
ƒ By successively delaying these subsequences, we can reconstruct h [ n ] by
L −1

h [ n] h [ n] e0 [ n ] h0 [ n ] h [ n ] = ∑ hk [ n − k ]
↓L ↑L k =0

ek [ n ] = h [ nL + k ] = hk [ nL ]
z
h [ n + 1] e1 [ n ]
↓L ↑L z −1 +

z
h [ n + 2] e2 [ n ]
↓L ↑L z −2
...

...

...

z eM −1 [ n]
−( M −1)
↓L ↑L z
h[ n + M −1]
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 2. Periodic sampling of continuous-time signals
School of Electrical Engineering
h [ n] e0 [ n ] x [ n]
↓L ↑L +
( )
E0 z L
z z −1
z −1
h [ n + 1] e1 [ n ] y [ n]
↓L ↑L + ( )
E1 z L
+
:

...
...

+
...
z −1
z eM −1 [ n] z −1

h[ n + M −1]
↓L ↑L ( )
EM −1 z L

x [n ] E0 ( z ) ↑L + y [n ]

⇒ z −1

E1 ( z ) ↑L +

z −1
E L −1 ( z ) ↑L
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 2. Periodic sampling of continuous-time signals
School of Electrical Engineering

• Digital processing of analog signals

xc (t) Anti- x (t) x ⎡⎣n⎤⎦ x̂ ⎡⎣n⎤⎦ Discrete-time ŷ ⎡⎣n⎤⎦ Compensated y(t)


a
aliasing S&H A/D D/A reconstructure
system
filter filter

Δ Δ
– Quantization error: − < q [ n ] = x [ n ] − xˆ [ n ] ≤
2 2
x [n ] x̂ [ n ] x [n ] x̂ [ n ]
Q ⇔ +

q [n ]

– Assuming that the error sequence q [ n ] is uncorrelated with x [ n ] and it is uniformly


⎡ Δ Δ⎤
distributed over ⎢ − , ⎥ ,
⎣ 2 2⎦ Δ
Δ
2
1
σ =∫
2 2
Δ q ⋅ dq =
2

Δ
q
− 12
2

2−2 k X m2
For a (K+1)- bit quantizer with full-scale value X m , σ =
2
– q
12
σ X2 X
SQNR = 10 log 2 = 6.02 K + 10.8 − 20log m
σq σX
⇒ SQNR is increases approximately 6dB for each bit added to the quantizer.

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University
School of Electrical Engineering

Transform analysis of L.T.I. systems


• Frequency response of LTI systems

xn yn
hn

y [ n] = ∑ x [ k ] h [ n − k ] ⇔ Y ( z ) = H ( z ) X ( z )
k

⇒ Y (e ) = H (e ) X (e ) = H (e ) X (e ) e ( ( ) ( ))
jω jω jω jω jω j ArgH e jω + ArgX e jω

↑ eigenfunction x [ n ] = e jω n
complex gain (or eigenvalue)

– Ideal frequency-selective filters


⎧⎪1, ω ≤ ω c
H lp ( e

) = ⎨0,
⎪⎩ otherwise ω c < ω ≤ π
⇒ H hp ( e jω ) = 1 − H lp ( e jω ) : ideal high - pass filter
⇒ hhp [ n ] = δ [ n ] − hlp [ n ]
sin ω c n
= δ [ n] − ⇐ not computationally realizable
Digital Signal Processing
πn Yong-Hwan Lee
Seoul National University
School of Electrical Engineering

– Ideal delay hid [ n ] = δ [ n − nd ]


⇒ H id ( e jω ) = e − jω nd = 1 e − jω nd , ω < π

– Low-pass filter with linear phase (or delay)


⎧⎪e − jω nd , ω ≤ ω c
H p (e ) = ⎨

⎪⎩ 0 ,ω c ≤ ω ≤ π
sin ω c ( n − nd )
⇒ hhp [ n ] = ← Regardless of nd , it is still noncausal
π ( n − nd )
– Group delay: A measure of the nonlinearity of the phase
I (ω ) = −
d

(
Arg H ( e jω ) )
(
Example Arg H ( e ) ≈ −φ0 − ω nd

)
For an input x [ n ] = s [ n ] cos ω 0 n,
y [ n ] ≈ s [ n − nd ] cos (ω 0 ( n − nd ) − φ0 )

⇒ The time delay of the envelope s [ n ] of narrowband signal centered at ω 0 is


given by the negative of the slope of the phase at ω 0.

Digital Signal Processing Yong-Hwan Lee


Seoul National University
School of Electrical Engineering

• Linear constant coefficient difference equation


N M

∑ ak y [ n − k ] = ∑ bk x [ n − k ]
k =0 k =0
N M
⇒ ∑ ak z − kY ( z ) = ∑ bk z − k X ( z )
k =0 k =0
M

Y ( z) ∑
−k
bz k
It does not uniquely specify
⇒ H (z) Δ = k =0
⇐ the impulse response of an
X ( z) N

∑a z k =0
k
−k
LTI system

b0 ∏ (1 − ck z −1 )
M

= k =1
⇒ zeros: z = ck ; poles: z = d k
a0 ∏ (1 − d k z )
N
−1

k =1

Example
H (z) =
(1 + z )
=
−1 2
1 + 2 z −1 + z −2
=
Y ( z) 1 3
⇒ zeros: z = −1, −1; poles: z = , −
⎛ 1 −1 ⎞⎛ 3 −1 ⎞ 1 + 1 z −1 − 3 z −2 X ( z ) 2 4
⎜1 − z ⎟⎜ 1 + z ⎟
⎝ 2 ⎠⎝ 4 ⎠ 4 8
1 3
⇒ y [ n] + y [ n − 1] − y [ n − 2] = x [ n ] + 2 x [ n − 1] + x [ n − 2]
4 8
Digital Signal Processing Yong-Hwan Lee
Seoul National University
School of Electrical Engineering

– Causal system
h [ n ] is a right-sided sequence
⇒ The region of convergence of H c ( z ) should be outside the outermost pole
– Stable system: absolutely summable

∑ h [ n] < ∞ ⇔ ∑ h [ n] z
n =−∞ n
−n
< ∞ for z =1

⇒ The ROC of H(z) includes the unit circle


– Example 5
y [ n ] − y [ n − 1] + y [ n − 2] = x [ n ]
2
1 1
⇒ H (z) = = 1 2

1 − z −1 + z −2 ⎛⎜1 − z −1 ⎞⎟ (1 − 2 z −1 )
5 1 2

2 ⎝ 2 ⎠
To be causal, ROC ⇒ z >2

1
To be stable, ROC ⇒ 2 < z < 2
– In order for an LTI system to be both stable and causal, the ROC must be outside the
outermost pole and include the unit circle, i.e., all poles inside the unit circle
– Depending upon the choice of ROC, the same difference equation results in a different
impulse response

Digital Signal Processing Yong-Hwan Lee


Seoul National University
School of Electrical Engineering

– Inverse system
1
ƒ Let H ( z ) be H ( z ) =
i i H (z)
G( z) H ( z ) H i ( z ) = 1 ⇒ g [ n ] = h ( n ) ∗ hi [ n ] = δ [ n ]
ƒ To hold this equation, the ROC of Hi(z) and H(z) must overlap
ƒ If H(z) is causal, the ROC is z > max
k
dk
⇒ The ROC of H i ( z ) should overlap with z > max d k
k
Example 1:
1 − 0.5 z −1
H (z) = with ROC: z > 0.9
1 − 0.9 z −1
1 − 0.9 z −1
⇒ Hi ( z ) = ⇒ ROC: z > 0.5 (to be overlapped with z > 0.9)
1 − 0.5 z −1
⇒ hi [ n ] = 0.5n u [ n ] − 0.9 ⋅ 0.5n−1 u [ n − 1]

Example 2:
z −1 − 0.5
H ( z) = with ROC : z > 0.9
1 − 0.9 z −1
−2 + 1.82 z −1
⇒ Hi ( z ) =
1 − 2 z −1
For an ROC z < 2; hi1 [ n ] = 2 ⋅ 2n u [ − n − 1] − (1 ⋅ 8 ) ⋅ 2n−1 u [ − n ] ⇒ stable & noncausal
For an ROC z > 2; hi 2 [ n ] = −2 ⋅ 2n u [ n ] + 1 ⋅ 8 ⋅ 2n−1 u [ n − 1] ⇒ unstable & causal
Digital Signal Processing Yong-Hwan Lee
Seoul National University
School of Electrical Engineering

ƒ If H(z) is causal with zeros at ck , H i ( z ) will be causal iff the Roc of H i ( z ) is


z > max ck
k

ƒ If H i ( z ) is stable, the RoC of H i ( z ) must include the unit circle, max


k
ck < 1
ƒ H(z) and its inverse are stable and causal iff both poles and zeros of H(z) are
inside the limit circle. ⇒ minimum-phase system

– Impulse response of for rational system functions


M −N N
Ak
H (z) = ∑ B z

+ ∑1− d −1
,M ≥ N
=0 k =1 k
z
FIR term IIR term
ƒ If causal,
M −N N
h [ n] = ∑ B δ [ n − ] + ∑ A d u [ n], k
n
k M ≥N
=0 k =1
M −N N
⇒ y [ n] = ∑ B x[n − ] + ∑ Ak d knu [ n] ∗ x [ n]
=0 k =1

ƒ Example: A first-order IIR filter


1
y [ n ] − ay [ n − 1] = x [ n ] ⇒ H ( z ) = ; ROC : z > a
1 − az −1
For stability, a < 1 ⇒ h [ n ] = a nu [ n ]
Digital Signal Processing Yong-Hwan Lee
Seoul National University
School of Electrical Engineering

ƒ FIR system
M
H ( z ) = ∑ bk z − k
k =0
M ⎧b , 0 ≤ n ≤ M
⇒ h ⎡⎣ n ⎤⎦ = ∑ bkδ ⎡⎣ n − k ⎤⎦ = ⎪⎨ n
k =0 ⎪⎩0, otherwise
M
⇒ y ⎡⎣ n ⎤⎦ = ∑ bk x ⎡⎣ n − k ⎤⎦
k =0

Example
⎧a n , 0 ≤ n ≤ M
h [ n] = ⎨
⎩0 , otherwise M =7
1 − a M +1 z (
M − M +1)
⇒ H (z) = ∑a z n −n
=
n =0 1 − az −1
2π k
j
Zeros : zk = ae M +1
, k = 0,1, 2,..., M
M
⇒ y [ n] = ∑ a k x [ n − k ]
k =0

or y [ n ] − ay [ n − 1] = x [ n ] − a M +1 x [ n − M − 1]

Digital Signal Processing Yong-Hwan Lee


Seoul National University
School of Electrical Engineering

• Frequency response for rational systems

∏ (1 − c e ω )
M M

∑ bk e− jωk k
−j

H ( e jω ) = H ( z ) z =e jω =
b0
k =0
= k =1

∏ (1 − d e ω )
N N

∑a e − jω k a0 −j
k k
k =0 k =1
M

∏ 1− c e − jω
∏ (1 − c e ω )(1 − c e ω )
M
k −j * j

⇒ H (e )
2
jω b ⎛b ⎞ k k
= 0 H ( e jω )
k =1 2
N =⎜ 0 ⎟ k =1

∏ 1− d e
a0 − jω
∏ (1 − d e ω )(1 − d e ω )
N
k ⎝ a0 ⎠ −j * j
k k
k =1
k =1
– Gain (or attenuation)
Gain = 20log10 H ( e jω )
M M
b0
= 20log10 + 20∑ log10 1 − ck e − jω
− 20∑ log10 1 − d k e− jω (dB )
a0 k =1 k =1
– Phase response
⎛ b0 ⎞ M
Arg ( H (e ) ) = Arg ⎜ ⎟ + ∑ Arg (1 − ck e ) − ∑ Arg (1 − d k e − jω ) ; − π < Arg ( x ) ≤ π
M
jω − jω

⎝ a0 ⎠ k =1 k =1

– Group delay

grd ( H (e ) ) = −∑ Arg (1 − ck e ) + ∑ Arg (1 − d k e − jω )


M M
jω d − jω d
k =1 dω k =1 dω

Digital Signal Processing Yong-Hwan Lee


Seoul National University
School of Electrical Engineering

• Frequency response of a single pole or zero

– Single zero
H ( z ) = 1 − az −1 ⇒ H ( e jω ) = (1 − ae − jω ) ; a = re jθ

⇒ H ( e jω ) = 1 − re jθ e− jω = (1 − re jθ e − jω )(1 − re − jθ e jω )
2

= 1 + r 2 − 2r cos (ω − θ )
r sin (θ − ω )
( )
⇒ A rg H ( e jω ) = tan −1
1 − r cos (θ − ω )

(
⇒ grd H ( e jω ) = ) d ⎡
dω ⎣
(
A rg H ( e jω ) ⎤
⎦ ) r = 0.9
r 2 − r cos (θ − ω ) θ =0
φ3 =
1 + r 2 − 2r cos (θ − ω ) θ = 0.5π
` θ =π
v2 v
z−a
H ( z) =
3
θ
ω v1 z
e jω − re jθ
⇒ H (e )
jω v3
= = = v3
e jω v1

( )
A rg H ( e jω ) = φ3 − φ1 = φ3 − ω
Digital Signal Processing Yong-Hwan Lee
Seoul National University
School of Electrical Engineering

– Example: Real single zero

H ( z ) = 1 − az −1
⇒ H ( e jω ) = (1 − ae − jω ) ; a = re jθ
If θ =π , a = − r
⇒ H (e jω
) = 1 + re − jω 2

= 1 + r 2 − 2r cos ω
r sin ω
(
⇒ A rg H ( e jω ) = tan −1 )
1 + r cos ω

(
⇒ grd H ( e jω ) =
d ⎡
dω ⎣
)
A rg H ( e jω ) ⎤
⎦( )
r 2 + r cos ω
=
1 + r 2 + 2r cos ω

Digital Signal Processing Yong-Hwan Lee


Seoul National University
School of Electrical Engineering

– Second-order IIR system


1 1
H ( z) = =
(1 − re jθ
z −1 )(1 − re jθ z −1 ) 1 − 2r cosθ z −1 + r 2 z −2
⇔ y [ n ] − 2r cosθ y [ n − 1] + r 2 y [ n − 2] = x [ n ]
r n sin ( n + 1)θ
⇒ h [ n] = u [ n]
sin θ

v1
ω v3
−θ
v2

H (e )
jω v 1
= 3 =
v1 ⋅ v2 v1 v2
r sin (θ − ω ) r sin (θ + ω )
( )
A rg H ( e jω ) = − tan −1
1 − r cos (θ − ω )
− tan −1
1 − r cos (θ + ω )
1
H (z) =
1 − 0.9 2 z −1 + 0.81z −2
Digital Signal Processing Yong-Hwan Lee
Seoul National University
School of Electrical Engineering

– Third-order IIR system

0.05634 (1 + z −1 )(1 − 1.0166 z −1 + z −2 )


H ( z) =
(1 − 0.683z )(1 − 1.4461z
−1 −1
+ 0.7957 z −2 )
⇒ z z = −1, e ± j1.0376 (59.45 )
⇒ z p = 0.683, 0.892e ± j 0.6257 (35.85 )

Digital Signal Processing Yong-Hwan Lee


Seoul National University
School of Electrical Engineering

• Relationship between magnitude and phase

– In general, magnitude information ⎯ ⎯→


No
←⎯⎯ phase information
No
– In cases of rational system functions, there is some constraint between magnitude and
phase
⎛1⎞
H ( e jω ) = H ( e jω ) H ∗ ( e jω ) = H ( z ) H ∗ ⎜ * ⎟
2

⎝ z ⎠ z =e jω

∏ (1 − c z ) ∏ (1 − c z )
M M
−1 ∗

⎛1⎞ b
k k
b0
H ( z) = k =1
; H∗⎜ ∗ ⎟ = 0 k =1

∏ (1 − d z ) ⎝ z ⎠ a0
∏ (1 − d z )
N N
a0 −1 ∗
k k
k =1 k =1

– The square of the magnitude frequency response is the evaluation of z-transform on


the unit circle
C (z) Δ H (z)H * ( )
1
z
*

– Question: Can we know of H(z) from C(z) ?

H ( z ): pole d k ; zero ck
⎛1⎞ conjugate reciprocal pairs
H ∗ ⎜ ∗ ⎟ : pole ( d k∗ ) ; zero (c )
−1 ∗ −1
k
⎝z ⎠
Digital Signal Processing Yong-Hwan Lee
Seoul National University
School of Electrical Engineering

– If H(z) is assumed to be causal & stable, all its poles are in the unit circle
⇒ Poles of H(z) can be identified uniquely

Example System with the same C(z)

2 (1 − z −1 )(1 + 0.5 z −1 )
H1 ( z ) = π π
⎛ j
4 −1
⎞⎛ −j
4 −1

⎜ 1 − 0.8e z ⎟⎜ 1 − 0.8e z ⎟
⎝ ⎠⎝ ⎠

H2 ( z ) =
(1 − z )(1 + 2 z )
−1 −1 −0.5 −2
π π
⎛ j
4 −1
⎞⎛ −j
4 −1

⎜1 − 0.8e z ⎟⎜ 1 − 0.8e z ⎟
⎝ ⎠⎝ ⎠
⇒ H1 ( e jω ) = H 2 ( e jω )
⎛1⎞
C1 ( z ) = H1 ( z ) H1* ⎜ * ⎟
⎝z ⎠
⎛1⎞
C2 ( z ) = H 2 ( z ) H 2* ⎜ * ⎟ ⇒ C1 ( z ) = C2 ( z )
⎝z ⎠

Digital Signal Processing Yong-Hwan Lee


Seoul National University
School of Electrical Engineering

• All pass system

– A stable system function of the form


z −1 − a ∗
H ap ( z ) =
1 − az1
has a frequency-response magnitude independent of ω.
e − jω − a∗ 1 − a∗e jω − jω
H ap ( e ) =

− jω
= − jω
e ⇒ H ap ( e jω ) = 1
1 − ae 1 − ae
r sin (ω − θ )
( )
A rg H ap ( e jω ) = −ω − 2 tan −1
1 − r cos (ω − θ )

– In general, the transfer function of an all-pass system is given by

H ap ( z ) = A ∏
z −1 − d k
Mr Mc
(z −1
− ek

)( z −1
− ek )
k =1 1 − d k z
−1 ∏ (1 − e z )(1 − e z ) ;
k =1
−1 ∗ −1
A > 0, d k < 1, ek < 1
k k

– All-pass system can be used for compensating group delay distortion.


– Causal all-pass system has positive group delay (but not continuous phase) property

Digital Signal Processing Yong-Hwan Lee


Seoul National University
School of Electrical Engineering

– Example

z −1 ∓ 0.9
H (z) =
1 ∓ 0.9 z1

z p = 0.9
z p = −0.9

Digital Signal Processing Yong-Hwan Lee


Seoul National University
School of Electrical Engineering

– Example

0.8
π
4

4 1 2
− − .75 0.5
3

Digital Signal Processing Yong-Hwan Lee


Seoul National University
School of Electrical Engineering

• Minimum-phase system

– It has its poles and zeros all inside the unit circle.

⇒ Any minimum-phase system H ( z ) is causal and stable.

⇒H
−1
(z) is a causal, stable, and min-phase system
– Cascade of both systems will not introduce any delay
H ( z ) H −1 ( z ) = 1 ⋅ e jo
– Energy concentration
ƒ For an arbitrary stable and causal system F ( e jω ) , let G ( e jω ) be the min-phase
function s.t., G ( e jω ) = F ( e jω ) , ∀ω .

ƒ Then, for any sequence x [ n ] and K,


K K

∑ ( x [ n ] ∗ g [ n ])k ≥ ∑ ( x [ n ] ∗ f [ n ])k
2 2

k =0 k =0

⇒ The signal energy is transported with the smallest possible delay using a

minimum-phase system
K K
Example If x [ n ] = δ [ n ] , ∑ g 2 [k ] ≥ ∑ f 2 [k ]
k =0 k =0

Digital Signal Processing Yong-Hwan Lee


Seoul National University
School of Electrical Engineering
– The min-phase function has its energy maximally concentrated near the time origin.
proof
F ( e jω )
Let H ( e jω
)Δ , ∀ω be stable, causal and all pass
G ( e jω )
H ( e jω ) = 1
xn yn zn
c h
G e jω c h
H e jω
min-phase all-pass
phase shifter
The energy of y [ n ]
ω0

E y Δ E { y [ n ]} = Y ( e jω ) dω , ω 0 =
1 2

∫ω
2 2
ω0 −
2
0
T
ω0
Ez Δ E { z 2 [ n ]} = H ( e jω ) Y ( e jω ) dω = E y
1 2

ω 0 ∫− 2
2
ω0
K
Assume y [ n ] vanishes for n < 0 a n d n < K , i .e ., Ey = ∑
n=0
y 2 [n ]
But z [ n ] is not necessarily zero for n > K
K
Ez = Ey ≥ ∑
n=0
z 2 [n ]
– H (z) cannot be uniquely determined from G ( z ) , because cascading all-pass filters
does not affect the magnitude of the frequency response.

Digital Signal Processing Yong-Hwan Lee


Seoul National University
School of Electrical Engineering

– Any rational rational transfer function can be expressed as


H (z ) = H m in ( z ) H a p ( z )
ƒ Assume that H ( z ) has all zeros and poles inside the unit circle except one
zero outside the unit circle at z =
1
*
, c <1
c
H ( z ) = H1 ( z )( z −1 − c* )
−1 z −1 − c*
= H1 ( z ) ⋅ (1 − cz ) ⋅
1 − cz −1
minimum phase
all pass

where H1 ( z ) is minimum phase

ƒ H min ( z ) has poles and zeros of H ( z ) inside the unit circle plus zeros that are
conjugate reciprocals of the zeros of H ( z ) outside the unit circle

ƒ H ap ( z ) contains all the zeros of H ( z ) outside the unit circle


ƒ Example
1 −1 1
−1 1+ z z −1 +
1 + 3z
H (z ) = 1
= 3⋅ 3
1

1
3
1 + z −1 1 + z −1 1 + z −1
2 2 3
H m in ( z ) H ap ( z )

Digital Signal Processing Yong-Hwan Lee


Seoul National University
School of Electrical Engineering

– The amplitude characteristics of a minimum-phase filter is fully determined by the


phase characteristics and vice versa ⇒ We can compute G ( e jω ) from G ( e jω )
Proof
Since G ( z ) has its poles and zeros inside the unit circle, ln G ( e jω ) is analytic for z > 1
⇒ ln G ( e jω ) has a causal and well behaved inverse Fourier transform, i.e.,

ln G ( e jω
) = ∑ g [ n] e − jω n
= X ( e jω ) + jφG ( e jω )
n =0
∞ ∞
where X ( e jω ) = ln G ( e jω ) = ∑ g [ n ] cos nω ; φG ( e jω ) = −∑ g [ n ] sin nω
n =0 n=0

We can see that X ( e ) φG ( e )


jω jω
and form a Hilbert transform pair.
Since X ( e jω ) is the logarithm of a real-valued symmetric function of frequency, it
is real and symmetric ⇒ x [ n ] = x [ −n ] , ∀n

⇒ X ( e jω ) = x [ 0] + 2∑ x [ n ] cos nω
n =0

⇒ g [ 0] = x [ 0] and g [ n ] = 2 x [ n ] , n ≥ 1

Thus we can compute φG ( e )


Digital Signal Processing Yong-Hwan Lee


Seoul National University
School of Electrical Engineering

– Frequency-response compensation
ƒ If H d ( z ) is a min-phase system, perfect compensation is generally possible

sn sc n
Hd z bg Hc zbg
H d ( z ) = H min ( z ) H ap ( z )
1
Let H c ( z ) = ⇒ G ( z ) = H d ( z ) H c ( z ) = H ap ( z )
H min ( z )

ƒ The frequency response magnitude is exactly compensated with some delay


Example
H ( z ) = (1 − 0.9e j 0.6π z −1 )(1 − 0.9e − j 0.6π z −1 )(1 − 1.25e j 0.8π z −1 )(1 − 1.25e− j 0.8π z −1 )
⇒ H min ( z ) = 1.252 (1 − 0.9e j 0.6π z −1 )(1 − 0.9e − j 0.6π z −1 )
⋅ (1 − 0.8e j 0.8π z −1 )(1 − 0.8e− j 0.8π z −1 )

⇒ H ap ( z) =
(1 − 1.25e j 0.8π
z −1 )(1 − 1.25e − j 0.8π z −1 )
(1 − 0.8e j 0.8π
z −1 )(1 − 0.8e − j 0.8π z −1 )

Digital Signal Processing Yong-Hwan Lee


Seoul National University
School of Electrical Engineering

H ( z) H min ( z ) H ap ( z )

Digital Signal Processing Yong-Hwan Lee


Seoul National University
School of Electrical Engineering

ƒ In general, min-energy delay property h [ 0 ] ≤ h m in [ 0 ]


z −1 − a
H ( z ) = H m in ( z ) , a <1
1 − a z −1
1 − a z −1
lim H m in ( z ) = lim − 1 H (z )
z→ ∞ z→ ∞ z −a
1
⇒ h m in [ 0 ] = − h [ 0 ] ⇒ h [ 0 ] = − a h m in [ 0 ] a <1
a
⇒ h [ 0 ] ≤ h m in [ 0 ]

– Maximum phase system is a stable system whose poles and zeros are all outside the
unit circle M

∏ (z − c ) k
H (z ) = k =1
N
c k > 1, d k > 1
∏ (z − d )
k =1
k

stable ⇒ R oc : z < smallest dk


⇒ all poles contribute to h [ n ] with terms of the form − ( d k ) u [− n − 1]
n

⇒ anti causal!

Digital Signal Processing Yong-Hwan Lee


Seoul National University
School of Electrical Engineering

ƒ Note that FIR max-phase sequence can be made causal by introducing a finite
delay
z −1 − c k
H m a x ( z ) = h m in [ 0 ] ∏ (1 − c ∗
)∏ 1 − c k∗ z
k

= H m in ( z ) H a p ( z )
– Property of min-phase systems
ƒ minimum phase-lag
arg ⎡⎣ H ( e jω ) ⎤⎦ = arg ⎡⎣ H min ( e jω ) ⎤⎦ + arg ⎡⎣ H ap ( e jω ) ⎤⎦

negative for 0 ≤ ω ≤ π

ƒ minimum group-delay
ƒ minimum energy delay property

h [ 0 ] ≤ h m in [ 0 ]

Digital Signal Processing Yong-Hwan Lee


Seoul National University 4. Structure for discrete-time systems
School of Electrical Engineering

Structure for discrete-time systems


• Characterization of an LTI system can be represented by difference equation, impulse
response or system function
b0 + b1 z −1
Example: H (z) = , z >a
1 − az −1
⇒ Impulse response : h [ n ] = b0 a nu [ n ] + b1a n −1u [ n − 1]
⇒ Infinite duration impulse response
⇒ Not possible to implement the system by discrete time convolution
⇒ The output can be calculated by a recursive computation algorithm
y [ n ] = ay [ n − 1] + b0 x [ n ] + b1 x [ n − 1]
• For description of systems for implementation, use the block diagram and/or signal flow
graph method

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 4. Structure for discrete-time systems
School of Electrical Engineering

• Basic block diagram symbols


yn

zn =xn +yn
xn

xn a y n = ax n

y n = x n −1
xn −1
z

Example y [ n ] = a1 y [ n − 1] + a2 y [ n − 2] + bx [ n ]

xn b yn

z −1
a1
y n −1

z −1
a2

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 4. Structure for discrete-time systems
School of Electrical Engineering

y [ n ] = ∑ ak y [ n − k ] + ∑ bk x [ n − k ]
N M

k =1 k =0

bg
H1 z H2 z bg
xn b0
yn

z −1 z −1
b1 a1
x n −1 y n −1

z −1 z −1
b2 a2
x n−2

: :
:
bM −1 a N −1
x n − M +1
y n − N +1

z −1 z −1
x n− M bM aN
y n− N

< direct form I>

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 4. Structure for discrete-time systems
School of Electrical Engineering

– By interchanging the cascaded blocks,


Y (z)
= H (z)
X (z)
= H1 ( z ) H 2 ( z )
= H 2 ( z ) H1 ( z )
x n ω [n ] b0 y n x [n ] b0 y [n ]

z −1 z −1 z −1
ω [n − 1]
a1 b1 a1 b1

z −1 z −1 :
a2 : z −1
ω [n − 2 ] ⇒ a2

: b2

a N −1 b N −1 :
:
a N −1
−1 −1
z z b N −1
aN ω [n − N ] bN
z −1
aN
bN

< direct form II or canonic direct form >

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 4. Structure for discrete-time systems
School of Electrical Engineering

• Signal flow graph representation

node j branch j , k
ω j ⎣⎡ n ⎦⎤ ω k ⎡⎣ n ⎤⎦
node k

Example
d

a
b e
x n ω1 n c ω2 n y n

ω1 [ n ] = x [ n ] + aω 2 [ n ] + bω 2 [ n ]
ω 2 [ n ] = cω1 [ n ]
y [ n ] = dx [ n ] + eω 2 [ n ]

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 4. Structure for discrete-time systems
School of Electrical Engineering

Example

xn ωn xn ωn b0 yn
yn
b0

z −1
−1
z
a b1
ω n −1

a b1

ω [ n ] = x [ n ] + aω [ n − 1]
y [ n ] = b0ω [ n ] + b1ω [ n − 1]
⇒ W ( z ) = X ( z ) + aW ( z ) z −1 ⇒ X ( z ) = (1 + az −1 )W ( z )
Y ( z ) = b0W ( z ) + bW
1 ( z ) z −1 ⇒ Y ( z ) = ( b0 + b1z −1 )W ( z )
Y (z) X (z)
⇒W (z) = =
b0 + b1 z −1 1 + az −1
Y ( z ) b0 + b1 z −1
⇒ H (z) = =
X ( z ) 1 + az −1

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 4. Structure for discrete-time systems
School of Electrical Engineering

• Basic structures for IIR systems

– Direct form I
1 + 2 z −1 + z −2
H (z) =
1 − 0.75 z −1 + 0.125 z −2
xn 1 yn

z −1 z −1
2 0.75

z −1 z −1
1

−0125
.

– Direct form II

xn yn
z −1
2
0.75
z −1

−0125
.

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 4. Structure for discrete-time systems
School of Electrical Engineering

– Cascade form
∏ (1 − g ) ∏ (1 − h z )(1 − h z )
M1 M2
−1 −1 * −1
k
z k k
H ( z ) = A kN=1 k =1

∏ (1 − c z )∏ (1 − d z −1 )(1 − d k* z −1 )
1 N2
−1
k k
k =1 k =1

1 − ( d k + d k* ) z −1 + d k z −2
2

z −1 z −1 z −1

cd + d h
1
*
1
z −1
c
− h1 + h *
1 h z −1 − ( h2 + h2* ) c1 −g1

− d1
2
h1
2
cd 2 + d 2* h − d2
2
h2
2

Example H (z) =
(1 + z )(1 + z ) −1 −1

(1 − 0.5 z )(1 − 0.25 z )−1 −1

xn yn

z −1 z −1

0.25 0.5

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 4. Structure for discrete-time systems
School of Electrical Engineering
– Parallel form
Np N1
Ak N Bk (1 − ek z −1 )
H ( z ) = ∑ gk z + ∑ +∑
2
−k

k =1 1 − ck z k =1 (1 − d k z )(1 − d k z )
−1 −1 * -1
k =0

N = N1 + 2 N 2 N2
e0 k + e1k z −1
M ≥ N, Np = M − N

k =1 1 − a1k z
−1
− a2 k z −2
g0

z −1
g1

z −1
g2
: : :
gNp
x n e01 yn

z −1
a 11
e11
z −1

a 21

A1

z −1
c1

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 4. Structure for discrete-time systems
School of Electrical Engineering

1 + 2 z −1 + z − 2
Example H (z) =
1 − 0.75 z −1 + 0.125 z −1
−7 + 8 z −1
=8+
1 − 0.75 z −1 + 0.125 z −1
18 25
=8+ −
1 − 0.5 z −1 1 − 0.25 z −1

xn −7 yn

z −1

0.75 8
z −1

−01125
.

xn 8 18 yn

0.5 z −1
−0.25

0.25 z −1

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 4. Structure for discrete-time systems
School of Electrical Engineering

• Transposed forms

– Signal flow graph methods provide procedures for transforming graphs into different forms
– Transposition of a flow graph (flow graph reversal) is obtained by reversing the directions
of all branches, while keeping the branch transnittances and reversing the roles of the
input and output
1
Example H (z) =
1 − az −1 x n yn

z −1

a
Transposed form
yn x n

The difference is
z −1
the change in ordering
a

xn yn

z −1

a
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 4. Structure for discrete-time systems
School of Electrical Engineering

Example Transposed form of a second-order structure


xn ωn b0 yn

z −1
ω [ n ] = a1ω [ n − 1] + a2ω [ n − 2] + x [ n ]
a1 b1

z −1 y [ n ] = b0ω [ n ] + b1ω [ n − 1] + b2ω [ n − 2]


a2 b2

Transposed direct form II


yn xn

b0
z −1

a1 b1
−1
z

a2 b2

xn b0 v0 n yn

b1 z −1 a1

b2 z −1 a
2

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 4. Structure for discrete-time systems
School of Electrical Engineering

• Basic network structure for FIR systems

– Direct form
⎧bn , 0 ≤ n ≤ M
Causal FIR systems y [ n ] = ∑ bk x [ n − k ] ⇒ h [ n ] = ⎨
M

k =0 ⎩0 , otherwise
Transversal filter or
xn z −1 z −1 z −1
" tapped delay line

h0 h1 h2 h[M ]

yn

In the transposed form,

yn z −1 z −1
"

h0 h1 h2 h M
xn
"

z −1 z −1 z −1 z −1 yn
⋅ ⋅ ⋅

h M h M −1 h [ M − 2] h0
xn
"

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 4. Structure for discrete-time systems
School of Electrical Engineering

– Cascade form

H ( z ) = ∑ h [ n ] z − n = ∏ ( b0 k + b1k z −1 + b2 k z −2 ); M s = ⎢⎣( M + 1) / 2 ⎥⎦
M Ms

k =0 k =1

x [ n] b01 b02 b0Ms y [ n]


"

z−1 z−1 z−1

b11 b12 b1Ms


−1
−1 −1
z z z

b21 b22 b2Ms

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 4. Structure for discrete-time systems
School of Electrical Engineering

– Structure for linear phase FIR systems


ƒ Causal linear phase FIR systems
h [ M − n ] = h [ n ] or h [ M − n ] = − h [ n ] for 0 ≤ n ≤ M

⇒ y [ n] = ∑ h [ k ] x [ n − k ]
M

k =0
M
−1
⎡M ⎤ ⎡ M⎤
∑ h [ k ] x [ n − k ] + h ⎢ 2 ⎥x ⎢ n − h[k ] x[n − k ]
2 M
= + ∑
2 ⎥⎦ k = M / 2+1
k =0 ⎣ ⎦ ⎣
M M
−1 −1
⎡M ⎤ ⎡ M⎤ 2
= ∑ h[k ] x [n − k ] + h ⎢ ⎥ x ⎢n − ⎥ + ∑ h[ M − k ] x [n − M + k ]
2

k =0 ⎣2⎦ ⎣ 2 ⎦ k =0
When h [ M − n ] = h [ n ] (type - I system),
M
−1
⎡M ⎤ ⎡ M⎤
y [ n] = ∑ h [ k ] ( x [ n − k ] + x [ n − M + k ]) + h ⎢ 2 ⎥ x ⎢ n −
2

k =0 ⎣ ⎦ ⎣ 2 ⎥⎦
z −1 z −1 z −1

z −1 z −1 z −1
"
h0 h1 h2 LM M − 1OP LM M OP
h
N2 Q h
N2Q
yn
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 4. Structure for discrete-time systems
School of Electrical Engineering

ƒ Symmetry condition
⇒ zeros of H ( z ) occur mirror image pairs
1
z1*
z3

z1

z4 z2 1
z* z2
1
*
z 3
1
z1
If h [ n ] is real, zeros of H ( z ) occur in complex conjugate pairs.

H ( z ) = h [ 0] (1 + z −1 )(1 + az −1 + z −2 )(1 + bz −1 + z −2 )(1 + cz −1 + dz −2 + cz −3 + z −4 )


2
1 ⎧ 1⎫ 1
where a = z2 + , b = 2 Re{ z3 } , c = −2Re ⎨ z1 + ⎬ , d = 2 + z1 +
z2 ⎩ z1 ⎭ z1

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

Filter Design Techniques


• Design procedure

– Specify the desired frequency Response


– Approximate the specifications
⎛ω ⎞
– Realize the filter H ( e jω ) = H eff ⎜ ⎟ , ω <π
⎝T ⎠

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Design of discrete-time IIR filters from continuous-time filters

– Filter design by impulse invariance


h [ n ] = Td hc ( nTd )

bg
xa τ xn yn bg
ya τ
C/D hn D/C

T Td T
⎛ ω 2π ⎞ ω
⇔ 2π f ( = Ω )

H ( e jω ) =
∑ H c⎜ + k ⎟
k =−∞ ⎝ Td Td ⎠ T d

ƒ The discrete-time filter specifications are transformed to continuous-time filter


⎛ω ⎞
specifications by H ( e jω ) = H c ⎜ ⎟ , ω ≤ π , if H c ( f ) = 0, f ≥
1
⎝ Td ⎠ 2Td
ƒ Design a suitable continuous-time filter H c ( s)
ƒ Transform to the desired discrete-time filter H ( z )

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering
⎧ N A es t , t ≥ 0
ƒ For H c ( s ) = ∑ k , hc ( t ) = ⎪⎨∑
k
N
A k
k =1
k =1 s − sk
⎪⎩ 0 , t >0

By sampling hc ( t ) ,

h [ n ] = Td hc [ nTd ] = ∑ Td Ak e s nT u [ n ] = ∑ Td Ak ( e s T ) u [ n]
N N n
k d k d

k =1 k =1
N
Td Ak
⇒ H (z) = ∑
k =1 1 − e z −1
sT
k d

ƒ A pole at s = sk in the s-plane is transformed to a pole at z = e s T in the z-plane. k d

ƒ If H c ( s ) is stable, the real part of sk < 0


⇒ es T < 1
k d

⇒ pole is inside the unit circle


⇒ H ( z ) is also stable

Although the poles in the s-plane are mapped in the z-plane in a simple manner,
the zeros are not.

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering
– Butterworth (BW) filter
ƒ The magnitude response of a BW filter is
1 1
Hc ( f ) ⇐ H ( s ) H ( −s ) =
2
= 2N 2N
⎛ f ⎞ ⎛ s ⎞
1+ ⎜ ⎟ 1+ ⎜ ⎟
⎝ fc ⎠ ⎝ 2π f c ⎠
where f c is the 3dB frequency

⎧ j
π
( 2 k + N −1) ⎫
⇒ poles are ⎨ sk = Ω c e 2N
; k = 0,1, 2, , 2 N − 1⎬
⎩ ⎭

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering
Example Design a continuous-time Butterworth (BW) filter s.t.
1
0.89125 ≤ H c ( f ) ≤ 1, 0 ≤ f ≤ 0.1
1− δ1
1
H c ( f ) ≤ 0.17783 0.15 ≤ f ≤
2 δ2
Let Td = 1 so that ω = Ω
ωp ωs
ƒ The magnitude response of a BW filter is
1 1 δ 1 = 0.10875
Hc ( f ) ⇐ H ( s ) H ( −s ) =
2
= 2N 2N
⎛ f ⎞ ⎛ s ⎞ δ 2 = 0.17783
1+ ⎜ ⎟ 1+ ⎜ ⎟
⎝ fc ⎠ ⎝ 2π f c ⎠ ω p = 0.2π
where f c is the 3dB frequency ω s = 0.3π
By solving
⎧ ⎛ 0.1 ⎞ 2 N ⎛ 1 ⎞
2

⎪1 + ⎜ ⎟ =⎜ ⎟ ⇒ N = 5.8858 ⇒ N = 6
⎪ ⎝ c ⎠f ⎝ 0.89125 ⎠
⎨ 2N f c = 0.11216 0.7032
⎪ ⎛ 0.15 ⎞
2
⎛ 1 ⎞
⎪1 + ⎜ f ⎟ = ⎜ 0.17783 ⎟
⎩ ⎝ c ⎠ ⎝ ⎠

π
⎛ −0.182 ± j 0.679 ⎞
⇒ poles are ⎜⎜ −0.497 ± j 0.497 ⎟⎟
12

sk = 2π f c e
j ( 2 k + N −1)
⎛ 0.1 ⎞
1+ ⎜ ⎟ = 1.258928
2N

⎜ −0.679 ± j 0.182 ⎟ ⎝ fc ⎠
⎝ ⎠
⇒ f c = 0.111918

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

0.12093
Hc ( s ) =
( s + 0.3645 + 0.4945)( s + 0.99455 + 0.4945) ⋅ ( s 2 + 1.35855 + 0.4945)
2 2

A1 A2
= +
( s + 0.182 + j 0.679 ) ( s + 0.182 − j 0.679 )
A3 A4
+ +
( s + 0.497 + j 0.497 ) ( s + 0.497 − j 0.497 )
A5 A6
+ +
( s + 0.679 + j 0.182 ) ( s + 0.679 − j 0.182 )
A1 A2
⇒ H (z) = + + ⋅⋅⋅
(1 − e−0.182e− j 0.679 z −1 ) (1 − e0.182e+ j 0.679 z −1 )
z1 = e −0.182− j 0.679 = 0.8336 ( 0.7782 − j 0.6280 )
= 0.6487 − j 0.5235 ⇒ z1 = 0.69489
2

0.2871 − 0.4466 z −1
H (z) =
1 − 1.2974 z −1 + 0.6949 z −2
−2.1428 + 1.1455 z −1
+
1 − 1.0691z −1 + 0.3699 z −2
1.8557 − 0.63032 z −1
+
1 − 0.9972 z −1 + 0.2570 z −2

ƒ This method is useful only for band-limited filters


420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 5. Filter design techniques
School of Electrical Engineering

– Bilinear transformation
ƒ To avoid aliasing, we employ the bilinear transform s = 2 ⎛⎜ 1 − z −1 ⎞⎟
−1

Td ⎝ 1 + z ⎠

2π f
ω
∞ −∞ −π π
⎡ 2 ⎛ 1 − z −1 ⎞ ⎤
H ( z ) = Hc ⎢ ⎜ −1 ⎟ ⎥
⎣ Td ⎝ 1 + z ⎠ ⎦
π
2 ⎛ 1 − z −1 ⎞ 1+ s
s= ⎜ −1 ⎟
⇒z= 2 ⇐ s = σ + j 2π f
Td ⎝ 1 + z ⎠ 1− s
Td
2
σT
1 + d + jπ fTd
= 2
σ Td
1− − jπ fTd
2
⇒ z < 1, if σ < 0

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

ƒ The j 2π f axis of the s-plane maps onto the unit circle of the z-plane
For s = j 2π f ,
1 + jπ fTd 1 + jπ fTd
z= ⇒ z =1 ⇒ e jω =
1 − jπ fTd 1 − jπ fTd
or 2 ⎛ 1 − e − jω ⎞
⎟ ( = σ + j 2π f )
s= ⎜ jΩ Im
Td ⎝ 1 + e− jω ⎠
⎛ω ⎞
2e − jω 2 j sin ⎜ ⎟
2 ⎝2⎠ σ
= Re
Td ⎛ω ⎞
2e − j 2 ω cos ⎜ ⎟ −π
⎝2⎠
2 ω
= j tan ω
Td 2
π
1 ω ⎛ 2 ω⎞
⇒ σ = 0 and f = tan ⎜ or Ω = tan ⎟
π Td 2 ⎝ Td 2⎠
⎛T Ω⎞
or ω =2tan -1 ⎜ d ⎟ b
Ω or 2πf g
⎝ 2 ⎠
−π
ω = 2 tan −1
FG ΩT IJ
H2K
d

= 2 tan −1 bπT f g
d

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

Ω
Ωs
Ωp
Hc (Ω)

ω
ωp ωs π ω

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering
Example Bilinear transformation of a BW filter
0.89125 ≤ H ( e jω ) ≤ 1, 0 ≤ ω ≤ 0.2π
H ( e jω ) ≤ 0.17783, 0.3π ≤ ω ≤ π
2 0.2π
0 ≤ ω ≤ 0.2π ⇒ 0 ≤ Ω ≤ tan = 0.6498; Td = 1
Td 2
2 0.3π
0.3π ≤ ω ⇒ tan ≤ Ω ⇒ 1.01905 ≤ Ω
Td 2
2N
⎛ 0.6498 ⎞
2
1 ⎛ 1 ⎞
Hc (Ω) =
2
⇒1+ ⎜ ⎟ =⎜ ⎟ = 1.2589
⎝ Ωc ⎠ ⎝ 0.89125 ⎠
2N
⎛Ω⎞
1+ ⎜ ⎟
⎝ Ωc ⎠
2N
⎛ 1.01905 ⎞
2
⎛ 1 ⎞
1+ ⎜ ⎟ =⎜ ⎟ = 31.6220
⎝ Ωc ⎠ ⎝ 0.17783 ⎠

⎧⎪ ⎡⎛ 1 ⎞
2
⎤ ⎡⎛ 1 ⎞
2
⎤ ⎫⎪
⎨ ⎢⎜ ⎟ − 1⎥ ⎢ ⎜ ⎟ − 1⎥⎬
⎪⎣⎢ ⎝ 0.17783 ⎠ ⎥
⎦ ⎣ ⎢ ⎝ 1.89125 ⎠ ⎥⎦ ⎭⎪ 2.0729
⇒N=⎩ ≅ ≅ 5.30267
⎛ 1.01905 ⎞ 0.3909
2log ⎜ ⎟
⎝ 0.6498 ⎠
⇒ N = 6 ⇒ Ω c = 0.76622

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

π
⎛ ±j
⎜ 0.76622 ⋅ e , = 0.7401 ± j 0.1983
12

⎜ ±j π
3

⇒ Poles are 0.76622 ⋅ e 12
= 0.5418 ± j 0.5418


5
±j π

⎜ 0.76622 ⋅ e = 0.1983 ± j 0.7401


12

0.20238
⇒ Hc ( s) =
( s + 0.39965 + 0.5871)( s 2 + 1.08365 + 0.5871)
2

1
×
( s + 1.48025 + 0.5871)
2

0.0007378 (1 + z −1 )
6

⇒ H (z) =
(1 − 1.2686 z −1
+ 0.7051z −2 )(1 − 1.0106 z −1 + 0.3583 z −2 )
1
×
(1 − 0.9044 z −1
+ 0.2155 z −2 )

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

ƒ The magnitude of N-th order Butterworth filter can be represented by


ωc ΩcTD ω
H ( e jω ) =
2 1 2
; tan = ⇐ Ω = tan
ω
2N
⎛ ⎞ 2 2 Td 2
⎜ tan 2 ⎟
1+ ⎜ ⎟
ω
⎜ tan c ⎟
⎝ 2 ⎠

ƒ Note that this BW filter is maximally flat, H ( e jω c


) = 12 , and periodic with a period
of 2π.

ƒ Maximally flat ⇔ The first (2N-1) derivatives of are zero at ω = 0


H ( e jω )
2
ƒ It is not easy to directly find the poles and zeros in the z-plane from
since the magnitude-squared function should be factorized into H ( z ) H ( z −1 ) to
determine H ( z ) .

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Design of type-I Chebyshev filters


1
1
H (Ω) =
2
1− ε
⎛Ω⎞
1 + ε 2VN2 ⎜ ⎟
⎝ Ωc ⎠
– VN ( x ) is the N-th order Chebyshev polynomial defined by Ωp Ωs

VN ( x ) = cos ( N cos −1 x )
V0 ( x ) = cos 0 = 1
V1 ( x ) = cos ( cos −1 x ) = x
V2 ( x ) = cos ( 2cos −1 x ) = 2 x 2 − 1
V3 ( x ) = 2 x ( x 2 − 1) − x = 4 x 3 − 3 x

VN +1 ( x ) = 2 xVN ( x ) − VN −1 ( x )
⇒ 0 ≤ x ≤ 1 ⇒ 0 ≤ VN2 ( x ) ≤ 1
x > 1 ⇒ cos −1 x is imaginary ⇒ VN ( x ) ∼ hyperbolic cosine
⇒ VN ( x ) increases monotonically

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

– Property of VN ( x )
ƒ {VN ( x )} forms an orthogonal set over −1 ≤ x ≤ 1

⎧ 0, M ≠N
1 ⎪
VN ( x ) VM ( x ) dx = ⎨π / 2, M = N ≠ 0
1
∫ −1
1 − x2 ⎪π , M = N =0

ƒ For each N, VN (1) = 1
ƒ For even N, VN ( −1) = 1; VN ( 0 ) = ( −1)
N /2

VN ( x ) = VN ( − x )
ƒ For odd N, VN ( −1) = −1; VN ( 0 ) = 0
VN ( x ) = −VN ( − x )
ƒ The zeros of {VN ( x )} lie in −1 ≤ x ≤ 1
ƒ The range of {VN ( x )} is between –1 and 1 for −1 ≤ x ≤ 1

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering
1
Ω 1
⇒ For 0 ≤ ≤ 1, 1 ≤ H ( Ω ) ≤
2
1− ε
Ωc 1+ ε 2
Ω
> 1, H ( Ω ) decreases monotonically
Ωc
Ωp Ωs
ƒ Ripple factor: ε 2 ⇒ ripple amplitude δ =1- 1
1+ε 2
ƒ Since N ( )
V 1 = 1

H e ( jω pT
) = 1 +1ε 2
⇐ H ( e jωT ) =
1
1 + ε 2VN ⎡⎣ k tan (ωT / 2 )⎤⎦

ƒ Rule: choose ε , N and Ωc

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

– Consider the first zeros of 1 + ε VN ( x ) = 0


2 2

ƒ Letting cos r ≡ cos(u + jv) = x ⇒ cos −1 x = r


VN ( x ) = cos ( N cos −1 x ) = cos Nr
= cos Nu cosh Nv − j sin Nu sinh Nv
= ± j /ε
1
⇒ cos Nu cosh Nv = 0 & sin Nu sinh Nv = ±
ε
⇒ u = ( 2 M + 1)π / 2 N , M = 0,1,2, ,2 N − 1
1 1
v= sinh −1
N ε
ƒ The poles of the Chebyshev filter lie on an ellipse in the s-plane
σ2 Ω2
+ = 1; s = σ + jΩ
sinh 2 v cosh 2 v

σ p = ( sinh v ) cosθ = aΩc cosθ


Ω p = ( cosh v ) sin θ = bΩc sin θ

1⎛ ⎞ 1⎛ N − ⎞
1 1 1 1

a = ⎜α N − α N ⎟ , b = ⎜α + α ⎟ , α = ε + 1 + ε
N −1 −2

2⎝ ⎠ 2⎝ ⎠
N =3
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Design of Type II Chebyshev Filters

1
Hc (Ω) =
2
−1
⎡ ⎛ Ω ⎞⎤
1 + ⎢ε 2VN ⎜ c ⎟ ⎥
⎣ ⎝ Ω ⎠⎦

• Elliptic filter
– The error is distributed over the entire frequency band ⇒ Equal ripple in all band
1
Hc (Ω) =
2

⎛Ω⎞ ⇒ min order of the filter


1 + ε 2U N2 ⎜ ⎟
Ω
⎝ c⎠
U N (Ω) : Chebyshev rational function
of degree N

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Example

– Filter specifications
ƒ Passband

0.99 ≤ H ( e jω ) ≤ 1.01; ω ≤ 0.4π

ƒ Stopband

H ( e jω ) ≤ 0.001; 0.6π ≤ ω ≤ π

ƒ This implies that δ1 = 0.01, δ 2 = 0.001, ω p = 0.4π and ωs = 0.6π

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

Butterworth filter with N=14 Chev-type I filter with N=8

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


2 ⎛ 1 − z −1 ⎞
s= 5. Filter design techniques
Td ⎜⎝ 1 + z −1 ⎟⎠
Seoul National University
School of Electrical Engineering
Chev-type II filter with N=8 Elliptic filter with N=6

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

– Poles and zeros of the designed filters

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Design of FIR filters by windowing

– FIR filter design directly approximates the desired frequency response of the discrete-
time system

– When the desired frequency response is



H d ( e jω ) = ∫ π H ( e ) dω
1
∑ h [ n]e hd [ n ] =
− jω n π jω
;

d − d
h =−∞
consider the design of a causal FIR filter that approximates the ideal response
– The truncation of the desired impulse response results in the Gibbs phenomenon
– Rectangular Windowing

⎧h [ n], 0 ≤ n ≤ M
h [ n] = ⎨ d ⇒ h [ n ] = hd [ n ]ω r [ n ]
⎩ 0 , otherwise

where ω r [ n ]is the windowing function given by


⎧1, 0 ≤ n ≤ M
ω r [ n] = ⎨
⎩0, otherwise
⇒ H ( e jω ) =
1
∫ π H ( e )ω ( e ( ) ) dθ
π θ j j ω −θ

2π − d r

Note that H ( e jω ) is a smeared version of H d ( e jω )

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

– Effect of windowing
c h
Hd e jω
Wr ( e jω )

ω ω
0

c h
ω r e jω

Wr ( e ) = ∑e
M
jω − jω n
peak side lobe
n =0

1 − e − jω ( M +1)
= 2π
1 − e − jω M +1 design paramters

ω ( M + 1) ΔWm =
sin ωM M +1
−j
= 2 e 2
ω
sin
2
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Common windowing functions


– Bartlett (triangular) ⎧ 2n M
⎪ M, 0≤n≤
2

⎪ 2n M
wB [ n ] = ⎨2 − , ≤n≤M
⎪ M 2
⎪ 0, otherwise
⎪⎩
– Hanning
⎧ ⎛ 2π n ⎞
⎪0.5 ⎜1 − cos ⎟, 0 ≤ n ≤ M
whan [ n ] = ⎨ ⎝ M ⎠
⎪ 0
⎩ , otherwise
– Hamming
⎧ 2π n
⎪0.54 − 0.46cos ,0≤n≤M
wham [ n ] = ⎨ M
⎪⎩ 0 , otherwise
– Blackman
⎧ ⎛ 2π n ⎞ 4π n
⎪0.42 − 0.5cos ⎜ ⎟ + 0.08cos , 0≤n≤M
wBL [ n ] = ⎨ ⎝ M ⎠ M
⎪ 0

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

Trade off between the main lobe width and the peak of the side lobe
Peak side lobe Main-lobe Peak approx.
width error
Rectangular − 13 4π /( M + 1) − 21
Bartlett − 25 8π / M − 25
Hanning − 31 8π / M − 44
Hamming − 41 8π / M − 53
Blackman − 57 12π / M − 74

Rectangular window
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 5. Filter design techniques
School of Electrical Engineering

Bartlett window Hamming window

Hanning window Blackman window


420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 5. Filter design techniques
School of Electrical Engineering

– Kaiser window
⎧ ⎡ n −α ⎤ ⎤
2

⎪ I0 ⎢ β 1 − ⎡
⎢ ⎥ ⎥
⎪ ⎢ ⎣ α ⎦ ⎥⎦
w[ n ] = ⎨ ⎣ ,0 ≤ n ≤ M , α =
M
⎪ I0 ( β ) 2

⎩ 0 ,otherwise

where I 0 ( ⋅ ) is the zeroth-order modified Bessel function of the first kind defined by
1 π jx sinθ 2 ⎛ π⎞
I0 ( x ) =
∫ e dθ ≈ cos ⎜ x − ⎟ ( for large x )
2π −π πx ⎝ 4⎠
ƒ As β = 0 → rectangular window case
ƒ If the window is tapered more (i.e., β is increased), the main lobe width becomes
wider and the peak of the side lobe becomes lower

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

ƒ Increasing M while holding β constant


results in the main lobe width decreased

but does not affect the peak of the side

lobe.

ƒ Given δ is fixed, ω p is defined to be


the highest frequency such that
H ( e jω ) ≥ 1 − δ

and ω s to be the lowest frequency such that


H ( e jω ) ≤ δ

ƒ Then β can be empirically determined by


⎧0.1102 ( A − 8.7 ) , A > 50
⎪⎪
β = ⎨0.5842 ( A − 21) + 0.07886 ( A − 21) 21 ≤ A ≤ 50
0.4

⎪ 0 , A < 21
⎪⎩
A−8
M= ;
2.285Δω
where Δω = ω s − ω p , A = −20log δ

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

– Comparison of commonly used windows

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

Design example
ω p + ωs
ω p = 0.4π ; ω s = 0.6π ⇒ ω c = = 0.5π
2
Δω = ω s − ω p = 0.2π
δ 1 = 0.01; δ 2 = 0.001 ⇒ δ = 0.001
⇒ A = −20log δ = 60dB
⇒ β = 0.1102 ( A − 8.7 ) = 5.65326
A−8 60 − 8
M= = = 36.219 ⇒ M = 37; Type - II FIR
2.285Δω 2.285 × 0.2π

⇒ h [ n ] = hd [ n ] ⋅ ω [ n ]
⎧ ⎡ 2 2⎤
1

⎪ ⎛ ⎛ n − 18.5 ⎞ ⎞ ⎥
I 0 ⎢5.65326 ⎜1 − ⎜ ⎟ ⎟ ⎥
⎪⎪ ⎢ ⎝ 18.5 ⎠ ⎠
= ⎨ sin 0.5π ( n − 18.5 ) ⎢ ⎝
⋅ ⎣ ⎦⎥ , 0 ≤ n ≤ M
⎪ π ( n − 18.5 ) I 0 ( 5.65326 )

⎪⎩0, otherwise

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Linear system with generalized linear phase

– For casual system, zero phase is not achievable


ƒ Phase distortion exists
ƒ Linear phase results in a simple time shift
– System with linear phase
ƒ Ideal delay
H id ( e jω ) = e − jωα , ω <π
⇒ H id ( e jω ) = 1

A rg ⎡⎣ H id ( e jω ) ⎤⎦ = −αω

grd ⎣⎡ H id ( e jω ) ⎦⎤ = − αω = α
∂ω
sin π ( n − α )
From the inverse Fourier transform, hid [ n ] = , −∞<n<∞
π (n −α )
For an input x [ n ] ,
sin π ( n − α )
y [ n] = x [ n] ∗
π (n −α )

sin π ( n − k − α )
= ∑
k =−∞
x[k ]
π (n − k −α )
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 5. Filter design techniques
School of Electrical Engineering

In particular, if α = nd , hid [ n ] = δ [ n − nd ]
⇒ y [ n ] = x [ n ] ∗ hid [ n ] = x [ n − nd ]

ƒ Ideal LPF with linear phase


⎧⎪e− jωα , ω < ω c sin ω c ( n − α )
H p (e ) = ⎨

⇒ h p [ n] =
⎪⎩0, ωc < ω ≤ π π (n −α )

ƒ If α = nd , the impulse response is symmetric about n = α , i.e.,


h p [ 2α − n ] = h p [ n ]

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

– Generalized linear phase

H ( e jω ) = A ( e jω ) e
− j (αω − β )

= A ( e jω ) cos ( β − ωα ) + jA ( e jω ) sin ( β − ωα ) ⇒ τ (ω ) = grd ⎡⎣ H ( e jω ) ⎤⎦

H (e jω

) = ∑ h [ n]e − jω n =−
d

{ }
A rg ⎡⎣ H ( e jω ) ⎤⎦
n =−∞
∞ ∞

= ∑ h [ n] cos ωn − j ∑ h [ n]sin ωn
n =−∞ n =−∞

=−∑
sin ( β − ωα ) h [ n ] sin ω n
tan ( β − ωα ) = ⇒ ∑ h [ n ] sin ⎡⎣ω ( n − α ) + β ⎤⎦ = 0, ∀ω
cos ( β − ωα ) ∑ []
h n cos ω n n

This is satisfied when β = 0 or π , 2α is an integer, and h [ 2α − n ] = h [ n ]


Alternatively, if β =π /2 or 3π / 2, ∑ h [ n] cos ⎡⎣ω ( n − α )⎤⎦ = 0
⇒ 2α = M = an integer and h [ 2α − n ] = − h [ n ]

ƒ This is a necessary condition for h [ n ] to have a constant group delay


ƒ There are other systems having linear phase characteristics without this
symmetry condition

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

– Causal generalized linear phase systems



ƒ If causal, ∑ h [ n]sin ⎡⎣ω ( n − α ) + β ⎤⎦ = 0, ∀ω
n =0

ƒ Causal FIR systems of length (M+1) have generalized linear phase, if


h [ n ] = h [ 2α − n ] or h [ n ] = − h [ 2α − n ]
ƒ If
⎧h [ M − n ] , 0 ≤ n ≤ M
h [ n] = ⎨
⎩ 0 , otherwise
jω M
then H ( e ) = A (e )e

jω jω 2
e

where A ( e ) is a real, even periodic function of ω


e

ƒ If
⎧−h [ M − n ] , 0 ≤ n ≤ M
h [ n] = ⎨
⎩ 0 , otherwise
jω M jω M +π
then H ( e ) = jA ( e ) e = A ( e ) e
− −
jω jω 2 jω 2
o o

where A ( e ) is a real, odd periodic function of ω


o

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

ƒ Type I FIR linear phase systems


h [ n] = h [ M − n] 0≤n≤M

where M is an ever integer


M
−1 ωM
⎡M ⎤ −j
H ( e jω ) = ∑ h [ n ] e − jω n = ∑ h [ n ] e − jω n + h ⎢ ⎥ e
M 2 M

n =0 n =0 ⎣2⎦
2
+ ∑ h [ n] e
M
− jω n

n= +1
2
M M
−1 ωM −1
2
⎡M ⎤ −j 2 2
= ∑ h [ n] e + ∑ h [ M − n] e ( )
− jω n − jω M − n
+ h⎢ ⎥e
n =0 ⎣2⎦ n =0
M
−1

( ) ⎡ M ⎤ − jω
2 M
= ∑ h [ n] e − jω n − jω ( M − n )
+e + h⎢ ⎥e 2
n =0 ⎣2⎦
M M
−1 ωM
⎡ M⎤ ⎡M ⎤
M
2 − jω 2 −j
= 2 ∑ h [ n ] cos ⎢ n − ⎥ ω +h ⎢ ⎥ e 2
= ∑ a [ k ] cos ω k ⋅ e 2

n =0 ⎣ 2⎦ ⎣2⎦ k =0

where
⎡M ⎤ ⎡M ⎤ M
a [ 0] = h ⎢ ⎥ , a [ k ] = 2h ⎢ − k ⎥ , k = 1, 2,.... .
⎣2⎦ ⎣2 ⎦ 2
ωM
⇒ H (e ) = A (e )e
−j
jω jω 2
e

where M

Ae ( e jω ) = ∑ a [ k ] cos ω k
2

k =0

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

Example

⎧1, 0 ≤ n ≤ 4
h [ n] = ⎨
⎩0, otherwise

sin
⇒ H ( e jω ) = ∑ e − jω n
4
= 2 e − j 2ω
n =0
ω
sin
2

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

ƒ Type II linear phase systems


h [ n] = h [ M − n], 0 ≤ n ≤ M
where M is an odd integer

⇒ H ( e jω ) = ∑ h [ n ] e − jω n
M

n =0
M +1
2
⎡M +1 ⎤ ⎡ ⎛ 1 ⎞ ⎤ − j ω2M
= ∑ 2h ⎢ − k ⎥ cos ⎢ω ⎜ k − ⎟ ⎥ ⋅ e
k =1 ⎣ 2 ⎦ ⎣ ⎝ 2 ⎠⎦

Example
⎧1, 0 ≤ n ≤ 5
h [ n] = ⎨
⎩0, otherwise
sin 3ω 5
⇒ H (e )=
−j ω
jω 2
e
ω
sin
2
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 5. Filter design techniques
School of Electrical Engineering

ƒ Type III FIR linear- phase systems


h [ n ] = −h [ M − n ] , 0 ≤ n ≤ M
where M is an even integer
M
ωM
⎡M ⎤
⇒ H ( e ) = j 2∑ h ⎢ − k ⎥ ⋅ sin ω k ⋅ e
2 −j
jω 2

k =1 ⎣ 2 ⎦

Example

h [ n ] = δ [ n ] − δ [ n − 2]
H ( e jω ) = 1 − e − j ω = j 2sin ω ⋅ e − jω
2

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

ƒ Type IV FIR linear- phase systems


h [ n] = −h [ M − n], 0 ≤ n ≤ M

where is an odd integer


M +1

⎡ M +1 ⎤ ⎡ ⎛ 1 ⎞ ⎤ − j ω2M
⇒ H (e ) = j2 ∑ h ⎢
2

− k ⎥ ⋅ sin ⎢ω ⎜ k − ⎟ ⎥ ⋅ e
k =1 ⎣ 2 ⎦ ⎣ ⎝ 2 ⎠⎦

Example

h [ n ] = δ [ n ] − δ [ n − 1]
⇒ H ( e jω ) = 1 + ( e jω ) = 1 − e− jω
ω
ω −j
= j 2sin ⋅e 2
2

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

– Location of zeros for FIR linear-phase systems


M
H ( z ) = ∑ h [ n] z − n
{h [ n]}
n =0
ƒ If are symmetric,

= z − M H ( z −1 )
M o
H ( z ) = ∑ h [ M − n] z − n = ∑ h[k ] z k −M

n =0 k =M

ƒ If z0 = re jθ is a zero of H ( z ) , then
H ( z 0 ) = z0
−M
H z0( )=0
−1

That is, z0−1 = r −1e − jθ is also a zero of H ( z ).


ƒ When h [ n ] is real and z0 is a zero of H ( z ) , z0∗ = re− jθ will also be a zero of H ( z ) ,
and so will (z )
∗ −1
0 .
Therefore, when h [ n ] is real, there will be four conjugate reciprocal zeros of the
form
(1 − re jθ
z −1 )(1 − re − jθ z −1 )(1 − r −1e jθ z −1 )(1 − r −1 z − jθ z −1 )

unless r = 1.

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

ƒ If {h [ n ]} are anti-symmetric, we have

H ( z ) = −∑ h [ M − n ] z − n = − ∑ h [ k ] z k − M = − z − M H ( z −1 )
M o

n =0 k =M

In particular, when z = 1, H (1) = − H (1) and if z = −1, H ( −1) = ( −1) H ( −1).


M +1

Thus, H ( z ) must have a zero at z = 1.

It also must have a zero at z = −1 ⇔ ω = π when M is even.

type - II type - III type - IV

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Relation of FIR linear-phase systems to minimum-phase systems

– Any FIR linear-phase system can be represented by


H ( z ) = H min ( z ) H max ( z ) H uc ( z )
where H max ( z ) = H min ( z −1 ) z − M i , M i = no. of zeros of H min ( z )
and H uc ( z ) has only M 0 zeros on the unit circle.

⇒ The order of M is 2 M i + M 0

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

Example: Decomposition of a linear-phase system


H min ( z ) = 1.252 (1 − 0.9e j 0.6π z −1 )(1 − 0.9e − j 0.6π z −1 )(1 − 0.8e j 0.8π z −1 )(1 − 0.8e − j 0.8π z −1 )
⇒ H max ( z ) = ( 0.9 ) (1 − 1.1111e j 0.6π z −1 )(1 − 1.1111e − j 0.6π z −1 )(1 − 1.25e j 0.8π z −1 )(1 − 1.25e − j 0.8π z −1 )
2

ƒ The overall system H ( z ) = H min ( z ) H max ( z ) has linear phase

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

– Causal and linear phase FIR filter


⎧ w[ M − n ] 0 ≤ n ≤ M M

w[ n ] = ⎨ ⇒ W ( e jω ) = We ( e jω ) e 2
− jω

⎩ 0
even function of ω
ƒ The impulse response of a desired filter is also symmetric; hd [ n ] = hd [ M − n ]
ωM
Hd (e ) = H (e )e
−j
jω jω 2
e

ƒ The overall response


H ( e jω ) =
1

∫ H d ( e jθ )W e j (ω −θ ) dθ( )
θM (ω −θ ) M
1
H e ( e ) e We e ( )
−j j (ω −θ ) −j
= ∫
jθ 2
e 2 dθ

ωM
1
H e ( e )We e ( )
j (ω −θ ) −j
= ∫

e 2 dθ

ωM
= Ae ( e )e
−j
jω 2

Ae ( e jω ) = ∫ π H ( e )W ( e ) dθ
1 π θ (ω θ )
j j −
where
2π − e e

ƒ The resulting response has generalized linear phase and its magnitude is also an
even real function.

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering
Example Linear-phase lowpass filter

⎧ − j ω2M
⎪e , ω < ωc ωM
H d ( e jω ) = ⎨
1
⇒ hd [ n ] =
ωc −j
∫ω e 2
e jω n dω
⎪⎩ 0 , ω c < ω ≤ π 2π − c

⎡ ⎛ M ⎞⎤
sin ⎢ω c ⎜ n − ⎟⎥
= ⎣ ⎝ 2 ⎠⎦
π ⎛⎜ n − ⎞⎟
M
⎝ 2 ⎠

h [ n ] = hd [ n ]ω [ n ] h [ n ] = hd [ n ] w[ n ]

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

– Filter design by Kaiser method


ƒ High-pass filter
⎧0 0 ≤ ω ≤ ωc

H hp ( e ) = ⎨ − j ω M

⎪⎩e 2 ωc ≤ ω ≤ π
ωM
H hp ( e )=e − H ep ( e jω )
−j
jω 2

⎛ M⎞ ⎛ M⎞
sin π ⎜ n − ⎟ sin ω c ⎜ n − ⎟
⇒ hhp [ n ] = ⎝ 2 ⎠
− ⎝ 2 ⎠
π ⎛⎜ n − ⎞⎟ π ⎛⎜ n − ⎞⎟
M M
⎝ 2 ⎠ ⎝ 2 ⎠

• Design example:

If ω s = 0.35π , ω p = 0.5π and δ 1 = δ 2 = δ = 0.021


⇒ A = 33.56
⇒ β = 0.5842 ( A − 21) + 0.07886 ( A − 21)
0.4

= 2.5974
33.56 − 8
M= = 23.73 ⇒ M = 24
2.285 × 0.15π

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

ƒ High-pass filter example

A = 33.56
β = 2.5974
M = 24 ⇒ type I FIR

Actual error=0.0213>0.021

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

ƒ High-pass Kaiser high-pass filter example with M=25 (type-II)


• Use of a type-II Kaiser HPF

may not be appropriate

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

– FIR filter with generalized response

G1 ⎛ M⎞
N =4 sin ω ⎜ n − ⎟
⎝ 2 ⎠
k

⇒ hd [ n ] = ∑ ( Gk − Gk +1 )
N
G2
π ⎛⎜ n − ⎞⎟
k =1 M
G4
⎝ 2 ⎠
G3 where GN +1 = 0
0 ω1 ω2 ω3 π ⇒ h [ n ] = hd [ n ]ω [ n ]

– Differentiator
ωM
Hd (e ) = jω e
−j
jω 2
−π <ω <π
⎡ ⎛ M ⎞⎤ ⎡ ⎛ M ⎞⎤
cos ⎢π ⎜ n − ⎟⎥ sin ⎢π ⎜ n − ⎟ ⎥
⇒ hd [ n ] = ⎣ ⎝ 2 ⎠⎦
− ⎣ ⎝ 2 ⎠⎦
2
n−
M ⎛ M⎞
π ⎜n − ⎟
2 ⎝ 2 ⎠

In the case of using a symmetric window of size M + 1, h [ n ] = hd [ n ] ⋅ ω [ n ] results in


h [ M − n] = −h [ n]

Kaiser formulae were developed for frequency response with simple magnitude
discontinuities, but still works on differentiator

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

ƒ Kaiser window design of a differentiator


The amplitude error: E (ω ) = ω − Ao ( e ) ; 0 ≤ ω ≤ π

where Ao ( e jω ) is the amplitude of the filter H ( z ) and has zeros at z = ±1

By not imposing constraint H(z) to have a zero at z=-1, it is possible to design a


filter having better approximation to the desired response, while using a less
number of filter taps.

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

ƒ Example: Impulse response of Kaiser-windowed differentiatore

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Optimum approximation of FIR filters

– Design a filter that best approximates the desired response for a given M
– Rectangular window provides the best-mean squared approximation:
⎧h [ n ] , 0 ≤ n ≤ M
h [ n] = ⎨ d
minimizes ⎩ 0 , otherwise

∫ π H (e ) − H (e )
1 π 2
ε =2 jω jω

2π − d


= ∑ e [ n]
n =−∞
2

⎧⎪hd [ n ] − h [ n ]; 0 ≤ n ≤ M
e [ n] ⎨
⎪⎩hd [ n ]; otherwisw

ƒ Do not permit individual control errors in


different bands

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Consider the design of a type-I FIR filter with zero phase, i.e., he [ n ] = he [ − n ]
– Corresponding frequency response
Ae ( e ) = ∑ h [ n]e
L L

e
− jω n
= he [ 0] + ∑ 2he [ n ] cos (ω n )
n =− L n =0

is a real, even and periodic function of ω

ƒ A causal system can be obtained by delaying it by L samples


h [ n ] he [ n − L ] = he [ 2 L − n ]
– From a polynomial approximation
cos ω n = Tn ( cos ω ) ; Tn ( x ) = cos ( n cos −1 x )
A ( e jω ) can be represented as an L-th degree trigonometric polynomial
A( e ) = ∑a
L L

k cos ω = P ( x ) x=cos ω ; P ( x ) = ∑ ak x k
k

k =0 k =0
– Define an error function by

E (ω ) = W (ω ) H d ( e jω ) − H ( e jω )
2

where W (ω ) is a weighting function

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

– Example

⎧1, 0 ≤ ω ≤ ω p
Hd (e ) = ⎨

⎩0, ωs ≤ ω ≤ π

⎧1
⎪ ; 0 ≤ ω ≤ ωp δ1
W (ω ) = ⎨ K ; K=
⎪⎩1, δ2
ωs ≤ ω ≤ π

Maximum weighted absolute approximation error

is δ = δ2

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

– Minimax or Chevyshev criterion


min
{he [ n];0≤n≤ L} ω∈F ( max E(ω) )
F = {ω : 0 ≤ ω ≤ ω p , ωs ≤ ω ≤ π }
ƒ Find a set of impulse response that minimizes δ
– Alternative theorem:
ƒ Let denote a closed subset comprising the disjoint union of closed subsets of real
axis x. Then m
P ( x ) = ∑ ak x k
k =0

is an m-th order polynomial

ƒ For desired function DP ( x ) and positive function WP ( x) which are continuous


on FP , and weighted error defined by
EP ( x ) = WP ( x ) ⎡⎣ DP ( x ) − P ( x ) ⎤⎦
a necessary and sufficient condition that be a unique r-th order polynomial
minimizing E = max EP ( x ) is that EP ( x ) has at least r+2 alternations
x∈FP

At least r+2 values xi in FP such that x1 < x2 < < xr + 2 and


EP ( xi ) = − EP ( xi +1 ) = ± E , i = 1,2, ,r + 2
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 5. Filter design techniques
School of Electrical Engineering

– Example: Consider 5-th order polynomials Pj ( x ) that


approximate unity for −1 ≤ x ≤ −0.1 and zero for
0.1 ≤ x ≤ 1
ƒ Assume that WP ( x) = 1 for these two regions
ƒ The optimum 5-th order polynomial has at least 7
alternations of the error in the region in FP

ƒ P1 ( x ) has 3 alternations in −1 ≤ x ≤ −0.1 and


2 alternations in 0.1 ≤ x ≤ 1

ƒ P2 ( x ) also has 5 alternations; 3 in −1 ≤ x ≤ −0.1


and 2 in 0.1 ≤ x ≤ 1

ƒ P3 ( x ) has 8 alternations in −1 ≤ x ≤ −0.1 and

0.1 ≤ x ≤ 1 ⇒ optimum polynomial

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Optimum type-I lowpass filters

– Consider polynomial P ( x ) defined by


L=7
L
P ( cos ω ) = ∑ ak ( cos ω )
k

k =0
– Assume that
⎧1; cos ω p ≤ cos ω ≤ 1
DP ( cos ω ) = ⎨
⎩0; − 1 ≤ cos ω ≤ cos ωs
⎧1/ K ; cos ω p ≤ cos ω ≤ 1
WP ( cos ω ) = ⎨
⎩0; − 1 ≤ cos ω ≤ cos ωs

EP ( cos ω ) = WP ( cos ω ) ⎡⎣ DP ( cos ω ) − P ( cos ω ) ⎤⎦


FP = {ω : 0 ≤ ω ≤ ω p , ωs ≤ ω ≤ π }
– Equi-ripple approximation
ƒ A set of coefficients {ak } is designed to make EP ( cos ω ) have at least ( L + 2 )
alternations on FP

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Optimum type-I lowpass filters (cont.)

– Redraw A e

( ) in terms of x = cos ω

L=7

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Optimum type-I lowpass filters (cont.)

– Max. possible number of alternations of the error


is ( L + 3) since an L-th degree polynomial can

have at most ( L − 1) points with zero slope


∂ L
P ( cos ω ) = − sin ω ∑ kak ( cos ω )
k −1

∂ω k =0
L −1
= − sin ω ∑ ( k + 1) ak +1 ( cos ω )
k

k =0
ƒ Has zeros at ω = 0, ω = π and roots of

( L − 1) -th order polynomial


– Alternations always occur at ω = ω p and ω = ωs
– The filter will be equi-ripple except possibly at
ω = 0 or ω = π

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Parks-McClellan algorithm

– The alternation theorem indicates that the optimum filter Ae e



( ) will satisfies

W (ωi ) ⎡⎣ H d ( e jωi ) − Ae ( e jωi ) ⎤⎦ = ( −1) δ ; i = 1,2,


i +1
,L + 2

⇒ H d ( e jωi ) = Ae ( e jωi ) + ( −1) δ / W (ωi )


i +1

Ae ( e ) = ∑ h [ n]e
L L L L

e
− jω n
= he [ 0] + ∑ 2he [ n ] cos (ω n ) = ∑ ak cos ω = ∑ ak x k
k

n =− L n =0 k =0 k =0

– Hd e i ( ) can be rewritten as
⎡ 2 L 1 ⎤
⎢1 x x x
W (ω1 ) ⎥
1 1 1
⎡ H d ( e jω1 ) ⎤ ⎢ ⎥ ⎡a ⎤
⎢ ⎥ ⎢ −1 ⎥ 0
⎢ H d ( e ) ⎥ ⎢1 x2 x2
jω2 2 L ⎢ ⎥
x2 ⎥
W ( ω2 ) ⎢ ⎥ a
⎢ ⎥=⎢
1
⎥⎢ ⎥
⎢ ⎥ ⎢ ⎥⎢ ⎥
⎢ jωL + 2 ⎥
⎢⎣ H d ( e )⎥⎦ ⎢⎢ 2 L ( −1) ⎥
L+2
⎥ ⎣δ ⎦
⎢ L+2 L+2
1 x x x L+2
W (ωL+ 2 ) ⎥⎦

– Solution for ak and δ can be found by means of polynomial interpolation

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Parks-McClellan algorithm (cont.)

– For a given set of extremal frequencies, the P-M algorithm determines


L+2

∑b H (e ω )
k d
j k
L+2
1
δ= bk = ∏
k =1
;
bk ( −1)
k +1
L+2
xk − xi
∑k =1 W ( ωk )
i =1
i≠k

– For given ak and δ , the error function has magnitude ±δ at L + 2 frequencies ωi

– Ae ( e jω ) has values 1 ± K δ for 0 ≤ ω ≤ ω p and ±δ for ωs ≤ ω ≤ π


– An L-th order trigonometric polynimial Ae ( e ) can be obtained by interpolating

E (ωi )

L +1
d k Ck
∑ x − xk
Ae ( e ) = P ( cos ω ) = Lk =+11

dk
∑k =1 x − xk

( −1) δ ,
k +1 L +1
x = cos ω , Ck = H d ( e ) W (ω ) 1
jωk
− dk = ∏ = bk ( xk − xL+ 2 )
k i =1 xk − xi
i≠k

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Parks-McClellan algorithm (cont.)

ak and δ
Ae ( e jω ) 1 ± Kδ

Example: L = 7

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Characteristics of optimum FIR filters

– Size of the filter tap


−10log (δ1δ 2 ) − 13
M=
2.324 (ωs − ω p )

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Filter design examples by Parks-McClellan algorithm


δ1 = 102 ; δ 2 = 10−3
ω p = 0.4π ; ωs = 0.6π

M = 26 M = 27

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Filter design example (cont.)

– Compensation of zero-order holder

⎧ ω/2
⎪ ; 0 ≤ ω ≤ ωp
H d ( e jω ) = ⎨ sin (ω / 2 )
⎪ ωs ≤ ω ≤ π
⎩0;

δ1 = 102 ; δ 2 = 10 −3 ; ω p = 0.4π ; ωs = 0.6π

M = 28 ⇒ L = 14

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Optimum bandpass filter design

⎧0; 0 ≤ ω ≤ 0.3π

H d ( e jω ) = ⎨1; 0.35π ≤ ω ≤ 0.3π
⎪0; 0.7π ≤ ω ≤ π

⎧1; 0 ≤ ω ≤ 0.3π

W ( e jω ) = ⎨1; 0.35π ≤ ω ≤ 0.3π
⎪0.2; 0.7π ≤ ω ≤ π

M = 74 ⇒ L = 37

– Local extrema may occur in the transition


regions

– The approximation need not be equi-ripple


in the approximation regions

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Optimum approximation of FIR filters

– Design a filter that best approximates the desired response for a given M
– Rectangular window provides the best-mean squared approximation:
⎧h [ n ] , 0 ≤ n ≤ M
h [ n] = ⎨ d
minimizes ⎩ 0 , otherwise

∫ π H (e ) − H (e )
1 π 2
ε =2 jω jω

2π − d


= ∑ e [ n]
n =−∞
2

⎧⎪hd [ n ] − h [ n ]; 0 ≤ n ≤ M
e [ n]  ⎨
⎪⎩hd [ n ]; otherwisw

ƒ Do not permit individual control errors in


different bands

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Consider the design of a type-I FIR filter with zero phase, i.e., he [ n ] = he [ − n ]
– Corresponding frequency response
Ae ( e ) = ∑ h [ n]e
L L

e
− jω n
= he [ 0] + ∑ 2he [ n ] cos (ω n )
n =− L n =0

is a real, even and periodic function of ω

ƒ A causal system can be obtained by delaying it by L samples


h [ n ]  he [ n − L ] = he [ 2 L − n ]
– From a polynomial approximation
cos ω n = Tn ( cos ω ) ; Tn ( x ) = cos ( n cos −1 x )
A ( e jω ) can be represented as an L-th degree trigonometric polynomial
A( e ) = ∑a
L L

k cos ω = P ( x ) x=cos ω ; P ( x ) = ∑ ak x k
k

k =0 k =0
– Define an error function by

E (ω ) = W (ω ) H d ( e jω ) − H ( e jω )
2

where W (ω ) is a weighting function

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

– Example

⎧1, 0 ≤ ω ≤ ω p
Hd (e ) = ⎨

⎩0, ωs ≤ ω ≤ π

⎧1
⎪ ; 0 ≤ ω ≤ ωp δ1
W (ω ) = ⎨ K ; K=
⎪⎩1, δ2
ωs ≤ ω ≤ π

Maximum weighted absolute approximation error

is δ = δ2

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

– Minimax or Chevyshev criterion


min
{he [ n];0≤n≤ L} ω∈F ( max E(ω) )
F = {ω : 0 ≤ ω ≤ ω p , ωs ≤ ω ≤ π }
ƒ Find a set of impulse response that minimizes δ
– Alternative theorem:
ƒ Let denote a closed subset comprising the disjoint union of closed subsets of real
axis x. Then m
P ( x ) = ∑ ak x k
k =0

is an m-th order polynomial

ƒ For desired function DP ( x ) and positive function WP ( x) which are continuous


on FP , and weighted error defined by
EP ( x ) = WP ( x ) ⎡⎣ DP ( x ) − P ( x ) ⎤⎦
a necessary and sufficient condition that be a unique r-th order polynomial
minimizing E = max EP ( x ) is that EP ( x ) has at least r+2 alternations
x∈FP

At least r+2 values xi in FP such that x1 < x2 < " < xr + 2 and
EP ( xi ) = − EP ( xi +1 ) = ± E , i = 1,2,", r + 2
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 5. Filter design techniques
School of Electrical Engineering

– Example: Consider 5-th order polynomials Pj ( x ) that


approximate unity for −1 ≤ x ≤ −0.1and zero for
0.1 ≤ x ≤ 1
ƒ Assume that WP ( x) = 1 for these two regions
ƒ The optimum 5-th order polynomial has at least 7
alternations of the error in the region in FP

ƒ P1 ( x ) has 3 alternations in −1 ≤ x ≤ −0.1 and


2 alternations in 0.1 ≤ x ≤ 1

ƒ P2 ( x ) also has 5 alternations; 3 in −1 ≤ x ≤ −0.1


and 2 in 0.1 ≤ x ≤ 1

ƒ P3 ( x ) has 8 alternations in −1 ≤ x ≤ −0.1 and

0.1 ≤ x ≤ 1 ⇒ optimum polynomial

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Optimum type-I lowpass filters

– Consider polynomial P ( x ) defined by


L=7
L
P ( cos ω ) = ∑ ak ( cos ω )
k

k =0
– Assume that
⎧1; cos ω p ≤ cos ω ≤ 1
DP ( cos ω ) = ⎨
⎩0; − 1 ≤ cos ω ≤ cos ωs
⎧1/ K ; cos ω p ≤ cos ω ≤ 1
WP ( cos ω ) = ⎨
⎩0; − 1 ≤ cos ω ≤ cos ωs

EP ( cos ω ) = WP ( cos ω ) ⎡⎣ DP ( cos ω ) − P ( cos ω ) ⎤⎦


FP = {ω : 0 ≤ ω ≤ ω p , ωs ≤ ω ≤ π }
– Equi-ripple approximation
ƒ A set of coefficients {ak } is designed to make EP ( cos ω ) have at least ( L + 2 )
alternations on FP

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Optimum type-I lowpass filters (cont.)

– Redraw A e

( ) in terms of x = cos ω

L=7

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Optimum type-I lowpass filters (cont.)

– Max. possible number of alternations of the error


is ( L + 3) since an L-th degree polynomial can

have at most ( L − 1) points with zero slope


∂ L
P ( cos ω ) = − sin ω ∑ kak ( cos ω )
k −1

∂ω k =0
L −1
= − sin ω ∑ ( k + 1) ak +1 ( cos ω )
k

k =0
ƒ Has zeros at ω = 0, ω = π and roots of

( L − 1) -th order polynomial


– Alternations always occur at ω = ω p and ω = ωs
– The filter will be equi-ripple except possibly at
ω = 0 or ω = π

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Parks-McClellan algorithm

– The alternation theorem indicates that the optimum filter Ae e



( ) will satisfies

W (ωi ) ⎡⎣ H d ( e jωi ) − Ae ( e jωi ) ⎤⎦ = ( −1) δ ; i = 1,2,", L + 2


i +1

⇒ H d ( e jωi ) = Ae ( e jωi ) + ( −1) δ / W (ωi )


i +1

Ae ( e ) = ∑ h [ n]e
L L L L

e
− jω n
= he [ 0] + ∑ 2he [ n ] cos (ω n ) = ∑ ak cos ω = ∑ ak x k
k

n =− L n =0 k =0 k =0

– Hd e i ( ) can be rewritten as
⎡ 1 ⎤
⎢1 x x 2
" x L

W (ω1 ) ⎥
1 1 1
⎡ H d ( e jω1 ) ⎤ ⎢ ⎥ ⎡a ⎤
⎢ ⎥ ⎢ −1 ⎥ 0
⎢ H d ( e ) ⎥ ⎢1 x2 x2 " x2
jω2 2 L ⎢ ⎥

W ( ω2 ) ⎢ ⎥ a
⎢ ⎥=⎢
1
⎥⎢ ⎥
⎢ # ⎥ ⎢# # # " # # ⎥⎢ # ⎥
⎢ jωL + 2 ⎥
⎢⎣ H d ( e )⎥⎦ ⎢⎢ ( −1) ⎥
L+2
⎥ ⎣δ ⎦
⎢ L+2 L+2
2
" L

W (ωL+ 2 ) ⎥⎦
1 x x x L+2

– Solution for ak and δ can be found by means of polynomial interpolation

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Parks-McClellan algorithm (cont.)

– For a given set of extremal frequencies, the P-M algorithm determines


L+2

∑b H (e ω )
k d
j k
L+2
1
δ= bk = ∏
k =1
;
bk ( −1)
k +1
L+2
xk − xi
∑k =1 W ( ωk )
i =1
i≠k

– For given ak and δ , the error function has magnitude ±δ at L + 2 frequencies ωi

– Ae ( e jω ) has values 1 ± K δ for 0 ≤ ω ≤ ω p and ±δ for ωs ≤ ω ≤ π


– An L-th order trigonometric polynimial Ae ( e ) can be obtained by interpolating

E (ωi )

L +1
d k Ck
∑ x − xk
Ae ( e ) = P ( cos ω ) = Lk =+11

dk
∑k =1 x − xk

( −1) δ ,
k +1 L +1
x = cos ω , Ck = H d ( e ) W (ω ) 1
jωk
− dk = ∏ = bk ( xk − xL+ 2 )
k i =1 xk − xi
i≠k

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Parks-McClellan algorithm (cont.)

ak and δ
Ae ( e jω ) 1 ± Kδ

Example: L = 7

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Characteristics of optimum FIR filters

– Size of the filter tap


−10log (δ1δ 2 ) − 13
M=
2.324 (ωs − ω p )

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Filter design examples by Parks-McClellan algorithm


δ1 = 102 ; δ 2 = 10−3
ω p = 0.4π ; ωs = 0.6π

M = 26 M = 27

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Filter design example (cont.)

– Compensation of zero-order holder

⎧ ω/2
⎪ ; 0 ≤ ω ≤ ωp
H d ( e jω ) = ⎨ sin (ω / 2 )
⎪ ωs ≤ ω ≤ π
⎩0;

δ1 = 102 ; δ 2 = 10 −3 ; ω p = 0.4π ; ωs = 0.6π

M = 28 ⇒ L = 14

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 5. Filter design techniques
School of Electrical Engineering

• Optimum bandpass filter design

⎧0; 0 ≤ ω ≤ 0.3π

H d ( e jω ) = ⎨1; 0.35π ≤ ω ≤ 0.3π
⎪0; 0.7π ≤ ω ≤ π

⎧1; 0 ≤ ω ≤ 0.3π

W ( e jω ) = ⎨1; 0.35π ≤ ω ≤ 0.3π
⎪0.2; 0.7π ≤ ω ≤ π

M = 74 ⇒ L = 37

– Local extrema may occur in the transition


regions, which may not be acceptable

– The approximation need not be equi-ripple


in the approximation regions

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

Discrete Fourier transform


• Discrete Fourier series representation of periodic sequences

– Let x [ n ] be a periodic sequence with period N such that x [ n ] = x [ n + mN ] for any


integer m

Example A periodic complex exponential


2π kn
ek [ n ] = e = ek [ n + mN ]; k is an interger
j
N

Note that ek [ n ] = ek +AN [ n ] for any integer A


– A set of N periodic complex exponentials {e [ n]} ,
k k = 0,1,2,...N − 1, defines all the
frequency components
2π kn
1 N −1 i
⇒ x [ n ] = ∑ X [ k ]e N
j

N k =0
N −1 2π mn
−j
X [ k ] = ∑ x [ n ] e N

n =0

– Fourier series representation


2π kn
1 N −1 i
x [ n ] = ∑ X [ k ]e N
j

N k =0

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering
N −1 2π rn N −1 2π kn 2π rn
−j 1 N −1  −j
∑ x [ n]e = ∑ ∑ X [ k ]e
j
N N
e N
n =0 n =0 N k =0

N −1 2π ( k − r ) n
1 N −1 j
= ∑ X [k ] ∑ e
 N

k =0 N k =0
2π ( k − r ) n
1 N −1 j ⎧1, k − r = AN
Since ∑e N
=⎨
N n =0 ⎩0, otherwise
N −1 2π rn

∑ x [ n] e = X [ r ]
j
N

n =0

ƒ The Fourier series coefficient can be obtained by


N −1 2π kn
−j
X [ k ] = ∑ x [ n ] e N

n =0
N −1 2π ( k + N ) n N −1 2π kn
−j −j
X [ k + N ] = ∑ x [ n ] e N
= ∑ x [ n ] e N − j 2π n
e = X [ k ]
n −0 n −0

ƒ The Fourier series coefficients is a periodic sequence


– Discrete Fourier series (DFS)
ƒ Define by x [ n ] ←⎯⎯
DFS
→ X [ k ]
N −1 2π
−j
Analysis equation : X [ k ] = ∑ x [ n ] wNkn ; wN = e N

n =0

1 N −1 
Synthesis equation : x [ n ] = ∑ X [ k ]wN− kn
N k =0
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

Example Periodic pulse train



⎧1, n = mM
x [ n ] = ∑ δ [ n − mN ] = ⎨
r =−∞ ⎩0, otherwise
Since x [ n ] = δ [ n ] , 0 ≤ n ≤ N − 1
N −1
X [ k ] = ∑ δ [ n ] wN− kn = 1
n =0

1 1 N −1 − kn 1 N −1 j N kn
⇒ x [ n ] = ∑ X [ k ] wN = ∑ wN = ∑ e
 − kn

N N k =0 N k =0
Example Duality in DFS
Let the DFS coefficient be a periodic impulse train

Y [ k ] = N ∑ δ [ k − rN ]
r =−∞
N −1
⇒ y [ n ] = ∑ N δ [ k ] wN− kn =wN−0 = 1, ∀n
k =0

Y [ k ] = Nx [ n ] ↔ y [ n ] = X [ n ]

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

Example Periodic rectangular pulse train

πk
4 4 −j

1−W 5k sin 4π k
X [ k ] = ∑W nk
= ∑e 10
kn
= =
10 2 e − j 10
n −0
10
n =0 1−W k
πk
sin
10
10

ƒ Any periodic sequence can be represented as a sum of complex exponential


sequences
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

• Properties of DFS

– Linearity
ax1 [ n ] + bx2 [ n ] ←⎯⎯
DFS
→ aX [ k ] + bX [ k ]

– Shift of a sequence
N −1 2π N −1 2π 2π 2π
−j −j ( n−m ) − j −j
∑ x [ n − m] e = ∑ x [ n − m ] e = X [ k ] e = X [ k ]WNkm
kn km
N N N N
e
n =0 n=0

⇒ x [ n − m ] ←⎯⎯DFS
→ X [ k ]WNkm

– Duality
x [ n ]W − nA ←⎯⎯
N
DFS
→ X [ k − A ]

1 N −1  N −1
x [ n ] = ∑ X [ k ]wN ⇒ Nx [ − n ] = ∑ X [ k ]WNkn
− kn

N k =0 k =0
N −1
⇒ Nx [ − k ] = ∑ x [ n ]WNkn
k =0

If x [ n ] ←⎯⎯
DFS
→ X [ k ] , X [ n ] ←⎯⎯
DFS
→ Nx [ − k ]
– Symmetry properties
x * [ n ] ←⎯⎯
DFS
→ X * [ − k ]
x * [ −n ] ←⎯⎯
DFS
→ X * [ k ]

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering
⇒ If x [ n ] is real, X [ k ] = X * [ − k ]

X [ k ] = X [ − k ]
– Periodic convolution
N −1 N −1
x3 [ n ] = ∑ x1 [ m ] x2 [ n − m ] = ∑ x2 [ m ] x1 [ n − m ]
m =0 m=0


N −1 N −1

X 3 [ k ] = ∑ ⎜ ∑ x1 [ m ] x2 [ n − m ] ⎟WNkn

n =0 ⎝ m =0 ⎠
N −1 N −1
= ∑ x1 [ m ] ∑ x2 [ n − m ]WNkn
m =0 n =0
N −1
= X 2 [ k ] ∑ x1 [ m ]WNkm = X 1 [ k ] X 2 [ k ]
m =0
N −1
⇒ ∑ x1 [ m ] x2 [ n − m ] ←⎯⎯
DFS
→ X 1 [ k ] X 2 [ k ]
m =0
ƒ Duality
1 N −1 
x1 [ n ] x2 [ n ] ←⎯⎯
→ ∑ X 1 [ m ] X 2 [ k − m ]
DFS

N m =0
ƒ Difference between aperiodic convolution and periodic convolution
• The sum is over an interval 0 ≤ m ≤ N − 1
• x 2 [ n − m ] = x 2 ⎡⎣ − ( m − n ) ⎤⎦

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering
Example Periodic convolution

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering
– Properties of DFS

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering
– Properties of DFS (cont.)

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

• Fourier transform (F.T.) of periodic signals

– A sequence should be absolutely summable to guarantee the uniform convergence of


its Fourier transform

– Periodic signals are not absolutely summable


– The F.T. of a periodic signal can be interpreted as an impulse train in the frequency
domain with impulse values proportional to the DFS coefficients for the sequence

– If x [ n ] is periodic with period N, the Fourier transform of x n [ ] is defined by

2π ∞
⎛ 2π k ⎞
x [ n ] ⇔ X ( e jω ) = ∑ 
X [ k ] δ ⎜ ω − ⎟
N k =−∞ ⎝ N ⎠

ƒ Although the F.T. of a periodic sequence does not converge in the normal sense,
the introduction of impulses enables to use the F. T.

ƒ Note: X e

( ) has a necessary periodicity with period 2π
2π ⎛ 2π k ⎞ jωn
X ( e jω )e jωn dω =
1 2π −ε 1 2π −ε
∫ ∫ ∑ X [ k ]δ ⎜ ω − ⎟ e dω ; 0 < ε < 2π / N
2π 0−ε 2π 0−ε N k ⎝ N ⎠
1 ∞  2π −ε ⎛ 2π k ⎞ jωn
= ∑ X [k ] ∫ δ ⎜ω − ⎟e dω
N k =−∞ 0 −ε
⎝ N ⎠

1 ∞ 
= ∑ X [ k ] e N = x [ n ]
j kn
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
N k =−∞
Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

Example: Fourier transform of a periodic impulse train



p [ n ] = ∑ δ [ n − mN ] ⇒ P [ k ] = 1, ∀ k
m = −∞

2π ∞
⎡ 2π k ⎤
⇒ P e jω =( ) ∑ δ
N k = −∞ ⎢⎣
ω −
N ⎥⎦
– For a finite-length sequence x [ n ] , ( i.e ., x [ n ] = 0 for n < 0 and n ≥ N )
x [ n ] = x [ n ] ∗ p [ n ]
∞ ∞ ∞
= ∑ ∑ δ [A − mN ]x [ n − A] = ∑ x [ n − mN ]
m =−∞ A =−∞ m =−∞

X ( e jω ) = X ( e jω ) P ( e jω )
2π ∞
⎛ 2π k ⎞
= X (e ) jω
∑ δ ⎜⎝ ω − ⎟
N k =−∞ N ⎠
2π ∞
⎛ j 2Nπ k ⎞ ⎛ 2π k ⎞
= ∑ ⎜ ⎟ ⎜⎝
X e δ ω −
N ⎠

N k =−∞ ⎝ ⎠
⎛ j 2Nπ k ⎞ N −1 2π
⇒ X [ k ] = X ( e jω )
−j
⎟ ∑ [ ]
k
2π = X ⎜e = 
x n e N
ω=
N
k
⎝ ⎠ n =0
Thus, X [ k ] is obtained by sampling the Fourier transform of a finite sequence x [ n ]
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

Example: Relationship between the DFS coefficients and the FT of one period
sin ( 5ω / 2 ) − j 2ω
( )
4
⎧1; 0 ≤ n ≤ 4
x [n ] = ⎨ ⇒ X e

= ∑ e − jω n
=
sin (ω / 2 )
e
⎩ 0; otherwise n=0

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

• Sampling the Fourier transform

– Since X ( e jω ) is periodic with period 2π , X [ k ] is also periodic in k with period N.


⎛ j 2Nπ k ⎞ N −1 2π
X [ k ] = X ( e jω )
−j k
– Since
2π = X ⎜ e ⎟ = ∑ x [ n ]e N ,
ω= k
N ⎝ ⎠ n =0
2π 2π
1 N −1 ⎡ ∞ − j mk ⎤ j kn
x [ n ] = ∑ ⎢ ∑ x [ m ] e N ⎥e N
N k =0 ⎣ m=−∞ ⎦
∞ 2π
1 N −1 j N ( k −m )n
= ∑ x [ m] ∑ e
m =−∞ N k =0
∞ ∞
= ∑ x [ m ] ∑ δ [ n − m − AN ]
m =−∞ A =−∞

= x [ n ] ∗ ∑ δ [ n − AN ]
A =−∞

= ∑ x [ n − AN ]
A =−∞

The samples of the F.T. of x [ n ] can be thought of as DFS coefficients of a periodic


sequence x [ n ] obtained through periodic replication of x [ n ]

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering
– A periodic sequence X [ k ] can be interpreted as equally spaced samples of the
Fourier transform of one period of x [ n ]
⎧ x [ n ] , 0 ≤ n ≤ N − 1
x [ n] = ⎨
⎩ 0 , otherwise
N −1 N −1
X (e jω
) = ∑ x [ n] e − jω n
= ∑ x [ n ] e− jω n
n =0 n =0


⇒ X [ k ] = X ( e jω ) 2π k ⇐ Sampling of the Fourier transform at a rate of
ω=
N ω

Example ⎧1, 0 ≤ n ≤ 4
x [ n] = ⎨
⎩0, otherwise

2 e− j 2ω ⇒ X [ k ] = sin ( kπ / 2 ) e− j 4 kπ /10
sin
X ( e jω ) = ∑ e− jω n
4
=
n =0 sin
ω sin ( kπ /10 )
2

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

• Fourier representation of finite-duration sequences: Discrete Fourier transform (DFT)


⎧ x [ n ] , 0 ≤ n ≤ N − 1 ∞
x [ n] = ⎨ ⇔ x [ n ] = ∑ x [ n − AN ] = x ⎡⎣( ( n ) ) N ⎤⎦
⎩ 0 , otherwise A =−∞

where x ⎡⎣( ( n ) ) N ⎤⎦  x ⎡⎣( n modulo N ) ⎤⎦

– x [ n ] can be visualized as warping the finite sequence around the cylinder


– Since the Fourier series coefficients X [ k ] of x [ n ] is also a periodic sequence with
a period of N, the DFT of x [ n ] can be obtained by

⎪⎧ X [ k ] , 0 ≤ k ≤ N − 1
X [k ] = ⎨
⎪⎩0 , otherwise

X [ k ] = X ⎡⎣( ( k ) ) N ⎤⎦ ⇔ X [ k ] = ∑ X [ k − mN ]
m =−∞
N −1
1 N −1 
– Since X [ k ] = ∑ x [ n ]WN and x [ n ] = ∑ X [ k ]WN− nk ,
  nk

n =0 N k =0
⎧ N −1 ⎧ 1 N −1
⎪∑ [ ] ⎪ ∑ X [ k ]WN , 0 ≤ n ≤ N − 1
− nk
x n W nk
, 0 ≤ n ≤ N − 1
X [ k ] = ⎨ k =0 and x [ n ] = ⎨ N k =0
N

⎪ ⎪
⎩ 0 , otherwise ⎩ 0 , otherwise

x [ n ] ←⎯⎯
DFT
→ X [k ]

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

– Example
N −1 − j 2π
1 − e − j 2π k ⎧ N , k = 0, ± N , ±2 N , ⋅⋅ ⋅
X [ k ] = ∑ e N
= 2π k
=⎨
n =0
1− e
−j
N ⎩0, otherwise

N=5; x [ n]

x [ n ]

X [ k ] X [k ]

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

– Example: N=10

x ⎡⎣ n ⎤⎦

x ⎡⎣ n ⎤⎦

X [k ]

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

• Properties of the DFS

– Linearity
x [ n ] ←⎯⎯
DFT
→ X [ k ] ⇒ α x1 [ n ] + β x2 [ n ] ←⎯⎯
DFT
→α X 1 [ k ] + β X 2 [ k ]
N1 N2 N ≥ max ⎡⎣ N1, N 2 ⎤⎦ with zero padding

– Circular shift
x1 [ n ] = x [ n − m ] ←⎯⎯
DFT
→ X ( e jω ) e − jω m

x1 [ n ] ←⎯⎯
→ X1 [k ] = X [k ]e
−j km
ƒ Let DFT N

ƒ Since x1 [ n ] = 0 outside 0 ≤ n ≤ N -1, x1 [ n ] cannot be obtained by simply time shifting


x [ n]

⇒ x1 [ n ] = x1 ⎡⎣( ( n ) ) N ⎤⎦ ←⎯⎯


DFT
→ X 1 [ k ] = X 1 ⎡⎣( ( k ) ) N ⎤⎦
2π m( ( k ) ) 2π km 2π km
⇒ X 1 [ k ] = X ⎡⎣( ( k ) ) N ⎤⎦ e = X ⎡⎣( ( k ) ) N ⎤⎦ e
−j −j −j
= X [ k ] e
N
N N N

⎧⎪ x1 [ n ] = x ⎡( ( n − m ) ) ⎤ , 0 ≤ n ≤ N − 1
⇒ x1 [ n ] = ⎨ ⎣ N⎦

⎪⎩ 0 , otherwise
2π km
⇒ x ⎡⎣( ( n − m ) ) N ⎤⎦ ←⎯
−j

DFT
→ X [k ]e N
, 0 ≤ n ≤ N − 1: circular shift

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

– Example: circular shift

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

– Duality
x [ n ] = X ⎣⎡( ( n ) ) N ⎦⎤ ←⎯ ⎯
DFT
→ X [ k ] = X ⎣⎡( ( k ) ) N ⎦⎤
⇒ X [ k ] ←⎯⎯ DFT
→ Nx [ − k ]

Let x1 [ n ] = X [ n ] ⇒ x1 [ n ] ←⎯⎯


DFT
→ X 1 [ k ] = Nx [ − k ]
⎧ Nx [ − k ] , 0 ≤ k ≤ N − 1
X1 [k ] = ⎨
⎩0, otherwise
⎧⎪ N x ⎡( ( − k ) ) ⎤ , 0 ≤ k ≤ N − 1
=⎨ ⎣ N⎦

⎪⎩0, otherwise
⇒ X [ n ] ←⎯⎯ DFT
→ N x ⎡⎣( ( − k ) ) N ⎤⎦ , 0 ≤ k ≤ N − 1
– Symmetry

DFT of x [ n ] = DFS coefficients of x [ n ] = x ⎡⎣( ( n ) ) N ⎤⎦

⇒ x∗ [ n ] ←⎯⎯
DFT
→ X ∗ ⎡⎣( ( − k ) ) N ⎤⎦ , 0 ≤ n ≤ N − 1

x∗ ⎡⎣( ( − n ) ) N ⎤⎦ ←⎯⎯
DFT
→ X ∗ [k ]

{ x [ n ] + x ∗ [ − n ]}; x [ n ] = x ⎡⎣( ( n ) ) N ⎤⎦
1
xe [ n ] =
2
x0 [ n ] = { x [ n ] − x ∗ [ − n ]}
1
2
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

xe [ n ] = xe [ n ] , 0 ≤ n ≤ N − 1

=
1
2
{
x ⎡⎣( ( n ) ) N ⎤⎦ + x∗ ⎡⎣( ( n ) ) N ⎤⎦}
= { x [ n ] + x∗ [ N − n ]} ⇐ ( ( − n ) ) N = ( N − n ) ; ( ( n ) ) N = n; 0 ≤ n ≤ N − 1
1
2
→ X e [ k ] = { X [ k ] + X ∗ [ k ]} = Re{ X [ k ]}
1
xe [ n ] ←⎯⎯
DFT

2
Similarly,
xo [ n ] = xo [ n ] , 0 ≤ n ≤ N − 1
⇒ x0 [ n ] ←⎯⎯
DFT
→ j Im { X [ k ]}

– N-point Circular convolution


N −1
x3 [ n ] = ∑ x1 [ m ] x2 [ n − m ] , 0 ≤ n ≤ N −1
m =0
N −1
= ∑ x1 ⎡⎣( ( m ) ) N ⎤⎦ x2 ⎡⎣( ( n − m ) ) N ⎤⎦
m=0
N −1
= ∑ x1 [ m ] x2 ⎡⎣( ( n − m ) ) N ⎤⎦
m=0

Δ x1 [ n ] N x2 [ n ]
N −1
= ∑ x1 ⎡⎣( ( n − m ) ) N ⎤⎦ x2 [ m ]
m=0

= x2 [ n ] N x1 [ n ]
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

Example

x1 [ n ] = δ [ n − 1]

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

Example: N-point circular convolution


⎧1 0 ≤ n ≤ L − 1
x1 [ n ] = x2 [ n ] = ⎨
⎩0 otherwise
ƒ N=L:
N −1
⎧N , k = 0
X 1 [ k ] = X 2 [ k ] = ∑1 ⋅ WNkn = ⎨
n =0 ⎩0, otherwise
⎧N 2, k = 0
⇒ X 3 [k ] = X1 [k ] X 2 [k ] = ⎨
⎩0, otherwise
⇒ x3 [ n ] = N , 0 ≤ n ≤ N − 1

ƒ N =2 L: Linear convolution ?

x1 [ n ] N x2 [ n ] ←⎯⎯
DFS
→ X1 [k ] X 2 [k ]
1 N −1
⇔ x1 [ n ] x2 [ n ] ←⎯⎯
DFS
→ X 3 [k ] = ∑ X 1 [A ] X 2 ⎣⎡( ( k − A ) ) N ⎦⎤
N A =0
1
X1 [k ] N X 2 [k ]
N

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

Example: N(=2L)-point circular convolution


⎧1 0 ≤ n ≤ L − 1
x1 [ n ] = x2 [ n ] = ⎨
⎩0 otherwise

x1 [ n ] N x2 [ n ] ←⎯⎯ DFT
→ X1 [k ] X 2 [k ]
1 N −1
x1 [ n ] x2 [ n ] ←⎯⎯
DFT
→ X 3 [ k ] = ∑ X 1 [ A ] X 2 ⎣⎡( ( k − A ) ) N ⎦⎤
N A =0
1
= X1 [k ] N X 2 [k ]
N
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

• Linear convolution using the DFT

x1 [ n ]

x3 [ n ] = ∑ x [ m] x [ n − m]
1 2
m =−∞
0 L

x2 [ n ]

0 L + p −1
0 p

– N Δ ( L + p − 1)-point circular convolution with zero padding

⎧ x [ n ] , 0 ≤ n ≤ N − 1
x p [ n] = ⎨ ; x [ n ] = ∑ x [ n − mN ]
⎩ 0, otherwise m

X 3 ( e jω ) = X 1 ( e jω ) X 2 ( e jω ) ⇒ X 3 [ k ] = X 3 ( e jω ) 2π k , 0 ≤ k ≤ N −1
ω=
N

= X 1 ( e jω ) X 2 ( e jω ) 2π k
ω=
N

= X1 [k ] X 2 [k ]
⇒ x3 p [ n ] = x1 [ n ] N x2 [ n ]

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

– The circular convolution of two finite-length sequences can be equivalent to linear


convolution of the two sequences.
⎧⎪∑ x3 [ n − mN ] , 0 ≤ n ≤ N − 1
x3 p [ n ] = ⎨ m
⎪⎩0, otherwise

– Calculation of the output of an LTI using the DFT


hn

zero padding

0 p

y [ n] = h [ n] ∗ x [ n]
xn
L −1
0
L L
– How to resolve the issue when x [ n ] is infinite?

ƒ Assume x [ n ] = 0 for n < 0


ƒ The sequence x [ n ] can be decomposed in to a sum of shifted finite-length
∞ ⎧ x [ n + mL ] , 0 ≤ n ≤ N − 1
segments of length L x [ n ] = ∑ xm [ n − mL ]; xm [ n ] = ⎨
m =0
⎩ 0 , otherwise
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

– Illustration of warping around due to improper circular convolution

N=L N = L + p −1

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

• Linear convolution using the discrete Fourier transform

– How to resolve the issue when x [ n ] is infinite?


ƒ Assume x [ n ] = 0 for n < 0
ƒ The sequence x [ n ] can be decomposed in to a sum of shifted finite-length
segments of length L

x [ n ] = ∑ xm [ n − mL ];
m =0

⎧ x [ n + mL ] , 0 ≤ n ≤ N − 1
where xm [ n ] = ⎨
⎩ 0 , otherwise

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

– Overlap-add method y [ n] = h [ n] ∗ x [ n]

xm [ n ] = x [ n + mL ] , 0 ≤ n ≤ L − 1


y [ n ] = ∑ ym [ n − mL ]
N -point circular convolution
m =0

ym [ n ] = h [ n ] ∗ xm [ n ]

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

– Overlap-save method y [ n ] = h [ n ] ∗ x [ n ]

xm [ n ] = x ⎡⎣ n + m ( L − p + 1) − p + 1⎤⎦
0 ≤ n ≤ L −1

N -point circular convolution


y [ n ] = ∑ ym ⎡⎣ n − m ( L − p + 1) + p − 1⎤⎦
m =0

ym [ n ] = h [ n ] ∗ xm [ n ]

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering
Homework #7 :
• The discrete Cosine transform (DCT)
8 - 29, - 31, - 34, - 36,
– General class of finite-length transform - 39, - 49, & - 64
N −1
Α [ k ] = ∑ x [ n ] φk∗ [ n ] Due by June 9
n =0

1 N −1
x [ n] =
∑ Α [ k ] φk [ n ]
N k =0 ⎧1, m = k
where {φk [ n ]} are referred to the basis sequences s.t.
1 N −1
∑ φk [ n ]φm∗ [ n ] = ⎨
2π kn N n =0 ⎩0, m ≠ k
e.g. DFT: φk [ n ] = e
j
N

– DCT definition
π kn
ƒ The basis sequences {φk [ n ]} are cosine functions cos
N
ƒ Assume that x [ n ] are periodic and even symmetric

– Type-I periodic sequence: even periodic symmetry about n=0, N-1, 2(N-1),   
x1 [ n ] = xα ⎡⎣( ( n ) )2 N − 2 ⎤⎦ + xα ⎡⎣( ( − n ) )2 N − 2 ⎤⎦

xα [ n ] = α [ n ] x [ n ]
⎧1
⎪ n = 0 and N -1
α [ n] = ⎨ 2
⎩⎪ 1 1 ≤ n ≤ N − 2

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

ƒ DCT-1 is defined by
N −1
π kn
X 1c [ k ] = 2∑α [ n ] x1 [ n ] cos , 0 ≤ k ≤ N −1
n =0 N −1
1 N −1 π kn
x1 [ n ] = ∑ α [ k ] X 1c [ k ] cos , 0 ≤ n ≤ N −1
N − 1 k =0 N −1

– Type-II periodic sequence: periodic with period 2N


x2 [ n ] = x ⎡⎣( ( n ) )2 N ⎤⎦ + x ⎡⎣( ( − n − 1) )2 N ⎤⎦
ƒ DCT-2 is defined by
N −1 π k ( 2n + 1)
X 2c [ k ] = 2∑ x2 [ n ] cos , 0 ≤ k ≤ N −1
n =0 2N
1 N −1 π k ( 2n + 1)
x2 [ n ] = ∑ β [ k ]X 2c [ k ] cos , 0 ≤ n ≤ N −1
N k =0 2N

⎧1
⎪ , k =0
β [k ] = ⎨ 2
⎩⎪ 1 , 1 ≤ k ≤ N − 1

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

– Relationship between DFT and DCT-1


x1 [ n ] = xα ⎡⎣( ( n ) )2 N − 2 ⎤⎦ + xα ⎡⎣( ( − n ) )2 N − 2 ⎤⎦ = x1 [ n ] , 0 ≤ n ≤ 2 N − 3

ƒ 2(N-1)-point DFT of x1 [ n ] :
X 1 [ k ] = X α [ k ] + X α∗ [ k ] = 2 Re{ X α [ k ]} , 0 ≤ k ≤ 2 N − 3
N −1
2π kn
X α [ k ] = 2∑α [ n ] x [ n ] cos
n =0 2 ( N − 1)
= X 1c [ k ]
ƒ The DCT-1 of N-point sequence is identical to 2(N-1)-point DFT of x1 [ n ].
2π kn
2 N −3
1
x1 [ n ] = ∑ X [k ]e
j
2( N −1)

2 ( N − 1) k =0 1
π kn
⎡ N −1 c π kn
( N −1) ⎤
π kn 2 N −3
[ 2 N − 2 − k ]e
2 N −3 j
1
⎢ ∑ X [ k ]e + ∑ X 1 [ 2( N − 1) − k ]e ∑ ( N −1)
j j
( N −1) X 1c
= c

2 ( N − 1) ⎣ k =0 1 k =N

k=N

N −2 ( 2 N − 2 − m )π n
= ∑ X 1c [ m ]e
j
1 ⎡ N −1 c π kn N −2
N −1 ⎤
π kn N −1

∑ [ ] ∑ [ ]
j j
= X k e N −1
+ X c
k e
2 ( N − 1) ⎢⎣ k =0 ⎥
1 1 m =1
k =1 ⎦ N −2 − nmπ

⎤ =∑ [ m]e
j

1 ⎡ N − 2 c ⎛ j πNkn−1 − j πNkn−1 ⎞ π ( N −1) n X 1c N −1

∑ [ ]⎜ 1[ ] 1[ 1] e
j
= + ⎟ + c
+ c
− N −1 m =1

2 ( N − 1) ⎢⎣ k =1 1 ⎥
X k e e X 0 X N
⎝ ⎠ ⎦
⎧1
1 N −1 π nk ⎪ , k = 0 and N − 1
= ∑ α [ k ] X 1c [ k ] cos , 0 ≤ n ≤ N − 1; α [k ] = ⎨ 2
N − 1 k =0 N −1
⎩⎪1 , 1 ≤ k ≤ N − 2
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

ƒ Note : DCT-1 involves only real-valued coefficients


⇒ reduce the implementation complexity.

– Relationship between DFT and DCT-2


x2 [ n ] = x ⎣⎡( ( n ) )2 N ⎦⎤ + x ⎣⎡( ( − n − 1) )2 N ⎦⎤ = x2 [ n ] , 0 ≤ n ≤ 2 N − 1

ƒ 2N-point DFT of 2N-point sequence x2 [ n ]


X 2 [ k ] = X [ k ] + X * [ k ] e j 2π k / 2 N
= e jπ k / 2 N ( X [ k ] e − jπ k / 2 N + X * [ k ] e jπ k / 2 N )
= 2e jπ k / 2 N Re{ X [ k ] e − jπ k / 2 N } , 0 ≤ k ≤ 2 N − 1
N −1
π k (2n + 1)
Re{ X [ k ] e − jπ k / 2 N } = ∑ x [ n ] cos
k =0 2N
⇒ X 2 [ k ] = 2Re { X [ k ] e
c − jπ k / 2 N
}; 0 ≤ k ≤ N − 1
⇒ X 2c [ k ] = X 2 [ k ] e − jπ k / 2 N ; 0 ≤ k ≤ N − 1
N −1
π (2 N − k )(2n + 1)
X 2c [ 2 N − k ] = 2∑ x [ n ] cos = − X 2c [ k ]; 0 ≤ k ≤ 2 N − 1
k =0 2N
⎧ X 2c [ 0] , k =0
⎪ c 1 2 N −1
⎪ X 2 [k ]e k = 1, ⋅ ⋅⋅, N − 1 x2 [ n ] = ∑ X 2 [ k ] e j 2π k / 2 N ,
jπ k / 2 N
, ⇔
⇒ X 2 [k ] = ⎨ 2 N k =0
⎪0, k=N
n = 0,1, ⋅ ⋅ ⋅, 2 N − 1
⎪− X c [ 2 N − k ] e jπ k / 2 N , k = N + 1, ⋅ ⋅⋅,2 N − 1
⎩ 2
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

– Energy compaction property of DCT-2


ƒ Since DCT-2 coefficients of a finite-length sequence are concentrated in the low
indices than DFT, DCT-2 is often used for data compression applications in
preference to DFT
N −1
1 N −1
∑ x [ n] ∑ β [ k ] X 2c [ k ]
2 2
=
n=0 N k =0
32 - point DFT
Example x [ n ] = a cos (ω 0 n + φ )
n

⇐ 32 − point DCT

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

ƒ Energy concentration can be examined by measuring the truncation error of the


transformations.
1 N −1
xm [ n ] = ∑ Tm [ k ] X [ k ] e j 2π k / 2 N , n = 0,1, ⋅ ⋅ ⋅,2 N − 1; m = 1,3,5, ⋅ ⋅ ⋅, N − 1
N k =0

⎧1, 0 ≤ k ≤ ( N −1− m)/ 2



Tm [ k ] = ⎨0, ( N +1− m)/ 2 ≤ k ≤ ( N −1+ m)/ 2

⎩1, ( N +1+ m)/ 2 ≤ k ≤ N −1
1 N −1− m π k (2n + 1)
xmc [ n ] = ∑ β [ k ] X 2c [ k ] cos ; 0 ≤ n ≤ N −1
N k =0 2N
1 N −1
MS truncation error : EDFT [ m ] = ∑ x [ n ] − xm [ n ]
2

N n =0
1 N −1
EDCT [ m ] = ∑ x [ n ] − xmc [ n ]
2

N n =0

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

Discrete Fourier transform


• Discrete Fourier series representation of periodic sequences

– Let x [ n ] be a periodic sequence with period N such that x [ n ] = x [ n + mN ] for any


integer m

Example A periodic complex exponential


2π kn
ek [ n ] = e = ek [ n + mN ]; k is an interger
j
N

Note that ek [ n ] = ek +AN [ n ] for any integer A


– A set of N periodic complex exponentials {e [ n]} ,
k k = 0,1,2,...N − 1, defines all the
frequency components

1 N −1 i
⇒ x [ n ] = ∑ X [ k ]e N
j kn

N k =0
N −1 2π mn
−j
X [ k ] = ∑ x [ n ] e N

n =0

– Fourier series representation



1 N −1
x [ n ] = ∑ i X [ k ]e N
j kn

N k =0

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering
N −1 2π N −1 2π kn 2π
−j 1 N −1  − j rn
∑ x [ n]e = ∑ ∑ X [ k ]e
rn j
N N
e N
n =0 n =0 N k =0
N −1 N −1 2π
1 j ( k − r )n
= ∑ X [ k ] ∑ e N
k =0 N k =0
1 N −1 j 2Nπ ( k −r )n ⎧1, k − r = AN
Since ∑e =⎨
N n =0 ⎩0, otherwise
N −1 2π

∑ x [ n] e = X [ r ]
j rn
N

n =0

ƒ The Fourier series coefficient can be obtained by


N −1 2π
−j
X [ k ] = ∑ x [ n ] e
kn
N

n =0
N −1 2π N −1 2π
− j (k +N )n −j
X [ k + N ] = ∑ x [ n ] e = ∑ x [ n ] e = X [ k ]
kn
N N − j 2π n
e
n −0 n−0

ƒ The Fourier series coefficients is a periodic sequence


– Discrete Fourier series (DFS)
ƒ Define by x [ n ] ←⎯⎯
DFS
→ X [ k ]
N −1 2π
−j
Analysis equation : X [ k ] = ∑ x [ n ] wNkn ; wN = e N

n =0

1 N −1 
Synthesis equation : x [ n ] = ∑ X [ k ]wN− kn
N k =0
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

Example Periodic pulse train



⎧1, n = mM
x [ n ] = ∑ δ [ n − mN ] = ⎨
r =−∞ ⎩0, otherwise
Since x [ n ] = δ [ n ] , 0 ≤ n ≤ N − 1
N −1
X [ k ] = ∑ δ [ n ] wN− kn = 1
n =0

1 1 N −1 − kn 1 N −1 j N kn
⇒ x [ n ] = ∑ X [ k ] wN = ∑ wN = ∑ e
 − kn

N N k =0 N k =0
Example Duality in DFS
Let the DFS coefficient be a periodic impulse train

Y [ k ] = N ∑ δ [ k − rN ]
r =−∞
N −1
⇒ y [ n ] = ∑ N δ [ k ] wN− kn =wN−0 = 1, ∀n
k =0

Y [ k ] = Nx [ n ] ↔ y [ n ] = X [ n ]

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

Example Periodic rectangular pulse train

πk
4 4 −j

1−W 5k sin 4π k
X [ k ] = ∑W nk
= ∑e 10
kn
= =
10 2 e − j 10
n −0
10
n =0 1−W k
πk
sin
10
10

ƒ Any periodic sequence can be represented as a sum of complex exponential


sequences
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

• Properties of DFS

– Linearity
ax1 [ n ] + bx2 [ n ] ←⎯⎯
DFS
→ aX [ k ] + bX [ k ]

– Shift of a sequence
N −1 2π N −1 2π 2π 2π
−j −j ( n−m ) − j −j
∑ x [ n − m] e = ∑ x [ n − m ] e = X [ k ] e = X [ k ]WNkm
kn km
N N N N
e
n =0 n=0

⇒ x [ n − m ] ←⎯⎯DFS
→ X [ k ]WNkm

– Duality
x [ n ]W − nA ←⎯⎯
N
DFS
→ X [ k − A ]

1 N −1  N −1
x [ n ] = ∑ X [ k ]wN ⇒ Nx [ − n ] = ∑ X [ k ]WNkn
− kn

N k =0 k =0
N −1
⇒ Nx [ − k ] = ∑ x [ n ]WNkn
k =0

If x [ n ] ←⎯⎯
DFS
→ X [ k ] , X [ n ] ←⎯⎯
DFS
→ Nx [ − k ]
– Symmetry properties
x * [ n ] ←⎯⎯
DFS
→ X * [ − k ]
x * [ −n ] ←⎯⎯
DFS
→ X * [ k ]

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering
⇒ If x [ n ] is real, X [ k ] = X * [ − k ]

X [ k ] = X [ − k ]
– Periodic convolution
N −1 N −1
x3 [ n ] = ∑ x1 [ m ] x2 [ n − m ] = ∑ x2 [ m ] x1 [ n − m ]
m =0 m=0


N −1 N −1

X 3 [ k ] = ∑ ⎜ ∑ x1 [ m ] x2 [ n − m ] ⎟WNkn

n =0 ⎝ m =0 ⎠
N −1 N −1
= ∑ x1 [ m ] ∑ x2 [ n − m ]WNkn
m =0 n =0
N −1
= X 2 [ k ] ∑ x1 [ m ]WNkm = X 1 [ k ] X 2 [ k ]
m =0
N −1
⇒ ∑ x1 [ m ] x2 [ n − m ] ←⎯⎯
DFS
→ X 1 [ k ] X 2 [ k ]
m =0
ƒ Duality
1 N −1 
x1 [ n ] x2 [ n ] ←⎯⎯
→ ∑ X 1 [ m ] X 2 [ k − m ]
DFS

N m =0
ƒ Difference between aperiodic convolution and periodic convolution
• The sum is over an interval 0 ≤ m ≤ N − 1
• x 2 [ n − m ] = x 2 ⎡⎣ − ( m − n ) ⎤⎦

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering
Example Periodic convolution

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering
– Properties of DFS

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering
– Properties of DFS (cont.)

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

• Fourier transform of periodic signals

– A sequence should be absolutely summable to guarantee the uniform convergence of


its Fourier transform

– Periodic signals are not absolutely summable


– The F.T. of a periodic signal can be interpreted to be an impulse train in the frequency
domain with the impulse values proportional to the DFS coefficients for the sequence

– If x [ n ] is periodic with period N, the Fourier transform of x n [ ] is defined as

2π ∞
⎛ 2π k ⎞
x [ n ] ⇔ X ( e jω ) = ∑ 
X [ k ] δ ⎜ ω − ⎟
N k =−∞ ⎝ N ⎠

ƒ Although the F.T. of a periodic sequence does not converge in the normal sense,
the introduction of impulses enables to use the F. T.

ƒ Note: X e

( ) has the necessary periodicity with period 2π
2π ⎛ 2π k ⎞ jωn
X ( e jω )e jωn dω =
1 2π −ε 1 2π −ε
∫ ∫ ∑ X [ k ]δ ⎜ ω − ⎟ e dω ; 0 < ε < 2π / N
2π 0−ε 2π 0−ε N k ⎝ N ⎠
1 ∞  2π −ε ⎛ 2π k ⎞ jωn
= ∑ X [k ] ∫ δ ⎜ω − ⎟e dω
N k =−∞ 0 −ε
⎝ N ⎠

1 ∞ 
= ∑ X [ k ] e N = x [ n ]
j kn
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
N k =−∞
Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

Example: Fourier transform of a periodic impulse train



p [ n ] = ∑ δ [ n − mN ] ⇒ P [ k ] = 1, ∀ k
m = −∞

2π ∞
⎡ 2π k ⎤
⇒ P e jω =( ) ∑ δ
N k = −∞ ⎢⎣
ω −
N ⎥⎦
– For a finite-length sequence x [ n ] , ( i.e ., x [ n ] = 0 for n < 0 and n ≥ N )
x [ n ] = x [ n ] ∗ p [ n ]
∞ ∞ ∞
= ∑ ∑ δ [A − mN ]x [ n − A] = ∑ x [ n − mN ]
m =−∞ A =−∞ m =−∞

X ( e jω ) = X ( e jω ) P ( e jω )
2π ∞
⎛ 2π k ⎞
= X (e ) jω
∑ δ ⎜⎝ ω − ⎟
N k =−∞ N ⎠
2π ∞
⎛ j 2Nπ k ⎞ ⎛ 2π k ⎞
= ∑ ⎜ ⎟ ⎜⎝
X e δ ω −
N ⎠

N k =−∞ ⎝ ⎠
⎛ j 2Nπ k ⎞ N −1 2π
⇒ X [ k ] = X ( e jω )
−j
⎟ ∑ [ ]
k
2π = X ⎜e = 
x n e N
ω=
N
k
⎝ ⎠ n =0
Thus, X [ k ] is obtained by sampling the Fourier transform of the finite sequence x [ n ]
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 6. Discrete Fourier transform
School of Electrical Engineering

Example: Relationship between the DFS coefficients and the FT of one period
sin ( 5ω / 2 ) − j 2ω
( )
4
⎧1; 0 ≤ n ≤ 4
x [n ] = ⎨ ⇒ X e

= ∑ e − jω n
=
sin (ω / 2 )
e
⎩ 0; otherwise n=0

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 7. Fourier analysis of signals using DFT
School of Electrical Engineering

Fourier Analysis of Signals Using DFT


• Discrete Fourier transform (DFT) can analyze the frequency content of continuous-time
signal

1 ∞ ⎛ ω 2π k ⎞
X (e ) = ∑ X c ⎜ +


T k =−∞ ⎝ T T ⎠

V ( e jω ) = X ( e jθ )W ( e j (ω −θ ) ) dθ
1 π

2π ∫π

v [ n] = x [ n] w[ n ]
N −1 2π kn
= V ( e jω )
−j
V [ k ] = ∑ v [ n ]e N
2π k ; ω = ΩT
ω=
n=0 N

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 7. Fourier analysis of signals using DFT
School of Electrical Engineering
– Example

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 7. Fourier analysis of signals using DFT
School of Electrical Engineering

– Length of the DFT


N −1 2π kn
= V ( e jω )
−j
V [ k ] = ∑ v [ n] e N
2π k ; ω = ΩT
ω=
n =0 N

2π 2π
ΔΩ ≤ ⇒N≥
NT ΔΩT

ƒ Example: T=1/5000 and 10Hz resolution


2π 5000
10 ⋅ 2π ≤ ⇒N≥ = 500 ⇒ N = 512 = 29
NT T =1/ 5000 10
– Relationship between DFT values

N = 512; T = 1/ 5000
If V [11] = 2000 (1 + j ) ;

V [ k ] = V * [ ((− k )) N ] ⇒ V [ N − k ] = V * [ k ]
⇒ V [512 − 11] = V [501] = V * [11] = 2000 (1 − j )
Ω11 = 2π ⋅ 11 ⋅ 5000 / 512 = 2π ⋅ 107.4
⇒ X c ( Ω11 ) ≈ T ⋅ V [11] = 0.4 (1 + j )

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 7. Fourier analysis of signals using DFT
School of Electrical Engineering

• DFT analysis of sinusoidal signals

– Windowing and spectral sampling have an important effect on the analysis of


sinusoidal signals using the DFT

– Effect of windowing
sc (t ) = A0 cos(Ω 0t + θ 0 ) + A1 cos(Ω1t + θ1 )
⇒ x [ n ] = A0 cos(ω0 n + θ 0 ) + A1 cos(ω1n + θ1 )
ƒ After the windowing
v [ n ] = x [ n] w[ n]
= A0 w[ n ] cos(ω0 n + θ 0 ) + A1w[ n ] cos(ω1n + θ1 )

=
A0
2
( )
w[ n ] e jω0n+θ0 + w[ n ] e − j (ω0n+θ0 ) + 1 ( w[ n ] e jω1n+θ1 + w[ n ] e − j (ω1n+θ1 )
A
2

V ( e jω ) =
A0 ⎡
2 ⎣
( ) ( ) A
( )
W e ( 0 ) e jθ0 + W e ( 0 ) e − jθ0 ⎤ + 1 ⎡W e ( 1 ) e jθ1 + W e ( 1 ) e − jθ1 ⎤
j ω −ω j ω +ω
⎦ 2⎣
j ω −ω j ω +ω
⎦( )
it can be suffered from reduced resolution and leakage of spectrum

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 7. Fourier analysis of signals using DFT
School of Electrical Engineering

Example Leakage due to the use of a rectangular window


ω0 =
6

ω1 =
3

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 7. Fourier analysis of signals using DFT
School of Electrical Engineering

ƒ The resolution is primarily affected by the width of the main lobe of W e( )


ƒ The degree of leakage depends on the relative amplitude of the main and side
lobe of W e jω ( )
ƒ These are associated with the window length L and the shape of the window

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 7. Fourier analysis of signals using DFT
School of Electrical Engineering

Example: Kaiser window

⎧ ⎡ n −α ⎤ ⎤
2

⎪ I0 ⎢β 1 − ⎡
⎢ ⎥ ⎥
⎪ ⎢ ⎣ α ⎦ ⎥⎦ L −1
w[n] = ⎨ ⎣ , 0 ≤ n ≤ L − 1, α =
⎪ I0 ( β ) 2

⎩ 0 , otherwise

A sl

24π ( Asl + 12 )
L +1
155 Δ ml
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 7. Fourier analysis of signals using DFT
School of Electrical Engineering

– Effect of spectral sampling

V [ k ] = V ( e jω ) 2π k ; Ω k = 2π k / ( NT )
ω=
N

ƒ Example N = 64
2π n 4π n
v [ n ] = cos + 0.75 cos ;
14 15
0 ≤ n ≤ 63

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 7. Fourier analysis of signals using DFT
School of Electrical Engineering

– Spectral sampling with frequencies matching DFT frequencies


2π n 2π n
ƒ Example v [ n ] = cos + 0.75 cos ; 0 ≤ n ≤ 63
16 8

N = 64

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 7. Fourier analysis of signals using DFT
School of Electrical Engineering

– DFT analysis by Kaiser window


2π n 4π n
ƒ Example v [ n ] = wK [ n ] cos + 0.75 wK [ n ] cos ; 0 ≤ n ≤ 63
14 15

L = 64 L = 32

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 7. Fourier analysis of signals using DFT
School of Electrical Engineering

– DFT analysis with 32-point Kaiser window and zero padding


2π n 4π n
ƒ Example v [ n ] = cos + 0.75 cos ; β = 5.48, L = 32 Kaiser window
14 15

N = 32 N = 128

N = 64 N = 1024
420.461: Digital Signal Processing copyright@Yong-Hwan Lee
Seoul National University 7. Fourier analysis of signals using DFT
School of Electrical Engineering

– DFT analysis with Kaiser window and zero padding


2π n 4π n
ƒ Example v [ n ] = cos + 0.75 cos ; β = 5.48 Kaiser window
14 15

N = 1024, L = 32 N = 1024, L = 54

N = 1024, L = 42 N = 1024, L = 64

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 7. Fourier analysis of signals using DFT
School of Electrical Engineering

• Fourier analysis of stationary random signals: Periodogram

– The sample mean and sample variance respectively defined by


2
1 L −1 1 L −1
mˆ X = ∑ x [ n ]; σˆ X = ∑ ( x [ n ] − mˆ X )
2

L n =0 L n =0
are unbiased and asymptotically unbiased estimators, respectively

– Periodogram analysis: estimation of the power spectrum

⎛ω ⎞ L −1
V (e ) = ∑ x [ n]w[ n] e
1
PXX (ω ) = PSS ⎜ ⎟ jω − jω n
T ⎝T ⎠ n =0
ƒ Periodogram is the F. T. of aperiodic correlation of windowed data sequence
L −1
V ( e jω ) =
1 1
I (ω ) = ∑ cvv [ m ]e − jωm
2

LU LU m =− L +1
L −1
cvv [ m ] = ∑ x [ n ]w[ n ] x [ n + m ] w [ n + m ]
n =0

ƒ Modified periodogram: w [ n ] is not a rectangular window

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 7. Fourier analysis of signals using DFT
School of Electrical Engineering

– Periodogram can be calculated by means of the DFT


1
I ( ωk ) = V [k ]
2

LU
– Properties of the periodogram:
L −1
E { I (ω )} = ∑ E {c [ m]}e
1 − jω m
vv
LU m =− L +1
L −1
E {cvv [ m ]} = ∑ w[ n ] w[ n + m ] E { x [ n ] x [ n + m ]}
n =0
L −1
= ∑ w[ n ] w[ n + m ]φxx [ m ]
n =0

= cww [ m ]φxx [ m]
L −1
φxx [ m ] = E { x [ n ] x [ n + m ]} ; cww [ m ] = ∑ w[ n ] w[ n + m ]
n =0

E { I (ω )} = ( ) dθ ; CWW ( e jω ) = W ( e jω )
1 π
PXX (θ ) CWW e
j (ω −θ )
2

LU ∫π

ƒ To make the periodogram unbiased,


L −1
1 L −1 2
∫ π W (e )
1 π 1
∑ w [ n] = 1 ⇒ U = ∑ w [ n]
2

dω = 2

2π LU − LU n =0 L n =0

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 7. Fourier analysis of signals using DFT
School of Electrical Engineering

– As the window size increases, the peridogram becomes a consistent estimate


ƒ Example: white noise generation with rectangular windowing
L −1 2
1 1
I [ k ] = I ( ωk ) = V [ k ] = ∑ w[ n] x [ n] e
2 − j 2π kn / N

L L m =− L +1

L = 16 LL==256
256

L = 64 varL{=I 1024
(ωk )} 2
PXX (ω )

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 7. Fourier analysis of signals using DFT
School of Electrical Engineering

– Edge effect due to covolution of finite sequences


L −1
cvv [ m ] = ∑ w[ n ] w[ n + m ] x [ n ] x [ n + m ]
n =0

ƒ As m becomes close to L, the


calculation becomes inconsistent

ƒ This problem can be alleviated by


averaging multiple independent

periodogram estimates

xr [ n ] = w[ n ] x [ rR + n ]; 0 ≤ n ≤ Q − 1

1 K −1 1 L −1
I (ω ) = ∑ ∑ X r ( e jω )
2

K r =0 LU n =0

420.461: Digital Signal Processing copyright@Yong-Hwan Lee


Seoul National University 7. Fourier analysis of signals using DFT
School of Electrical Engineering

– Example ( )
x [ n ] = 0.5cos ( 2π n / 21 + θ ) + e [ n ]; e [ n ] ∼ U − 3, 3 ⇒ σ e2 = 1
A2π
PXX (ω ) = ⎡⎣δ (ω − ω0 ) + δ (ω + ω0 ) ⎤⎦ + σ e2
2
Q = 1024; U = 1

K = 31, L = 64

K = 1, L = 1024 K = 127, L = 16

420.461: Digital Signal Processing copyright@Yong-Hwan Lee

You might also like