Noise adaptive strong tracking extended Kalman filter quadrotor attitude solution method

The noise-adaptive strong tracking extended Kalman filter method solves the problems of MEMS sensor drift and noise interference in quad-rotor aircraft, achieves high-precision attitude calculation and aircraft control, and enhances the tracking capability and smoothness of the system.

CN114964226BActive Publication Date: 2024-09-20YANSHAN UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202210471564.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-04-29
Publication Date
2024-09-20
Estimated Expiration
2042-04-29

AI Technical Summary

Technical Problem

MEMS sensors have drift, noise and external interference problems in quad-rotor aircraft, which lead to attitude calculation errors and affect the control accuracy of the aircraft.

Method used

The noise-adaptive strong tracking extended Kalman filter method is used to construct the system state equation and observation equation through the state transition matrix, introduce the rotation matrix and strong tracking filter, calculate the sub-optimal fading factor, and dynamically adjust the noise through the noise adaptive mechanism Variance and mean to improve attitude calculation accuracy.

Benefits of technology

It achieves improved attitude resolution accuracy in MEMS sensors, enhances the tracking speed and smoothness of the system, reduces errors caused by external interference, and improves the control accuracy of the aircraft.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114964226B
    Figure CN114964226B
Patent Text Reader

Abstract

The present invention relates to a noise-adaptive strong tracking extended Kalman filter quadrotor attitude solution method, which belongs to the technical field of unmanned aerial vehicles, including constructing state equations and observation equations, initializing system noise and measurement noise initial values; calculating a predicted state at the next moment; calculating new information, updating a strong tracking filter, and splitting a suboptimal fading factor; calculating an improved one-step prediction error covariance matrix to re-estimate the noise variance and noise mean at the next moment, and introducing the estimated value into an EKF formula; calculating the Kalman gain matrix, the secondary estimate of the state and the secondary estimate of the error covariance, and judging whether the cycle is ended; and outputting the result. The present invention introduces a strong tracking filter to solve the problem of weak tracking ability of a traditional extended Kalman filter caused by problems such as Taylor expansion approximate linearization, and by improving the introduction form of the suboptimal fading factor, the symmetry of the covariance matrix calculation result is guaranteed, and the system tracking speed is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to a noise adaptive strong tracking extended Kalman filter quadrotor attitude solution method, belonging to the technical field of unmanned aerial vehicles. Background Art

[0002] A drone is a special unmanned aircraft that is autonomously controlled using wireless remote control equipment or preset onboard programs. With the development of microcomputer electronics, inertial measurement systems with MEMS devices as the core have become the mainstream application of drone navigation and measurement devices. MEMS has the advantages of small device size, fast response, and low cost. IMU based on MEMS sensors has been widely used, such as drones, unmanned vehicles, trajectory tracking, strapdown inertial navigation, etc., which have a wide range of engineering application markets.

[0003] The basis of quadcopter flight is accurate attitude calculation, but the gyroscope in the MEMS sensor will drift; the accelerometer has poor dynamic performance and is easily affected by external vibrations, resulting in large noise measurements, which introduces large errors into the system; the magnetometer is easily disturbed by external magnetic field signals and is sensitive to the surrounding environment. The generation of the above three errors cannot be predicted and is random, so in-depth research is needed on the attitude calculation of quadcopters. Summary of the invention

[0004] The purpose of the present invention is to provide a noise adaptive strong tracking extended Kalman filter quadrotor attitude solution method, which can obtain high-precision attitude in real time and thus better control the flight state of the aircraft.

[0005] In order to achieve the above object, the technical solution adopted by the present invention is:

[0006] A noise adaptive strong tracking extended Kalman filter quadrotor attitude solution method comprises the following steps:

[0007] S1: Construct the system state equation and observation equation through the state transfer matrix, initialize the system noise Q and the initial value of the measurement noise

[0008] S2: The second estimate of the current moment With the state transfer matrix Multiply to get the predicted state at the next moment

[0009] S3: Calculate new information and update the variable V in the strong tracking filter calculation process k+1 、M k+1 、N k+1 , then calculate the suboptimal fading factor λ k+1 , and split the suboptimal fading factor into two square root forms;

[0010] S4: Multiply the suboptimal fading factors in the split form of step S3 by the one-step prediction covariance matrix P k+1|k On both sides of the improved one-step forecast error covariance matrix P k+1|k ;

[0011] S5: Noise variance for the next moment and noise mean Re-estimate and introduce the estimated value into the EKF formula;

[0012] S6: Calculate the Kalman gain matrix K k+1 ,state The quadratic estimate and error covariance P k+1|k+1 The second estimation is used to determine whether the loop is finished. If the loop is finished, the process goes to step S7. If not, the process goes back to step S2.

[0013] S7: Output the experimental results.

[0014] A further improvement of the technical solution of the present invention is that: the step S1 adopts the rotation matrix Construct the state equation and observation equation. The specific process is as follows:

[0015]

[0016] In formula (15), θ, φ, and φ are the pitch angle, yaw angle, and roll angle, respectively;

[0017]

[0018] Formula (16) It represents the projection of the angular velocity of the navigation system relative to the aircraft system on the aircraft system, express The cross product matrix of , from which we can extract the third column:

[0019]

[0020] Among them, x is

[0021] b g,k+1 =b g,k +w g,k (18)

[0022] In formula (18), b g,k 、w g,k are the drift and noise of the gyroscope at time k, b g,k+1 represents the gyroscope drift at time k+1;

[0023] Define the system state model:

[0024]

[0025] In order to run on an actual computer, the function is discretized using the first-order difference in equation (19) to obtain the system state equation:

[0026]

[0027] In formula (20), T a Indicates the interval between two samples, and indicates the integration time in the program. k is the state value at time k, ω b,k is the measurement value of the gyroscope at time k;

[0028] The state model (20) is expanded using Taylor series to obtain the information required by EKF, and the system state is:

[0029]

[0030] The state transfer matrix and noise driving matrix are:

[0031]

[0032] Observation value Z k+1 The accelerometer observation value can be expressed as:

[0033]

[0034] The observation equation of the system can be expressed as:

[0035]

[0036] The observation matrix is:

[0037] H k+1 =[0 3×3 -gI3] (25)

[0038] The further improvement of the technical solution of the present invention is that: the specific process of step S3 is to keep the new information sequences at different times orthogonal, build a strong tracking filter, and then calculate the suboptimal fading factor λ k+1 , and split the suboptimal fading factor into two square root forms, and introduce the split formula of the suboptimal fading factor into the extended Kalman filter.

[0039] The further improvement of the technical solution of the present invention is that the specific process of step S5 is to introduce a noise adaptive mechanism to dynamically adjust the noise in real time with a fixed initial value of the noise to adapt to the needs of the system. The specific formula steps are as follows:

[0040]

[0041]

[0042]

[0043]

[0044]

[0045]

[0046]

[0047]

[0048]

[0049]

[0050]

[0051]

[0052]

[0053] P k+1|k+1 =(IK k+1 H k+1 ) k+1|k (14)

[0054] In the above formula, are the estimated noise variance and noise mean, S k+1 is the new information, R0 and r0 are the initial values ​​of the noise variance and mean respectively. As k increases, it is ensured that the system has a certain initial value of noise, so that the Kalman gain K k+1 Too large or too small, the system loses its regulating effect; k+1 、M k+1 、N k+1 To calculate the intermediate amount of the suboptimal fading factor, λ k+1 is the suboptimal fading factor, P k+1|k is the one-step forecast covariance matrix.

[0055] Due to the adoption of the above technical solution, the technical effects achieved by the present invention are as follows:

[0056] The present invention utilizes multi-sensor fusion technology to construct system state equations and observation equations through rotation matrices, which is easy for engineering transplantation.

[0057] The present invention solves the problem of weak tracking ability of the traditional extended Kalman filter caused by problems such as Taylor expansion approximate linearization by introducing a strong tracking filter, and ensures the symmetry of the covariance matrix calculation result by improving the introduction form of the suboptimal fading factor, thereby improving the system tracking speed.

[0058] Aiming at the characteristic that inertial devices have a certain proportion of fixed noise, the present invention uses a noise adaptive estimator to add a certain proportion of initial noise and dynamically adjust the noise mean and variance according to the changes in new information, thereby solving the problem that inertial devices are easily affected by environmental interference, resulting in large output value errors. BRIEF DESCRIPTION OF THE DRAWINGS

[0059] Figure 1 It is a block diagram of the algorithm of the present invention;

[0060] Figure 2 It is a comparison diagram of pitch angles (Pitch) of the extended Kalman filter, the strong tracking extended Kalman filter, and the noise adaptive strong tracking extended Kalman filter under the simulation conditions of the present invention;

[0061] Figure 3 It is a comparison diagram of the roll angle (Roll) of the extended Kalman filter, the strong tracking extended Kalman filter, and the noise adaptive strong tracking extended Kalman filter under the simulation conditions of the present invention;

[0062] Figure 4 is the system measurement noise variance estimated by the noise adaptive strong tracking extended Karl Kalman filter under the simulation conditions of the present invention;

[0063] Figure 5 It is a comparison diagram of the roll angle (Roll) of the extended Kalman filter, the strong tracking extended Kalman filter, and the noise adaptive strong tracking extended Kalman filter in the actual object of the present invention;

[0064] Figure 6 It is the system measurement noise variance estimated by the noise adaptive strong tracking extended Kalman filter under the actual conditions of the present invention. DETAILED DESCRIPTION

[0065] The present invention is further described in detail below with reference to the accompanying drawings and specific embodiments:

[0066] A noise adaptive strong tracking extended Kalman filter quadrotor attitude solution method, the quadrotor comprises a single chip microcomputer and a gyroscope, an accelerometer, and a geomagnetic sensor connected to the single chip microcomputer, and the single chip microcomputer is connected to the ground system QGC ground station for communication; Figure 1 As shown, the following steps are included:

[0067] S1: Construct the system state equation and observation equation through the state transfer matrix, initialize the system noise Q and the initial value of the measurement noise

[0068] Using rotation matrix Construct the state equation and observation equation. The specific process is as follows:

[0069]

[0070] In formula (15), θ, φ, and φ are the pitch angle, yaw angle, and roll angle, respectively;

[0071]

[0072] Formula (16) It represents the projection of the angular velocity of the navigation system relative to the aircraft system on the aircraft system, express The cross product matrix of , from which we can extract the third column:

[0073]

[0074] Among them, x is

[0075] b g,k+1 =b g,k +w g,k (18)

[0076] In formula (18), b g,k 、w g,k denote the drift and noise of the gyroscope at time k, respectively, and the gyroscope drift b at time k+1 g,k+1 Also as one of the system states;

[0077] Define the system state model:

[0078]

[0079] In order to run on an actual computer, the function is discretized using the first-order difference in equation (19) to obtain the system state equation:

[0080]

[0081] In formula (20), T s Indicates the interval between two samples, and indicates the integration time in the program. k is the state value at time k, ω b,k is the measurement value of the gyroscope at time k;

[0082] The state model (20) is expanded using Taylor series to obtain the information required by EKF, and the system state is:

[0083]

[0084] The state transfer matrix and noise driving matrix are:

[0085]

[0086] Observation value Z k+1 The accelerometer observation value can be expressed as:

[0087]

[0088] The observation equation of the system can be expressed as:

[0089]

[0090] The observation matrix is:

[0091] H k+1 =[0 3×3 -gI3] (25)

[0092] S2: The second estimate of the current moment State transition matrix Multiply to get the predicted state at the next moment

[0093] S3: Calculate new information and update the variable V in the strong tracking filter calculation process k+1 、M k+1 、N k+1 , then calculate the suboptimal fading factor λ k+1 , and split the suboptimal fading factor into two square root forms.

[0094] The specific process is to keep the new information sequences at different times orthogonal, build a strong tracking filter, and then calculate the suboptimal fading factor λ k+1 , and split the suboptimal fading factor into two square root forms, and introduce the split formula of the suboptimal fading factor into the extended Kalman filter.

[0095] S4: Multiply the suboptimal fading factors in the split form of step S3 by the one-step prediction covariance matrix P k+1|k On both sides of the improved one-step forecast error covariance matrix P k+1|k ;

[0096] S5: Noise variance for the next moment and noise mean Re-estimate and introduce the estimated value into the EKF formula.

[0097] Since the strong tracking filter introduced in step S3 cannot determine the accuracy of a single sensor, if the sensor is susceptible to new information changes caused by the external environment, the strong tracking filter may introduce errors into the system. Therefore, step S5 introduces a noise adaptive mechanism based on the characteristics of the inertial sensor, with a fixed initial value of the noise, and dynamically adjusts the noise in real time to meet the needs of the system. The specific formula steps are as follows:

[0098]

[0099]

[0100]

[0101]

[0102]

[0103]

[0104]

[0105]

[0106]

[0107]

[0108]

[0109]

[0110]

[0111] P k+1|k+1 =(IK k+1 H k+1 ) k+1|k (14)

[0112] In the above formula, are the estimated noise variance and noise mean, respectively. R0 and r0 are the initial values ​​of the noise variance and mean, respectively. As k increases, it is ensured that the system has a certain initial noise value, so that the Kalman gain K is not k+1 Too large or too small will cause the system to lose its regulating effect; V k+1 、M k+1 、N k+1 To calculate the intermediate amount of the suboptimal fading factor, λ k+1 is the suboptimal fading factor, P k+1|k is the one-step forecast covariance matrix.

[0113] S6: Calculate the Kalman gain matrix K k+1 ,state The quadratic estimate and error covariance P k+1|k+1 The second estimation is used to determine whether the loop is finished. If the loop is finished, the process goes to step S7; if not, the process goes back to step S2.

[0114] S7: Output the experimental results.

[0115] Steps S2, S4, and S6 use the extended Kalman filter to estimate the optimal attitude angle. The specific steps are as follows: First, use step S2 to calculate the one-step prediction, and multiply the state value estimated at the previous moment by the state transfer matrix at this moment to obtain the one-step prediction of the state. Second, calculate the Jacobian matrix through step S4 And calculate the improved one-step forecast error covariance matrix P k+1|k Finally, the Kalman gain matrix K is calculated by step S6 k+1 ,state The quadratic estimate of the error covariance P k+1|k+1 The second estimate of is prepared for the next iterative update.

[0116] The noise adaptive strong tracking extended Kalman filter of the present invention takes into account the influence of the noise of the inertial device on the system. The strong tracking filter solves the problem that the extended Kalman filter has poor tracking ability due to the inaccurate approximate linearization model caused by Taylor expansion and the large proportion of historical values. At the same time, the noise adaptive estimator is dynamically estimated according to the characteristics of the inertial device. By introducing the initial value of the noise, when the system transitions from a stable state to a moving state, the Kalman gain can be quickly adjusted, and the error will not be introduced into the system due to the influence of the sensor noise, thereby improving the accuracy of attitude solution.

[0117] Figure 2 , Figure 3 They are the comparison diagrams of pitch angle (Pitch) and roll angle (Roll) of extended Kalman filter, strong tracking extended Kalman filter and noise adaptive strong tracking extended Kalman filter in simulation environment. It can be clearly seen that the extended Kalman filter has the slowest tracking speed. After the state changes suddenly, it enters the vicinity of the desired target very slowly. The strong tracking extended Kalman filter reaches the desired target faster. However, due to the characteristics of the strong tracking filter, the accelerometer of the inertial device is greatly affected by the external environment and will introduce errors into the system. The figure shows that the tracking speed is fast, but the overshoot is large. The noise adaptive strong tracking extended Kalman filter proposed in this application is not lower than the strong tracking filter in tracking speed, but has almost no overshoot and smoothly enters the desired state.

[0118] Figure 4 is the noise variance value estimated by the noise adaptive strong tracking extended Kalman filter, compared with Figure 3 Figure 2 From the perspective of the system state, when there is a large mutation in the system state, the system passes the new information S k+1 The measurement equations for real-time estimation also undergo significant changes to adapt to changes in system noise.

[0119] Figure 5 This is a comparison chart of the roll angle (Roll) of the extended Kalman filter, the strong tracking extended Kalman filter, and the noise adaptive strong tracking extended Kalman filter under the real object. Figure 5 It can be seen that the results are consistent in the real environment and the simulation environment.

[0120] Figure 6 is the system measurement noise variance estimated by the noise adaptive strong tracking extended Kalman filter under real conditions, compared with Figure 5 ,from Figure 6 It can be seen from the figure that when the system state changes greatly, the system can dynamically adjust the observed noise in real time due to the role of the noise adaptive estimator, but Figure 4 Compared with the above, the adjustment strength is obviously increased. This is because the noise value of the sensor in the simulation environment is an artificially specified Gaussian noise, but in actual situations, the variance of the online experimental noise varies more, such as Figure 6 The noise variance changes by 250%, which is because the physical experiment data comes from real sensors and the superposition of more environmental interference factors, so it is more reflected in the physical experiment. The overall online physical experiment and offline simulation experiment have consistent results.

Claims

1. A noise adaptive strong tracking extended Kalman filter quadrotor attitude solution method, characterized in that: The steps include: S1: Construct the system state equation and observation equation through the state transfer matrix, initialize the system noise Q and the initial value of the measurement noise S2: The second estimate of the current moment With the state transfer matrix Multiply to get the predicted state at the next moment S3: Calculate new information and update the variable V in the strong tracking filter calculation process k+1 、M k+1 、N k+1 , and then calculate the suboptimal fading factor λ k+1 , and split the suboptimal fading factor into two square root forms; S4: Multiply the suboptimal fading factors in the split form of step S3 by the one-step prediction covariance matrix P k+1|k On both sides of the improved one-step forecast error covariance matrix P k+1|k ; S5: Noise variance for the next moment and noise mean Re-estimate and introduce the estimated value into the EKF formula; S6: Calculate the Kalman gain matrix K k+1 ,state The quadratic estimate and error covariance P k+1|k+1 The second estimation is used to determine whether the loop is finished. If the loop is finished, the process goes to step S7. If not, the process goes back to step S2. S7: Output the experimental results.

2. The noise adaptive strong tracking extended Kalman filter quadrotor attitude solution method according to claim 1 is characterized in that: The step S1 uses a rotation matrix Construct the state equation and observation equation. The specific process is as follows: In formula (15), θ, φ are pitch angle, yaw angle, and roll angle respectively; Formula (16) It represents the projection of the angular velocity of the navigation system relative to the aircraft system on the aircraft system, express The cross product matrix of , from which we can extract the third column: Among them, x is b g,k+1 =b g,k +w g,k (18) In formula (18), b g,k 、w g,k are the drift and noise of the gyroscope at time k, b g,k+1 represents the gyroscope drift at time k+1; Define the system state model: In order to run on an actual computer, the function is discretized using the first-order difference in equation (19) to obtain the system state equation: In formula (20), T s Indicates the interval between two samples, and indicates the integration time in the program; x k is the state value at time k, ω b,k is the measurement value of the gyroscope at time k; The state model (20) is expanded using Taylor series to obtain the information required by EKF, and the system state is: The state transfer matrix and noise driving matrix are: Observation value Z k+1 The accelerometer observation value can be expressed as: The observation equation of the system can be expressed as: The observation matrix is: <h2 style=";text-align:left;direction:ltr">H<h2 style=";text-align:left;direction:ltr"> k+1 <h2 style=";text-align:left;direction:ltr"> =[0<h2 style=";text-align:left;direction:ltr"> 3×3 <h2 style=";text-align:left;direction:ltr"> -gI3] (25)。 3. The noise adaptive strong tracking extended Kalman filter quadrotor attitude solution method according to claim 1, characterized in that: The specific process of step S3 is to keep the new information sequences at different times orthogonal, construct a strong tracking filter, and then calculate the suboptimal fading factor λ k+1 , and split the suboptimal fading factor into two square root forms, and introduce the split formula of the suboptimal fading factor into the extended Kalman filter.

4. The noise adaptive strong tracking extended Kalman filter quadrotor attitude solution method according to claim 1, characterized in that: The specific process of step S5 is to introduce a noise adaptive mechanism to adjust the noise dynamically in real time with a fixed initial value of the noise to adapt to the system needs. The specific formula steps are as follows: P k+1|k+1 =(I-K k+1 H k+1 )P k+1|k (14) In the above formula, are the estimated noise variance and noise mean, S k+1 is the new information, R0 and r0 are the initial values ​​of the noise variance and mean, respectively. As k increases, it is ensured that the system has a certain initial value of noise, so that the Kalman gain K k+1 Too large or too small will cause the system to lose its regulating effect; V k+1 、M k+1 、N k+1 To calculate the intermediate amount of the suboptimal fading factor, λ k+1 is the suboptimal fading factor, P k+1|k is the one-step forecast covariance matrix.