ESE531 Spring University of Pennsylvania Department of Electrical and System Engineering Digital Signal Processing

Similar documents
ESE 531, Introduction to Digital Signal Processing Final Project

Spring 2018 EE 445S Real-Time Digital Signal Processing Laboratory Prof. Evans. Homework #1 Sinusoids, Transforms and Transfer Functions

The University of Texas at Austin Dept. of Electrical and Computer Engineering Final Exam

Adaptive Systems Homework Assignment 3

(i) Understanding the basic concepts of signal modeling, correlation, maximum likelihood estimation, least squares and iterative numerical methods

Performance Optimization in Wireless Channel Using Adaptive Fractional Space CMA

ECE438 - Laboratory 7a: Digital Filter Design (Week 1) By Prof. Charles Bouman and Prof. Mireille Boutin Fall 2015

(i) Understanding of the characteristics of linear-phase finite impulse response (FIR) filters

System Identification and CDMA Communication

(i) Understanding of the characteristics of linear-phase finite impulse response (FIR) filters

GEORGIA INSTITUTE OF TECHNOLOGY SCHOOL of ELECTRICAL and COMPUTER ENGINEERING. ECE 2025 Fall 1999 Lab #7: Frequency Response & Bandpass Filters

ECE 5650/4650 Computer Project #3 Adaptive Filter Simulation

Lakehead University. Department of Electrical Engineering

Electrical & Computer Engineering Technology

Digital Filtering: Realization

Short-Time Fourier Transform and Its Inverse

INSTANTANEOUS FREQUENCY ESTIMATION FOR A SINUSOIDAL SIGNAL COMBINING DESA-2 AND NOTCH FILTER. Yosuke SUGIURA, Keisuke USUKURA, Naoyuki AIKAWA

Project I: Phase Tracking and Baud Timing Correction Systems

Jaswant 1, Sanjeev Dhull 2 1 Research Scholar, Electronics and Communication, GJUS & T, Hisar, Haryana, India; is the corr-esponding author.

Project 2 - Speech Detection with FIR Filters

Acoustic Echo Cancellation using LMS Algorithm

ELEC-C5230 Digitaalisen signaalinkäsittelyn perusteet

DSP First Lab 08: Frequency Response: Bandpass and Nulling Filters

GEORGIA INSTITUTE OF TECHNOLOGY. SCHOOL of ELECTRICAL and COMPUTER ENGINEERING. ECE 2026 Summer 2018 Lab #8: Filter Design of FIR Filters

Signals and Systems Lecture 6: Fourier Applications

Lab 6. Advanced Filter Design in Matlab

DSP First. Laboratory Exercise #7. Everyday Sinusoidal Signals

CS3291: Digital Signal Processing

B.Tech III Year II Semester (R13) Regular & Supplementary Examinations May/June 2017 DIGITAL SIGNAL PROCESSING (Common to ECE and EIE)

Final Exam Practice Questions for Music 421, with Solutions

Fourier Transform Analysis of Signals and Systems

2.161 Signal Processing: Continuous and Discrete Fall 2008

A Novel Adaptive Algorithm for

Signal Processing. Naureen Ghani. December 9, 2017

PROBLEM SET 6. Note: This version is preliminary in that it does not yet have instructions for uploading the MATLAB problems.

ECE 5650/4650 Exam II November 20, 2018 Name:

Multi Modulus Blind Equalizations for Quadrature Amplitude Modulation

Digital Signal Processing. VO Embedded Systems Engineering Armin Wasicek WS 2009/10

Performance Comparison of ZF, LMS and RLS Algorithms for Linear Adaptive Equalizer

Biomedical Signals. Signals and Images in Medicine Dr Nabeel Anwar

SMS045 - DSP Systems in Practice. Lab 1 - Filter Design and Evaluation in MATLAB Due date: Thursday Nov 13, 2003

DFT: Discrete Fourier Transform & Linear Signal Processing

The University of Texas at Austin Dept. of Electrical and Computer Engineering Midterm #1

Multirate Digital Signal Processing

Team proposals are due tomorrow at 6PM Homework 4 is due next thur. Proposal presentations are next mon in 1311EECS.

ECE 429 / 529 Digital Signal Processing

Today s menu. Last lecture. Series mode interference. Noise and interferences R/2 V SM Z L. E Th R/2. Voltage transmission system

Signals and Systems Lecture 6: Fourier Applications

Module 9: Multirate Digital Signal Processing Prof. Eliathamby Ambikairajah Dr. Tharmarajah Thiruvaran School of Electrical Engineering &

Audio Restoration Based on DSP Tools

ADSP ADSP ADSP ADSP. Advanced Digital Signal Processing (18-792) Spring Fall Semester, Department of Electrical and Computer Engineering

Frequency Modulation and Demodulation

ECE 3500: Fundamentals of Signals and Systems (Fall 2014) Lab 4: Binary Phase-Shift Keying Modulation and Demodulation

Detection and Estimation of Signals in Noise. Dr. Robert Schober Department of Electrical and Computer Engineering University of British Columbia

Subtractive Synthesis. Describing a Filter. Filters. CMPT 468: Subtractive Synthesis

Lab/Project Error Control Coding using LDPC Codes and HARQ

George Mason University ECE 201: Introduction to Signal Analysis Spring 2017

Digital Signal Processing ETI

Signals. Continuous valued or discrete valued Can the signal take any value or only discrete values?

DSP Laboratory (EELE 4110) Lab#10 Finite Impulse Response (FIR) Filters

Concordia University. Discrete-Time Signal Processing. Lab Manual (ELEC442) Dr. Wei-Ping Zhu

DIGITAL FILTERS. !! Finite Impulse Response (FIR) !! Infinite Impulse Response (IIR) !! Background. !! Matlab functions AGC DSP AGC DSP

George Mason University Signals and Systems I Spring 2016

SIGNALS AND SYSTEMS LABORATORY 13: Digital Communication

Performance Study of A Non-Blind Algorithm for Smart Antenna System

Speech Enhancement Based On Noise Reduction

6.02 Fall 2012 Lecture #13

Digital Signal Processing ETI

FFT analysis in practice

Performance Analysis of Equalizer Techniques for Modulated Signals

Lecture 4 Biosignal Processing. Digital Signal Processing and Analysis in Biomedical Systems

THE CITADEL THE MILITARY COLLEGE OF SOUTH CAROLINA. Department of Electrical and Computer Engineering. ELEC 423 Digital Signal Processing

Copyright S. K. Mitra

Qiz 1. 3.discrete time signals can be obtained by a continuous-time signal. a. sampling b. digitizing c.defined d.

Signal processing preliminaries

y(n)= Aa n u(n)+bu(n) b m sin(2πmt)= b 1 sin(2πt)+b 2 sin(4πt)+b 3 sin(6πt)+ m=1 x(t)= x = 2 ( b b b b

Application of Affine Projection Algorithm in Adaptive Noise Cancellation

Experiments #6. Convolution and Linear Time Invariant Systems

speech signal S(n). This involves a transformation of S(n) into another signal or a set of signals

ELEC3104: Digital Signal Processing Session 1, 2013

Adaptive Kalman Filter based Channel Equalizer

EE 422G - Signals and Systems Laboratory

Sampling and Reconstruction of Analog Signals

FIR/Convolution. Visulalizing the convolution sum. Convolution

Signal Processing for Speech Applications - Part 2-1. Signal Processing For Speech Applications - Part 2

Final Exam. EE313 Signals and Systems. Fall 1999, Prof. Brian L. Evans, Unique No

Revision of Channel Coding

A Comparison of the Convolutive Model and Real Recording for Using in Acoustic Echo Cancellation

Wireless Communication Systems Laboratory Lab#1: An introduction to basic digital baseband communication through MATLAB simulation Objective

EE456 Digital Communications

MATLAB SIMULATOR FOR ADAPTIVE FILTERS

EE482: Digital Signal Processing Applications

George Mason University ECE 201: Introduction to Signal Analysis

Laboratory Assignment 4. Fourier Sound Synthesis

Suggested Solutions to Examination SSY130 Applied Signal Processing

Lab course Analog Part of a State-of-the-Art Mobile Radio Receiver

Lecture 20: Mitigation Techniques for Multipath Fading Effects

Design of FIR Filters

Midterm 1. Total. Name of Student on Your Left: Name of Student on Your Right: EE 20N: Structure and Interpretation of Signals and Systems

ECE 301, final exam of the session of Prof. Chih-Chun Wang Saturday 10:20am 12:20pm, December 20, 2008, STEW 130,

Transcription:

University of Pennsylvania Department of Electrical and System Engineering Digital Signal Processing ESE531, Spring 2017 Final Project: Audio Equalization Wednesday, Apr. 5 Due: Tuesday, April 25th, 11:59pm Project Teams: You can work in groups of no more than 2 for this project. You may work alone. Each group must turn in one report with the clear contributions of each member clearly delineated. Everyone is responsible for understanding the design and report in its entirety, and the instructor reserves the right to interview the students to verify this. The teams must be reported to the instructor by April 11, 11:59pm via e-mail: taniak@seas.upenn.edu. You are to complete all three parts of the handout: Part A, Part B, and Part C. Part D may be turned in for extra credit. 1. Part A: MULTI-CHANNEL FIR FILTER-BANK. You are to implement a perfect reconstruction filter-bank (PR-FB) using Matlab, and apply it to one-dimensional signals (audio). You can use Matlab routines such as firpr2chfb and mfilt.firdecim, etc., for this purpose. (a) Design a 4-channel octave band scheme, in which the full-band is decomposed into 2 low frequency bands (1/8 of full-band each), an intermediate 1/4 of full-band, and the upper 1/2 high-frequency band. Use reasonable parameter values (filter length and band edges for the filters). Filter length should not be unreasonably long. (b) To test the filter-bank, use a simple test signal such as a number of sinusoids at different frequencies, or any other test signal of your choice. (c) Now use the filter-bank on an audible waveform such as a segment of music or speech. (i) Use the filter-bank to implement a simple equalizer for the speech or music; by this we mean impart different gains on the 4 subband signals before reconstruction, to enhance certain frequency bands relative to others (e.g. bass boost, high-frequency boost, etc). (ii) Find out if introduction of small relative delays in the four subbands prior to reconstruction affects your perception of the audio (i.e. determine to what extent differential phase shifts or delays are important in perception of speech or music). 2. Part B: ADAPTIVE NOTCH FILTER. DO NOT use high level Matlab commands that may be available in the Signal Processing and other Matlab toolboxes for adaptive filtering in this part. It is easy and much more instructive to write your own Matlab code to implement these. A simple real IIR notch filter is a second order filter with two conjugate zeros on the unit circle and two conjugate poles inside the unit circle, with system function 1

H(z) = (1 ejω 0 z 1 )(1 e jω 0 z 1 ) (1 re jω 0 z 1 )(1 re jω 0 z 1 ) = 1 + az 1 + z 2 1 + raz 1 + r 2 z 2 where a = 2cos(ω 0), and 0 r < 1 The notch is at real frequency ω 0 and the closeness of the poles to the unit circle determines the notch sharpness. This filter can be used to reject a strong interfering sinusoid that is contaminating a desired signal. For unknown interfering frequency we want to build an adaptive notch filter, based on the principle that the filter output is minimized when the notch is at the correct location. Note that the adaptation is with respect to the parameter value a, with r generally set at a fixed value. Since this is not an FIR filter, we cannot directly apply the LMS algorithm derived for adaptive FIR filters. However it is possible to develop a simple algorithm for the adaptive notch filter. We can decompose H(z) as a cascade of the FIR part followed by the all-pole filter, and we can write the output sequence y[n] when input sequence is x[n] in terms of an intermediate sequence e[n]: e[n] = x[n] + ax[n 1] x[n 2] y[n] = e[n] ray[n 1] r 2 y[n 2] The gradient of y[n] 2 with respect to a is 2y[n] dy[n] da thus, as an approximation we replace dy[n] da where the derivative is not simple; with de[n] = x[n 1]. To minimize E(y[n] 2 ), da we approximate its gradient as 2y[n]x[n 1]. The adaptive notch filter update of the parameter a (for fixed choice of r) is therefore: a[n + 1] = a[n] µy[n]x[n 1]. Since a = 2cos(ω 0 ) we have 2 a < 2. We should impose this constraint for the updates and reset a[n] = 0 if it is out of bounds. (a) Create a simple simulation of an adaptive notch filter for a desired signal with unwanted additive sinusoidal interference. The desired signal may be some real sequence perhaps with a small amount of additive noise; you can use a singlefrequency desired signal as one possibility, but experiment with other types of desired signal also. The interference will be a single strong frequency (low signalto-interference power ratio). Start with a = 0 (ω 0 = π, mid-point of frequency 2 band). Consider different small values of µ, different fixed values of r (of the order of 0.85 to 0.98), different interfering frequencies and powers. Note that µ will have to be quite small. Give plots and results on frequency response, convergence, spectra, etc. to show how well your adaptive filter works. (b) Consider one case where the single interfering sinusoid has a frequency that is changing slowly. For example, you might define the interference as a sinusoid with a slowly linearly increasing frequency or some other slowly changing profile. Examine the tracking ability of the adaptive notch filter and give your results and comments. (Note that the instantaneous frequency of a sinusoid cos(2π φ(t)) is dφ ) dt 2

(c) Can you extend your scheme of part 2(a) to a filter scheme creating two notches to reject two sinusoidal components? In particular, you might consider a cascade of two single-notch second-order notch filters, and adapt the a parameter of each (i.e. a = a 1 and a = a 2 ). Explain your approach and give your results for a test case of two interfering sinusoids on a desired signal. (d) Now investigate use of your 4-channel octave-band filter-bank scheme already designed in Part A for adaptive notch filtering applied separately in each subband. Suppose you have interfering sinusoids contaminating a desired signal with the constraint that there can be at most one interfering sinusoid in each of the four octave bands. Show your results for this situation, and comment on the effectiveness of this approach. 3. Part C: ADAPTIVE EQUALIZATION DO NOT use high level Matlab commands that may be available in the Signal Processing and other Matlab toolboxes for adaptive filtering in this part. It is easy and much more instructive to write your own Matlab code to implement these. Here you will use adaptive filtering to equalize or invert an unknown channel, with (1) the help of a training sequence and also (2) blindly, without training. Training Mode Equalization: Consider a source sending continuous-time pulses of amplitude A or A to represent bits 1 and 0. The sequence of such pulses passing through a channel can undergo distortion causing them to spread out and overlap with each other, creating what is called inter-symbol interference or ISI. In addition, any front-end filtering at the receiver may cause further pulse spreading. The channel may be modeled in discrete-time as follows: an input sequence s[n] (random sequence) of ±A amplitudes passes through a discrete-time LTI system (channel) with unit-sample response sequence h[n] to produce the observed sequence of channel output samples x[n] in the presence of noise. Thus we have x[n] = h[n] s[n] + w[n] where w[n] is a sequence of zero-mean, independent, Gaussian variates representing additive noise. The channel may be assumed to be an FIR channel of order L (length L + 1), and its unit-sample response h[n] is unknown. At the channel output we use an FIR adaptive equalizer filter of larger length M + 1 operating on x[n] to try to invert the channel, to ideally get at its output a delayed version of the original input sequence s[n], after the adaptive filter has converged. In order to implement the LMS training algorithm for the equalizer, we need a copy of the actual input sequence for use as the desired (delayed) output signal during an initial training phase. After the training phase, the equalizer should have converged to a good approximation of an inverse filter. (a) Produce a random ±1 amplitude training sequence of length 1000. Assume some channel unit-sample response h[n]; you may use for example something like h = [0.3, 1, 0.7, 0.3, 0.2] for your initial trials, but you should also test your implementation for different unknown channels of such short lengths ( 7). At 3

the output of the channel (after convolution of input sequence with h[n]) add Gaussian noise to simulate a more realistic noisy output condition. You may use an SNR of around 20-35 db. Now implement an adaptive filter operating on the noisy channel output x[n], using a training sequence which is an appropriately delayed version of the input sequence. The delay will take care of any unknown channel delay (for example, for the channel given above the channel delay may be 2 units,) and equalizer filter delay. Examine the performance you get with different combinations of equalizer filter order M (choose this between 10 and 30), filter step-size µ, adaptive filter initialization, SNR, channel impulse response h[n], etc. Examine the impulse and frequency response and pole-zero plot of the channel, and the impulse and frequency responses of the equalizer upon convergence, and provide plots and results that show how well your adaptive equalizer works under different channel and noise conditions. Plot also the impulse response and frequency response of the equivalent LTI system between input and output, i.e. the result of the channel and equalizer in cascade, after the equalizer has reached reasonable convergence. Determine if output decisions about the transmitted bits are better after equalization, compared to the un-equalized case. (You can check the output of the system using the equalizer obtained after convergence, by sending several thousand further inputs into the channel.) Comment on your findings. Blind Equalization: It is not always possible to have an initial training phase, during which an equalizer at the receiver knows the input, to form an error to drive its LMS training algorithm. The transmitter may be continuously sending data through a channel, and it may be left to the receiver to figure out for itself how to equalize the channel, without the benefit of a known training input sequence. In the context of the simple scenario of part 3(a), the situation now is that the receiver knows only that the transmitted pulse amplitudes are two-level ±1 values (more generally ±A amplitudes). It has to use only this general knowledge about the nature of the input to learn how to equalize the channel. It has no knowledge of an explicit transmitted sequence that it can use for training, and we say it is operating in the blind mode. A simple approach to blind equalization in this setting is based on the use of the constant- modulus property of the input; the modulus or absolute value of the input amplitude sequence is a constant (= 1 or more generally A). The constant-modulus (CM) blind equalization algorithm attempts to equalize the channel by iterative adjustments to the equalizer with the objective of minimizing a measure of deviation of the equalizer output modulus values from a constant modulus value. Referring to the LMS adaptive algorithm description, we now have input sequence x[n] to an equalizer that produces output y[n]. The error function for the CM blind equalizer is defined as e 2 n = ( y[n] 2 1) 2 = ( g T nx n 2 1 ) 2 where gn is the equalizer coefficient vector at time n. Differentiating this with respect to g n we easily find 4

that the gradient de2 n is proportional to ( y[n] 2 1)y[n]x dg n. Thus the corresponding n stochastic gradient algorithm becomes g n+1 = g n µ( y[n] 2 1)y[n]x n. (b) Implement this blind adaptive equalizer. Does the blind equalizer converge to a reasonably equalized condition? You will have to try different settings for µ and equalizer order M. (You will need possibly many tens of thousands of iterations, and will need to experiment with rather small value of µ, perhaps of the order of 10 4 depending on the specifics of your other parameters.) Use short channel impulse response lengths (around 5) and dont use equalizer lengths that are too long (around 20 maximum). Try different SNRs, but expect poor results if the SNR is not high. Provide plots and results, and give explanations/comments as in the case of part 2(a) above. Also provide a one-dimensional scatter plot of the output amplitudes after equalizer convergence, to get a visual sense of how well the equalizer is able to bring the output amplitudes close to the desired two amplitudes. 4. Part D: FILTER DESIGN USING LMS ALGORITHM DO NOT use high level Matlab commands that may be available in the Signal Processing and other Matlab toolboxes for adaptive filtering in this part. It is easy and much more instructive to write your own Matlab code to implement these. Suppose a desired frequency response H d (e jω ) is specified (with even magnitude and odd phase function). You want to design a real, causal, FIR impulse response {h[0], h[1],..., h[m]} for an M-th order FIR filter which gives a good approximation to this H d (e jω ). The desired frequency response may not be of a standard type such as a low-pass or bandpass specification. For this we may form a long, real, test input signal sequence {x in [n], n = 0, 1,..., K} consisting of a large number L of individual frequencies spanning the range (0, 0.5). The corresponding ideal desired output {x d [n], n = 0, 1,..., K} is obtained using the magnitude scaling and phase shift specified by H d (e jω ) for each such input frequency. The impulse response coefficients of an FIR filter of order M may then be adaptively learned using the LMS algorithm to get approximately this desired output sequence x d [n] when driven by the test input sequence x in [n]. (a) Let the desired magnitude response be: 2, for 0 f 0.1 H d (e j2πf ) = 1, for 0.1 f 0.3 3, for 0.3 f 0.5 and the FIR filter of order M is to have linear phase. Form reasonable test input and corresponding desired output sequences, containing an appropriate number L of individual frequencies spread over the (0,0.5) interval. Use the LMS adaptive FIR filter scheme to find a good design for a causal FIR filter of order M that will produce a good approximation of the desired output. Note that you will have to experiment with different combinations of 5

step-size (this has to be generally small), filter length M, number of test frequencies L, and length of the test sequences N (this will generally be large). Give plots of your designed filter(s) characteristics (impulse response, frequency response). Discuss briefly/comment on any specific aspects of your method or results that you want to highlight. (b) Now suppose the desired response is { H d (e j2πf j2πf, for 0 f 0.3 ) = 0, for 0.3 f 0.5 any additional linear phase term is allowed. The real FIR filter of order M approximating this is to have generalized linear phase. Repeat your procedure of part 4(a) for this case. After you have obtained your FIR filter, test it on some interesting inputs. 6

Project Submission: Your report submission for this project will consist of two parts. Project Report: You should submit by the due date a single filed report (preferably pdf) explaining what you did and the results you obtained, including figures, test cases, interpretations and comments, as well as responses to any specific questions asked above. Please explain briefly your Matlab code; include a copy of all your Matlab code in your report in an Appendix. The report must be uploaded to Canvas by midnight on the due date. MATLAB Code and Other Soft Files: Also submit (upload) by the due date through the Assignments Area on the ESE 531 Canvas Site all supporting material (all your Matlab code files, test input/output files, and any other results files). Ideally all placed in a compressed.zip file. Please make sure you follow the proper procedure for submitting files through Canvas. 7