How to plot the frequency response of a discrete cosine function?
13 次查看(过去 30 天)
显示 更早的评论
My attempt:
I tried doing it but I can't get the freq response to be plotted between pi and pi. Any help would be appreciated.
0 个评论
回答(1 个)
Rick Rosson
2015-11-14
编辑:Rick Rosson
2015-11-14
L = 1000;
n = 0:L-1;
x1 = fftshift(fft(x))/L;
dw = 2*pi/L;
w = -pi:dw:pi-dw;
stem(w,mag);
5 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Frequency Transformations 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!