DFT - How to label x-axis in frequency
2 次查看(过去 30 天)
显示 更早的评论
Hi,
I need to label my x-axis in frequency how can I do that ... follow my code
% function f2
N=length(f2);
n = 0:1:N-1; % row vector for n
k = 0:1:N-1; % row vecor for k
WN = exp(-1j*2*pi/N); % Twiddle factor (w)
nk = n'*k; % creates a N by N matrix of nk values
WNnk = WN .^ nk; % DFT matrix
Xk = (WNnk*f2 );
mag1=abs(Xk); ang1=(angle(Xk)*180)/pi;
Then here I need to plot an one sided fft Amplitude x Frequency.. Anyone can Help me???
2 个评论
Orion
2014-10-22
Hi,
what is f2 ? it's not defined in your text, so we can't run it to try your code.
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Spectral Measurements 的更多信息
产品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!