FIR Filter Design: Part II

Similar documents
Frequency Response of FIR Filters

FIR Filter Design: Part I

Discrete-Time Systems, LTI Systems, and Discrete-Time Convolution

The z-transform. 7.1 Introduction. 7.2 The z-transform Derivation of the z-transform: x[n] = z n LTI system, h[n] z = re j

The Discrete-Time Fourier Transform (DTFT)

Ch3 Discrete Time Fourier Transform

Chapter 7: The z-transform. Chih-Wei Liu

Introduction to Signals and Systems, Part V: Lecture Summary

EE Midterm Test 1 - Solutions

Generalizing the DTFT. The z Transform. Complex Exponential Excitation. The Transfer Function. Systems Described by Difference Equations

Frequency Domain Filtering

MAXIMALLY FLAT FIR FILTERS

COMM 602: Digital Signal Processing

Z - Transform. It offers the techniques for digital filter design and frequency analysis of digital signals.

Linear time invariant systems

Filter banks. Separately, the lowpass and highpass filters are not invertible. removes the highest frequency 1/ 2and

Exam. Notes: A single A4 sheet of paper (double sided; hand-written or computer typed)

FIR Filters. Lecture #7 Chapter 5. BME 310 Biomedical Computing - J.Schesser

2D DSP Basics: 2D Systems

ECE-S352 Introduction to Digital Signal Processing Lecture 3A Direct Solution of Difference Equations

Chapter 7 z-transform

ADVANCED DIGITAL SIGNAL PROCESSING

Lecture 3. Digital Signal Processing. Chapter 3. z-transforms. Mikael Swartling Nedelko Grbic Bengt Mandersson. rev. 2016

Fall 2011, EE123 Digital Signal Processing

ELEG3503 Introduction to Digital Signal Processing

Exponential Moving Average Pieter P

Finite-length Discrete Transforms. Chapter 5, Sections

Chapter 4. Fourier Series

x[0] x[1] x[2] Figure 2.1 Graphical representation of a discrete-time signal.

Chapter 9: Numerical Differentiation

A. Basics of Discrete Fourier Transform

Course Outline. Designing Control Systems. Proportional Controller. Amme 3500 : System Dynamics and Control. Root Locus. Dr. Stefan B.

MAS160: Signals, Systems & Information for Media Technology. Problem Set 5. DUE: November 3, (a) Plot of u[n] (b) Plot of x[n]=(0.

6.003 Homework #3 Solutions

Chapter 4 : Laplace Transform

Written exam Digital Signal Processing for BMT (8E070). Tuesday November 1, 2011, 09:00 12:00.

Signal Processing in Mechatronics. Lecture 3, Convolution, Fourier Series and Fourier Transform

3. Z Transform. Recall that the Fourier transform (FT) of a DT signal xn [ ] is ( ) [ ] = In order for the FT to exist in the finite magnitude sense,

Question1 Multiple choices (circle the most appropriate one):

Signals & Systems Chapter3

Module 18 Discrete Time Signals and Z-Transforms Objective: Introduction : Description: Discrete Time Signal representation

Chapter 8. DFT : The Discrete Fourier Transform

Lesson 10: Limits and Continuity

2.004 Dynamics and Control II Spring 2008

The z-transform can be used to obtain compact transform-domain representations of signals and systems. It

FFTs in Graphics and Vision. The Fast Fourier Transform

6.003 Homework #12 Solutions

6.3 Testing Series With Positive Terms

Infinite Sequences and Series

UNIVERSITY OF CALIFORNIA - SANTA CRUZ DEPARTMENT OF PHYSICS PHYS 116C. Problem Set 4. Benjamin Stahl. November 6, 2014

CS284A: Representations and Algorithms in Molecular Biology

Chapter 2. Simulation Techniques. References:

Assignment 2 Solutions SOLUTION. ϕ 1 Â = 3 ϕ 1 4i ϕ 2. The other case can be dealt with in a similar way. { ϕ 2 Â} χ = { 4i ϕ 1 3 ϕ 2 } χ.

Solutions. Number of Problems: 4. None. Use only the prepared sheets for your solutions. Additional paper is available from the supervisors.

The Random Walk For Dummies

The picture in figure 1.1 helps us to see that the area represents the distance traveled. Figure 1: Area represents distance travelled

6.003 Homework #12 Solutions

Olli Simula T / Chapter 1 3. Olli Simula T / Chapter 1 5

Definition of z-transform.

EE / EEE SAMPLE STUDY MATERIAL. GATE, IES & PSUs Signal System. Electrical Engineering. Postal Correspondence Course

EECE 301 Signals & Systems

Practical Spectral Anaysis (continue) (from Boaz Porat s book) Frequency Measurement

MASSACHUSETTS INSTITUTE OF TECHNOLOGY Department of Electrical Engineering and Computer Science. BACKGROUND EXAM September 30, 2004.

Review of Discrete-time Signals. ELEC 635 Prof. Siripong Potisuk

Time-Domain Representations of LTI Systems

Most text will write ordinary derivatives using either Leibniz notation 2 3. y + 5y= e and y y. xx tt t

Chapter 6 Infinite Series

Numerical Methods in Fourier Series Applications

Chapter 9 - CD companion 1. A Generic Implementation; The Common-Merge Amplifier. 1 τ is. ω ch. τ io

Ma 530 Introduction to Power Series

The Discrete Fourier Transform

ECEN 644 HOMEWORK #5 SOLUTION SET

Sequences A sequence of numbers is a function whose domain is the positive integers. We can see that the sequence

A sequence of numbers is a function whose domain is the positive integers. We can see that the sequence

Run-length & Entropy Coding. Redundancy Removal. Sampling. Quantization. Perform inverse operations at the receiver EEE

Signals and Systems. Problem Set: From Continuous-Time to Discrete-Time

Section 11.8: Power Series

Injections, Surjections, and the Pigeonhole Principle

Chapter 2 Feedback Control Theory Continued

Kinetics of Complex Reactions

NICK DUFRESNE. 1 1 p(x). To determine some formulas for the generating function of the Schröder numbers, r(x) = a(x) =

The Z-Transform. (t-t 0 ) Figure 1: Simplified graph of an impulse function. For an impulse, it can be shown that (1)

PAijpam.eu ON DERIVATION OF RATIONAL SOLUTIONS OF BABBAGE S FUNCTIONAL EQUATION

Z ß cos x + si x R du We start with the substitutio u = si(x), so du = cos(x). The itegral becomes but +u we should chage the limits to go with the ew

6.867 Machine learning, lecture 7 (Jaakkola) 1

1. Nature of Impulse Response - Pole on Real Axis. z y(n) = r n. z r

Computing the output response of LTI Systems.

Chapter 3. z-transform

SEQUENCES AND SERIES

1the 1it is said to be overdamped. When 1, the roots of

62. Power series Definition 16. (Power series) Given a sequence {c n }, the series. c n x n = c 0 + c 1 x + c 2 x 2 + c 3 x 3 +

subcaptionfont+=small,labelformat=parens,labelsep=space,skip=6pt,list=0,hypcap=0 subcaption ALGEBRAIC COMBINATORICS LECTURE 8 TUESDAY, 2/16/2016

. (24) If we consider the geometry of Figure 13 the signal returned from the n th scatterer located at x, y is

It is always the case that unions, intersections, complements, and set differences are preserved by the inverse image of a function.

MA131 - Analysis 1. Workbook 2 Sequences I

MATH 31B: MIDTERM 2 REVIEW

On a Smarandache problem concerning the prime gaps

TMA4205 Numerical Linear Algebra. The Poisson problem in R 2 : diagonalization methods

PROBLEM SET 5 SOLUTIONS 126 = , 37 = , 15 = , 7 = 7 1.

1.3 Convergence Theorems of Fourier Series. k k k k. N N k 1. With this in mind, we state (without proof) the convergence of Fourier series.

Transcription:

EEL335: Discrete-Time Sigals ad Systems. Itroductio I this set of otes, we cosider how we might go about desigig FIR filters with arbitrary frequecy resposes, through compositio of multiple sigle-peak geeral filters. 2. Geeral FIR filter A. Itroductio Cosider the frequecy respose H g ( e j plotted i Figure below. This filter passes through all ormalized frequecies without modificatio, but amplifies ( a > or atteuates ( a < frequecies i the rage [ c, c2 ]; also, there is a fiite-width trasitio regio of width from H g ( e j = to H g ( e j = a. As we will show below, assumig that we kow the impulse respose h g [ ] of this filter i terms of a, c, ad, we ca easily costruct filters that have more complex frequecy resposes. c2 H g ( e j a π c2 c c c2 π Figure B. Derivatio of ifiite impulse respose Below, we will use the iverse DTFT to determie the time-domai impulse respose h [ ] of the above filter, assumig o delay. For this filter, the iverse DTFT is give by, h g [ ] h g [ ] = = π ----- H 2π g ( e j e j d π ( c2 + ----- e 2π j c2 a d + ----- ----------- ( + π 2π c2 + a e j d + ( + c2 ----- c 2π aej ( d c a + ----- ----------- ( + c2 2π c + a e j d + c ( c ----- e 2π j d + ( c c a ----- ----------- 2π ( + a ejd ( c + ----- 2π aej d + c c c2 ( (2 ----- 2π ( c2 + c2 a ----------- ( c2 + a e j π d + ----- e 2π j d ( + c2 - -

EEL335: Discrete-Time Sigals ad Systems The itegral i equatio (2 is tedious to compute ad simplify; therefore, we solve the itegratio usig Mathematica (see fir_filter_desig_part2.b ad arrive at the followig expressio for h [ ]: h g [ ] = ( a cos( ( c + cos( ( c2 + cos( c cos( c2 si( π -------------------------------------------------------------------------------------------------------------------------------------------------, 2 + ------------------ π π < <. (3 Note that equatio (3 ca be further simplified, sice, si( π ------------------ = δ[ ] π for iteger. Therefore, (4 cos( ( c + cos( ( c2 + cos( c cos( c2 h g [ ] = ( a -------------------------------------------------------------------------------------------------------------------------------------------------,. (5 2 + δ[ ] < < π Note that, although h g [ ] is ifiite i legth, both forwards ad backwards i time, the impulse respose does decay to zero as. Figure 2 below, for example, plots h g [ ], 5 5, for c =, c2 = 3 2, = ad a = 2. 2.5 h g [ ].2..5 H g ( e j -3-2 - 2 3 + -------- 2π -. -.2-4 -2 2 4 Figure 2 C. Approximatig of ifiite impulse respose with a causal FIR filter Now, we will try to approximate the ifiite impulse respose i equatio (5 with a causal FIR filter usig the same procedure as we have used before: First, we will retai values for h g [ ] oly for a limited rage of, max max (6 sice values of h g [ ] approach zero as. Let us deote this fiite impulse respose as h g [ ], such that, h g [ ] = h g [ ] max max elsewhere (7 Secod, we will shift h g [ ] to be causal; let us deote the resultig impulse respose as ĥ g [ ] such that, ĥ g [ ] = h g [ max ]. (8-2 -

EEL335: Discrete-Time Sigals ad Systems Note that this shift will ot chage the steady-state frequecy respose of the resultig system, except to itroduce a delay at the output. Thus, the differece equatio correspodig to ĥ g [ ] ca be writte as: y [ ] = b k x [ k] where, 2 max k = (9 b k = ĥ g [ ] = h g [ max + k], k {,,, 2 max }. ( 3. Composite filter example A. Itroductio Give that we have computed the impulse respose h g [ ] for the filter i Figure, we are ow i positio to costruct filters with more complex frequecy resposes. Suppose, for example, we wated to costruct a filter with the idealized frequecy respose H c ( e j plotted i Figure 3 below for [, π]. (Sice He ( j is a eve fuctio, we do ot eed to explicitly plot it for = [ π,. We could, of course, derive the impulse respose h c [ ] of this filter by breakig up the iverse DTFT ito piecewise-cotiuous itegrals (as we did, for example, i equatio (2 above ad solvig the resultig expressio. Give that we have already compute h g [ ] [equatio (5], this difficult ad tedious procedure is ot ecessary, however. Istead, we ca treat H c ( e j as a composite filter cosistig of two differet H g ( e j filters coected i series. H c ( e j a 2 2 a 2 2 3 4 Figure 3 π Let, H ( e j = H g ( e j a a, c, c2 2, ad H 2 ( e j = H g ( e j a a2, c 3, c2 4, 2 where H g ( e j deotes the filter i Figure. The, we ca represet H c ( e j i Figure 3 as, H c ( e j = H ( e j H 2 ( e j or, i the time domai as, ( (2 (3-3 -

EEL335: Discrete-Time Sigals ad Systems h c [ ] ĥ [ ] * ĥ 2 [ ] (4 where ĥ [ ] ad ĥ 2 [ ] deote the causal FIR approximatios of the ifiite impulse respose of filters H ( e j ad H 2 ( e j, respectively. Below, we give oe example of such a composite filter. B. Example Let us assume that we wat to filter a piece of music, sampled at show i Figure 3 ad the followig umeric values: f s = 32 khz, with the composite filter a = ( 2 2 3.98. f = 375 Hz, f 2 = 5 Hz, (5 a 2 = ( 2 2.252, f 3 = 6 khz, f 4 = 5 khz, (6 ad f = Hz for both segmets. Note that the value of a correspods to +2dB (decibels, while the value of a correspods to -2dB. 2 First, we eed to covert the frequecy values above to ormalized frequecy values usig the coversio formula: = 2πf ------- f s (7 Applyig equatio (7, we get the followig values i terms of ormalized frequecy for f s = 32 = 3π 28, 2 = 3π 32, 3 = 3π 8, 4 = 5π 6 ad = 2 = 2π f f s = π 6. (8 The composite filter trasfer fuctio H c ( e j for the umeric values i (8 is plotted i Figure 4 below, i terms of ormal amplitude, ad decibel amplitude. khz: 4 3 2 H c ( e j 2log H c ( e j 5-5 -3-2 - 2 3 - Figure 4-3 -2-2 3 The FIR impulse-fuctio approximatios ĥ [ ] ad ĥ 2 [ ], correspodig to the filters defied by ( ad (2, respectively, are plotted i Figure 5 below for max = 5. Note that max was chose such that the h [ ] coefficiets ear = ad = 2 max are very close to zero i value. Now, we compute h c [ ], the composite-filter FIR impulse-fuctio approximatio, by covolvig ĥ [ ] ad ĥ 2 [ ] [see equatio (4 above]; h c [ ] is plotted i Figure 6. Observe from Figure 6, that h c [ ] is approximately twice as log as ĥ [ ]' ad ĥ 2 [ ] (2 vs. as should be expected from the covolutio operator. Also ote that may of the h c [ ] coefficiets are very close to zero i value; hece, we ca derive a shorter FIR filter by retaiig oly h c [ ] values i the rage [ 2, + 2 ], ad shiftig the resultig impulse respose to start at =. From Figure 6, we suggest that a value of 2 = 3 seems appropriate sice h c [ ] values for < 7 ad > 3 appear egligibly small. Let us deote the shorteed FIR filter as ĥ c [ ] : ĥ c [ ] = h c [ + 2 ], {,,, 2 2 }, 2 = 3. (9. For a amplitude A, the correspodig db value is give by 2log A. - 4 -

EEL335: Discrete-Time Sigals ad Systems.3.2 ĥ [ ]. -. -.2.3.2 2 4 6 8 ĥ 2 [ ]. -. -.2 2 4 6 8 Figure 5.4 h c [ ].2 -.2 -.4 5 5 2 Figure 6 This impulse respose ( ĥ c [ ] is plotted i Figure 7 below. Therefore, the differece equatio correspodig to this impulse fuctio is give by, 2 2 y [ ] = b k x [ k] k = (2 where, b k = ĥ c [ k], k {,,, 2 2 }, 2 = 3. (2 I Figure 8, we plot the magitude frequecy respose Ĥ c ( e j of system (2 give by, - 5 -

EEL335: Discrete-Time Sigals ad Systems.4 ĥ c [ ].2 -.2 -.4 2 3 4 5 6 Figure 7 6 Ĥ c ( e j = ĥ c [ ]e j = (22 both as a fuctio of ormalized frequecy ad real frequecy f. Note how closely we are able to approximate our desired frequecy respose (see Figure 4 with this FIR filter of legth 6; also ote that we ever had to compute h c [ ] usig the iverse DTFT, but rather computed it through time-domai covolutio of ĥ [ ] ad ĥ 2 [ ]. 4 3 Ĥ c ( e j 4 3 Ĥ c ( e j 2πf fs 2 2-3 -2-2 3-5 - -5 5 5 fkhz ( Figure 8 To see this filter i actio, we covolve ĥ with a sampled music file c [ ] x m [ ], ad compare the frequecy cotet of the origial music file x m [ ] ad the filtered music file y m [ ] where, y m [ ] = x m [ ] * ĥ c [ ]. (23 I Figure 9 below, we plot the spectrograms 2 of x m [ ] ad y m [ ], where we aalyze frequecy cotet i oe-secod log segmets with a 5% overlap. We also plot oe colum of both spectrograms (the magitude FFT for oe of the oe-secod segmets of x m [ ] ad y m [ ] i Figure below. Note, how the frequecy cotet i the rage f [ 375Hz, 5Hz] has bee amplified, while the frequecy cotet i the rage f [ 6kHz, 5kHz] has bee sigificatly atteuated, as we should expect from the frequecy respose of ĥ c [ ].. See the web page for this music file a 23.6 secod segmet of Key Roger s The Gambler, sampled at f s = 32 khz. 2. Recall from previous otes that the spectrogram gives us the magitude frequecy cotet of a sigal for short segmets of a log discrete-time sequece. - 6 -

EEL335: Discrete-Time Sigals ad Systems 5 Spectrogram ( x m [ ] 25 f ( Hz 75 5 25 5 5 2 t( sec 5 Spectrogram ( y m [ ] 25 f ( Hz 75 5 25 5 5 2 t( sec Figure 9-7 -

EEL335: Discrete-Time Sigals ad Systems 7 8 6 FFT ( x m [ ] 6 6 4 6 2 6 7 8 6 fkhz ( 5 5 FFT ( y m [ ] 6 6 4 6 2 6 fkhz ( 5 5 4. Coclusio Figure The Mathematica otebook fir_filter_desig_part2.b was used to geerate the detailed filterig example i this set of otes; that otebook also cotais a secod composite filter example for the same piece of music, where all the desig values (i.e., 2,, 3, 4 ad 2 are the same, except the values for a ad a 2 are reversed; that is, a = ( 2 2 ad a 2 = ( 2 2. (24 The filtered ad ufiltered music segmets referred to i these otes is available i mp3 ad wav formats o the course web site. - 8 -