0% found this document useful (0 votes)
36 views25 pages

Lecture Digital Filters An Introduction

Uploaded by

Nabeel Hashim
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)
36 views25 pages

Lecture Digital Filters An Introduction

Uploaded by

Nabeel Hashim
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/ 25

Be Advised!

This part of the course will be covered from

Digital Signal Processing: A Practical Approach


by Emmanuel Ifeachor
Barrier Jervis
Filter
 A filter is essentially a system or network that
selectively changes the wave shape, amplitude-
frequency and/or phase-frequency characteristics of
a signal in a desired manner

 In general, filtering is the processing of a time-


domain signal, resulting in some change in the
spectral content of the signal
Filter bands
 Pass band
 Stop band

 Transition band

1+p

1-p

Pass band
deviation
s

fp fs
Filter Types
 Low Pass

 High Pass

 Band Pass

 Band Stop
Low Pass Filter

B
|H(f)|

f
-fc fc
(f)

Passes frequencies smaller than a cut-off


High Pass Filter

|H(f)|

f
fc

(f)

Passes frequencies higher than a cut-off


Band Pass Filter

|H(f)| B

f
-fH -fL (f) fL fH

Passes frequencies between two cut-offs


Band Stop Filter
|H(w)|

f
-fH -fL fL fH

(w)

Passes frequencies other than those between two cut-offs


Digital Filters
 Where an analog filter operates on a continuous
signal, a digital filter processes a sequence of
discrete sample values

 A digital filter can be a software program, a


programmable hardware processor or a dedicated
integrated circuit
Digital Filters
 How can Digital Filters provide frequency selectivity?

 The digital signal we get, still has a frequency


definition into it
 In terms of sampling instant

 And a digital system has a frequency response

 So, the output of that system with the input gives us


the required frequency selectivity
Digital Filters vs Analog Filters
 Digital filters can have a linear phase response in
the band of interest as compared to analog filters,
which have non-linear phase response

 The frequency response of a Digital filter can be


easily adjusted (since it is a program), however, this
is not possible for an Analog filter (create a new
circuit)
 The performance of Digital filters is not affected by
environmental effects (heat), while it does affect
the performance of Analog filters
 Re-calibration

 Both filtered and un-filtered data can be stored

 Digital filters can work for low frequency signals


unlike Analog filters
 Digital filters are affected by the finite word length
effects

 The Processing capability of filter depends on the


speed of the Processor running the program
Types of Digital filters
 Like any LTI system, a digital filter can be
characterized by its Impulse Response (I.R.)

 Based on the IR, digital filters can be classified as


 Finite Impulse Response (FIR) filters
 Impulse Response becomes zero with time
 Time limited

 Infinite Impulse Response (IIR) filters


 Impulse Response does not become zero with time
 Time un-limited
Comparison between FIR & IIR

Finite Impulse Response Infinite Impulse Response

 Implemented non-  Implement recursively


recursively  With Feedback
 No Feedback

 Always stable  Stability not guaranteed

 Simple to implement  Difficult to implement

 Linear phase response in  Non-linear phase response


pass-band in pass-band
Finite Impulse Response Infinite Impulse Response

 Requires more filter co-effs  Requires less filter co-effs for


for a specified filter than IIR a specified filter than FIR
 More memory  Less memory

 More processing power  Less processing power

 Does not have an analog  Analog filters can be


counterpart converted into IIR filters

 Less susceptible to the effect  More susceptible to the


of using a limited number of effect of using a limited
bits to implement filters such number of bits to implement
as round off noise, and filters such as round off
coefficients quantization noise, and coefficients
error quantization error
Finite Impulse Response filters

Use FIR if the number of filter coefficients


is not too large and in particular if little or
no phase distortion is desired

Infinite Impulse Response filters

Use IIR when there are requirements such


as sharp cut off and high throughput
FIR Filters
 No feedback
 Output is function of the present input and the
past inputs
 Output does not depend on the previous outputs

yn b0 xn b1xn 1 ....  bN xn  N  (1)


L
yn  bi xn  i 
i0

 L+1 is said to be the filter length


IIR Filters
 Requires feedback
 Output is the function of the present input, the
past inputs and also the past outputs

yn b0 xn b1xn 1 ....  bL xn  L


 a1 yn 1 a2 yn  2 ....  aM yn  M  (2)
L M
yn  bi xn  i   a j yn  j 
i0 j 1
Digital Filter Design

1. Specification of the filter requirements

2. Calculation of suitable filter co-efficients

3. Representation of the filter by a suitable structure


(realization)

4. Analysis of the effects of the finite word-length on


filter performance

5. Implementation of filter in software/hardware


Specification of filter requirements

 Signal Characteristics

 Sampling Frequency Fs

 Highest Frequency of interest


 Characteristics of the filter (Frequency domain)
 Magnitude Response
  
Pass band deviation  p
 Stop band deviation  s 
 Pass band edge frequency f  
p
 Stop band edge frequency f s 

1+p

1-p

s

fp fs
 Stop band attenuation

As  20 log10  s 

 Pass band ripple

A  20 log
p 10
1 
p

 Transition width

 Phase Response
 Strictly Linear
 Which implementation would you choose?

 Loosely Linear
A filter has to be designed to meet the following specifications

Pass band : 0.18 – 0.33


Transition width : 0.04
Stop band deviation : 0.001
Pass band deviation : 0.05
Sampling frequency : 10 KHz
Phase requirements : Linear in pass band

The cutoff frequencies are given in normalized form, i.e. f/Fs, so the un-
normalized frequencies are:

Pass band = 0.18x10e3 to 0.33x10e3 i.e. from 1800 to 3300 Hz

Stop band 1 = 0 to 1800 - 400 =0 to 1400 Hz


Stop band 2 = 3300 + 400 to 5000 = 3700 to 5000 Hz

Pass band ripple = 20log10(1+0.05) = 0.42 dB

Stop band attenuation = -20log10(0.001) = 60 dB


Magnitude Response (dB) Frequency (kHz): 3.292847
Magnitude (dB): 0.0003152953
0

I’ve implemented the specification as an FIR filter -10

-20

-30

Magnitude (dB)
-40

-50 Frequency (kHz): 1.400146


Magnitude (dB): -60.00556
-60

-70

-80

-90
0 0.5 1 1.5 2 2.5 3 3.5 4 4.5
Frequency (kHz)

Phase Response

10

-10
Phase (radians)

-20

-30

-40

-50

0 0.5 1 1.5 2 2.5 3 3.5 4 4.5


Frequency (kHz)

You might also like