"Nasser M. Abbasi" <email@example.com> wrote in message news:firstname.lastname@example.org... > On 3/18/2013 5:10 AM, JankoZ wrote: >> Hi I need your help! >> >> I have measurement of acceleration in axis X,Y,Z (cca 6000 measurement >> with spet 0.02sec). >>I want to get final position with using Numerical Integration in Matlab. >>Can anybody help me? > > Numerical integration can be hard to get right for this. > > Better to do this in frequency domain using FFT. > > Take the FFT of acceleration data. Since displacement is integration > 2 times in time domain, then in frequency domain it becomes division > by -(n*w1)^2 where w1 is the fundamental frequency of the acceleration > signal (i.e. 2*pi/T) and n is the coefficient (i.e. bin) number. > i.e. n=0..N-1 > > Then you do ifft on the result. > > If you want just velocity, then divide by (I*n*w1) instead and > do the same. > > This is what I do. It works well. But if you really want to > do numerical integration, then get the AbraVibe matlab toolbox by > Anders Brandt, it has a well written timeint() function. Apply > it 2 times on your data. (for each x,y,z) > > --Nasser >
I believe the original data were not evenly sampled, making an FFT (or filter) solution problematic. Was that just a typo in the data?