Discussion - Integrating Accelerometer data to Position data from Frequency domain FFT
The point is that acceleration is the second derivative of displacement. So to get the displacement, one should integrate acceleration twice. To do this, one way is to numerically integrate. A more interesting approach is to use the time-integration property of the Fourier transform:
$$\mathcal{F}\left(\int_{-\infty}^t x(\tau)d\tau\right)=\frac{X(j\omega)}{j\omega}$$
Note that we require $X(0)=0$. So division by $-\omega^2$ means twice integration in time.
Assuming the sampling frequency is fs and a is accel. data, you can use something similar to the following code:

 l = length(a); % assume l even 
 w = 2*pi*fs/l*(-l/2:l/2-1);
 A = fftshift(fft(a));
 D = A./-w.^2;
 d = ifft(ifftshift(D),'symmetric');