I'm colleceting data samples from a device (temporal signal) in order to analyze it with FFT function in MATLAB R2015b,first i get N=4063 data points with (delta_t=0.000015s) so my frequency resolution is (delta_f=1/N*delta_t)=16.4Hz,this give me pretty good results with amplitude,but when i did another measurment with N=8192 data points (delta_t=0.000061) to obtain better resolution,the amplitude is not correct,i don't know really how to deal with this issue.so please if any body can help me with this i will be grateful,thank you

ps:i'm new in signal processing

below my code in MATLAB

Fs2 = 1/0.000061;      % Sampling frequency
T2 = 1/Fs2;            % Sampling period
L2 = 8192;             % Length of signal
t2 = (0:L2-1)*T2;      % Time vector
Y2 = fft(sig_2(:,2))
Q2 = abs(Y2/L2);
Q1 = Q2(1:L2/2+1);
Q1(2:end-1) = 2*Q1(2:end-1);
f2 = Fs2*(0:(L2/2))/L2; %FREQUENCY

spectrum 8k Data pts

  • $\begingroup$ Hiii! can you please also provide that asp_ach_de1 signal? or do you want us to predict it ? $\endgroup$
    – Fat32
    Commented Jan 21, 2019 at 16:55
  • $\begingroup$ thank you Fat32,but how i'm suppose to share it with you here,it's 8192 line txt file or how to attach it. $\endgroup$ Commented Jan 22, 2019 at 5:43
  • $\begingroup$ here's the 2 signals asp_ach_de1 "4k and 8k", gist.github.com/bishopreb85/19b056cfbea0d8c10e7ff1d0fa389d00 $\endgroup$ Commented Jan 23, 2019 at 8:48

1 Answer 1


I think that what is happening to u is that the frequency which you are trying to measure is in between 2 of your FFT bins which will cause the power to spread between two different indexes of your result FFT.

Another possible solution , only if with higher resolution you are getting a lower value , is that since as I understand this is a real signal with noise you may be summing more noise , on the first attempt, for each frequency of your FFT and as a result raising all the values of your FFT.

Without knowing the signal you are trying to process it is hard to know what is exactly the problem. also your FFT plots will help give a better answer.

  • $\begingroup$ Thank you shaiel cohen,it's a Vibration temporal signal,i'm suppose to get an amplitude between 25 and 35,so you see my amplitude is not correct. $\endgroup$ Commented Jan 22, 2019 at 5:49
  • $\begingroup$ Glad to help if you could provide the file and the graph of the 4k samples and the code for your first plot , that would help provide an answer. $\endgroup$ Commented Jan 22, 2019 at 6:09
  • $\begingroup$ shaiel cohen,i tried to attach the file here but,i can't find any way to do it,so how you wanna from me to share with you the signal,can you suggest for me $\endgroup$ Commented Jan 22, 2019 at 19:00
  • $\begingroup$ Upload to a gist on git will probably be the most useful $\endgroup$ Commented Jan 22, 2019 at 19:40
  • $\begingroup$ I'm really sorry,i don't think that i understand you with "git" or how to use it,i have only a txt file if you want i'll send it to you, $\endgroup$ Commented Jan 22, 2019 at 19:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.