-
Notifications
You must be signed in to change notification settings - Fork 29
Home
This work was initially completed because it is desirable to properly model the stochastic nature of the sensors in an inertial measurement unit (or IMU). This is done by using data from an IMU (sitting stationary for several hours) to generate Allan variance and power spectral density plots. From these plots we can extract information that is used by our model to replicate the Allan variance and power spectral density of the data. That model can then be used in simulation (either in Matlab or in C++). The sections below walk you through how to do this. Our simulation also has the ability to include certain types of deterministic-based errors (in particular a scale factor and fixed bias).
To generate an Allan variance plot with data collected at a roughly fixed frequency, simply use the allan.m function in the Matlab Data Analysis Tools Folder. Then simply input the entire set of measurements, the frequency at which the data was collected, and the number of discrete points desired on the Allan variance plot. To plot simply generate a log-log plot of the time window and square of the standard deviation output. See the example below and the first few lines of main.m under the Matlab Example folder.
[T,sigma] = allan(meas,fs,pts);
figure(1)
loglog(T,sigma.^2)
xlabel('Time Window, \tau (sec)')
ylabel('Allan Variance')
grid on;