1. Introduction
The autonomous driving and operation of Autonomous Mobile Systems (AMSs) are crucial to improving operational efficiency, addressing labor shortages, and enhancing safety in high-risk operations [
1,
2,
3,
4], constituting a major research trend across industrial and agricultural domains. Positioning and attitude determination constitute the fundamental technical basis for AMS to achieve environmental perception, path planning, and precise operation [
5,
6,
7,
8]. Multiple viable positioning methods exist for AMSs, primarily including Global Navigation Satellite Systems (GNSSs) [
9,
10], Strapdown Inertial Navigation Systems (SINSs) [
11,
12], and Vision Navigation [
13,
14]. However, achieving high-precision and high-update-rate attitude detection primarily relies on SINS. With its strong autonomy, high update frequency, and excellent dynamic performance, an SINS can provide accurate attitude determination for AMSs [
15,
16,
17].
By processing the raw measurement data acquired from inertial measurement units (IMUs), an SINS computes the relative motion state variation of the carrier with respect to its initial reference state [
18]. As a dead-reckoning navigation system, an SINS requires critically initialized parameters comprising attitude, velocity, and position to guarantee subsequent navigation precision. The initial velocity and position of the carrier can be obtained by sensors such as a GNSS or a priori information, while the acquisition of initial attitude requires the design of dedicated initial alignment algorithms [
19,
20]. Alignment speed and alignment accuracy are two critical performance metrics for the initial alignment algorithms [
21,
22].
Chronologically, the initial alignment process can be divided into coarse and fine alignment and stages [
21,
23]. The attitude solved by the coarse alignment algorithm serves as the fine alignment algorithm’s initial condition. Fine alignment typically employs data fusion methods, such as a Kalman filter, to estimate inertial sensor errors, yielding a high-precision attitude solution [
24,
25]. Therefore, the primary objective of coarse alignment is to rapidly converge the attitude error within a small-angle error range to enhance the convergence speed of the initial alignment process [
20,
26]. In practical applications, coarse alignment under static-base conditions exhibits inherent limitations. Hence, swaying-base coarse alignment currently represents the most efficient approach. This paper is primarily directed at the design of a rapid coarse alignment algorithm for a swaying base.
Extensive research on coarse alignment methods has been conducted by scholars worldwide [
20,
22,
26,
27]. Among these endeavors, the inertial frame coarse alignment method proposed by Yan Gongmin stands as a representative approach [
27]. This method employs a decomposition of the body attitude matrix into a product of several sub-matrices and achieves rapid initial attitude determination based on the dual-vector attitude determination principle. Subsequently, some scholars have made improvements based on this method [
28]. However, in general, coarse alignment methods utilizing dual-vector attitude determination do not fully exploit the vector information throughout the entire alignment process, resulting in limited alignment performance. Building upon the inertial frame coarse alignment method, Wu Yuanxin [
29] proposed an optimization-based alignment (OBA) method, reformulating the coarse alignment problem as an attitude determination problem of a constant attitude matrix. Subsequently, scholars have successively incorporated attitude determination methods such as q-method, Quaternion Estimator (QUEST), and Recursive QUEST (REQUEST) into coarse alignment methods to enhance alignment performance [
30,
31,
32]. Xu Xiang [
33,
34] et al. argued that in the coarse alignment observation vector model, the observation vectors contain accumulated errors due to inertial sensor inaccuracies, which constitute the primary factor limiting convergence speed. Therefore, Xu [
34] conducted research on Kalman filter-based vector reconstruction algorithms. Inspired by the work of Xu Xiang et al., this paper incorporates an investigation of a vector reconstruction method based on the Sage–Husa adaptive Kalman filter (AKF) algorithm for application in coarse alignment algorithms to accelerate convergence speed.
The remainder of this paper is organized as follows. The vector observation model for coarse alignment is devoted in
Section 2. The vector reconstruction model is constructed in
Section 3. The effectiveness and practicability of the proposed algorithm is demonstrated through simulation and turntable tests in
Section 4 and
Section 5. Finally, conclusions are drawn in
Section 6.
2. The Vector Observation Model for Coarse Alignment
In this section, an apparent velocity vector observation model based on sliding-window vector integration is constructed, utilizing the principle of coarse alignment in the inertial frame.
2.1. Definition of Coordinate Systems
The coordinate systems used in the paper are defined as follows:
- (1)
i-frame: inertial frame, Earth-centered initially fixed, orthogonal reference frame.
- (2)
n-frame: navigation frame, orthogonal reference frame aligned with East–North–Up (ENU) geodetic axes.
- (3)
n0-frame: orthogonal reference frame non-rotating relative to the i-frame, forming the n-frame at the start-up in the inertial space.
- (4)
b-frame: body frame, Right–Forth–Up orthogonal frame aligned with IMU axes.
- (5)
b0-frame: orthogonal reference frame non-rotating relative to the i-frame, forming the b-frame at the start-up in the inertial space.
- (6)
e-frame: Earth frame, Earth-centered Earth-fixed (ECEF) orthogonal reference frame.
- (7)
e0-frame: orthogonal reference frame non-rotating relative to the i-frame, forming the e-frame at start-up in the inertial space.
2.2. Decomposition of Attitude Matrix
The attitude matrix
at any time
t can be decomposed via the chain rule:
where
is the attitude matrix corresponding to the initial moment. The matrices
and
are the attitude change matrices of the
n-frame and
b-frame, respectively, from time
to
t. Obviously, the initial values of the attitude matrices
and
are both identity matrices, i.e.,
. The differential equations of the matrices
and
are expressed as
where the matrix
is the transpose matrix of original matrix
, namely
. The matrix
is the derivative of matrix
. The angular velocity
is the projection vector of the rotational angular velocity of the
n -frame relative to the
i-frame in the
n-frame, which can be calculated from the Earth’s rotation rate and geographical information. The matrix
represents the skew-symmetric matrix of vector
. The matrix
is the derivative of matrix
. The angular velocity
is the projection vector of the rotational angular velocity of the
b-frame relative to the
i-frame in the
b-frame, which can be measured by gyroscopes. The matrix
represents the skew-symmetric matrix of vector
.
2.3. Apparent Gravity Vector Observation Model
When the vehicle is under a swaying base, the linear velocity of the vehicle is zero. Then, the specific force equation can be simplified as
where
denotes a three-dimensional null vector.
denotes the specific force vector measured by the accelerometer.
denotes the gravitational acceleration vector.
Combining Equations (1) and (4) gives the following:
Multiplying both sides of the above equation by the matrix
yields the following:
Through Equation (6), the vector observation model based on the apparent gravity can be obtained:
where
The apparent gravity vector observation model presented above is derived based on the ideal specific force equation. As shown in Equation (8), the reference vector
is calculated by transforming the gravitational acceleration vector from the
n-frame to the
n0-frame. Since the vehicle’s geographic position is known and fixed, the reference vector
can be considered error-free. Conversely, the observation vector
is computed by transforming the specific force vector from the
b-frame to the
b0-frame. In an actual SINS, measurement errors in the data provided by the IMU must be considered. Let the error-containing outputs of the gyroscope and accelerometer be denoted as
and
, respectively, and their expressions are as follows:
where
represents the gyroscope bias vector,
represents the gyroscope measurement noise vector,
represents the accelerometer bias vector, and
represents the accelerometer measurement noise vector.
Since the gyroscope measurements contain errors, the matrix
computed via Equation (3) accumulates these inaccuracies. Consequently, Equation (3) is reformulated to express the practically computed matrix as
where, the matrix
is an expression of matrix
with an error component. The matrix
is the derivative of matrix
.
The matrix
can be expressed as the product of its true value
and the attitude error matrix between them:
where
denotes the misalignment angle between matrices
and
. On one hand,
depends on the magnitude of gyro bias
. On the other hand, it grows progressively with time.
Substituting Equation (10) into Equation (8) and ignoring second-order terms yields the following:
Substituting Equation (13) into Equation (7) and rearranging terms yields the following:
Consequently, the vector observation model based on apparent gravity vectors for practical SINS is derived from Equation (14):
where
As Equation (15) indicates, the apparent gravity observation vector incorporates multiple error terms. In addition to the random error term , there is also the constant error term and the variable error term . The magnitude of misalignment angle correlates with both alignment duration and gyro bias magnitude. Evidently, the norm of the time-varying noise term progressively increases with alignment time. This analysis demonstrates two critical aspects: First, the initial attitude result obtained by the coarse alignment method based on the inertial frame principle is a biased estimate, which corresponds to the limiting accuracy of coarse alignment. Second, the error of the biased estimation result calculated via the coarse alignment method also increases continuously. Consequently, to reduce the error drift of the alignment result, the alignment time should be shortened as much as possible.
2.4. Apparent Velocity Vector Observation Model
In the previous section, an apparent gravity vector observation model was constructed. As analyzed, the apparent gravity observation vector contains the random error term . However, the apparent gravity vector observation model only utilizes the vector information at the current moment, discarding all previous vector information. To reduce the influence of the random error term and fully utilize all vector information during the alignment process, a vector observation model based on apparent velocity will be derived and constructed below.
Integrating both sides of Equation (14) yields the vector observation model based on apparent velocity for solving initial attitude:
Assuming the accelerometer measurement noise
follows a Gaussian distribution, the integral term
. Hence, Equation (17) becomes
Consequently, the observation vector and reference vector based on apparent velocity are extracted from Equation (18):
where
The discretization process is performed on Equation (20). Assume the current time is
, where
is a positive integer, and
is the time interval of the SINS update period
, with
and
. In Equation (20), the reference vector
can be calculated according to [
35,
36] as
The observed vector
in Equation (20) can be calculated according to [
35,
36] as
Comparing Equation (18) with Equation (14) reveals that the apparent velocity vector eliminates the influence of accelerometer random errors on the initial alignment method through the integration of the apparent gravity vector. However, the accelerometer bias error term and the gyroscope bias error term remain. Moreover, due to the integration effect, the influence of the accelerometer and gyroscope bias error terms will become increasingly significant. Therefore, compared with the apparent gravity vector, the apparent velocity vector fully utilizes the vector information during the alignment process and can eliminate the influence of random errors on the system. Nevertheless, the integration also leads to a faster accumulation rate of vector drift errors. Ultimately, in terms of alignment error, the convergence process of the apparent velocity method is faster and smoother than that of the apparent gravity method, but it also exhibits a more rapid drift phenomenon.
2.5. Sliding Window Vector Integration Model
The preceding section noted that while the apparent velocity vector observation model can accelerate the convergence of coarse alignment, it accumulates inertial sensor errors in the observation vector. In this section, we employ the sliding-window vector integration method to effectively address this issue. The detailed process is as follows.
The schematic diagram of the vector integration principle is shown in
Figure 1. It can be clearly observed from
Figure 1 that when performing full integration on observation vectors, all previous observation vectors are involved in the calculation. This leads to the continuous accumulation of bias errors from gyroscope and accelerometer measurements within the observation vectors. In contrast, the sliding-window integration sampling algorithm only utilizes the information from the previous
S sampling moments when solving for the current observation vector. Bias errors in gyroscope and accelerometer measurements from sampling moments outside the sliding window do not accumulate into the current observation vector. Therefore, the sliding-window vector integration method enhances the accuracy of observation vectors.
Assume that the starting time of the sliding window integration is
and the current time is
. Therefore, the apparent velocity observation vector and reference vector based on sliding window vector integration can be extracted from Equation (19) as
where
Analogous to the calculation method of full integration vectors, the discrete expressions of the reference vector and observation vector in Equation (24) are given as follows:
3. The Vector Reconstruction Model
In Equation (6), the apparent velocity observation vector model based on sliding window vector integration can be expressed as
According to [
34], the expressions for matrices
,
and
are given as
where
and
denote the longitude and latitude of the carrier, respectively.
is the Earth’s rotation rate, and the matrices
,
, and
are constant. The matrix
is time-varying. Therefore, the apparent velocity observation vector model based on this can be expressed as
where
.
where
denotes the local gravitational acceleration value.
,
. The complete derivation of Equation (31) appears in
Appendix A.
Substituting Equation (30) into Equation (23) yields the following:
In the above equation, the matrix is constant. The vector is the vector in Equation (24).
Assume that the three channels of the apparent velocity vector are non-coupled. Therefore, taking the first channel as an example and denoting it as
, we present a unified parameter identification model. For convenience, the
of the
channel is expressed as
.
where
represents the first row of the matrix
.
For the observation vector
sampled at time
, analysis of the vector reconstruction model shows that the observation vector can be expressed as the sum of trigonometric functions and power functions, which can be decomposed into a power series form. In Equation (30), the true observation vector can be represented as a polynomial function of time. Here, let the dependent variable be the sampling time
, then the polynomial fitting model is established as follows:
where the vectors
and
are, respectively, as follows:
Taking the matrix
as the observation vector and Equation (34) as the measurement equation, the filter model for Sage–Husa AKF is constructed as follows:
where
. Assumedly, after polynomial fitting, only the random error term remains in the
channel of the observation vector, meaning
follows a zero-mean Gaussian distribution, i.e.,
,
. In the filter model given by Equation (37), the state transition matrix is an identity matrix.
The Sage–Husa AKF method is implemented to estimate the fitting parameter
. As detailed in [
37], the specific process is as follows:
- (1)
Calculate the measurement residual:
- (2)
The adaptive recursive estimation of the measurement noise covariance matrix:
- (3)
Calculate the filter gain:
- (4)
Update the state estimation:
- (5)
Update the mean square error of state estimation:
where the initial value
. And
is termed the forgetting factor, typically selected within
.
After estimating the fitting parameter
using the AKF algorithm, the estimated parameter
is then used to recalculate the fitted apparent gravity vector as follows:
where
represents the fitted observation vector. Therefore, the new vector observation model can be obtained as
where
denotes the residual error after fitting the observation vector. Based on the aforementioned vector reconstruction method, the quaternion
corresponding to the initial attitude matrix
can be solved using the optimal-REQUEST attitude determination algorithm from a prior publication, thereby accomplishing the coarse alignment process. Specific steps of the attitude determination algorithm are detailed in Reference [
30] and are not reiterated here.
4. Simulation Test
The effectiveness of the coarse alignment algorithm based on vector reconstruction via Sage–Husa AKF proposed in this paper is verified through simulation.
The parameters of the IMU in the simulation test are set as follows:
Gyroscopes biases: 0.02°/h;
Gyroscopes random noise: 0.005°/√h;
Accelerometers biases: 500 μg;
Accelerometers random noise: 50 μg/√Hz;
Output frequency: 200 Hz.
The simulation test will verify the performance of several coarse alignment methods through a swaying base, employing a sinusoidal motion model to simulate the swaying motion of the carrier under mooring or shaking conditions.
where parameters
,
and
represent the pitch, roll and yaw angle, parameters
,
, and
represent the swaying amplitudes; parameters
,
, and
represent the swaying frequencies; parameters
,
, and
represent the initial phases; and parameters
,
, and
represent the swaying centers. The swaying parameters in the simulation experiment are set as shown in
Table 1. The alignment time is 200 s.
Linear vibration disturbances are introduced in the simulation test to evaluate algorithm performance. Under linear vibration excitation, the generated linear velocity vector of the carrier
is:
where, variables
,
and
represent the amplitude of disturbance linear velocity. Variables
,
and
represent the period of disturbance linear velocity. Variables
,
, and
represent the initial phase of disturbance linear velocity. The amplitudes of disturbance linear velocity are 0.1 m/s, 0.1 m/s and 0.2 m/s, with periods of 6 s, 7 s, and 8 s respectively. The initial phase follows a uniform distribution in the interval [0, 2π].
In the sliding window vector integration method of the proposed coarse alignment algorithm, the sliding window length is a critical parameter. If the sliding window length is too short, the number of observation vectors involved in attitude determination is insufficient, leading to slow convergence of the coarse alignment. Conversely, if the window length is too long, an excessive number of observation vectors participate in attitude estimation, wherein the cumulative bias errors of inertial devices intensify, thereby degrading the accuracy of observation vector construction. In the simulation experiment, before comparing with other coarse alignment algorithms, the influence of different sliding window lengths on the performance of the proposed method was studied to select the optimal window length. In this experiment, four sliding window length parameters of 2 s, 5 s, 10 s, and 20 s were selected, named dLen2, dLen5, dLen10, and dLen20, respectively. For conciseness, this paper only details the comparison diagram of heading angle errors of the four sliding window length algorithms, as shown in
Figure 2. The results show that the coarse alignment methods corresponding to the four sliding window length parameters can converge quickly. Comprehensive evaluation of convergence speed and alignment accuracy across the four algorithms, the coarse alignment algorithm with a sliding window length of 10 s has the best alignment performance. Therefore, in the subsequent simulation experiments and turntable tests, the sliding window length of the algorithm in this paper is uniformly set to 10 s.
Simultaneously, the initial filter parameters in Sage–Husa AKF are configured as follows: the state vector is a 4-dimensional vector, the forgetting factor is set to 0.99, the initial measurement noise covariance matrix is set to 0.1, and the initial state covariance matrix is set to .
To thoroughly compare the performance of the algorithm proposed in this paper, three other coarse alignment algorithms are, respectively, introduced.
Scheme 1: the coarse alignment method with unprocessed observation vectors is denoted as Scheme 1, as described in [
30].
Scheme 2: the coarse alignment method using a digital low-pass Infinite Impulse Response (IIR) filter for noise reduction processing of observation vectors is denoted as Scheme 2.
Scheme 3: the vector reconstruction coarse alignment algorithm using Kalman filter in [
23,
34] is denoted as Scheme 3.
Scheme 4: the vector reconstruction coarse alignment method based on the Sage–Husa AKF proposed in this paper is denoted as Scheme 4.
Figure 3,
Figure 4 and
Figure 5 show the attitude error curves of the four coarse alignment algorithms under swaying conditions. The horizontal attitude error curves in
Figure 3 and
Figure 4 demonstrate that linear motion disturbances induce initial fluctuations in horizontal attitude errors across all four methods. Nevertheless, stable convergence is rapidly achieved in each case, with all horizontal attitude errors reaching within 0.02° by the end of the 200-s coarse alignment process. Comparatively, the proposed method exhibits significantly reduced susceptibility to such disturbances, attaining the fastest convergence rate for horizontal attitude errors.
Since the first 10 s fall within the sliding window length, the proposed coarse alignment algorithm did not output the heading angle. The heading angle error curve of Scheme 4 begins updating after 10 s. This is not a defect of the algorithm, and the method can also output the heading angle within the first 10 s.
Upon completion of the 200-s coarse alignment phase, heading angle errors for the four schemes are −1.0721°, −2.1035°, 0.2357°, and −0.1928° respectively. From both the final heading error results and the error curves in
Figure 5, the following phenomena can be observed:
- (1)
All four coarse alignment methods are based on the apparent velocity vector observation model. Due to the integration effect, the apparent velocity vector effectively reduces the impact of random noise on the alignment results. Furthermore, all historical observation vectors are involved in the attitude determination. Consequently, the attitude error curves of all four methods converge smoothly.
- (2)
Both Scheme 3 and Scheme 4 can effectively process the observation vectors, and their attitude error curves show better convergence speed. However, due to the time-delay error introduced by the IIR filter, the alignment error curve of Scheme 2 has an obvious lag, performing worse than that of Scheme 1.
- (3)
Among the four coarse alignment algorithms, Scheme 4 has the best convergence speed and convergence accuracy performance. From the alignment results, the heading angle error of Scheme 4 can converge to within 1° in about 60 s.
The main reasons for the superior coarse alignment performance of the proposed algorithm are as follows. Affected by the bias errors of inertial sensors contained in observation vectors, the full integration algorithm causes continuous accumulation of bias errors in observation vectors, leading to slow drift of alignment errors. In contrast, the sliding window integration sufficiently utilizes vector information while avoiding error accumulation. Additionally, the vector reconstruction method based on the Sage–Husa AKF further improves the construction accuracy of observation vectors. Meanwhile, the optimal-REQUEST attitude determination algorithm realizes adaptive weight allocation of observation vectors by performing an optimal filter on measurement noise.
5. Turntable Test
To verify the performance of the proposed coarse alignment algorithm in practical systems, relevant validation tests were performed using a high-precision three-axis turntable.
The inner frame, middle frame, and outer frame of the three-axis multi-functional turntable correspond to the roll angle, pitch angle, and heading angle of the SINS, respectively. The parameters of the IMU used in the turntable test are shown in
Table 2. The physical diagram of the three-axis multi-functional turntable is shown in
Figure 6, and the structural schematic diagram of the turntable test is shown in
Figure 7. Before the turntable test, the IMU was calibrated to compensate for the scale factor errors, installation errors, bias errors, etc., of the gyroscopes and accelerometers. As shown in
Figure 7, the data acquisition system simultaneously acquires IMU data and turntable attitude data via synchronous signals. After calibrating the installation errors between the IMU and turntable, the real-time turntable data can serve as the attitude reference for the turntable test.
The experimental scheme for coarse alignment on a swaying base is as follows: The IMU is installed at the center of the three-axis turntable, and installation errors and inertial sensors’ bias errors are calibrated in advance. The motion scheme of three-axis sinusoidal sway is designed for turntable tests under swaying conditions. The motion settings of the three-axis turntable under swaying conditions are as follows: the swaying center of the inner frame (roll angle) of the turntable is 0°, the amplitude is 5°, and the frequency is 0.15 Hz. The swaying center of the middle frame (pitch angle) is 0°, the amplitude is 4°, and the frequency is 0.125 Hz. The swaying center of the outer frame (yaw angle) is 0°, the amplitude is 3°, and the frequency is 0.2 Hz. The coarse alignment test time is set to 200 s.
As in the simulation experiments, three additional coarse alignment algorithms were introduced to conduct a comparative performance analysis with the proposed algorithm.
In the turntable test, the four comparative methods (Scheme 1~Scheme 4) follow the same definition approaches as in the simulation test. And the initial parameters of the filter model for the turntable test are configured identically to those in the simulation test.
Figure 8,
Figure 9 and
Figure 10 present the comparison curves of pitch angle error, roll angle error, and heading angle error of the four coarse alignment algorithms under swaying conditions. As shown in
Figure 8 and
Figure 9, the horizontal angle errors of the four coarse alignment methods can reach the limiting alignment accuracy within a short time.
Since the first 10 s fall within the sliding window length, the proposed coarse alignment algorithm did not output the heading angle. The heading angle error curve of Scheme 4 begins updating after 10 s. By comparing the heading angle error curve in
Figure 10, the following results can be obtained.
Similarly to the simulation experiment, due to the delay error of the IIR filter, the alignment error curve of Scheme 2 has an obvious lag, so the performance of Scheme 2 is worse than that of Scheme 1.
Among the four coarse alignment algorithms, Scheme 4 demonstrates the optimal performance in both convergence speed and accuracy.
To compare the performance of the four coarse alignment algorithms under swaying conditions more clearly and specifically, the mean error (MEAN), standard deviation (STD), and root mean square error (RMSE) of the attitude errors for each method were statistically analyzed. Equations (48)–(51) provides the mathematical formulas for the statistical errors of MEAN, STD, and RMSE. To compare the convergence speed and accuracy of the four coarse alignment methods, respectively, the attitude errors were statistically analyzed in 20~50 s and 100~200 s intervals.
Table 3 presents the error statistics of the alignment errors during the turntable test for the four coarse alignment algorithms.
where,
represents the mean error,
represents the
i-th calculated angle,
represents the
i-th reference angle,
represents the number of calculated angles,
represents the average value of calculated angles,
represents the standard deviation error,
represents the root mean square error.
As shown in the table, the statistical results of horizontal attitude angle errors of the four coarse alignment methods are close. Based on the statistical results of attitude errors at 20~50 s intervals, the proposed Scheme 4 method exhibits the lowest heading angle error among the four methods, indicating the fastest convergence speed. According to 100~200 s attitude error statistics, Scheme 4 achieves the most minor heading angle error, demonstrating superior convergence accuracy.
Based on a comprehensive analysis, the proposed coarse alignment method achieves horizontal attitude errors better than 0.01° within 20 s and maintains heading errors within ±0.6° after 100 s under swaying conditions. Turntable test results demonstrate that the proposed method delivers superior alignment performance compared to the other three coarse alignment algorithms.