I’m looking for help to find a robust technique to remove a once per revolution variation in some vehicle test data. The data is collected by driving a vehicle around a circular path at increasing speed whilst measuring, amongst other things, roll angle and lateral acceleration. Due to the slight tilt in the track surface, the roll data contains a once per revolution variation due to gravity, as per the following image:
From the other measurements made it is easy enough to replot this against ‘circles’ and more easily see the periodicity in the data:
Despite the apparently obvious variation at 1 cycle/circle, I am having great difficulty finding a method of removing it that isn’t super sensitive to small changes in the data or method.
Firstly, I generated replacement circle data so that it was equispaced and then mapped the roll angle data to it. I then used our proprietary analysis software to calculate an FFT and construct a cosine wave with the amplitude and phase at 1 cycle/circle. This cosine wave was then subtracted from the data. Remarkably, it worked very well – but only once. I found it not at all repeatable on other files and extremely sensitive to anything that changed the data even slightly. I tried various numbers of data points in the generated and mapped data sets to see how well the FFT performed. These ranged from using the same number of points as the original data (over 10k) to just a handful per circle. Every FFT was sufficiently different to prevent it being usable.
I’ve also tried a discrete Fourier transform method (in Excel), which has been successful in the past for other applications. This uses the following process, where $x$ is the circle data and $y$ is the roll data:
- Calculate $y \cdot cos(2πx)$
- Calculate $y \cdot sin(2πx)$
- Sum the values in step 1
- Sum the values in step 2
- Calculate $A$ by multiplying the sum from step 3 by 2/N, where N is the number of data points in each channel
- Calculate $B$ by multiplying the sum from step 4 by 2/N
- Calculate the amplitude using $√(A^2+B^2)$
- Calculate the phase using $atan2(-B,A)$ [note that in Excel atan2 uses (adjacent, opposite)]
- Construct a cosine wave using the amplitude and phase and subtract it from the data
The results from this method also seem variable, for example in the following image where the phase is about right but the amplitude is a bit less than half that necessary to remove the variation.
I’ve also tried removing the linear trend from the data first before mapping and calculating the transform but again the results are not robust. I’ve also applied a third order fit to the data and removed that before following the rest of the process. Sometimes the discrete transform produces a result that is so far from the variation seen by the eye that I’m beginning to wonder if there’s something not right in the way I’m applying the method. Here, for example, is the same data from all the previous images but with the third order fit removed and the DFT method used. The constructed cosine wave has approximately the right amplitude but this time the phase is almost 180 degrees out.
I’d be grateful for any guidance on either improving the reliability of the methods I’ve tried or ideas for alternative procedures.
Thanks.