0% found this document useful (0 votes)
12 views14 pages

Fir-Filter-Design (1) - 1-14

This document provides an overview of FIR filter design, including advantages and disadvantages, various design techniques using different window functions, and the mathematical foundations of FIR filters. It discusses the properties of linear phase FIR filters, including symmetric and antisymmetric responses, and the implications of causality on filter design. Additionally, it covers the frequency response characteristics and the relationship between impulse response and filter coefficients.

Uploaded by

shashiboorla
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
12 views14 pages

Fir-Filter-Design (1) - 1-14

This document provides an overview of FIR filter design, including advantages and disadvantages, various design techniques using different window functions, and the mathematical foundations of FIR filters. It discusses the properties of linear phase FIR filters, including symmetric and antisymmetric responses, and the implications of causality on filter design. Additionally, it covers the frequency response characteristics and the relationship between impulse response and filter coefficients.

Uploaded by

shashiboorla
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 14

UNIT - 2: FIR Filter Design

FIR Filter Design:[1, 2, 3, 4]

Slides are prepared to use in class room purpose, may be used as a


reference material
All the slides are prepared based on the reference material
Most of the figures/content used in this material are redrawn, some
of the figures/pictures are downloaded from the Internet.
This material is not for commercial purpose.
Unit 2: FIR Filter Design:

PART-B-Unit 2: FIR Filter Design:

Introduction to FIR Filters


Design of FIR Filters using
1 Rectangular window
2 Hamming window
3 Hanning window
4 Bartlet window
5 Kaiser window
Design of FIR Filter using frequency sampling technique.
FIR Filter Design Introduction

Advantages of the FIR digital filter


Relatively easy to design and computationally more efficient.
FIR filters are implemented in hardware or software.
The phase response is linear. Linear phase property implies that the phase is a linear
function of the frequency. FIR filter output is delayed by the same amount of time for all
frequencies, thereby eliminating the phase distortion (Group delay).
FIR filters are always stable i.e. for a finite input, the output is always finite.
In linear phase, for the filter of length N the number of operations are of the order of N/2.
Disadvantages of the FIR digital filter (compared to IIR filters)
They require more memory and/or calculation to achieve a given filter response
characteristic. Also, certain responses are not practical to implement with FIR filters.
For a desired frequency response, with tight constraints on the passband, transition band
and the stopband, a FIR filter may have large number of coefficients, thereby have more
arithmetic operations and hardware components.

An LTI system is causal iff


Input/output relationship: y [n] depends only on current and past input signal values.
Impulse response: h[n] = 0 for n < 0
System function: number of finite zeros ≤ number of finite poles.
FIR Filter Design Introduction

An ideal lowpass filter is given by


H d ( e jω )
 1
1 |ω| ≤ ωc
H(ω) =
0 ωc < |ω| ≤ π

−π −ωc 0 ωc π ω
The impulse response is given by
Figure 1: Ideal low pass filter
Zωc ( ωc
1 π
n=0
h(n) = H(ω)e jωn dω = ωc sin(ωc n)
2π π ωc n
n 6= 0
−ωc

Paley-Wiener Theorem:
If h(n) has finite energy and h(n) = 0 for n < 0
then

| ln |H(ω)||dω < ∞ Figure 2: Unit sample response
−π

H(ω) can be zero at some frequencies. but it cannot be zero over any finite of
frequencies, since the integral then becomes infinite.
H(ω) cannot be exactly zero over any band of frequencies. (Except in the trivial case where h[n]
= 0.) Furthermore, |H(ω)| cannot be flat (constant) over any finite band.
FIR Filter Design Introduction

Magnitude Characteristic of FIR filter


The magnitude response can be expressed as

1 − δ1 ≤ |H(ω)|1 + δ1 for 0 ≤ ω ≤ ωp
Magnitude =
0 ≤ |H(ω)δ2 for ωs ≤ ω ≤ π

Approximate formula for order N is


δ1 ‐‐Passband ripple
−10log10 (δ1 δ2 ) − 15 δ2 ‐‐ Stopband ripple
N= ωp‐‐Passband edge frequency
14∆f ωs‐‐Stopband edge frequency
ω −ω
where ∆f = s2π p = fs − fp
Approximate formula for order N is

N=k
ωs − ωp
The width of the main lobe is
N = k 2π
M
Figure 3: Magnitude Specification of FIR
FIR Filter Design Introduction

Ideal filters are noncausal, hence physically unrealizable for real time signal processing
applications.
Causality implies that the frequency response characteristic H(ω) of the filter cannot be
zero, except at finite set of points in the frequency range. And also H(ω) cannot have an
infinitely sharp cutoff from passband to stopband, that is H(ω) cannot drop from unity to
zero abruptly.
It is not necessary to insist that the magnitude be constant in the entire passband of the
filter. A small amount of ripple in the passband is usually tolerable.
The filter response may not be zero in the stopband, it may have small nonzero value or
ripple.
The transition of the frequency response from passband to stopband defines transition
band.
The passband is usually called bandwidth of the filter.
The width of transition band is ωs − ωp where ωp defines passband edge frequency and ωs
defines stopband edge frequency.
The magnitude of passband ripple is varies between the limits 1 ± δ1 where δ1 is the ripple
in the passband
The ripple in the stopand of the filter is denoted as δ2
FIR Filter Design FIR Filter Design

FIR Filter Design


FIR Filter Design FIR Filter Design

An FIR system does not have feedback. Hence y (n − k) term is absent in the system. FIR
output is expressed as
M
X
y (n) = bk x(n − k)
k=0

If there are M coefficients then


M−1
X
y (n) = bk x(n − k)
k=0

The coefficients are related to unit sample response as



bn for 0≤n ≤M −1
h(n) =
0 otherwise

Expanding the summation


y (n) = b0 x(n) + b1 x(n − 1) + b2 x(n − 2) + . . . b(M−1) x(n − M + 1)

Since h(n) = bn then y(n) is


M−1
X
y (n) = h(k)x(n − k)
k=0
FIR Filter Design Symmetric and Antisymmetric FIR Filters

Symmetric and Antisymmetric FIR Filters Linear Phase


FIR structure

Linear phase is a property of a filter, where the phase response of the filter is a linear
function of frequency. The result is that all frequency components of the input signal are
shifted in time (usually delayed) by the same constant amount, which is referred to as the
phase delay. And consequently, there is no phase distortion due to the time delay of
frequencies relative to one another.
Linear-phase filters have a symmetric impulse response.
The FIR filter has linear phase if its unit sample response satisfies the following condition:

h(n) = h(M − 1 − n) n = 0, 1, 2, . . . , N − 1

The Z transform of the unit sample response is given as

M−1
X
H(z) = h(n)z −n
n=0
FIR Filter Design Symmetric and Antisymmetric FIR Filters

Symmetry: h(n)=h(M-1-n) Odd M Symmetry: h(n)=h(M-1-n) Even M


h[n] h[n]

-2 -1 0 1 2 3 4

-2 -1 0 1 2 3 4
0 1 2 3 4 5 6 7 8 n 0 1 2 3 4 5 6 7 8 n

Center of Symmetry Center of Symmetry

Antisymmetry: h(n)=-h(M-1-n) Odd M Antisymmetry: h(n)=-h(M-1-n) Even M


h[n] h[n]
-2 -1 0 1 2 3 4

-2 -1 0 1 2 3 4
0 1 2 3 4 5 6 7 8 n 0 1 2 3 4 5 6 7 8 n

Center of Symmetry
Center of Symmetry

Figure 4: Symmetric and antisymmetric responses

The unit sample response of FIR filter is symmetric if h(n) = h(M − 1 − n)


The unit sample response of FIR filter is antisymmetric if h(n) = −h(M − 1 − n)
FIR Filter Design Symmetric and Antisymmetric FIR Filters

Frequency response of Linear Phase FIR Filter: Symmetric with M=odd


M−1
X
H(z) = h(n)z −n Symmetry: h(n)=h(M-1-n) Odd M Sy
h[n] h
n=0

-2 -1 0 1 2 3 4

-2 -1 0 1 2 3 4
Symmetric impulse response with M=odd Then
h(n) = h(M − 1 − n) and (z = e jω )

    (M−3)/2 0 1 2 3 4 5 6 7 8 n
M −1 M−1 X h i
H(z) = h z 2 + h(n) z −n + z −(M−1−n)
2 n=0 Center of Symmetry

M−3 Antisymmetry: h(n)=-h(M-1-n) Odd M An


    2
M −1 −jω M−1 X h h[n]
i h[
H(e jω ) = h e 2 + h(n) e −jωn + e −jω(M−1−n)
2 n=0

-2 -1 0 1 2 3 4

-2 -1 0 1 2 3 4
M−1 M−1 M−1 M−1
e −jωn = e −jωn e jω( 2
)
e −jω( 2
)
= e jω( 2
−n)
.e −jω( 2
)

−jω( M−1 −jω( M−1 M−1 M−1


e −jω(M−1−n) = e −jω(M−1) e jωn = e 2
)
.e 2
)
e jωn = 0e −jω( ) −jω(
1 2 3 24 5.e6 7 8 2n
−n)

    M−1   
−jω M−1 jω −n −jω M−1 −n
e −jωn + e −jω(M−1−n) = e 2 e 2 +e 2 Center of Symmetry

   
−jω M−1 M −1
= e 2 2cosω −n
2
FIR Filter Design Symmetric and Antisymmetric FIR Filters

M−3
2
M − 1 −jω( M−1 ) X
H(e jω
) = h( )e 2 + h(n)[e −jωn + e −jω(M−1−n) ]
2 n=0
M−3
    2    
M −1 −jω M−1 X M −1
−jω M−1
= h e 2 + h(n)e −n2 2cosω
2 n=0
2
 M−3

    2  
−jω M−1 M − 1 X M − 1
= e 2
h +2 h(n)cos ω −n 
 
2 n=0
2

H(ω) = |H(ω)|e j∠H(ω)

M−3
  2  
M −1 X M −1
|H(ω)| = h +2 h(n)cos ω −n
2 n=0
2

  
 −ω M−1 for |H(ω)| > 0
2
∠H(ω) =  
 −ω M−1 + π for |H(ω)| < 0
2
FIR Filter Design Symmetric and Antisymmetric FIR Filters

Frequency response of Linear Phase FIR Filter: Symmetric with M=Even


 
M −1
  2  
−jω M−1  X M −1
H(ω) = e 2
2 h(n)cos ω −n 

n=0
2
Symmetry: h(n)=h(M-1-n) Odd M Symmetry: h(n)=h(M-1-n) Even M
h[n] h[n]

-2 -1 0 1 2 3 4

-2 -1 0 1 2 3 4
H(ω) = |H(ω)|e j∠H(ω)

M −1
2  0 1 2 3 4 5
6 7 8 n 0 1 2 3 4 5 6 7 8 n
X M −1
|H(ω)| = 2 h(n)cos ω −n
n=0
2
Center of Symmetry Center of Symmetry
  
 −ω M−1 for |H(ω)| > 0
Antisymmetry: h(n)=-h(M-1-n) Odd M Antisymmetry: h(n)=-h(M-1-n) Even M
2
∠H(ω) =   h[n] h[n]
 −ω M−1 + π for |H(ω)| < 0
2
-2 -1 0 1 2 3 4

-2 -1 0 1 2 3 4
0 1 2 3 4 5 6 7 8 n 0 1 2 3 4 5 6 7 8 n

Center of Symmetry
Center of Symmetry

You might also like