I'm very new to signal processing and can't get ahead:
I'm using an Accelerometer to measure the acceleration of i.e. the building vibrations or elements/machinery etc. For creating the spectrum, I complete a fft, with python's numpy, and there reach at the state where my problem lays. I have 2 problems understanding the process of creating the frequency spectrum:
- The scaling of the y-axis, happening in the fft
- How does one get from the acceleration data to the rms velocity used for the VC (vibration criteria) curves (example at the end).
To clarify my problem let me create a minimalist and easy example:
Here is a small code which creates a default spectrum from a single sine wave:
Let's say that the sine has an Amplitude of 1 m/s², so the unit of the spectrum should also be in m/s², and the time is in seconds.
import numpy as np
import matplotlib.pyplot as plt
fig = plt.figure(figsize=(8, 8))
ax = fig.add_subplot(211)
ax_ps = fig.add_subplot(212)
ax_ps.set_xlim(45,55)
samp_freq = 1000
rate = 1/samp_freq
t = np.arange(0,1,rate) #s
func = 1np.sin(2np.pit50) #50 Hz
#fft:
fr = np.fft.rfftfreq(len(func),rate)
ft = abs(np.fft.rfft(func))
ax.plot(t,func)
ax_ps.plot(fr,ft)
plt.show()
This restults in the following plots:

As it should, it detects the 50$\,$Hz frequency without problems. Yet, I don't understand the enormous value of the y-axis of 500 (m/s²). The only thing I see is, that the value is dependent on both the sample rate and measuring time, as it rises with both individually. But the bigger problem - also connected to 1 - is part 2: how do I get from this spectrum to one, comparable with the following (not the layout, only the scaling of the y-axis):

I hope the question got clear, if not, please let me know.