• Sonuç bulunamadı

APPENDIX C compwind.m

N/A
N/A
Protected

Academic year: 2021

Share "APPENDIX C compwind.m"

Copied!
2
0
0

Yükleniyor.... (view fulltext now)

Tam metin

(1)

125

APPENDIX C

compwind.m

% % FUNCTION compwind %

% Display the sound before windowing and after windowing % function r = compwind(s, fs) l = length(s); m = 100; n = 256; nbFrame = floor((l - n) / m ) + 1; %

% Create a matrix M containg all the frames % for i = 1:n for j = 1:nbFrame M(i, j) = s(((j - 1) * m) + i); end end %

% Matrix M created. Now apply HAMMING window and store in matrix N. Column vectors of N are

% the original frame vectors transformed by the Hamming window filter %

h = hamming(n); N = diag(h) * M;

%

% Now plot the window, without window, and with window %

%

% Plot the Hamming window %

t = (0:n-1); subplot(3,1,1); plot(t,h);

title('Hamming Window'); xlabel('Samples');

ylabel('Amplitude'); %

% Plot the sound without windowing %

(2)

126 subplot(3,1,2);

plot(t,M);

title('Sound frames before windowing'); xlabel('Samples');

ylabel('Amplitude'); %

% Plot the sound with windowing %

subplot(3,1,3); plot(t,N);

title('Sound frames after windowing'); xlabel('Samples');

ylabel('Amplitude'); r=1;

% Plot the Hamming window %

t = (0:n-1); subplot(3,1,1); plot(t,h);

title('Hamming Window'); xlabel('Samples');

ylabel('Amplitude'); %

% Plot the sound without windowing %

subplot(3,1,2); plot(t,M);

title('Sound frames before windowing'); xlabel('Samples');

ylabel('Amplitude'); %

% Plot the sound with windowing %

subplot(3,1,3); plot(t,N);

title('Sound frames after windowing'); xlabel('Samples');

ylabel('Amplitude'); r=1;

Referanslar

Benzer Belgeler

[r]

Create Or Replace Function Empid Return

ORDBMS Object Relational Database Management System OSQL Object Structured Query Language. RDBMS Relational Database Management System SQL Structured

[r]

Testing Accuracy 1 st Quarter Second Experiment 92.8962 % Quarter 2: First experiment using 2 images for training & 1 image for testing..

[r]

Based on the surface charge measurements on the wafers and sta- bility testing of the CMP slurry in the presence of surfactants, CMP tests were performed to analyze the material

Store loyalty is operationalized as the household’s share of wallet (hereafter denoted SOW) in the chain, i.e., its spending in the chain (in euros) as a % of its total spending on