Matlab: - ylche21.files.wordpress.com file · Web viewMatlab: >>SPTOOL New. Design FIR....

Preview:

Citation preview

Matlab:>>SPTOOL

New

Design FIRResponse type: Bandpass

Astop means attenuation gain,

The coefficient of the filter can be seen from analysisfilter coefficient

Export the filter data

For convolution:If the coefficient of filter is a(1), a(2), a(2),and signal is bThen

%%convolutionfor i=3:length(b)+6newsignal(i)=a(1)*b(i)+a(2)*b(i-1)+a(3)*b(i-2);end

newsignal(1)=a(1)*b(1);newsignal(2)=a(1)*b(2)+a(2)*b(1);

%%so newsignal is the new signal

After the filter which we have designed

For the go

Left

Right

To get this, what I do isImport the signal from the workspace(import fuction under the file of the SPTOOL)Go1 left1 and right1 is the signal get from the wavread(‘***.wav’)

Select right filter and imput signal ,Click the apply, then u can name the output signal, then view it