Design and Implementation of An Inertial Navigatio
Design and Implementation of An Inertial Navigatio
net/publication/261482582
CITATIONS READS
9 199
3 authors, including:
Some of the authors of this publication are also working on these related projects:
Filtering and smoothing methods for hidden markov models View project
All content following this page was uploaded by Giorgio M. Vitetta on 08 June 2016.
Abstract—Inertial navigation systems for pedestrians are In this manuscript, starting from the methods and the results
infrastructure-less and can achieve sub-meter accuracy in the illustrated in [1], [6], we develop a novel INS based only
short/medium period. However, when low-cost inertial measure- on a low-cost IMU which performs PDR employing an EKF.
ment units (IMU) are employed for their implementation, they
suffer from a slowly growing drift between the true pedestrian Unlike previous approaches, the proposed solution relies on:
position and the corresponding estimated position. In this paper 1) Accelerometer and gyroscope measurements only (mag-
we illustrate a novel solution to mitigate such a drift by: netometer sensors are often completely unreliable in
a) using only accelerometer and gyroscope measurements (no indoor environments and other technologies for accurate
magnetometers required); b) including the sensor error model
parameters in the state vector of an extended Kalman filter; localization are expensive).
c) adopting a novel soft heuristic for foot stance detection and 2) A rigorous approach to the kinematic modelling of IMU
for zero-velocity updates. Experimental results evidence that our measurements; this involves the use of a large EKF state
inertial-only navigation system can achieve similar or better vector, including both physical variables (e.g., agent
performance with respect to pedestrian dead-reckoning systems position and heading) and quantities referring to the
presented in related studies, although the adopted IMU is less
accurate than more expensive counterparts. sensor error models (SEMs).
3) A new soft (rather than hard) heuristic for foot stance
I. I NTRODUCTION detection which increases the overall accuracy of the
INS.
In an inertial navigation system (INS) the position of a This manuscript is organized as follows. In Section II, the
mobile agent is tracked by means of an inertial measurement employed IMU and its calibration procedure are described.
unit (IMU) carried by the agent itself. IMU-based INSs can The proposed PDR-INS is illustrated in Section III, whereas
provide a low-cost and infrastructure-less solution to accurate its performance is assessed in Section IV. Finally, in Section
indoor navigation in the short/medium term. Unluckily, in V some conclusions are provided.
the medium/long term they usually suffer from a “drift” Notations: The probability density function (pdf) of a ran-
phenomenon [1], which originates from the noise and from any dom vector (rv) R evaluated at the point r is denoted as
small bias in the accelerations and angular velocities sensed f (r); N (r; m, Σ) denotes the pdf of a Gaussian rv R having
by the IMU. mean m and covariance matrix Σ, evaluated at the point
Recently, substantial attention has been devoted to pedes- r; kxk denotes the L2 norm of vector x; the expressions
trian dead-reckoning (PDR) INSs, where the prior knowledge {xi }ki=1 and x1:k both denote the sequence x1 , x2 , ..., xk .
of human walking patterns is exploited to reset, at least g , 9.80665 m/s2 denotes the gravitational acceleration;
partially, the accumulated errors due to various error sources finally, denotes the quaternion multiplication [7].
(e.g., the time-variant biases of IMUs). This approach has
been first proposed in [2], where the periods during which II. IMU D ESCRIPTION AND C ALIBRATION
the pedestrian’s foot is still on the ground are detected and In our PDR INS a mobile agent is equipped with a low-
exploited to introduce some corrections (the so-called zero cost IMU, called RazorIMU [8] and fixed on one of his/her
velocity updates (ZUPTs)) in the tracking filter. Further ad- feet using shoes’ laces (e.g., see [1], [3]–[5]). It is important
vances have been developed in [1], [3]–[5]. In particular, in to note that the IMU-sensed quantities are expressed in body
[1] and [3] an extended Kalman filter (EKF) processing IMU (or sensor) frame, i.e., they are referred to a right-handed
measurements exploits various heuristics to compensate for coordinate frame centered on the IMU with axes parallel to
the drift due to time-variant biases and measurement noise. the sensor sides; this frame is different from the so called
In [4] and [5], instead, additional measurements (from RFID navigation frame, which is a right-handed coordinate frame
devices) are adopted to mitigate the drift phenomenon. centered on some point of the navigation map and whose x
and y axes are parallel to Earth ground and z axis points away expensive dedicated hardware platform, so that b̂ω = 0 and
from Earth. the value provided in the gyroscope datasheet [8] for Ĝω have
The RazorIMU is a programmable device equipped with been adopted.
3-axis accelerometers, gyroscopes and magnetometers; our
III. T HE PDR INS
firmware outputs their measurements in “raw mode”, i.e., as
integer numbers, so that a calibration procedure is required. Our INS performs similarly to some other navigation sys-
The tri-axial accelerometer calibration procedure we adopted tems described in the technical literature (e.g., see [1]), but is
is similar to that described in [9], [10], but does not require based on a different approach and, in particular, on a set of
any additional hardware (besides the IMU itself). It relies on rigorous kinematic equations relating the quantities sensed by
the SEM (assuming a still sensor) [9], [10] the IMU with its orientation and 3D position. After describing
the structure of the state vector, the dynamic models and the
am = Ga a + ba + na (1) measurement models, we describe the use of an EKF for
where am ∈ Z3 is the vector of measured accelerations (in estimating the posterior distribution of the state vector. Finally,
body frame), a ∈ R3 is the vector of true accelerations (in we focus on a soft algorithm for foot stance detection.
body frame), Ga ∈ R3×3 is the gain matrix (diagonal if only A. State Vector
scale factors are accounted for, or a generic invertible matrix In our INS the state vector xk of the mobile agent wearing
if cross-couplings are also accounted for), ba ∈ R3 is the the IMU is defined as
bias vector, in body frame, and na ∈ R3 is the noise vector T
xk , pk , vk , ak , qkn.b , abk , ω b,b.n , bak , bω ∈ RD (7)
(in body frame) and is assumed to be additive Gaussian noise k k
(AGN) with covariance matrix Σa = σa2 I3 . The calibration where k is the time-index of the discrete-time tracking filter for
task for the accelerometer consists of estimating Ga and ba navigation, pk ∈ R3 , vk ∈ R3 and ak ∈ R3 are the position,
on the basis of N · P measured vectors {{am N P
i,p }i=1 }p=1 (in the velocity and the acceleration of the IMU sensor, measured
our setup N = 500 and P = 16), referring to P unknown in m, m/s and m/s2 , respectively; qkn.b ∈ H1 is a (random)
orientations of the still sensor (in the navigation frame). The quaternion representing the transformation which produces,
optimal (in the mean square error sense) estimators Ĝa and given a vector in navigation coordinates, a vector in body
b̂a of the terms Ga and ba appearing in (1) are given by coordinates [7]; abk and ω b,b.n ∈ R3 are the acceleration (in
k
P
X body frame) and the angular velocity (from body to navigation
a
Ĝa , b̂ = arg
min rp G̃, b̃, ām
p (2) frame, resolved in body coordinate frame [6]), measured in
(G̃,b̃)∈G×B p=1 m/s2 and rad/s, respectively; bak ∈ R3 and bω 3
k ∈ R are
m N the bias vectors of the accelerometer and of the gyroscope,
where ām
p is the mean of the measurements ai,p i=1 and expressed in body coordinate frame and measured in m/s2
2 and rad/s, respectively; finally, D = 25 is the size of xk .
rp G̃, b̃, ām , min G̃ã + b̃ − ām
(3)
p
ãp ∈A
p p
Note that: a) abk and ω b,b.n k are the (noisy) observable
variables; b) all the other variables can be pseudo-observed to
Once calibration is completed, the true acceleration vector
enhance the system stability whenever the foot is (approxim-
may be estimated as
ately) still; c) bak and bωk represent “fine” bias vectors, and play
â = Ĝ−1
a a m
− b̂a
. (4) a complementary role with respect to b̂a and b̂ω , respectively,
which account for time-variant and turn-on dependent biases;
Regarding the gyroscopes, a SEM similar to (1), i.e., d) the vector xk (7) has an heterogeneous structure, since it
ω m = Gω ω + bω + nω (5) consists of quantities of interest for the end-user of the INS
(namely, pk and vk ), quantities relating pk and vk to the
has been exploited to devise our calibration procedure; here sensor outputs (namely, ak , qkn.b , abk , ω b,b.n ) and quantities
k
ω m ∈ Z3 is the vector of measured angular velocities (in body related to the SEMs of accelerometers and gyroscopes (bak
frame), ω ∈ R3 is the vector of true angular velocities (in and bω k , respectively); e) including the IMU-sensed quantities
body frame), Gω ∈ R3×3 is the gain matrix (diagonal if only (abk , ω b,b.n ) in xk is important since impulsive noise (due to
k
scale factors are accounted for, or a generic invertible matrix hardware instability of low-cost sensors) may affect the IMU
if cross-couplings are also accounted for), bω ∈ R3 is the bias output and an accurate dynamic modelling of (k + 1)-th step
vector (in body frame), and nω ∈ R3 is the noise vector (in sensor orientation (qk+1 n.b
) requires the knowledge of the k-th
body frame) and is assumed to be AGN with covariance matrix step angular velocity (ω b,b.n ).
k
Σω = σω2 I3 . Similarly to (4), the true vector ω is estimated
as B. Dynamic and Measurement Models
ω̂ = Ĝ−1
ω ω m − b̂ω (6) The dynamic models adopted for the elements of xk (7)
can be summarised as follows. The Taylor-expansion models
where Ĝω and b̂ω denote the estimated bias vector and gain (e.g., see [6], [11, Sec. 4.3])
matrix of the gyroscope, respectively. However, unlike ac- 1
celerometer calibration, calibration of gyroscopes requires an pk+1 = pk + vk · Ts + ak · Ts2 + np,k (8)
2
and C. The EKF
vk+1 = vk + ak · Ts + nv,k (9) The goal of the INS is the sequential estimation of the
have been employed for the vectors pk and vk , respectively; hidden state vector xk representing the mobile agent given
here Ts denotes the sampling period of the INS (1/100 Hz the sequence of IMU measurements {z0:k }, i.e., the sequential
in our case) and the vectors np,k and nv,k are AGN terms estimation of the posterior pdf f (xk |z0:k ). Since our dynamic
affecting pk and vk , respectively. The model model is non-linear (see (10) and (11)), a non-linear filter, such
as an EKF, needs to be employed to solve this problem. It is
ak+1 = RT (qkn.b ) abk + g + na,k (10) important to mention that: a) the EKF alternates a prediction
has been used for ak , where R (qkn.b ) is the rotation matrix step with an update step; b) it estimates the first two moments
associated with the quaternion qkn.b (and thus representing of the posterior pdf f (xk |z0:k ), namely, the mean state vector
the transformation from navigation to body frame), g , x̂EKF EKF
k and the state vector covariance matrix P̂k , in a recursive
EKF EKF
T
[0, 0, −g] is the gravity vector in the navigation frame and fashion. In particular, given x̂k and P̂k , the EKF estimates
na,k is AGN. (prediction step) [12]
A further model relates the orientation of the sensor (rep- q EKF q T
x̂EKF EKF
k+1|k = q (x̂k ) P̂EKF
k+1|k = Jk P̂k (Jk ) + Q
resented by qkn.b ) to the angular velocity ω b,b.n
k and is given
by (e.g., see [6, Eq. (4.11), Eq. (4.20d)] and [7, Sec. 11.5]) where x̂EKF EKF
k+1|k and P̂k+1|k denote the (k+1)-th state mean and
T b,b.n
covariance, respectively, which can be predicted on the basis of
n.b
qk+1 = exp − ω k qkn.b + nq,k (11) the information available at the k-th step; here Jqk , ∂q(x)
2 ∂x
x̂k
where nq,k is AGN. is the D × D Jacobian matrix1 for our (non-linear) dynamic
Finally, the simple “random walk” models model. Then, the EKF evaluates (update step) [12]:
abk+1 = abk + na,k (12) sk+1|k = zk − r x̂EKF
k+1|k
b,b.n b,b.n T
ω k+1 = ω k + nω,k (13) Sk+1|k = Jrk P̂EKF r
k+1|k (Jk ) + R
bak+1 = bak + nba ,k (14) Kk+1|k = P̂EKF r −1 T
k+1|k (Jk ) Sk+1|k
bω ω
k+1 = bk + nbω ,k (15)
x̂EKF EKF
k+1 = x̂k+1|k + Kk+1|k sk+1|k
have been selected for the filtered states abk b,b.n
and ω k , and for P̂EKF r EKF
k+1 = (I − Kk+1|k Jk )P̂k+1|k
the sensor biases bak and bω k , where the {n·,k } terms denote
AGN contributions. where rk+1|k is the innovation residual and Sk+1|k its estim-
Regarding measurements models, simple linear relations ated covariance matrix, Kk+1|k is the Kalman gain, x̂EKF
k+1 is
involving only quantities in the body frame may be adopted, the new estimate of the state vector mean and P̂EKF is its
k+1
thanks to the structure chosen for xk (7): r ∂r(x)
estimated covariance matrix; moreover, Jk , ∂x is
x̂k+1|k
zfk = abk + bak + ma,k (16) the M × D Jacobian matrix for the measurement model.
zω b,b.n
+ bω It is worth noting that: a) in any EKF, at the end of the k-th
k = ωk k + mω,k (17)
iteration only the quantities x̂EKF EKF
k and P̂k need to be saved
Here zfk = â (see (4)) and zω
k = ω̂ (see (6)) denote the and this substantially simplifies the INS implementation; b)
calibrated force and angular velocity measurements provided given these quantities, the posterior
distribution f (xk |z0:k )
by the IMU and the vectors ma,k , mω,k represent the AGN is estimated by the EKF as N xk ; x̂k , P̂k ; c) the ini-
EKF EKF
terms affecting the measurements. tialisation of the INS represent a critical task, since initial
The dynamic models (8)-(15) can be summarised as errors cannot be mitigated by the EKF. As far as the last
f (xk+1 |xk ) = N (xk+1 ; q (xk ) , Q) (18) point is concerned, P̂EKF
0 = Q has been selected for the initial
covariance matrix, whereas the initial state vector x̂EKF 0 has
whereas the measurement models (16)-(17) can be summarised been estimated assuming the foot still in a known position;
as unfortunately, further details cannot be provided for space
f (zk |xk ) = N (zk ; r(xk ), R) (19) limitations.
where zk , [zfk , zω k]
T
∈ RM (with M = 6), the vector D. Foot Stance Detection
functions q (·) and r(·) are defined by (8)-(15) and by (16)-
Even if the EKF illustrated in the previous Paragraph
(17), respectively, and Q and R are D × D and M × M
includes the sensor biases bak and bω k in xk , due to the
diagonal covariance matrices for the AGN terms. Regarding
lack of robust models and, in particular, to the lack of bias
these matrices, it is worth mentioning that a) they may have a
observations, the tracking of such quantities mitigates but
strong impact on the EKF stability and b) the choice of their
diagonal values can be based, in practice, on some careful 1 This matrix cannot be put in a simple analytical form, so that its evaluation
tuning procedure (involving D + M = 31 parameters). requires use of computer algebra systems.
does not completely compensate for sensor inaccuracies. In 0 = zω = ω b,b.n
k + mω,k (26)
practice, the residual biases may quickly disrupt the INS â = zbk
a
= bak n.b
− R (qk ) g + mba ,k (27)
tracking since their effects accumulate over time. The effects ω
of these error sources can be mitigated exploiting some a ω̂ = zbk = bωk + mbω ,k (28)
priori knowledge about the typical human walking pattern where s is the time step corresponding to the beginning of the
and, in particular, the fact at the end of each step the foot current “foot still event” (so that p̂EKF
s represents the position
lies approximately still on the ground for a short period where the foot is still) and the vectors {m·,k } denote the
(typically, 0.1 − 0.2 s); during such a period, the value of AGN terms of the pseudo-measurement models. To avoid
most of the elements of xk are known a priori and the EKF discontinuities in the tracked path, the variance of these noise
state can be adjusted accordingly. In practice, the EKF can be terms is modulated in a soft way on the basis of the SFSk
provided with some “pseudo-measurements”, usually known signal. In practice, the soft ZUPT pseudo-measurement model
as ZUPTs [2], whenever a detection algorithm, processing the
IMU measurements in parallel to the EKF, detects a “foot still f (zpk |xk ) = N (zpk ; rp (xk ), [1 + K p (1 − SFSk )] Rp ) (29)
event”. In our work, a foot stance detection algorithm inspired ω p
is adopted where zpk , [zxy , z z , zv , ..., zbk ]T ∈ RM (with
by [1, Sec. II.C] has been used.
This algorithm evaluates four M p = 20); Rp is the diagonal covariance matrix collecting all
logical “condition signals” Ci1 , Ci2 , Ci3 , Ci4 associated with p
variance values of the {m·,k } terms; the vector function
r (·)
the IMU measurements zk and generated as p p
can be easily derived from (20)-(28); Jrk , ∂r∂x(x) is
(
f
x̂k+1|k
1 1 γ a, min <
zi
< γa,max the M p × D Jacobian matrix associated with the measurement
Ci ,
0 otherwise model (29) and K p is a parameter introduced to modulate
( the variance of ZUPT pseudo-measurements. Note that the is
2 1 σ zfi−S:i+S < σa,max the value of K p , the higher will be the variances associated
Ci ,
0 otherwise to zpk pseudo-measurement when SFSk = γSFS ; then, as SFSk
( goes from γSFS to 1, the variances associated to zpk decrease
1 kzω i k < γω,max
Ci3 , smoothly to the values collected in Rp . This approach ensures
0 otherwise that the tracked state vector x̂EKF
( k smoothly transitions to the
“reset” values defined by (20)-(28), when ZUPTs are injected
4 1 σ zω i−S:i+S < σω,max
Ci , in the EKF.
0 otherwise
Finally, it is worth noting that the pseudo-measurements
for i ∈ {k − F, ..., k + F }, where σ(x1 , x2 , ..., xN ) de- (20), (21), (22), (27) and (28) allow to “observe” otherwise
notes the standard deviation of the magnitude of the vectors unobservable state vector components and thus to “reset”
{x1 , x2 , ..., xN }, F is the size of the windows used for step errors they might contain.
detection, S is the size of the window used for the computation
of σ(·), and γa,max , σa,max , γω,max and σω,max represent proper IV. I NDOOR NAVIGATION T ESTS
thresholds. An hard detection algorithm based on the condition An experimental campaign has been carried out to acquire
signals defined above has been proposed in [1, Sec. II.C]; various sets of measurements generated by an agent equipped
it decides
Pk+F that1 the foot is “still”, during the k-th time step, with the IMU described in Section II and repeating the same
2 3 F
if j=k−F Cj Cj Cj > 2 . Here, we propose to use a soft test trajectory Nrep = 10 times in an indoor environment.
variant whose output is the soft foot still (SFS) signal These measurement sets have been stored on a notebook
k+F and then processed offline. The test trajectory contains long
1 X straight lines, 90 deg turns, short and long stops (e.g., to turn
SFSk , Ci1 Ci2 Ci3 Ci4
F on/off lights, to open/close doors, etc); the initial and final
i=k−F
positions coincide and the total travelled distance (TTD) LTTD
which ranges, for the k-th time step, from zero (moving foot)
associated to such test walk is LTTD ' 300 m.
to one (the foot is very likely to be still on the ground). Then,
An example of the resulting INS-estimated agent path2
whenever SFSk > γSFS (γSFS ∈ [0; 1] is a fixed threshold), a
is shown in Fig. 1. It is easy to recognize that the “drift”
“foot still event” begins and the EKF is fed with the pseudo-
phenomenon mentioned in Section I is present, although in
measurements
a very limited amount (specially considering the many loops
xy walked in the same verse by the agent).
[p̂EKF
s ]1:2 = z = [pk ]1:2 + mxy,k (20)
0 = z z = [pk ]3 + mz,k (21) To quantify
the performance
of the INS usually the quantity
1
EKF
TTD , LTTD p̂0 − p̂EKF
is exploited [1], where Ns is the
0 = zv = vk + mv,k (22) Ns
last time step in the recorded measurement set; of course,
a
0 = z = ak + ma,k (23)
2 Note that the values of the parameters introduced throughout the paper
ab T
−g = z = R (qk n.b
) abk
+ mab ,k (24) and used to produce such results have been properly tuned by means of an
b automated search procedure, but the resulting values cannot be shown for
kgk = za
b
=
ak
+ mab ,k (25) space limitations; see [13] for more details.
45
INS
IMU ARW/BI coefficient Unit
40 INSdcheckpoints √
Grounddtruthdcheckpoints N = [5.2, 12.1, 5.6] · 10−3 ( ◦ /s) / Hz
RazorIMU
35 4 B = [3, 18, 4.4] · 10−3 ◦ /s
gyro
4
√
30 N = [45, 41, 36] · 10−3 ( ◦ /s) / Hz
Xsens MTi
25
B = [7, 7, 5] · 10−3 ◦ /s
√
N = [5.5, 5.1, 7.6] · 10−3 m/s2 / Hz
yd[m]
20 RazorIMU
1
B = [609, 590, 732] · 10−6 m/s2
accel.
1
15 2 3 √
N = [900, 950, 850] · 10−6 m/s2 / Hz
10 3
Xsens MTi
2
B = [230, 270, 290] · 10−6 m/s2
5
Table I
0 C OMPARISON BETWEEN THE R AZOR IMU AND THE X SENS MT I IMU.
-5
0 10 20 30 40 50 60 70
xd[m]