Hi,
I have 30k samples and I make FFT.
Size of amplitudes in FFT is ok.
But I want make sum of all amplitudes and here I can see wrong number. For example here:
FFT picture:
https://ibb.co/Z1tgjBs
FFT seems OK.
If I use
I can see number 14.39 and it is nonsense. I need to see something about 1.
What I do wrong? How to correctly sum all amplitudes from FFT?
Data file excel:
https://file.io/YBMdA8plul3N
Any idea?
Thanks.
I have 30k samples and I make FFT.
Size of amplitudes in FFT is ok.
But I want make sum of all amplitudes and here I can see wrong number. For example here:
1 2 3 4 5 6 7 8 9 10 11 12 |
SAMPLES = 30000 T = 1 / 30000 x = np.linspace( 0.0 , SAMPLES * T, SAMPLES, endpoint = False ) y = v_data # v_data are from csv file, attached yf = fft(y) xf = fftfreq(SAMPLES, T)[:SAMPLES / / 2 ] self .canvas.axes.cla() self .canvas.axes.set_ylabel( "Amplitude in g RMS" ) self .canvas.axes.set_xlabel( "Frequency in Hz" ) self .canvas.axes.plot(xf, 2.0 / SAMPLES * np. abs (yf[ 0 :SAMPLES / / 2 ])) print ( sum ( 2.0 / SAMPLES * np. abs (yf[ 0 :SAMPLES / / 2 ]))) |
https://ibb.co/Z1tgjBs
FFT seems OK.
If I use
1 |
print ( sum ( 2.0 / SAMPLES * np. abs (yf[ 0 :SAMPLES / / 2 ]))) |
What I do wrong? How to correctly sum all amplitudes from FFT?
Data file excel:
https://file.io/YBMdA8plul3N
Any idea?
Thanks.