Abstract

To solve the problem of micro-electro-mechanical system (MEMS) gyroscope noise, this paper presents a variational mode decomposition (VMD) method based on crow search algorithm. First, the signal was decomposed by variational mode decomposition for optimization of crow search algorithm (CSA-VMD) method. The parameters required by the VMD method (penalty parameter α and decomposition number K) are given by the crow search algorithm, and then the signal is decomposed into the superposition of multiple subsignals, called intrinsic mode functions (IMFs). The sample entropy (SE) corresponding to each IMF is then obtained. By calculating the sample entropy, the noise signal can be divided into pure noise part, mixing part, and temperature drift part. Second, Savitzky–Golay smoothing denoising (SG) is used to filter the mixed noise signal to eliminate the influence of noise. Third, for the filtering of the drift part, the least square support vector machine optimized by the crow search algorithm (CSA-LSSVM) was used to filter, so as to reduce the effect of temperature drift. Finally, the processed signal is reconstructed to achieve the goal of denoising. Through the results, it can be found that the optimized VMD and LSSVM using CSA algorithm can achieve more effective denoising. After using the method proposed in this paper, the angular random walk value is 1.1175  10−4°/h/√Hz, and the bias stability is 0.0017°/h. Compared with the original signal, the two signals are optimized by 98.1% and 98.2%, respectively. It can be seen from the experimental results that the proposed CSA-VMD method, SG method, and CSA-LSSVM method can effectively eliminate noise effects.

1. Introduction

In recent years, the research of micro-electro-mechanical system (MEMS) gyroscope is endless, and it has been widely used in aviation, spaceflight, navigation, and civil electronic equipment. The reason for this is that micro-electro-mechanical system (MEMS) gyroscope has high efficiency, low price, low energy consumption, and other cost-effective characteristics [1]. However, some inevitable defects of the MEMS gyroscope (e.g., noise and temperature drift) limit its application in many aspects [2]. Therefore, it is crucial to eliminate the influence of errors. There are two kinds of temperature error processing methods: hardware compensation and software compensation [3].

By controlling the circuit and improving the structure of the gyroscope, the temperature performance of the gyroscope is improved and the hardware compensation is realized [4]. For instance, in [5], an innovative temperature compensation method is presented, which is based on variable temperature resistance-driven mode vibration characteristic compensation. In [6], it reduces the damping coefficient effect and designs an effective resonant frequency of the circuit.

The appearance of software compensation makes up the disadvantage of high cost and complicated steps in the hardware compensation of MEMS gyroscope. By setting up the specific mathematical model, it achieves the goal of simple operation and high performance-price ratio. Similar to signal filtering, temperature compensation is also the most commonly used software compensation method for various gyroscopes and MEMS gyroscopes when dealing with temperature error. In [7], improved empirical mode decomposition (EMD) and integrated extreme learning machine (ELM) model are used for temperature compensation.

In order to get the compensated signal and eliminate the drift and noise, we deal with the software temperature error of MEMS gyroscope. Through serial processing and parallel processing and according to the low frequency characteristics of the drift part and the high frequency characteristics of the noise part, they are processed, respectively [8]. Empirical mode decomposition (EMD) [9] and wavelet decomposition [10] are commonly used in multiscale analysis. However, mode mixing is often mixed with empirical mode decomposition (EMD), so ensemble empirical mode decomposition (EEMD) is proposed. In order to improve the shortcomings of EEMD, such as false mode, extra postprocessing, and large computation burden, and to avoid the problem of predecomposition and overdecomposition, this paper proposes a method to stratify the decomposed subsignals by using sample entropy.

Variational mode decomposition (VMD) can achieve noise signal processing to a certain extent, and it is necessary to determine the values of two parameters α and K when using this method. Different values have different influences on the final denoising results. Therefore, when these two parameters are artificially set, incomplete decomposition or excessive decomposition will usually be caused. Similarly, when the least square support vector machine (LSSVM) realizes temperature compensation, it also involves the choice of two parameters. The advantage of crow search algorithm (CSA) is that it can determine the optimal value of parameters, so as to achieve the most efficient signal processing.

The variational mode decomposition (VMD) method [11] optimized by CSA in this paper is used to decompose the noise signal, and the Savitzky–Golay smoothing denoising (SG) method is used to denoise the decomposed signal. The framework is as follows. We give a brief introduction to MEMS gyroscopes in Section 2. In Section 3, VMD and CSA-VMD are introduced, and the CSA algorithm is described in detail, and then the SG method is analyzed. In Section 4, the optimized VMD method is compared with the traditional VMD method to prove that the former is due to the latter. Section 5 draws the conclusion.

2. Dual-Mass MEMS Gyroscope

2.1. The Introduction of MEMS Gyroscope Structure

The gyroscope shown in Figure 1 has a tuning fork structure. As can be seen from Figure 1, the operating mode of the rotating fork gyroscope can be divided into the drive mode and sense mode. Drive frame, drive combs, and drive springs constitute the drive mode [12, 13], sense frame, sense combs, and sense springs constitute the sense mode, and the mass is included in them. Under the control of the monitoring circuit, the two masses of the drive mode vibrate opposite each other along the x axis, driven by a certain amount of static electricity. When the angular velocity along the Z-axis is input, the vibration mass produces a Coriolis effect, and it then moves onto the Y-axis and becomes a motion of the sensory frame [14].

The gyroscope connects the spring (U-shaped) to the driving mass, and the X-axis of the driving spring is connected to the two sensory masses, respectively. The driving mode follows the shifting fork principle. Figure 2 shows the first four stages of simulation using Ansys software, and there are large frequency differences between the modes. Here set the actual driving mode as the fourth with a quality factor greater than 2000. The other three modes have different driving modes with different resonant frequencies, and driver reversing mode is what we expect. Therefore, the left and right Coriolis masses are two degrees of freedom of the driving frame (X-axis) and the feeling frame (Y-axis), respectively.

MEMS gyroscope is driven by alternating Coriolis forces caused by orthogonal vibration and rotation. Based on the principle of conservation of angular momentum, it is a constantly rotating object, and the axis direction does not change with the rotation of the bracket. MEMS gyroscopes use Coriolis forces to provide the tangential force exerted by a rotating object in radial motion. The equations of motion of a gyroscope are equations (1)–(3).

is equivalent mass of drive mode, is the quality of sense mode, and is equivalent mass of Coriolis mass. , , and are the displacements of the driving mode, the sensing in-phase mode and the anti-phase mode respectively. , , and are the quality factors of driving mode, sensing in-phase and anti-phase modes.

2.2. The Introduction of the Gyroscope Monitoring System

The monitoring system of the gyroscope is shown in Figure 3. When the driving sensor comb perceives the displacement of the driving frame (set to x (t)), the signal is transmitted to the split amplifier to require the full-wave signal phasor, and the phase delay of the signal vector is 90°, which also satisfies the phasor and the AC drive signal. The low-pass filter and the rectifier are then applied to the extracted Vdac and the reference voltage Vref. After the comparator outputs, the integrator controller generates a control signal. Vdacsin (dt) low-pass filter demodulates the moving signal. The yellow part of the image shows the sensing open-loop output signal [15, 16].

By detecting the motion signals of the left and right sensing frames, the differential detection amplifier amplifies the output again and generates the motion signals of the sensing mode. Vdacsin (dt) demodulation can obtain detection mode movement signal and eliminate noise [17]. To generate a sensing mode movement signal, the output signal can be processed with a second differential amplification. Acquisition of detected mode motion signals is combined with the use of low-pass filter noise cancellation.

3. Algorithm

3.1. VMD Method

VMD is a method of signal decomposition, similar to a Vinax filter bank [11]. The technology has the ability to determine the number of mode decomposition. Then, the search and the solving process can adaptively match best center frequency for each mode and limited bandwidth and can achieve effective separation of intrinsic mode components (IMF) and signal in the frequency domain and then get the effective decomposition of given signal components. The sum of the decomposed subcomponents is the original signal, and the constraint variational expression is as follows:where represents the k-th IMF and represents the central frequency.

The Lagrange multiplier operator and α solve the problem of constrained variation by transforming the constrained variation into unconstrained variation. Therefore, the Lagrangian is

The multiplier alternating direction method (ADMM) can be used to solve equation (2) and is updated according to the following equations:

Update the Lagrange multiplier by the following equation:

The update process is repeated until equation (9) is satisfied.

Given  = 10−6, all IMFs can be recovered according to the above cycle. The specific VMD algorithm can be found in [18].

3.2. CSA-VMD Method

In the actual operation, the VMD method must set the parameters (α and K) artificially. In [1922], it is explained that these two parameters have a great influence on the decomposition amount, resulting in overdecomposition or underdecomposition; thus, loss of effective information and incomplete denoising are caused. The CSA algorithm can reasonably determine the parameters and optimize the parameters to the optimal position. Figure 4 shows the flowchart of CSA-VMD.

CSA is called a crow search algorithm, which is observed from the behavior of crows. The crows put the food they have hunted in their nests and take it back when they eat it. Crows also observe other crows hiding food in their nests and attempt to steal the food from the current nest. When the first crow commits a theft, it will be on high alert and take certain protective measures to prevent itself from becoming the victim of stolen food. Research has shown that crows are highly logical, and they will use a variety of reasonable ways to protect their food, such as moving nests. They use their behavioral experience to predict what the next thief will do and to move their nest to a safer place to avoid food theft.

Based on the habits of crows, the CSA algorithm is used in this paper to optimize the parameter selection of the traditional VMD method. The principles are as follows:(1)Crows live in groups.(2)Crows can remember the location of the nest where they hide their food.(3)Crows have the ability to learn from other crows to steal food.(4)Crows have a sense of protection and can reasonably choose the location of their new nest after being stolen.

Next, according to the above principles, in order to determine the internal parameters of the VMD method, we will conduct the simulation of this algorithm in a three-dimensional environment.

Step 1. initialize the problem. Let the number of crows N = 30, the probability of protection consciousness be AP = 0.1, the flight length be f1 = 2, all crows be regarded as a crow group, and the maximum iteration number be 30.

Step 2. Set the crow group and the crow memory matrix according to equations (10) and (11). Since the crows have no experience at the beginning, let the food be hidden in the crows’ nests, that is, the initial position.

Step 3. Since internal parameters α and K need to be optimized, we put values of α and K into each nest.

Step 4. The fitness function (ft) was set to determine whether the crows formed memories.

Step 5. Identify the location of the crow’s new nest by equation (12) and determine if it is feasible. If feasible, update the nest location; otherwise, the original position remains unchanged.where represents the new nest, represents the last nest, rand represents the consciousness probability of the crow, and represents the location of the new nest in the memory of the crow.

Step 6. Update the crow’s memory by equation (13).

Step 7. Determine whether the iteration is completed, determine the best memory and the best position, and correspond to the internal parameters α and K of the VMD method.

3.3. SE Method

Take a time series , whose length is n. Renumber k. generating a sequence of vectors with dimension m, where [2325]

This means that there are m consecutive values of x. The distance between and is the absolute value of the maximum value of the difference between the two elements.

Calculate the distance between and given, and record the number of distances that are less than or equal to r, which we call .

Define as

When the dimension is k+1, calculate the number of and that are less than r apart from . Define and as

The sample entropy is defined as

After CSA-VMD decomposition, sample entropy is used to classify the decomposed subsignals to achieve the purpose of denoising.

3.4. SG Filtering

The SG smoothing algorithm was proposed by Savitzky and Golay. Polynomial smoothing algorithm is based on least squares principle, also known as convolution smoothing. In [26], the algorithm is described in detail. Take m points near the original data x and set x as the origin. Next, construct 2m + 1 x-centered sampling points to take window data and then construct i-order polynomial:

The corresponding residual is

The filtering result is

Savitzky and Golay found that calculating is equivalent to performing a FIR filter on the original data. In other words, you can do it using convolution.

When is the minimum value, it has a good fitting degree with the original data. The partial derivative of with respect to each parameter is 0.

After the formula is solved, the result is

After equation (16), SG filtering is completed.

3.5. CSA-LSSVM Method

The introduction of CSA-LSSVM will be divided into two parts. SVM- and LSSVM-related issues will be explained.

Support vector machine (SVM) can directly analyze the linear case. When the linearity is not separable, the nonlinear mapping algorithm is used to transform it into the linear separable state of the high-dimensional mode. In this way, the linear algorithm is used to analyze the original nonlinear situation in the high-dimensional space, and then it is extended to the function fitting and other machine learning problems.

Based on structural risk minimization, SVM seeks a balance between the complexity (learning accuracy) and learning ability (error-free recognition) of the model constructed with limited sample information, so as to obtain the best generalization ability (generalization ability). SVM schematic diagram is shown in Figure 5. Its optimal classification function is

Obviously, the SVM classification function is similar to the neural network in form, which obtains the corresponding output through the linear combination of the process nodes. The inner product of the support vector machine corresponds to the nodes, which is also called the support vector network. Due to the inequality constraint problem, SVM has great hindrance in solving Lagrange multiplier and alpha. The least square support vector machine (LSSVM) transforms the original inequality constraint problem into equality constraint, which greatly optimizes the solution process and speeds up the operation speed. Inequality constraints for SVM are as follows:

The equality constraints for LSSVM are as follows:where is the relaxation variable and represents the introduction outlier in the support vector. The optimization objective contains and , and , and they determine the optimal hyperplane and the minimum deviation value. Next, the Lagrange multiplier method is used to find the maximum value of in the classification function

Take the derivative of the parameters, respectively, make the derivative result 0, and define the kernel matrix :

Obtain the linear equations of A and B:

After solving the equation and getting relevant data, the regression function of LSSVM is as follows:

The advantages of CSA-LSSVM are described below.

Firstly, the least square support vector machine (LSSVM) is an improvement of the support vector machine (SVM), which realizes the optimization of temperature compensation effect. It is to change the inequality constraint of traditional support vector machine into equality constraint and take the error square and loss function as the experience loss of training set, so that the quadratic programming problem is transformed into the problem of solving linear equations, and the speed and convergence precision of solving the problem are improved.

Secondly, CSA optimized the two parameters of LSSVM, GAM and SIG2, to find the optimal combination of parameters, so as to improve the classification accuracy and achieve the optimal processing of temperature compensation.

The flowchart of CSA-LSSVM model recognition process is shown in Figure 6.

3.6. CSA-VMD-SG-LSSVM Method

Based on the previous explanation, this paper integrates the above methods and applies them to MEMS gyroscope denoising and temperature compensation. The flowchart is shown in Figure 7. The specific steps are as follows:(1)The experimental MEMS gyroscope output data are decomposed by variational mode decomposition (VMD).(2)CSA is used to optimize the two parameters of VMD, and the optimal solution was obtained.(3)The decomposed components are divided into drift layer, mixed layer, and pure noise layer by using sample entropy.(4)CSA-LSSVM processing is applied to the trend layer, and SG filtering is applied to the mixed noise layer to remove the pure noise layer.(5)The processed trend layer and the mixed noise layer are superimposed to form the final reconstructed signal.

4. Experiment and Discussion

4.1. Experiments

By testing the temperature characteristics of MEMS gyroscopes, we can verify the accuracy and feasibility of the proposed method—CSA-VMD-SE-SG. The gyroscopes and instruments used in the experiment are shown in Figure 8. The detection circuit is connected to the electrical signal through a metal pin and the printed circuit board is wrapped with a rubber pad to protect the printed circuit. To shield against electromagnetic interference, the coated printed circuit board is placed in a grounded metal housing. The structure chip connection interface (the first PCB) realizes the processing of the weak signal, and the sensing loop and the drive closed loop correspond to the two remaining PCBs, respectively. The experimental device has a signal generator for generating test voltage, signal amplitude, and phase; ±10 v DC voltage and ground power supply (Agilent E3631A) are obtained by means of multimeter (Agilent 34401A) and oscilloscope (Agilent DSO7104B). The temperature oven provides a full temperature range for our experiment; the actual bandwidth is measured by the measuring gyroscope [24].

First, the MEMS gyroscope is powered for one hour at room temperature. The ambient temperature is raised to 60°C (initial temperature) using a temperature oven, and the temperature of the gyroscope’s inner shell remains the same as the ambient temperature. To ensure that there is no temperature difference between the gyroscope and the oven, the temperature of the oven should be kept at 10°C per hour during the data collection. The detailed experimental data and analysis process are presented below.

4.2. Experimental Results

The original data of the MEMS gyroscope experiment are shown in Figure 9. The experiment is accompanied by noise interference. Figure 9 shows the output analysis and temperature drift analysis based on the experimental data. It can be seen from the image that there is a certain correlation between the two, and the voltage changes by 0.0301 V between 55°C and −32°C. To minimize the error of the experimental results, we need to carry out denoising operation. Next, we will process the noise signal to make it easy to compare the effect before and after noise removal.

We decompose the experimental data using the CSA-VMD method, as shown in Figure 10, into eleven IMFs. Through experiments, we found that CSA found the optimal α and K (30 iterations). However, due to the influence of artificially set internal parameters, VMD has underdecomposition, as shown in Figure 11. Next, the sample entropy of the 11 components after decomposition is calculated, and the calculated results are shown in Figure 12. According to the sample entropy theory, the larger the sample entropy is, the more complex the sample component is. After the sample entropy is divided, the noisy component is divided into three parts, which are drift part, mixed noise part, and pure noise part.

First of all, SG filtering is used to denoise the mixed noise part. As can be seen from Figure 13, SG filtering can effectively filter out noise interference and retain effective data. Next, the drift part is compensated. The CSA-LSSVM compensation method adopts two groups of experimental data for training and testing. As shown in Figure 14, the predicted output and the test output have a good fit. The reconstructed signal after compensation is shown in Figure 15. It can be seen that the temperature drift phenomenon is greatly eliminated after compensation, and the fitting error is small.

4.3. Comparison

In the following, we will intuitively illustrate the effectiveness of the processing method by comparing the eigenvalues of the original signal and the signal processed based on CSA-VMD-SG-LSSVM. Figure 15 shows the comparison of denoising effects of different denoising methods in this experiment. It can be clearly seen that CSA-VMD-SG has the best denoising result. In order to illustrate the superiority and effectiveness of CSA algorithm, we separately compared VMD with CSA-VMD, LSSVM, and CSA-LSSVM.

As shown in Figure 16, due to the underdecomposition problem of VMD algorithm, although the noise is reduced to some extent, some noise is still not effectively removed. CSA-VMD selects the optimal parameters during the stratification, and after the optimal stratification, the noise can be removed to the maximum extent within the capability of the method, which lays a foundation for the subsequent SG filtering.

Similarly, there are two parameters of LSSVM that need to be determined by CSA algorithm. Figure 17 compares the predicted output and test output before and after the use of CSA. There is a significant error in the range of 6000 to 8000 seconds, and the LSSVM-predicted output has a large deviation from the test output. From the local magnification of other fitting parts, it can be seen that CSA-LSSVM has better fitting degree than LSSVM. The mean square error of LSSVM is 0.0049°/s, while that of CSA-LSSVM is 4.0678  10−5°/s, which can intuitively show the differences between the two methods through data. No matter the mean difference or the contrast figure of two methods, CSA-LSSVM has a higher fitting effect than LSSVM and can better eliminate errors caused by temperature drift.

The variances of the two signals are calculated by Allan algorithm. Allan algorithm has a high degree of recognition in the aspect of gyroscope denoising analysis. Figure 18 shows the processing results of signals before and after denoising using different algorithms. The results in the figure show that for the original signal, the angular random walk value is 0.0054°/h/√Hz, and the angular random walk value based on CSA-VMD-SE-SG-LSSVM processing is 1.1175  10−4°/h/√Hz. The bias stability of the original signal is 0.0909°/h, and the denoising signal is 0.0017°/h. Compared with the original signal, angular random walk value of the processed signal is optimized by 98.1% and bias stability of it is optimized by 98.2%.

In order to show the advantages of CSA algorithm directly, the Allan algorithm without using CSA algorithm is analyzed. The angular random walk value is 1.0364  10−4°/h/√Hz, and the bias stability is 0.0103°/h. Compared with the original signal, these two indexes are optimized by 98.1% and 88.7%, respectively. It can be clearly seen from the optimized percentage that the optimized result of CSA algorithm is significantly better than the unoptimized one. Therefore, the method proposed in this paper can filter out the noise in the original signal well and has a good performance in the data processing of MEMS gyroscope.

5. Conclusion

A temperature error denoising method for MEMS gyroscope based on CSA-VMD-SG-LSSVM is proposed in this paper. First of all, the above methods are effective in denoising. In both VMD and LSSVM, the optimized results using CSA are better than those before optimization. Each component can be distinguished from the analysis of the SE of each component, and the mixing layer can be filtered by SG and CSA-LSSVM compensates the drift layer. Then, by comparing the angular random walk value and the bias stability of the signal before and after denoising, the optimization effect is intuitively demonstrated. It can be seen from the above experimental results that the proposed method is more effective in MEMS gyroscope denoising.

Data Availability

The data used to support the findings of this study are available from the corresponding author upon request.

Conflicts of Interest

The authors declare that they have no conflicts of interest.