This preview has intentionally blurred sections. Sign up to view the full version.
View Full Document
Unformatted text preview: 1 ECE 408 COMPUTER ASSIGNMENT #3 AUDIO SIGNAL PROCESSING 3 Useful MATLAB functions: buttord, cheb1ord, cheb2ord, ellipord, butter, besself, cheby1, cheby2, ellip BUTTER Butterworth digital and analog filter design. [B,A] = BUTTER(N,Wn) designs an Nth order lowpass digital Butterworth filter and returns the filter coefficients in length N+1 vectors B (numerator) and A (denominator). The coefficients are listed in descending powers of z. The cutoff frequency Wn must be 0.0 &lt; Wn &lt; 1.0, with 1.0 corresponding to half the sample rate. If Wn is a twoelement vector, Wn = [W1 W2], BUTTER returns an order 2N bandpass filter with passband W1 &lt; W &lt; W2. [B,A] = BUTTER(N,Wn,'high') designs a highpass filter. [B,A] = BUTTER(N,Wn,'stop') is a bandstop filter if Wn = [W1 W2]. When used with three lefthand arguments, as in [Z,P,K] = BUTTER(...), the zeros and poles are returned in length N column vectors Z and P, and the gain in scalar K. When used with four lefthand arguments, as in [A,B,C,D] = BUTTER(...), statespace matrices are returned. BUTTER(N,Wn,'s'), BUTTER(N,Wn,'high','s') and BUTTER(N,Wn,'stop','s') design analog Butterworth filters. In this case, Wn is in [rad/s] and it can be greater than 1.0. See also BUTTORD, BESSELF, CHEBY1, CHEBY2, ELLIP, FREQZ, FILTER. 1. Read a short wav file into MATLAB and pass it through a digital IIR lowpass filter with specifications Approximation: Butterworth Passband cutoff frequency: 500 Hz Stopband cutoff frequency: 1000 Hz Maximum loss in the passband: 2dB Minimum loss in the stopband: 35dB (a) Play the sound before and after the filter. (b) Plot the waveforms in the time domain before and after the filter. (c) Plot the spectrums (fft magnitude) before and after the filter. 2 (d) Plot the impulse response, magnitude response, phase response, polezero diagram of the filter. Hint: %File Name: asp3LPF.m %Written by Dr. James S. Kang, ECE Department, Cal Poly Pomona. %Audio signal processing 3. Using wav file....
View
Full Document
 Summer '10
 JamesKang
 Digital Signal Processing, Signal Processing, Lowpass filter, Cutoff frequency, passband cutoff frequency, stopband cutoff frequency

Click to edit the document details