Battery SOC estimation method fusing improved GRU network and Bayesian filtering

By adopting the improved fusion method of GRU neural network and Bayesian filtering in lithium-ion battery SOC estimation, combined with the adaptive gray wolf optimization algorithm, the problem of insufficient model generalization ability in the existing technology is solved, and a higher Prediction accuracy and stability.

CN118914854APending Publication Date: 2024-11-08CHANGAN UNIV
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202410972135.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-07-19
Publication Date
2024-11-08

AI Technical Summary

Technical Problem

In the existing SOC estimation methods of lithium-ion batteries, neural network-based models lack generalization capabilities, resulting in large fluctuations in prediction accuracy and low reliability, and it is difficult for a single algorithm to model accurate complex nonlinear systems.

Method used

Using the improved fusion method of GRU neural network and Bayesian filtering, the initial weight and bias of GRU neural network is optimized by introducing an adaptive gray wolf optimization algorithm, and the fusion of multiple GRU models is improved through Bayesian filtering. model adaptability and predictive stability.

Benefits of technology

It improves the accuracy and generalization ability of SOC estimation of lithium-ion batteries, enhances the prediction stability and reliability of the model, and can more accurately consider the combined impact of battery state of charge and current, voltage and temperature.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118914854A_ABST
    Figure CN118914854A_ABST
Patent Text Reader

Abstract

The invention provides a battery SOC estimation method fusing an improved GRU network and Bayesian filtering, and the method comprises the steps: carrying out the normalization processing of the parameters of a lithium ion battery, and forming normalized data, which comprises a training set and a test set; a convergence factor of the grey wolf algorithm is optimized by introducing randomness and a nonlinear decline mode, and an improved grey wolf algorithm is formed; optimizing the initial weight and bias of the GRU neural network by adopting an improved grey wolf algorithm to form an optimized GRU neural network; substituting the training set into the optimized GRU neural network to obtain a plurality of GRU neural network models; and based on the plurality of GRU neural network models, fusing the plurality of GRU neural network models through Bayesian filtering to obtain a GRU neural network model after Bayesian filtering fusion, and estimating the lithium ion battery soc.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of battery technology, and specifically relates to a battery SOC estimation method integrating an improved GRU network and Bayesian filtering. Background Art

[0002] Accurate estimation of the battery state of charge (SOC) directly affects the efficiency and safety of lithium battery packs. Today's lithium-ion battery SOC estimation methods are roughly divided into mechanism-based, data-driven and fusion-based models. Although the mechanism-based model has high accuracy, it is not widely applicable and requires modelers to have a very high theoretical knowledge foundation. Its prediction accuracy is greatly affected by the accuracy of the model. The more accurate the model, the more factors it considers, the higher the complexity of the model, and the difficulty of modeling also increases sharply. Data-driven models only require a large amount of battery degradation data to achieve modeling of nonlinear systems such as lithium-ion battery SOC estimation, and they have very wide applicability. However, there is still no accurate answer to what algorithm is the optimal solution to simulate complex nonlinear systems such as batteries. Different algorithms have their unique advantages, but also have their unavoidable defects. It is often difficult to model a very accurate model using a single algorithm.

[0003] In the existing technology, there are methods for estimating battery SOC using neural networks, but most of them do not take into account the generalization ability of the built model, resulting in large fluctuations in model prediction accuracy and low reliability. Summary of the invention

[0004] In order to overcome the shortcomings of the above-mentioned existing technologies, a model is built based on the advantages of the integrated gated recurrent unit (GRU) neural network and the improved grey wolf optimization algorithm (AGWO). By establishing multiple models and fusing them with Bayesian filtering, the adaptability of the model is further improved and its prediction stability is improved. At the same time, the rationality of model selection is also explained in detail when selecting the main body of the prediction model. Through the reasonable combination of algorithms and the comprehensive advantages of each, a battery SOC estimation method integrating the improved GRU network and Bayesian filtering is proposed.

[0005] The present invention proposes a battery SOC estimation method integrating an improved GRU network and Bayesian filtering, comprising:

[0006] Acquiring parameters of the lithium-ion battery, and normalizing the parameters of the lithium-ion battery to form normalized data, wherein the normalized data includes a training set and a test set;

[0007] The convergence factor of the Grey Wolf Algorithm is optimized by introducing randomness and nonlinear decreasing mode to form an improved Grey Wolf Algorithm.

[0008] The improved grey wolf algorithm is used to optimize the initial weights and biases of the GRU neural network to form an optimized GRU neural network;

[0009] Bringing the training set into the optimized GRU neural network to obtain multiple GRU neural network models;

[0010] Based on the multiple GRU neural network models, preliminary screening is performed through GRU neural network model test errors, and the multiple GRU neural network models are fused through Bayesian filtering to obtain a GRU neural network model fused through Bayesian filtering;

[0011] The soc of the lithium-ion battery is estimated based on the GRU neural network model after Bayesian filtering fusion.

[0012] Preferably, the optimization of the convergence factor of the Grey Wolf Algorithm by introducing randomness and nonlinear decreasing mode to form an improved Grey Wolf Algorithm comprises:

[0013] Generate a random number in the range of 0-1;

[0014] The convergence factor of the gray wolf algorithm is introduced into the trigonometric function to change the distribution characteristics of random numbers and together with the random numbers constitute a nonlinear decreasing pattern of the convergence factor. At the same time, the current number of iterations, the maximum number of iterations and the random number of the gray wolf algorithm are combined to form an improved gray wolf algorithm.

[0015] Preferably, the convergence factor is determined based on the current number of iterations of the Grey Wolf Algorithm and the random number, using the following calculation formula:

[0016]

[0017] In the above formula: α is the convergence factor of the gray wolf algorithm, rand() is a random number in the range of 0-1, t is the current number of iterations, T max is the maximum number of iterations.

[0018] Preferably, the parameters of the lithium-ion battery are obtained, and the parameters of the lithium-ion battery are normalized to form normalized data, and the normalized data includes a training set and a test set. The specific process satisfies the following formula:

[0019]

[0020] Where: v represents the normalized data; v0 represents the parameters of the lithium-ion battery; v min The minimum value of the lithium-ion battery parameter, v max Indicates the maximum value of the parameter of lithium-ion battery.

[0021] Preferably, the improved grey wolf algorithm is used to optimize the initial weights and biases of the GRU neural network to form an optimized GRU neural network, including:

[0022] Using an improved gray wolf algorithm to optimize the initial weights of the GRU neural network and the initial bias of the GRU neural network to form the optimized initial weights of the GRU neural network and the optimized initial bias of the GRU neural network;

[0023] Adopting the improved grey wolf algorithm to iteratively optimize the optimization initial weight and the optimization bias;

[0024] When the number of iterations reaches the preset maximum number of iterations, the final optimization weights and final optimization biases of the GRU neural network optimized by the improved grey wolf algorithm are output to form an optimized GRU neural network.

[0025] Preferably, in the iterative optimization process, the fitness function of the improved grey wolf algorithm is defined as follows:

[0026]

[0027] In the above formula: F is the fitness value, M is the number of samples s for the initial weight and bias of the iteration, is the expected output of the kth output node of sample s; is the output of the kth output node under the action of sample s, and n is the number of output nodes.

[0028] Preferably, the training set is introduced into the optimized GRU neural network to obtain multiple GRU neural network models, including:

[0029] The training set includes: battery voltage, current and average temperature. The input of the optimized GRU neural network is a 3×M matrix consisting of voltage, current and average temperature as training set samples. The matrix is ​​expressed as follows:

[0030]

[0031] In the above matrix, M represents the total number of training set samples, u1...u M is the voltage, i1...i M is the current, t1...t M is the average temperature, X is a matrix;

[0032] The output variable is a 1×M row vector composed of battery parameters, which satisfies the following row vector:

[0033] X=(soc1…soc M )

[0034] In the above row vector: soc1…soc M are the elements in the row vector.

[0035] Based on the input variables and output variables, multiple GRU neural network models are formed.

[0036] Preferably, the multiple GRU neural network models are preliminarily screened by GRU neural network model test errors, and the multiple GRU neural network models are fused by Bayesian filtering to obtain a GRU neural network model fused by Bayesian filtering, including:

[0037] Based on the multiple GRU neural network models, the errors of the multiple GRU neural network models are calculated by using a root mean square error formula for the multiple GRU neural network models through a test set;

[0038] Screening the corresponding multiple GRU neural network models whose errors are within the preset error interval, using the data of the test set to estimate the battery SOC value through the GRU neural network model, taking the SOC value estimated by the multiple GRU neural network models selected and the GRU neural network model corresponding to the maximum error as the prior value of the Bayesian filter, taking the SOC value estimated by the multiple GRU neural network models selected and the multiple GRU neural network models corresponding to the smaller error as the posterior value of the Bayesian filter, the posterior value is used to correct the multiple GRU neural network models with large error values, and fusing the multiple GRU neural network models selected through Bayesian filtering to form a GRU neural network model after Bayesian filtering fusion;

[0039] The method of estimating the soc of the lithium-ion battery according to the GRU neural network model after the Bayesian filtering fusion includes:

[0040] The battery SOC is estimated by the battery voltage, current and temperature according to the GRU neural network model after Bayesian filtering fusion.

[0041] Compared with the closest prior art, the present invention has the following beneficial effects:

[0042] 1. The battery SOC has a very strong correlation with the battery current, voltage and temperature. In addition to the strong correlation at the current moment, this correlation also has a strong correlation in the single variable time series. Therefore, when estimating SOC through a neural network, the combined effects of the variables in the past and present should be considered. Therefore, the present invention estimates the battery SOC with the gated recurrent unit (GRU) neural network as the backbone. The GRU neural network is a variant of the recurrent neural network (RNN), which has the characteristics of a simple structure and few parameters. It has a faster training speed and lower computing cost in some tasks, and also avoids the problem of vanishing gradients in RNN. At the same time, its biggest feature is that it can integrate the influence of variables on the time series, which is very consistent with the above idea in terms of function.

[0043] 2. Since the training mode of the GRU neural network is similar to that of most neural networks, the gradient descent algorithm is used to update the parameters. However, once the initial weight and bias selection of the gradient descent algorithm deviates too much from the minimum error value, it is likely to fall into the local minimum. In order to improve this shortcoming of the GRU neural network, the present invention optimizes its weights and biases based on a gray wolf optimization algorithm (GWO) with better global search capability.

[0044] 3. By introducing random numbers and nonlinear functions to change the calculation method of the GWO convergence factor α, it is improved to the adaptive grey wolf optimization algorithm (AGWO), so that the global search ability and convergence speed of GWO are further enhanced, and the initial weights and biases of the GRU neural network are optimized to improve its shortcoming of being easily trapped in the local minimum.

[0045] 4. Multiple GRU neural network models are established through multiple training sets, and then the error size of each model is evaluated through multiple test sets. Different weights are assigned according to the error size, and then the established GRU neural network models are fused through Bayesian filtering to obtain the final fusion model, so as to further increase the estimation accuracy and generalization ability of the fusion model. Taking full account of the generalization ability of the model, the model prediction accuracy fluctuates little and has high reliability. BRIEF DESCRIPTION OF THE DRAWINGS

[0046] Figure 1 is a work flow chart of the method of the present invention;

[0047] Figure 2 It is the internal structure diagram of the GRU algorithm of the present invention;

[0048] Figure 3 is a work flow chart of the method of the present invention;

[0049] Figure 4 It is the workflow diagram of the GRU neural network model of the present invention;

[0050] Figure 5 This is the GRU neural network model fusion flow chart of the present invention. DETAILED DESCRIPTION

[0051] The following is combined with Figure 1-5 The specific implementation methods of the present invention are further described in detail.

[0052] Embodiment 1:

[0053] A battery SOC estimation method integrating an improved GRU network and Bayesian filtering of the present invention comprises:

[0054] Acquiring parameters of the lithium-ion battery, and normalizing the parameters of the lithium-ion battery to form normalized data, wherein the normalized data includes a training set and a test set;

[0055] The convergence factor of the Grey Wolf Algorithm is optimized by introducing randomness and nonlinear decreasing mode to form an improved Grey Wolf Algorithm.

[0056] The improved grey wolf algorithm is used to optimize the initial weights and biases of the GRU neural network to form an optimized GRU neural network;

[0057] Bringing the training set into the optimized GRU neural network to obtain multiple GRU neural network models;

[0058] Based on the multiple GRU neural network models, the multiple GRU neural network models are fused through Bayesian filtering to obtain a GRU neural network model after Bayesian filtering fusion; GRU stands for gated recurrent unit.

[0059] According to the GRU neural network model after Bayesian filtering fusion, the soc of the lithium-ion battery is estimated, and soc represents the state of charge of the battery.

[0060] Preferably, the optimization of the convergence factor of the Grey Wolf Algorithm by introducing randomness and nonlinear decreasing mode to form an improved Grey Wolf Algorithm comprises:

[0061] Generate a random number in the range of 0-1;

[0062] The convergence factor of the gray wolf algorithm is introduced into the trigonometric function to change the distribution characteristics of random numbers and together with the random numbers constitute a nonlinear decreasing pattern of the convergence factor. At the same time, the current number of iterations, the maximum number of iterations and the random number of the gray wolf algorithm are combined to form an improved gray wolf algorithm.

[0063] Furthermore, the convergence factor is determined based on the current number of iterations of the gray wolf algorithm and the random number, using the following calculation formula:

[0064]

[0065] In the above formula: α is the convergence factor of the gray wolf algorithm, rand() is a random number in the range of 0-1, t is the current number of iterations, T max is the maximum number of iterations.

[0066] Furthermore, the parameters of the lithium-ion battery are obtained, and the parameters of the lithium-ion battery are normalized to form normalized data, wherein the normalized data includes a training set and a test set, and the specific process satisfies the following formula:

[0067]

[0068] Where: v represents the normalized data; v0 represents the parameters of the lithium-ion battery; v min The minimum value of the lithium-ion battery parameter, v max Indicates the maximum value of the parameter of lithium-ion battery.

[0069] Furthermore, the improved grey wolf algorithm is used to optimize the initial weights and biases of the GRU neural network to form an optimized GRU neural network, including:

[0070] Using an improved gray wolf algorithm to optimize the initial weights of the GRU neural network and the initial bias of the GRU neural network to form the optimized initial weights of the GRU neural network and the optimized initial bias of the GRU neural network;

[0071] Adopting the improved grey wolf algorithm to iteratively optimize the optimization initial weight and the optimization bias;

[0072] When the number of iterations reaches the preset maximum number of iterations, the final optimization weights and final optimization biases of the GRU neural network optimized by the improved grey wolf algorithm are output to form an optimized GRU neural network.

[0073] Furthermore, in the iterative optimization process, the fitness function of the improved grey wolf algorithm is defined as follows:

[0074]

[0075] In the above formula: F is the fitness value, M is the number of samples s for the initial weight and bias of the iteration, is the expected output of the kth output node of sample s; is the output of the kth output node under the action of sample s, and n is the number of output nodes.

[0076] Furthermore, the training set is introduced into the optimized GRU neural network to obtain multiple GRU neural network models, including:

[0077] The training set includes: battery voltage, current and average temperature. The input of the optimized GRU neural network is a 3×M matrix consisting of voltage, current and average temperature as training set samples. The matrix is ​​expressed as follows:

[0078]

[0079] In the above matrix, M represents the total number of training set samples, u1...u M is the voltage, i1...i M is the current, t1...t M is the average temperature, X is a matrix;

[0080] The output variable is a 1×M row vector composed of battery parameters, which satisfies the following row vector:

[0081] X=(soc1…soc M )

[0082] In the above row vector: soc1…soc M are the elements in the row vector.

[0083] Based on the input variables and output variables, multiple GRU neural network models are formed.

[0084] Furthermore, based on the multiple GRU neural network models, the multiple GRU neural network models are fused through Bayesian filtering to obtain a GRU neural network model fused through Bayesian filtering, including:

[0085] Based on the multiple GRU neural network models, the errors of the multiple GRU neural network models are calculated by using a root mean square error formula for the multiple GRU neural network models through a test set;

[0086] Screening the corresponding multiple GRU neural network models whose errors are within the preset error interval, using the data of the test set to estimate the battery SOC value through the GRU neural network model, taking the SOC value estimated by the multiple GRU neural network models selected and the GRU neural network model corresponding to the maximum error as the prior value of the Bayesian filter, taking the SOC value estimated by the multiple GRU neural network models selected and the multiple GRU neural network models corresponding to the smaller error as the posterior value of the Bayesian filter, the posterior value is used to correct the multiple GRU neural network models with large error values, and fusing the multiple GRU neural network models selected through Bayesian filtering to form a GRU neural network model after Bayesian filtering fusion;

[0087] Furthermore, the estimating the SOC of the lithium-ion battery according to the GRU neural network model after the Bayesian filtering fusion includes:

[0088] The battery SOC is estimated through the battery voltage, current and temperature according to the GRU neural network model after Bayesian filtering fusion.

[0089] Gray Wolf Optimization (GWO) is a swarm intelligence optimization algorithm, an optimization search method inspired by the predation of gray wolves. It has the characteristics of strong global search ability, strong convergence performance, few parameters, and easy implementation. Gray wolves are social animals that strictly abide by a social dominance hierarchy. According to the hierarchy, they can be divided into four levels, which are represented as α, β, δ, and ω from high to low. The hunting process is divided into searching, surrounding and attacking prey.

[0090] The traditional Grey Wolf Algorithm has the disadvantages of slow convergence in the later stage and easy to fall into the local optimum. This patent optimizes the calculation method of the convergence factor to construct an Adaptive Grey Wolf Optimizer (AGWO) with good global optimization. AGWO improves the balance between global search and local search in the traditional Grey Wolf Algorithm, so that the algorithm can more effectively locate the global optimal solution in the search space, while avoiding premature convergence or falling into the local optimal solution. This method enhances the exploration and development capabilities of the algorithm by introducing randomness and nonlinear decreasing patterns.

[0091] The voltage, current, and temperature are input through an AGWO-GRU neural network model with a large error to estimate an SOC value using the model, which is also the prior value. Then, the SOC value (likelihood value) under the voltage, current, and temperature is input through an AGWO-GRU neural network model with a small error to correct the prior value, thereby obtaining the corrected SOC value (posterior value). Here, it is assumed that the SOC value distribution is Gaussian distribution, and the fusion model is the fusion of three AGWO-GRU neural network models, and the size of the distribution function variance is determined by the size of its root mean square error.

[0092] The fusion model makes full use of the advantages of each algorithm by arranging and combining different algorithms, so as to achieve the best approximation of the complex nonlinear system of lithium-ion battery SOC estimation.

[0093] Embodiment 2:

[0094] A lithium-ion battery SOC estimation method that integrates a gated recurrent unit neural network (AGWO-GRU) optimized by an improved gray wolf algorithm and Bayesian filtering. By analyzing the strong correlation factors of battery SOC, and proposing that the overall effect of a single factor on a time series should be considered when using a neural network model, it is proposed to use a gated recurrent unit (GRU) neural network with this effect as the model body of the battery SOC estimation method of the present invention. On this basis, considering the defect that the gradient descent algorithm of the GRU neural network itself is prone to fall into the local optimal solution, the gray wolf optimization algorithm with strong global search ability is used to optimize its initial weights and biases. Considering that the gray wolf optimization algorithm has a slow convergence speed in the later stage and may fall into the local optimal situation, it is improved to an adaptive gray wolf optimization algorithm (AGWO) by introducing nonlinear functions and random numbers to change the calculation method of the adaptive factor α to further improve the global search ability and convergence speed of the gray wolf optimization algorithm. At the same time, considering that the generalization ability of the AGWO-GRU neural network model may be poor and the uncertainty of a single model is large, multiple AGW O-GRU neural network models are established through multiple training sets. The models are verified through test sets. After analyzing the accuracy of each model, these models are fused through Bayesian filtering to obtain the final fusion model for battery SOC estimation.

[0095] Those skilled in the art should know that:

[0096] Gray Wolf Optimization (GWO) is a swarm intelligence optimization algorithm, an optimization search method inspired by the predation of gray wolves. It has the characteristics of strong global search ability, strong convergence performance, few parameters, and easy implementation. Gray wolves are social animals that strictly abide by a social dominance hierarchy. According to the hierarchy, they can be divided into four levels, which are represented as α, β, δ, and ω from high to low. The hunting process is divided into searching, surrounding and attacking prey.

[0097] The traditional grey wolf algorithm has the disadvantages of slow convergence in the later stage and easy to fall into the local optimum. This patent optimizes the calculation method of the convergence factor to construct an adaptive grey wolf algorithm (Adaptive GreyWolf Optimizer, AGWO) with good global optimization. AGWO improves the balance between global search and local search in the traditional grey wolf algorithm, so that the algorithm can more effectively locate the global optimal solution in the search space, while avoiding premature convergence or falling into the local optimal solution. The present invention enhances the exploration and development capabilities of the algorithm by introducing randomness and nonlinear decreasing mode. The formula is as follows:

[0098]

[0099] Among them, rand() generates a random number in the interval [0,1], cos(rand()) Here the cosine function is applied to the random number. This transformation changes the distribution characteristics of the random number, which helps the Gray Wolf Algorithm to better search the solution space. t The current number of iterations reflects the progress of the algorithm, T max is the maximum number of iterations, α is the convergence factor, which decreases with the number of iterations and is controlled in the range of [0,2].

[0100] The Gated Recurrent Unit (GRU) neural network is derived from the Recurrent Neural Network (RNN). The traditional RNN has the problem of vanishing gradients, which makes it weak in processing feature information of data with a long time distance. At the same time, its training process also uses the gradient descent algorithm to adjust the network parameters, which makes it easy to fall into the local optimal solution. As a variant of RNN, GRU reduces the problem of vanishing gradients of RNN while retaining the advantages of RNN such as its ability to process time series data. At the same time, its structure is simple and has fewer parameters, so it has faster training speed and lower computational cost in some tasks.

[0101] The parameter adjustment algorithm of the GRU neural network is essentially a gradient descent algorithm, and it is inevitable that it is easy to fall into the local optimal solution during the training process. The Gray Wolf Algorithm is an optimization algorithm with a very strong global search capability. On its basis, the Adaptive Gray Wolf Algorithm (AGWO) is formed by introducing random numbers and nonlinear functions into the convergence factor to further enhance its global optimization ability and avoid it from falling into the local optimal solution. By using AGWO to find a set of optimal initial weights and biases of the GRU neural network, the advantage of GRU in processing time series data is brought into play, while the defect of its easy falling into the local optimal solution is improved.

[0102] Based on the above reasons, the present invention is designed as follows:

[0103] Step 1: Normalize the input matrix and output vector to eliminate the impact of dimension and singular sample data. Normalization method:

[0104]

[0105] In the above formula: v represents the normalized result; v0 represents the original value; v min Indicates the minimum value of the row where variable v is located, v max Indicates the maximum value of the row where v is located;

[0106] The input variables are voltage, current and average temperature, and the output variable is battery soc. For the training process, the input is a 3×M matrix consisting of voltage, current and average temperature, which is in the following form:

[0107]

[0108] Where M represents the total number of training set samples. The output is a 1×M row vector consisting of battery soc, in the following format:

[0109] X=(soc1…soc M )

[0110] Step 2: Determine the neural network topology, maximum number of iterations, learning rate, target error, initialize its weights and biases, and determine the maximum number of iterations of the adaptive gray wolf optimization algorithm.

[0111] Step 3: At the same time, define the adaptive gray wolf algorithm fitness function as follows:

[0112]

[0113] Step 4: Calculate the fitness of each initial weight and bias using the output value obtained in step (3). Define the three data with the smallest fitness as the three gray wolves αβδ and the rest as the wolves ω

[0114] Step 5: Update the position of each wolf using the wolf position update formula, and then substitute the weights and biases of these wolves into the neural network for training.

[0115] Step 6: Repeat steps 4 and 5 until the maximum number of iterations of the adaptive gray wolf optimization algorithm is reached, and use the weights and biases represented by α wolf in the last iteration result as the initial weights and biases of the final GRU neural network.

[0116] Step 7: Train the GRU neural network using the weights and biases optimized by the adaptive grey wolf algorithm.

[0117] Based on the AGWO-GRU model, we hope to further increase its accuracy and generalization ability. Although the GRU neural network optimized by AGWO reduces the probability of falling into the local optimum, its essence is still a way to estimate SOC through a neural network. The prediction accuracy of the neural network is affected by the network type, training samples, etc. The battery SOC is affected by current, voltage, temperature, etc. At the same time, from the actual driving scene, such as battery temperature, the temperature at the previous moment and the temperature at the next moment are often not independent and unrelated. If the temperature at the previous moment is high, the temperature at the next moment cannot be very low. That is to say, the correlation of a single variable in the time series should be considered during the neural network training process, and the GRU neural network meets this requirement very well. Therefore, on the basis of not changing the neural network used, in order to further increase its prediction accuracy, the prediction accuracy and generalization ability are further optimized through Bayesian filtering.

[0118] Bayesian filtering:

[0119] Bayesian filtering comes from the Bayesian formula, and is also the origin of Kalman filtering, variant Kalman filtering, particle filtering and other filtering. It obtains the posterior probability by combining the prior probability with the likelihood probability. Whether it is a subjective guess by a person, a direct measurement by a sensor, or a simulation by a model, it is impossible to be 100% error-free. Bayesian filtering combines subjective or well-founded speculation with the quantity or observation after model simulation to obtain the data closest to the actual value.

[0120] The continuous occasion Bayesian formula is as follows:

[0121]

[0122] Where: f X|Y (x|y) represents the posterior probability density function, f X (x) represents the prior probability density function, f Y|X (y|x) represents the likelihood probability density function.

[0123] Bayesian filtering principle:

[0124] Suppose there is a random process X0,X1…X K Starting from X1, each time an observation Y1, Y2…Y K , used to correct the value of X. The following equations are the state equation and the observation equation. The state equation is used to reflect the value of X. K and X K-1 relationship.

[0125] X K =f(X K-1 )+Q K (17)

[0126] Y K =f(X K )+R K (18)

[0127] Here, since the corresponding model of the battery's SOC and temperature, voltage, and current has been obtained through the GRU neural network model, the model can be directly used to replace the state equation and observation equation.

[0128] The traditional steps are as follows:

[0129]

[0130] In the present invention, a GRU neural network model with a large error is used to input voltage, current, and temperature to estimate a SOC value using the model, which is also a priori value. Then, a GRU neural network model with a small error is used to input the SOC value (likelihood value) under the voltage, current, and temperature to correct the priori value, thereby obtaining a corrected SOC value (posterior value).

[0131] Here it is assumed that the SOC value distribution is Gaussian distribution, the fusion model is a fusion of three GRU neural network models, and the variance of its distribution function is determined by the size of its root mean square error.

[0132] Root mean square error calculation formula:

[0133]

[0134] Where n is the number of samples, soc0 is the soc value of the test set, and soc1 is the soc value estimated by the model.

[0135] Through 10 groups of different data, 3 groups are used as test sets and 7 groups are used as training sets, and the cross-training and validation method is adopted. Five GRU neural network models are trained, and the root mean square error of the five models is found through three test sets. The largest and smallest ones are discarded, and the three middle neural network models are retained. The three neural network models are sorted according to the root mean square error size, and weights are assigned from large to small. This weight is reflected in the variance size of the probability density function. The larger the error, the larger the variance. Then the three GRU neural network models are fused through Bayesian filtering to obtain the final GRU neural network model after Bayesian filtering fusion. Since the errors of the same model may be different for different test sets, three test sets are used here to calculate the size of the average error, so as to indirectly indicate the approximate prediction accuracy of the neural network model, and then the three retained neural network models are fused through Bayesian averaging. During fusion, the one with the largest error is fused to the one with the smallest error. The one with the largest error is the prior data, and the one with the smallest error is the likelihood data. The fused one is the posterior data, which is the final fusion result.

[0136] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention application rather than to limit its protection scope. Although the present invention application is described in detail with reference to the above embodiments, ordinary technicians in the relevant field should understand that after reading the present invention application, those skilled in the art can still make various changes, modifications or equivalent substitutions to the specific implementation methods of the application, but these changes, modifications or equivalent substitutions are all within the protection scope of the claims to be approved.

Claims

1. A battery SOC estimation method integrating improved GRU network and Bayesian filtering, It is characterized in that include: Acquiring parameters of the lithium-ion battery, and normalizing the parameters of the lithium-ion battery to form normalized data, wherein the normalized data includes a training set and a test set; The convergence factor of the Grey Wolf Algorithm is optimized by introducing randomness and nonlinear decreasing mode to form an improved Grey Wolf Algorithm. The improved grey wolf algorithm is used to optimize the initial weights and biases of the GRU neural network to form an optimized GRU neural network; Bringing the training set into the optimized GRU neural network to obtain multiple GRU neural network models; Based on the multiple GRU neural network models, preliminary screening is performed through GRU neural network model test errors, and the multiple GRU neural network models are fused through Bayesian filtering to obtain a GRU neural network model fused through Bayesian filtering; The soc of the lithium-ion battery is estimated based on the GRU neural network model after Bayesian filtering fusion.

2. The method according to claim 1, It is characterized in that The convergence factor of the grey wolf algorithm is optimized by introducing randomness and nonlinear decreasing mode to form an improved grey wolf algorithm, including: Generate a random number in the range of 0-1; The convergence factor of the gray wolf algorithm is introduced into the trigonometric function to change the distribution characteristics of random numbers and together with the random numbers constitute a nonlinear decreasing pattern of the convergence factor. At the same time, the current number of iterations, the maximum number of iterations and the random number of the gray wolf algorithm are combined to form an improved gray wolf algorithm.

3. The method according to claim 2, It is characterized in that The convergence factor is determined based on the current number of iterations of the gray wolf algorithm and the random number, using the following calculation formula: In the above formula: α is the convergence factor of the gray wolf algorithm, rand() is a random number in the range of 0-1, t is the current number of iterations, T max is the maximum number of iterations.

4. The method according to claim 1, It is characterized in that The parameters of the lithium-ion battery are obtained, and the parameters of the lithium-ion battery are normalized to form normalized data. The normalized data includes a training set and a test set. The specific process satisfies the following formula: Where: v represents the normalized data; v0 represents the parameters of the lithium-ion battery; v min The minimum value of the lithium-ion battery parameter, v max Indicates the maximum value of a lithium-ion battery parameter.

5. The method according to claim 1, It is characterized in that The improved grey wolf algorithm is used to optimize the initial weights and biases of the GRU neural network to form an optimized GRU neural network, including: Using an improved gray wolf algorithm to optimize the initial weights of the GRU neural network and the initial bias of the GRU neural network to form the optimized initial weights of the GRU neural network and the optimized initial bias of the GRU neural network; Adopting the improved grey wolf algorithm to iteratively optimize the optimization initial weight and the optimization bias; When the number of iterations reaches the preset maximum number of iterations, the final optimization weights and final optimization biases of the GRU neural network optimized by the improved grey wolf algorithm are output to form an optimized GRU neural network.

6. The method according to claim 5, It is characterized in that In the iterative optimization process, the fitness function of the improved grey wolf algorithm is defined as follows: In the above formula: F is the fitness value, M is the number of samples s for the initial weight and bias of the iteration, is the expected output of the kth output node of sample s; is the output of the kth output node under the action of sample s, and n is the number of output nodes.

7. The method according to claim 1, It is characterized in that The training set is introduced into the optimized GRU neural network to obtain multiple GRU neural network models, including: The training set includes: battery voltage, current and average temperature. The input of the optimized GRU neural network is a 3×M matrix consisting of voltage, current and average temperature as training set samples. The matrix is ​​expressed as follows: In the above matrix, M represents the total number of training set samples, u 1 ...u M is the voltage, i 1 ...i M is the current, t 1 ...t M is the average temperature, X is a matrix; The output variable is a 1×M row vector composed of battery parameters, which satisfies the following row vector: X=(soc 1 ...soc M ) In the above row vector: soc 1 …soc M are the elements in the row vector. Based on the input variables and output variables, multiple GRU neural network models are formed.

8. The method according to claim 1 or 7, It is characterized in that The method of performing preliminary screening based on the multiple GRU neural network models through GRU neural network model test errors, fusing the multiple GRU neural network models through Bayesian filtering, and obtaining a GRU neural network model after Bayesian filtering fusion, includes: Based on the multiple GRU neural network models, the errors of the multiple GRU neural network models are calculated by using a root mean square error formula for the multiple GRU neural network models through a test set; The multiple GRU neural network models corresponding to the errors within the preset error interval are screened, and the battery soc value is estimated through the GRU neural network model using the data of the test set, and the soc value estimated by the GRU neural network model corresponding to the maximum error of the multiple GRU neural network models screened is used as the prior value of the Bayesian filter, and the soc value estimated by the multiple GRU neural network models corresponding to the smaller error of the multiple GRU neural network models screened is used as the posterior value of the Bayesian filter, and the posterior value is used to correct the multiple GRU neural network models with large error values, and the multiple GRU neural network models screened are fused through Bayesian filtering to form a GRU neural network model after fusion through Bayesian filtering.

9. The method according to claim 8, It is characterized in that The method of estimating the soc of the lithium-ion battery according to the GRU neural network model after the Bayesian filtering fusion includes: The battery SOC is estimated by the battery voltage, current and temperature according to the GRU neural network model after Bayesian filtering fusion.

Citation Information

Cited By

  • Thermal station secondary return water temperature prediction method and device based on XGBoost and neural network

    CN119918400A