Fourier transform of hamming window function
Afficher commentaires plus anciens
I want to apply fourier transform onto hamming window but when I use fft function to get fourier transform but it shows graph like showed below. When I referred https://en.wikipedia.org/wiki/Window_function#Hamming_window they show different graph. There is also code attached. Can someone please help me to figure out.
if true
if true
hfft = hamming(framelength);
plot(abs(fft(hfft)));
end
end

Réponses (1)
jie li
le 28 Août 2020
1 vote
framelength = 60
hfft = hamming(framelength);
%hfft = rectwin(framelength);
%hfft = blackman(framelength);
A = fft(hfft, 2048) / (framelength /2);
mag = abs(fftshift(A));
freq = linspace(-0.5, 0.5, length(A));
response = 20 * log10(mag);
% lowvalue = -80;
% response(response < lowvalue) = lowvalue;
plot(freq,response)
Catégories
En savoir plus sur Fast Fourier Transforms dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!