differ-ent acceleration magnitude behaviors are illustrated in Figure 5.5. The Weinberg step length estimation formula shown in Equation (1.8) relates the trunk vertical accel-eration to the horizontal displacement by assuming the sensor attached to the upper body. This assumption no longer holds when the sensor (i.e., the embedded IMU in the smartphone) is hand-held. In this case, the formula has to be calibrated not only according to the test subject walking characteristic, but also according to the sensor degrees of freedom.
The idea behind the proposed approach is to adopt a constant K for the step length estimation which relies on the acceleration magnitude as “motion quantity indicator.”
Experimental tests have lead to the development of the following novel formula which allows one to automatically calibrate the step length estimator according to the smartphone position:
K = β · 1
pa3 m,max(i) (5.18)
where: β is a per-subject estimated constant (dimension: [(m/s2)1/3]); am,max(i) is the maximum value in the acceleration magnitude during the considered i-th step (dimension: [m/s2]). Experimentally, it has been found that, for the test subject whom the following results refer to, β = 0.7 (m/s2)1/3 is an efficient choice.
In the following section, the results have been obtained by considering multiple experimental set-ups with a single test subject.
5.3 Performance Analysis
The experiments have been carried out in the Department of Engineering and Ar-chitecture of the University of Parma (latitude: 44.765277, longitude: 10.308277), along the main corridor, where markers (i.e., paper tags attached to the corridor’s walls) were placed every 5 m. In order to obtain accurate measurements, the final distance (i.e., the one between the final marker and the ending position) has been measured with a measuring tape. Every test has been video recorded to obtain (as a reference) the precise step count. As shown in Figure 5.6, the corridor length is
Figure 5.6: Department of Engineering and Architecture of the University of Parma.
The trials have been carried out in indoor environment along the main corridor (highlighted in red) which has approximate length of 188 m.
5.3. Performance Analysis 101
Table 5.2: System performance: smartphone in texting/navigation mode.
# Step Detected step True dist. [m] Estimated dist. [m] %on dist.
S7 N6 5T S7 N6 5T S7 N6 5T S7 N6 5T
20 20 21 20 13.9 13.5 12.3 13.3 12.4 12.8 4.3 8.1 4.6
50 49 52 52 34.5 33.1 33.5 32.9 31.7 35.9 4.6 4.1 7.1
100 101 104 96 69.7 65.7 61.4 68.2 67.9 63.2 2.1 3.3 2.9
500 503 505 491 348.5 352.2 361.2 340.7 370.5 350.3 2.3 5.2 3.2
Table 5.3: System performance: smartphone in phoning mode.
# Step Detected step True dist. [m] Estimated dist. [m] %on dist.
S7 N6 5T S7 N6 5T S7 N6 5T S7 N6 5T
20 20 21 21 14.2 13.5 13.6 14.9 14.1 13.8 4.9 4.3 1.7
50 50 49 48 35.4 33.7 33.8 34.9 35.3 33.8 1.4 4.7 0
100 101 97 101 69.1 66.7 66.5 70.4 69.4 71.2 1.8 4 1.6
500 502 498 504 351.3 345.3 352.6 365.3 332.5 344.8 3.9 3.7 2.8
approximately 188 m: for the longest tests (i.e., the walks with 500 steps), the subject has performed a single curve with no step, namely by turning in a single movement. In order to evaluate the step detection accuracy together with the step length estimation capability, several tests have been performed. The data have been analyzed through a Matlab-based script. An Android application has been developed in order to test the navigation algorithm in real-time.
5.3.1 Experimental Results
In Table 5.2 and Table 5.3, the results obtained in the experimental trials are summa-rized. The experimental data have been organized according to the smartphone use modes.
In Table 5.2, the presented results show the algorithm effectiveness using the smartphones in texting/navigation mode. As one can see, the proposed approach can correctly detect almost all the steps, with an error, with respect to the total number of steps, which is always below 4%. These results are valid for all the three tested smartphones, i.e., the accuracy is independent of the hardware platform.
In Table 5.3, the performance results with the smartphone in phoning mode are
shown: one can observe the algorithm capability to accurately identify the steps independently of the smartphone position. This is due to the linear acceleration estimation procedure presented in Subsection 5.2.1, which allows to estimate the vertical orientation with respect to the Earth reference system. In this experimental test, as already highlighted for the previous results in Table 5.2, the proposed approach has been able to identify the steps with high accuracy, namely, with a relative error below 3%. In Table 5.2 and Table 5.3, it is possible to observe that the estimated distance error varies when the step number varies. This is due to error averaging over a path: more precisely, a single step length estimation error has a higher impact in shorter paths than in longer ones.
Considering the performance in terms of path length estimation, the algorithm presents a significant variance in the estimated distances, due to a high vertical displacement variability of the smartphone. Nevertheless, as can be observed in Table 5.2 and Table 5.3, it can automatically adapt the step length estimation to the specific smartphone mode under use. In fact, the errors are comparable in both tables, which means that the bias is introduced by the common walking pattern dynamics, but not from the step length estimation formula, which is thus independent of the smartphone placement. The average (relative) error in Table 5.2 is approximately 4.3% of the total traveled distance, whereas in Table 5.3 the average (relative) error is below 3%. In Table 5.3, it can also be observed that the results are comparable between the three smartphones: this proves that the algorithm performance is independent of the hardware, thus making the proposed approach applicable to multiple devices.
It is important to remark that no modification in the step length estimation algo-rithm is needed to adapt the Weinberg formula to the smartphone use mode. In fact, the novel strategy introduced in Equation (5.18), based on the acceleration magni-tude, enables the automatic correction of the constant K depending on the “oscillation quantity.”
5.3.2 Android Application
The Android application has been developed in order to verify the algorithm capability to reconstruct the traveled path in real-time and to provide a continuous feedback to the
5.3. Performance Analysis 103
Figure 5.7: A screen capture of the Android Application. The top graph represents the acceleration magnitude am in blue, and the vertical acceleration a(W)z,lin. The light blue dots represents the maximum az,max and the minimum az,min in the vertical acceleration. The bottom graph represents the estimated path. The x and y axis are stated in meters.
user. In the application layout, shown in Figure 5.7, one can see (top) the acceleration (linear vertical and magnitude) with step detection/gait segmentation and, (bottom) the estimated path.
The top graph is updated every time a new sample is collected from the sensor.
As soon as the algorithm detects the maximum az,max(i)or the minimum az,min(i) in the vertical acceleration during the i-th step, a blue dot is displayed at the cor-responding coordinates in the graph. Since the Android operating system does not ensure a constant sampling rate, the proposed algorithm sets the sampling rate to the maximum possible rate (i.e., SensorManager.SENSOR_DELAY_FASTEST) which corresponds, for the considered smartphones, to approximately 150 ÷ 200 Hz.
In Figure 5.7, right under the acceleration graph (on top), the current step length and the current yaw (heading) are displayed. These are updated every time a “Step terminal phase” is completed. Moreover, the application allows to set the algorithm key parameters such as: the minimum distance between two subsequent peaks, denoted as mind(MIN_PEAK_DIST); the constant β (K_WEINBERG) needed to evaluate K according to Equation (5.18); and the difference threshold between the acceleration magnitude and the vertical acceleration, denoted as thd (STEP_DECT_SENS).
In the bottom graph in Figure 5.7, the current coordinates, with respect to the starting point, expressed in meters—the default starting point is the axis origin p(0) = (0,0)—are displayed. In the path shown in the bottom graph, instead, every point represents a step.