EKF: fixed some comment typos

Signed-off-by: CarlOlsson <carlolsson.co@gmail.com>
This commit is contained in:
Carl Olsson
2019-03-18 10:20:33 -04:00
committed by Daniel Agar
parent 6e77b197c7
commit f0889c1760
27 changed files with 133 additions and 134 deletions
@@ -21,7 +21,7 @@ imu_data.accel_dt = IMT(:,4);
imu_data.del_vel = IMT(:,9:11);
save imu_data.mat imu_data;
%% convert magnetomer data
%% convert magnetometer data
clear mag_data;
last_time = 0;
output_index = 1;
@@ -25,7 +25,7 @@ imu_data.del_ang = [gyro_rad0.*imu_data.gyro_dt, gyro_rad1.*imu_data.gyro_dt, gy
imu_data.accel_dt = accelerometer_integral_dt ./ 1e6;
imu_data.del_vel = [accelerometer_m_s20.*imu_data.accel_dt, accelerometer_m_s21.*imu_data.accel_dt, accelerometer_m_s22.*imu_data.accel_dt];
%% convert magnetomer data
%% convert magnetometer data
clear mag_data;
last_time = 0;
output_index = 1;
@@ -8,7 +8,7 @@ function [...
P, ... % predicted covariance
magMea, ... % body frame magnetic flux measurements
testRatio, ... % Size of magnetometer innovation in standard deviations before measurements are rejected
R_MAG) % magnetoemter measurement variance - gauss^2
R_MAG) % magnetometer measurement variance - gauss^2
q0 = states(1);
q1 = states(2);
@@ -87,7 +87,7 @@ stateVectorNew = [quatNew;vNew;pNew;dAngBiasNew;dVelBiasNew;magNnew;magEnew;magD
% Define the control (disturbance) vector. Error growth in the inertial
% solution is assumed to be driven by 'noise' in the delta angles and
% velocities, after bias effects have been removed. This is OK becasue we
% velocities, after bias effects have been removed. This is OK because we
% have sensor bias accounted for in the state equations.
distVector = [daxVar;dayVar;dazVar;dvxVar;dvyVar;dvzVar];
@@ -6,7 +6,7 @@ function P = PredictCovariance(deltaAngle, ...
param) % tuning parameters
% Set filter state process noise other than IMU errors, which are already
% built into the derived covariance predition equations.
% built into the derived covariance prediction equations.
% This process noise determines the rate of estimation of IMU bias errors
dAngBiasSigma = dt*dt*param.prediction.dAngBiasPnoise;
dVelBiasSigma = dt*dt*param.prediction.dVelBiasPnoise;
+2 -2
View File
@@ -249,7 +249,7 @@ for index = indexStart:indexStop
end
elseif (param.fusion.magFuseMethod == 2)
% fuse magnetomer data as a single magnetic heading measurement
% fuse magnetometer data as a single magnetic heading measurement
[states, covariance, hdgInnov, hdgInnovVar] = FuseMagHeading(states, covariance, mag_data.field_ga(latest_mag_index,:), param.fusion.magDeclDeg*deg2rad, param.fusion.magHdgGate, param.fusion.magHdgError^2);
% log data
@@ -317,7 +317,7 @@ for index = indexStart:indexStop
viso_fuse_index = viso_fuse_index + 1;
last_drift_constrain_time = local_time;
% convert delta positon measurements to velocity
% convert delta position measurements to velocity
relVelBodyMea = [viso_data.dPosX(latest_viso_index);viso_data.dPosY(latest_viso_index);viso_data.dPosZ(latest_viso_index)]./viso_data.dt(latest_viso_index);
% convert quality metric to equivalent observation error
@@ -25,7 +25,7 @@ param.fusion.baroHgtGate = 5.0; % Size of the IMU velocity innovation consistenc
param.fusion.baroHgtNoise = 2.0; % 1SD observation noise of the baro measurements (m)
%% Magnetometer measurement fusion
param.fusion.magTimeDelay = 0.0; % Magnetomer time delay relative to IMU (sec)
param.fusion.magTimeDelay = 0.0; % magnetometer time delay relative to IMU (sec)
param.fusion.magFuseMethod = 1; % 0: 3-Axis field fusion with free declination, 1: 3-Axis field fusion with constrained declination, 2: magnetic heading fusion. (None)
param.fusion.magFieldError = 0.05; % Magnetic field measurement 1SD error including hard and soft iron interference. Used when magFuseMethod = 0 or 1. (gauss)
param.fusion.magHdgError = 0.1745; % Magnetic heading measurement 1SD error including hard and soft iron interference. Used when magFuseMethod = 2. (rad)
+1 -1
View File
@@ -25,7 +25,7 @@ param.fusion.baroHgtGate = 5.0; % Size of the IMU velocity innovation consistenc
param.fusion.baroHgtNoise = 2.0; % 1SD observation noise of the baro measurements (m)
%% Magnetometer measurement fusion
param.fusion.magTimeDelay = 0.0; % Magnetomer time delay relative to IMU (sec)
param.fusion.magTimeDelay = 0.0; % magnetometer time delay relative to IMU (sec)
param.fusion.magFuseMethod = 1; % 0: 3-Axis field fusion with free declination, 1: 3-Axis field fusion with constrained declination, 2: magnetic heading fusion. (None)
param.fusion.magFieldError = 0.05; % Magnetic field measurement 1SD error including hard and soft iron interference. Used when magFuseMethod = 0 or 1. (gauss)
param.fusion.magHdgError = 0.1745; % Magnetic heading measurement 1SD error including hard and soft iron interference. Used when magFuseMethod = 2. (rad)
@@ -62,7 +62,7 @@ syms R_DECL R_YAW real; % variance of declination or yaw angle observation
syms BCXinv BCYinv real % inverse of ballistic coefficient for wind relative movement along the x and y body axes
syms rho real % air density (kg/m^3)
syms R_ACC real % variance of accelerometer measurements (m/s^2)^2
syms Kaccx Kaccy real % derivative of X and Y body specific forces wrt componenent of true airspeed along each axis (1/s)
syms Kaccx Kaccy real % derivative of X and Y body specific forces wrt component of true airspeed along each axis (1/s)
%% define the state prediction equations