3.1. Experimental Setup
To validate the advantages of the proposed rapid continuous trajectory reconstruction method in terms of measurement efficiency and accuracy, we designed and constructed an experimental platform to simulate underground boreholes. A comparative study was then conducted against the conventional static point-by-point measurement method commonly used in mining.
First, regarding the construction of the experimental platform, it is primarily composed of three main components: a custom-designed borehole surveying robot, a simulated borehole pipe, and a data acquisition system. As shown in
Figure 10a, the robot utilizes a wheeled structure with multi-point elastic support. This design allows the robot to adaptively maintain its body centered within a certain range of pipe diameters through the passive extension and retraction of its support wheels, and to provide stable wall contact pressure for the high-friction-coefficient driving wheels, enabling it to travel inside the pipe at a stable speed. Its core sensing unit is the aforementioned nine-axis MEMS-IMU module, which is rigidly fixed at the robot’s geometric center with its Y-axis aligned with the robot’s forward direction. As shown in
Figure 10b, two PVC pipes, with lengths of 10 m and 12 m, respectively, were set up to simulate underground mine boreholes. Their geometric curved shapes were preset to mimic realistic borehole trajectories. Discrete points were marked along the pipeline’s axis, and their 3D spatial coordinates were extracted to construct the reference trajectory. A displacement sensor was mounted at the pipe entrance, with the end of its draw-wire rigidly connected to the robot’s rear. It was used for real-time measurement of the robot’s traveled distance along the pipe’s axis. To ensure measurement accuracy, the wire outlet was kept collinear with the pipe’s axis, and the angle between the wire and the pipe inlet plane was controlled within 0° to 2°. This setup is designed to minimize friction and lateral force components. To ensure communication reliability in potentially complex electromagnetic environments and over long-distance transmission, all sensors are connected to the data acquisition computer via the RS-485 bus, which supports long-distance transmission, and communicate using the industry-standard Modbus RTU protocol, thereby guaranteeing the packet-loss-free reception of the high-frequency data stream and timestamp synchronization.
Based on the experimental platform described above, the continuous measurement method proposed in this paper aims to achieve rapid and accurate reconstruction of the borehole trajectory. First, during the measurement preparation stage, the measurement unit is kept stationary at the pipe entrance to collect an initial set of IMU data. This data is used not only to calculate the gyroscope’s static bias but also to solve for the initial attitude quaternion, . Subsequently, during the trajectory measurement stage, the robot is operated to travel through the entire pipeline in a single, complete pass at a nearly constant velocity (approx. 0.2 m/s). Throughout this process, both the IMU and displacement data are recorded simultaneously. Finally, in the data processing and trajectory reconstruction stage, a two-step pre-processing is performed. First, the calculated static bias is used to compensate the gyroscope’s angular velocity data. Subsequently, a low-pass filter is applied to suppress high-frequency noise in the data. Following the data pre-processing, the displacement data is interpolated using a cubic spline method. Based on the robot’s smooth motion and the extremely short 50 ms sampling interval, this interpolation can generate with high precision bore depth values that are precisely synchronized with the IMU data at each moment, rendering the introduced error negligible. Simultaneously, the attitude quaternion sequence, , is computed from the IMU data via a complementary filter algorithm. Each quaternion in this sequence is then converted into a DCM, from which the pipeline’s inclination and azimuth angles at the current measurement point are resolved. Finally, the complete borehole trajectory is reconstructed through an iterative process based on the Mean Angle Tangential method. This involves calculating the 3D coordinate increment in the global frame at each timestamp using the attitude angles and the corresponding depth increment. By continuously accumulating these small displacement increments, the full trajectory is formed. A key advantage of this method is its ability to complete the survey in a single, continuous pass, which significantly enhances measurement efficiency.
Under the same experimental environment and sensor configuration, a control experiment was designed based on the operational principle of common mining inclinometers. This experiment employs a static, point-by-point discrete measurement mode, hereinafter referred to as the ‘discrete inclinometry method’. In this control experiment, the robot advances along the pipe’s axis in a step-wise manner. Whenever the displacement sensor reading increases by a fixed step length (set to ∆L = 10 cm in this study), the robot is brought to a complete stop. During this stationary period, a set of accelerometer and magnetometer readings is collected and averaged to mitigate sensor noise. Subsequently, the attitude angles at the current measurement point are calculated using analytical formulas derived for the specific coordinate systems defined in this paper, which represents a common approach for mining inclinometers [
8]. The equations are as follows:
The roll angle (
) and pitch angle (
) can be determined from the tri-axial accelerometer outputs
using the following equations:
By combining the roll (
) and pitch (
) angles obtained from the accelerometer with the tri-axial magnetometer outputs
, the yaw angle (
) can be calculated as follows:
Finally, at each measurement point, the calculated attitude angles are used to resolve the fixed step increment (∆L) into its 3D coordinate components in the global frame. The full borehole trajectory is then constructed by iteratively accumulating these coordinate increments in a piece-wise manner.
To systematically validate the effectiveness and feasibility of the method proposed in this paper, a comparative analysis of the two algorithmic approaches will be conducted. This comparison will focus on several key aspects, including attitude estimation accuracy, trajectory continuity, and the ability to suppress error accumulation.
3.2. Trajectory Error Analysis
Due to the combined effects of sensor noise, system coupling errors, and external disturbances, the calculated borehole trajectory inevitably deviates from its true path. This deviation manifests as spatial position offsets, local oscillations, or trend drift. To evaluate the accuracy of the proposed algorithm, it is necessary to quantitatively analyze the 3D trajectory error from multiple perspectives, including its spatial distribution, statistical characteristics, and global deviation trends.
First, a segment-wise calibration method was employed to establish a reference trajectory. Using a ruler, the 3D coordinate sequence of the red markers on the pipe, , was acquired. This set of points constitutes the discrete reference trajectory, describing the actual geometric path of the pipeline. The coordinate sequence of the calculated trajectory is denoted as . To ensure a comparable sampling resolution along the pipe’s primary axis, cubic spline interpolation was used to perform curve fitting and resampling on both trajectories, such that .
To establish a unified longitudinal interval for error measurement and to avoid comparison errors arising from inconsistent endpoints, the initial orientation of the pipe (the Y-axis) was used as a reference. The upper bound for comparison was set to the minimum of the two trajectories’ final endpoint projections onto the Y-axis. The length of the error calculation interval is thus defined as:
Starting from the same initial point, a total of
error measurement points are defined along the Y-axis at fixed intervals of ∆L. The longitudinal position of each sampling point is given by:
For each longitudinal position
, a corresponding point is found on both the reference and the calculated trajectories whose Y-axis projection is closest to this value:
The 3D Euclidean error,
, at the
k-th measurement position is then defined as:
Finally, the trajectory error is quantitatively evaluated from different perspectives using three metrics:
for the maximum deviation,
for the overall average deviation, and
for the error fluctuation. Their formulas are as follows:
3.4. Trajectory Reconstruction Results and Performance Discussion
To validate the effectiveness of the borehole trajectory reconstruction method proposed in this paper, a comparison was made between the experimentally obtained trajectories and the reference trajectory, as shown in
Figure 12. The red curve represents the reference trajectory of Pipe 1. The blue and black curves depict the trajectories obtained using the proposed complementary filter-based continuous reconstruction method and the control discrete inclinometry method, respectively. The blue curve accurately resolves the geometric profile of the pipe, with its trend showing high consistency with the reference path. In contrast, the discrete inclinometry method exhibits an azimuth deviation from the very beginning of the measurement. As the measurement distance increases, its issues with error accumulation and susceptibility to environmental disturbances become more pronounced.
This is particularly evident in the middle section of the pipe (approximately the 5–8 m segment), where the trajectory displays irregular lateral drift and path tortuosity, which completely contradicts the smooth profile of the pipe. The root cause is that the discrete inclinometry method directly relies on quasi-static, deterministic observations from the accelerometer and magnetometer to calculate the azimuth angle. In the complex experimental environment, the magnetometer’s readings are corrupted by a combination of its own high-frequency random noise and local, time-varying magnetic field distortions from the surroundings. Lacking an effective filtering and fusion mechanism, this method incorrectly interprets these significant error components as heading changes, while the attitude error accumulates through a path with no feedback, ultimately leading to severe geometric distortion of the trajectory.
Figure 13 further presents the projections of the reconstructed trajectories onto the XY (horizontal) and YZ (vertical) planes. This 2D perspective allows for a deconstruction of the 3D error characteristics and path deviation trends.
In the XY-plane projection (
Figure 13a), which illustrates the lateral continuity and deviation of the trajectories, the path reconstructed by the complementary filter fused with high-frequency displacement data is notably smoother, showing no abrupt changes or sharp angles. In contrast, the trajectory from the discrete inclinometry method exhibits a large lateral deviation from the very beginning. As the path extends, this issue is compounded by multiple “misalignments” and “offsets” at the pipe connection points, leading to continuous error accumulation.
Figure 13b highlights the differences between the two methods in the vertical direction. The projection curve generated by the proposed method maintains a similar undulation rhythm to the reference path. Although a progressive vertical deviation appears in the latter half of the trajectory, its overall smoothness is well-preserved. The YZ-plane projection of the discrete method, however, suffers from two major issues. First, due to its significant lateral tortuosity in the XY-plane, its effective forward travel distance along the Y-axis is severely shortened. This directly results in its trajectory in the YZ projection failing to reach the endpoint, making it shorter than both the proposed method’s and the reference path’s trajectories. Furthermore, in terms of morphology, its path is not a smooth curve but rather a polyline composed of discrete measurement points, characterized by irregular serrations and severe distortion.
To transform the preceding qualitative morphological comparison into a precise quantitative evaluation,
Figure 14 illustrates the evolution of the X-direction error, Z-direction error, and the cumulative spatial error for different methods as a function of the Y-axis coordinate during the trajectory reconstruction process.
In the lateral direction (X-direction), the error of the proposed method (blue curve) remains consistently within 0.2 m, exhibiting almost no significant drift. This result is in complete agreement with its smooth trajectory that closely follows the reference path in the XY projection. In contrast, the lateral error of the discrete inclinometry method (red curve) increases rapidly at the initial stage of the measurement, exceeding 0.5 m at Y = 1 m. It then drops sharply before embarking on a continuous accumulation process after Y = 2.3 m, accompanied by large oscillations. The maximum deviation exceeds 2 m, eventually stabilizing at 1.6 m at the end of the measurement.
In the longitudinal direction (Z-direction), the errors of both methods show a cumulative trend with distance. The longitudinal error generated by the proposed method grows very gently and smoothly, reaching a final error of 0.25 m. In comparison, the final error for the discrete inclinometry method is 0.31 m. Although this value is not substantially different from that of the proposed method, its error curve does not exhibit smooth growth; instead, it is characterized by noticeable irregular fluctuations throughout the overall accumulation process.
The cumulative error curve reveals that the proposed method maintains a low level of accumulated error throughout the entire range, without showing a clear distance-dependent cumulative drift. The cumulative error curve of the discrete inclinometry method closely resembles its lateral error curve, indicating that the lateral error component, induced by incorrect heading estimation, is dominant. This error exhibits an approximately linear or even super-linear accumulation trend, reaching a maximum value of 2.064 m at Y = 7.5 m.
To provide a more concise and objective evaluation of the overall algorithm performance from a statistical perspective,
Figure 15 presents a visual comparison of key statistical metrics for the directional errors of the two methods using a bar chart. The results show that the proposed method, which fuses a complementary filter with high-frequency displacement data, comprehensively outperforms the traditional discrete inclinometry method across all metrics.
Specifically, the proposed algorithm significantly enhances the system’s robustness by reducing the total maximum error from 2.078 m to 0.308 m, effectively suppressing the occurrence of extreme errors. In terms of accuracy, the total mean error is reduced from 1.028 m to 0.153 m. Furthermore, regarding the root mean square error (RMSE), which reflects the error’s dispersion and overall stability, our algorithm’s total RMSE is only 0.079 m, far lower than the control algorithm’s 0.625 m. This indicates that its output not only has a smaller deviation but also exhibits lower volatility. These findings provide strong evidence that the proposed fusion strategy can effectively overcome the drift issues of the traditional method, achieving a comprehensive performance improvement in positioning accuracy, stability, and robustness.
Building upon the measurement accuracy previously demonstrated in horizontal boreholes, this experiment was designed to further validate the adaptability and robustness of our method for long-distance, complex trajectories with large angle variations. For this purpose, Pipe 2 was used, which is longer and features a significant spatial geometry change—transitioning from a horizontal section to a steeply inclined ascent. This setup imposes more stringent requirements on the accuracy and stability of the trajectory reconstruction algorithm.
Figure 16 presents the trajectory reconstruction results for Pipe 2 from both the proposed complementary filter-based fusion method and the traditional discrete inclinometry method. As shown in the figure, the trajectory reconstructed by our proposed method (blue curve) exhibits a high degree of consistency with the reference trajectory (red curve) in its overall trend. Whether in the initial horizontal segment or the subsequent inclined ascending segment that undergoes a large spatial bend, our method’s trajectory accurately reflects the 3D orientation and morphological features of the pipe. This indicates that the precise attitude angles obtained via the complementary filter provide a reliable directional reference for the displacement vectors in 3D space. Concurrently, the high-frequency displacement fusion strategy ensures that these vectors are accurately accumulated in the global coordinate system, effectively suppressing error divergence.
In contrast, the discrete inclinometry method, although showing relatively high accuracy in the initial stage, reveals its inherent limitations as the path length increases. Specifically, during long-distance dynamic operation, the complex magnetic environment and dynamic disturbances cause a continuous cumulative drift in the azimuth angle. Furthermore, the motion-induced acceleration itself becomes a major source of interference for the inclination measurement, thereby significantly degrading its estimation accuracy. As depicted by the black curve in
Figure 16, after the travel distance exceeds 1 m, the black curve progressively deviates from the reference trajectory, with errors accumulating rapidly. The trajectory’s azimuth and inclination undergo drastic changes, causing it to exhibit large-amplitude, irregular oscillations in 3D space and completely lose its expected smoothness.
To conduct a more detailed qualitative analysis of the aforementioned error characteristics from different perspectives,
Figure 17 provides a comparison of the trajectory projections from the two algorithms onto the XY and YZ planes for the Pipe 2 experiment.
The trajectory reconstructed by the proposed algorithm exhibits a smooth and continuous curve in both orthogonal projection planes, free of any serrated or abrupt changes. It demonstrates an exceptionally high responsiveness to changes in the path’s geometry. When the reference trajectory undergoes a lateral turn at Y = 6 m and an upward incline at Y = 8 m, the algorithm achieves synchronous and precise tracking, with only minor deviations throughout the process, strongly demonstrating that the robot platform’s multi-point elastic support structure effectively absorbed the minor vibrations at the pipe joints, while the complementary filter algorithm accurately tracked the rapid angular changes, and the millimeter-level spatial sampling density ensured the high-fidelity reconstruction of the sharp bend’s geometry.
Conversely, the discrete inclinometry method suffers from rapid accumulation of lateral errors due to its azimuth estimation inaccuracies, causing its trajectory to fail to match the direction of the reference path and exhibit large-scale, irregular oscillations. Although the trajectory shows an upward-inclining trend to some extent, thanks to the use of the accelerometer for inclination measurement, its projection on the YZ-plane presents the same issue observed in the Pipe 1 experiment. Specifically, its effective forward travel distance along the Y-axis is severely shortened. This results in the reconstructed trajectory in the YZ projection being significantly shorter than those of the proposed method and the reference path, failing to extend to the final endpoint.
To further refine the preceding analysis on geometric deviations and to investigate the distribution and characteristics of errors in different dimensions,
Figure 18 provides a quantitative analysis of the reconstruction errors from both algorithms in the Pipe 2 experiment. It presents the evolution of the X-direction, Z-direction, and total errors.
The error of the proposed algorithm demonstrates stability across all dimensions. Although its lateral (X-direction) error shows an extremely slow linear growth trend with travel distance, reaching 0.368 m at the end of the path, it does not exhibit uncontrolled non-linear divergence like the control method. The vertical (Z-direction) error increases slowly with distance, peaks at 0.168 m at Y = 8 m, and then flattens out with a slight decrease, reducing to 0.06 m at Y = 9.3 m. The growth of the total error is gentle and controllable, remaining within an acceptable range.
In stark contrast, the lateral (X-direction) error of the discrete inclinometry method shows a distinct point of abrupt change at Y = 1.65 m, from which the error begins to grow rapidly in a non-linear fashion, eventually stabilizing above 3 m. Its vertical error exhibits a slow growth trend before Y = 6.7 m, after which it follows a nearly linear, monotonically increasing trend with distance, with the final error exceeding 0.7 m. The total error curve closely resembles the lateral error curve, also increasing sharply at Y = 1.6 m and reaching a final error of nearly 3.5 m.
To accurately assess the overall error and stability of the two algorithms from a macroscopic perspective,
Figure 19 further summarizes and compares their key error statistical metrics in each direction. First, regarding the maximum error metric, the proposed algorithm’s errors in the lateral, vertical, and total components are 0.368 m, 0.168 m, and 0.373 m, respectively. The error peaks are constrained to within 0.4 m. In contrast, the maximum lateral and total errors of the control method are as high as 3.466 m and 3.469 m, respectively, confirming that its estimation system lacks the necessary robustness for long-distance dynamic scenarios.
Second, concerning the mean error metric, which reflects the overall error level, the total mean error of our algorithm is only 0.180 m and remains on the same order of magnitude as its maximum error. The discrete inclinometry method, however, has a mean error of 2.089 m, indicating that its reconstructed trajectory exhibits a severe overall deviation.
Furthermore, for the root mean square error (RMSE), an indicator of error dispersion, our algorithm’s total RMSE is 0.121 m, a value close to its mean error. This suggests the absence of extreme outliers that could significantly impact the overall trajectory accuracy. The traditional method’s RMSE, in contrast, is 1.115 m. This quantitative comparison of key metrics—from maximum deviation and overall level to error distribution—comprehensively and forcefully demonstrates the advantages of our proposed algorithm in terms of estimation accuracy, stability, and robustness.
In addition to its significant advantages in measurement accuracy and robustness, the method proposed in this paper also achieves a substantial improvement in surveying efficiency. The following section provides a comparative estimation of the time cost for the data acquisition phase of both methods, based on the experimental parameters.
The proposed method employs a continuous measurement mode, completing the data acquisition in a single, uninterrupted pass. According to the experimental setup, the robot travels at an average velocity of approximately 0.2 m/s. Therefore, the theoretical time required to survey the 10-meter-long Pipe 1 is about 50 s, and for the 12-meter-long Pipe 2, it is about 60 s. In contrast, the time cost of the traditional discrete inclinometry method consists of the cumulative cycles of ‘travel-stop-static measurement’. For Pipe 1, with a measurement step of 10 cm, a total of 100 measurements are required. Based on experimental records, the average time for each cycle is approximately 3.5 s, resulting in a total measurement time of up to 350 s.
This quantitative estimation reveals that, for the same surveying task, the proposed method significantly reduces the time cost. Furthermore, it lowers the need for on-site manual intervention, thereby reducing labor costs and the potential for operational errors.