MATLAB Example – Simulating the Speech Scrambler

Hamming401 note implements point by point

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: mple rate fs the equivalent DT filter has impulse response h [ n ] = Ts hLP ( nTs ) where Ts=1/fs. So, set Ts=1/fs; r=10000*Ts; n=[- 200:1:200]; %creates vector [- 200, - 199,…,0,…199,200] h=r*sinc(r*n); To smooth this at the endpoints so we don’t get ringing in the frequency response, we next apply a 401- point Hamming window: h=h.*hamming(401)’; (Note: “.*” implements point- by- point multiplication. The h that we originally created is a row vector; the hamming command creates a column vector. (To check this, you can use the size command – e.g., size(h) returns the number of rows and number of columns in h (that is, 1 401). ) Point- by- point operations in MATLAB require vectors or matrices of the same size and orientation. The apostrophe ‘ implements the transpose operation – so, hamming(401)’ is changed from a column vector to a row vector.) To verify that this corresponds to the desired LPF,...
View Full Document

This test prep was uploaded on 03/06/2014 for the course ECE 563 taught by Professor Goeckel during the Fall '11 term at UMass (Amherst).

Ask a homework question - tutors are online