Battery charge state estimation method and device
By constructing a first-order Nernst equivalent circuit model of the battery and a CNN-BiLSTM neural network, and combining the particle filtering algorithm for multi-model fusion, the data-driven SOC estimation method is solved, and the generalization ability and robustness of the data-driven SOC estimation method is insufficient when facing no data or new operating conditions, and a more accurate and stable SOC estimation is achieved.
Patent Information
- Application Number
- CN202411647538.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-18
- Publication Date
- 2025-02-28
AI Technical Summary
The data-driven battery SOC estimation method is difficult to ensure generalization capability and robustness when facing unseen data or new operating conditions, and is sensitive to noise and outliers, resulting in unstable estimation results.
By constructing a first-order Nernst equivalent circuit model of the battery, using the FFRLS algorithm for parameter identification, combining the filtering algorithm for SOC estimation, and constructing a CNN-BiLSTM neural network for SOC estimation, and finally fusion calculation of multiple estimates through the particle filtering algorithm.
It improves the accuracy, generalization ability and robustness of SOC estimation, can process data under different operating conditions more effectively, and reduces the impact of noise and outliers on the estimation results.
Smart Images

Figure CN119535211A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of battery state of charge estimation, and in particular to a battery state of charge estimation method and a battery state of charge estimation device. Background Art
[0002] At present, mainstream battery SOC (State of Charge) estimation methods include open circuit voltage method, ampere-hour integration method, model-based algorithm and data-driven method.
[0003] In recent years, compared with the open circuit voltage method, the ampere-hour integration method and the model-based algorithm, the data-driven method can achieve more accurate SOC estimation and has gained wide attention and application in the field of SOC estimation. However, this type of method also has certain problems. First, the generalization ability of this method for new data is difficult to guarantee. When faced with unseen data or new operating conditions, the data-driven model may not be able to provide accurate SOC estimation. Secondly, the data-driven method also has challenges in ensuring the robustness of the estimation. This method is sensitive to noise and outliers in the data, resulting in instability in the estimation results. Summary of the invention
[0004] In order to solve one of the above technical problems, the present invention proposes the following technical solution.
[0005] The first aspect of the present invention proposes a method for estimating the state of charge of a battery, comprising the following steps: constructing a first-order Nernst equivalent circuit model of a battery; obtaining the operating parameters of the battery based on the first-order Nernst equivalent circuit model; performing parameter identification on the first-order Nernst equivalent circuit model using an FFRLS (Finite-Window Recursive Least Squares) algorithm; performing SOC estimation based on the first-order Nernst equivalent circuit model after parameter identification and using a filtering algorithm to obtain a first SOC estimation value; constructing a neural network and training it using the operating parameters of the battery, performing SOC estimation using the trained neural network to obtain a second SOC estimation value; and performing a fusion calculation on the first SOC estimation value and the second SOC estimation value to obtain the SOC estimation value of the battery.
[0006] In addition, the battery state of charge estimation method according to the above embodiment of the present invention may also have the following additional technical features.
[0007] According to one embodiment of the present invention, the expression of the first-order Nernst equivalent circuit model is:
[0008]
[0009] Among them, R0 is the ohmic internal resistance, R cd R is the internal resistance during charging and discharging c or R d , when the battery is in the discharge process, R cd =R d , during the charging process, R cd =R c , R c , R d are the hysteresis resistances for simulating the charge and discharge hysteresis voltages, R p is the polarization resistance, C p is the polarization capacitance, U p is the capacitance C p Voltage across the terminals, U L is the battery terminal voltage, U OC is the open circuit voltage, I L is the battery load current, K1, K2, K3 are U which has no physical meaning OC Fitting parameters, SOC is the battery state of charge.
[0010] According to an embodiment of the present invention, the operating parameters of the battery include a voltage sequence, a current sequence, a temperature sequence and a SOC sequence of the battery.
[0011] According to one embodiment of the present invention, the first-order Nernst equivalent circuit model is parameter identified by using the FFRLS algorithm, including:
[0012] The following state-space equations for dynamic parameter identification using the FFRLS algorithm are constructed:
[0013] Simplifying the Nernst equivalent circuit model, we can get:
[0014] U L (k) = c1 + c2U L (k-1)+c3lnSOC(k)+c4ln(1-SOC(k))+c5I L (k)+c6I L (k-1)
[0015] Where k is the discrete time index, U L (k) is the terminal voltage of the battery at time k, U L (k-1) is the terminal voltage of the battery at time k-1, SOC(k) is the state of charge of the battery at time k, I L (k) is the load current of the battery at time k, I L(k-1) is the load current of the battery at time k-1, c1, c2, c3, c4, c5 and c6 are all coefficients to be identified in the least squares method, which are specifically:
[0016]
[0017] Where T represents the sampling interval of the discrete time state.
[0018] The parameter vector θ and the input vector are defined by the following formula In order to be applied to the FRRLS algorithm:
[0019] θ(k)=[c1 c2 c3 c4 c5 c6]
[0020]
[0021] Using the FRRLS algorithm to perform dynamic parameter identification on the first-order Nernst equivalent circuit model;
[0022] The relevant parameters of the first-order Nernst equivalent circuit model are obtained by inverse solution, and the specific expression is:
[0023]
[0024] According to one embodiment of the present invention, the neural network includes two layers of one-dimensional CNN structures, two layers of bidirectional BiLSTM structures and one fully connected layer, which are connected in sequence.
[0025] According to one embodiment of the present invention, the loss function of the neural network includes an MSE loss function and a knowledge loss function, wherein the knowledge loss function is:
[0026]
[0027] Among them, L K is the knowledge loss function, and are the estimated SOC values of the neural network at the sth step and the s-1th step, respectively. is the theoretical value of the SOC change between the sth step and the s-1th step, η is the coulomb efficiency, I L,s-1 is the load current at step s-1, Δt is the time interval between adjacent discrete time steps, C N is the initial capacity of the battery.
[0028] According to one embodiment of the present invention, the first SOC estimation value and the second SOC estimation value are fused and calculated by the following formula:
[0029]
[0030] in, is the estimated SOC value of the battery obtained by fusion, are the first SOC estimation value and the second SOC estimation value, respectively. σ1 and σ2 are the variances of the estimation errors of the first SOC estimation value and the second SOC estimation value, respectively.
[0031] According to one embodiment of the present invention, when performing fusion calculation, the importance density function of each particle is calculated by the following formula: and weights
[0032]
[0033] in, is the importance density function of the ith particle in the sth step, is the weight of the ith particle in the sth step, L1 is the estimated error distribution of the first SOC estimate, L2 is the estimated error distribution of the second SOC estimate, y S is the state variable to be estimated at the sth step, and are the first and second estimates at step s-1, respectively, and z S is the observed value of the state variable SOC at step s, and are the first and second estimates at step s, respectively. is the SOC estimation value of the battery in the sth step obtained by fusion, σ1 and σ2 are the variances of the estimation errors of the first SOC estimation value and the second SOC estimation value, respectively.
[0034] The second aspect of the present invention proposes a battery state of charge estimation device, including: a construction module, used to construct a first-order Nernst equivalent circuit model of a battery; a determination module, used to obtain the operating parameters of the battery based on the first-order Nernst equivalent circuit model; an identification module, used to perform parameter identification on the first-order Nernst equivalent circuit model using an FFRLS algorithm; a first estimation module, used to perform SOC estimation based on the first-order Nernst equivalent circuit model after parameter identification and using a filtering algorithm to obtain a first SOC estimation value; a second estimation module, used to construct and train a neural network for SOC estimation, and perform SOC estimation through the neural network to obtain a second SOC estimation value; a fusion module, used to perform fusion calculation on the first SOC estimation value and the second SOC estimation value to obtain the SOC estimation value of the battery.
[0035] The technical solution of the embodiment of the present invention obtains the SOC estimation value by multi-model fusion based on the first-order Nernst equivalent circuit model, which is beneficial to improving the accuracy, generalization ability and robustness of the SOC estimation. BRIEF DESCRIPTION OF THE DRAWINGS
[0036] Figure 1 Flow chart of a battery state of charge estimation method according to an embodiment of the present invention.
[0037] Figure 2 A schematic diagram of a first-order Nernst equivalent circuit model provided by an embodiment of the present invention.
[0038] Figure 3 A schematic diagram of the structure of a CNN-BiLSTM network provided in an embodiment of the present invention.
[0039] Figure 4 FIG. 4 is a block diagram of a battery state of charge estimation device according to an embodiment of the present invention. DETAILED DESCRIPTION
[0040] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0041] The embodiment of the present invention proposes a battery state of charge estimation method, which combines two methods based on data drive and battery model through a particle filter algorithm, aiming to improve the accuracy, generalization ability and robustness of the estimation.
[0042] Figure 1 Flow chart of a battery state of charge estimation method according to an embodiment of the present invention.
[0043] like Figure 1 As shown, the battery state of charge estimation method includes the following steps S1 to S6.
[0044] The battery state of charge estimation method according to the embodiment of the present invention can be applied to various types of batteries, such as lithium batteries.
[0045] S1, construct the first-order Nernst equivalent circuit model of the battery.
[0046] Among them, the first-order Nernst equivalent circuit model includes parameters such as ohmic internal resistance, polarization resistance, polarization capacitance and open circuit voltage.
[0047] Specifically, an improved equivalent circuit model based on the Nernst equation and its expression are designed as the first-order Nernst equivalent circuit model of the battery, which mainly improves the model of the open-circuit voltage of the battery model.
[0048] S2, the operating parameters of the battery are obtained based on the first-order Nernst equivalent circuit model.
[0049] Among them, the operating parameters of the battery include voltage sequence, current sequence, temperature sequence and SOC sequence.
[0050] Specifically, the first-order Nernst equivalent circuit model can be subjected to offline parameter identification to obtain the relationship between the model's ohmic internal resistance, polarization resistance, polarization capacitance, and open-circuit voltage and SOC, and simulated operating condition tests can be performed to obtain the battery's voltage sequence, current sequence, temperature sequence, and SOC sequence.
[0051] S3, use the FFRLS algorithm to perform parameter identification on the first-order Nernst equivalent circuit model.
[0052] By identifying the dynamic parameters of the first-order Nernst equivalent circuit model, the relevant parameters of the model, such as ohmic internal resistance, polarization resistance, polarization capacitance, etc., are obtained.
[0053] S4, based on the first-order Nernst equivalent circuit model after parameter identification, and using a filtering algorithm, SOC estimation is performed to obtain a first SOC estimation value.
[0054] The filtering algorithm may be an unscented Kalman filtering algorithm. The first SOC estimation value refers to an SOC estimation value estimated by using the filtering algorithm.
[0055] Specifically, based on the identified first-order Nernst equivalent circuit model, an algorithm for SOC estimation using an unscented Kalman filter algorithm is constructed, and the SOC estimation is performed using the algorithm to obtain a first SOC estimation value.
[0056] S5, constructing a neural network, and training it with the operating parameters of the battery, and performing SOC estimation with the trained neural network to obtain a second SOC estimation value.
[0057] The neural network may be a CNN-BiLSTM network (adding BiLSTM on the basis of CNN). The second SOC estimated value refers to the SOC estimated value estimated by the neural network.
[0058] Specifically, a CNN-BiLSTM network is constructed, and the data obtained in step S2 can be used as training data. After preprocessing, the voltage, current, and temperature of the battery are used as inputs, and the SOC is used as output to train the CNN-BiLSTM network. The SOC is estimated by the trained CNN-BiLSTM network to obtain a second SOC estimation value.
[0059] S6, performing a fusion calculation on the first SOC estimation value and the second SOC estimation value to obtain an SOC estimation value of the battery.
[0060] Specifically, a fusion algorithm based on particle filtering may be constructed, and the particle filtering fusion algorithm may be used to perform fusion calculation on the first SOC estimation value and the second SOC estimation value to obtain the SOC value of the battery.
[0061] By combining the network model-based method and the data-driven method, the advantages of physical models and machine learning models are utilized to obtain more reliable SOC estimation under different working conditions and system changes. Through multi-model fusion, the accuracy and reliability of battery SOC estimation can be improved to meet the needs of battery management and control.
[0062] In general, in order to accurately estimate the state of charge of the battery, the embodiment of the present invention establishes a first-order Nernst equivalent circuit model of the battery, and combines parameter identification and unscented Kalman filtering algorithm to achieve the estimation of the state of charge. At the same time, the SOC estimation algorithm based on the CNN-BiLSTM network is introduced to improve the accuracy and generalization ability of the estimation. Finally, the particle filter algorithm is used to fuse multiple estimated values, which further improves the accuracy and robustness of the estimation, and has broad application prospects in fields such as lithium battery management systems.
[0063] Therefore, the battery state of charge estimation method of the embodiment of the present invention obtains the SOC estimation value by multi-model fusion based on the first-order Nernst equivalent circuit model, which is beneficial to improving the accuracy, generalization ability and robustness of SOC estimation.
[0064] In one embodiment of the present invention, the first-order Nernst equivalent circuit model is as follows: Figure 2 As shown, unlike the existing equivalent circuit model, the first-order Nernst equivalent circuit model describes the relationship between the battery open circuit voltage and the battery state of charge based on physical mechanism. Its specific expression is:
[0065]
[0066] Among them, R0 is the ohmic internal resistance, R cd R is the internal resistance during charging and discharging c or R d , when the battery is in the discharge process, Rcd =R d , during the charging process, R cd =R c , R c , R d are the hysteresis resistances for simulating the charge and discharge hysteresis voltages, R p is the polarization resistance, C p is the polarization capacitance, U p is the capacitance C p Voltage across the terminals, U L is the battery terminal voltage, U OC is the open circuit voltage, I L is the battery load current, K1, K2, K3 are U which has no physical meaning OC Fitting parameters, SOC is the battery state of charge.
[0067] Taking lithium batteries as an example, the relationship between the open circuit voltage in the above expression (1) is constructed as follows:
[0068] The Nernst model is used to analyze the internal physical mechanism and electrochemical reaction of the battery and construct the empirical equation of the model. The internal chemical reaction of the lithium battery is a basic redox reaction. When charging, the lithium atoms at the positive electrode of the battery undergo an oxidation reaction, lose electrons and deintercalate into lithium ions. The positive electrode reaction equation is:
[0069] LiM x O y =Li (1-x) M x O y +xLi + +xe - (2)
[0070] During discharge, an oxidation reaction occurs at the negative electrode of the battery, and the lithium ions embedded in the carbon layer of the negative electrode are released and move back to the positive electrode. The more lithium ions return to the positive electrode, the higher the discharge capacity. The negative electrode reaction equation is:
[0071] nC+L + +xe - =Li x C n (3)
[0072] The overall reaction equation of the battery is:
[0073] LiM x O y +nC=Li (1-x) M x O y +Li x C n (4)
[0074] In the above three chemical reaction equations, M can represent Co, Mn, Fe, and Ni, which represent lithium cobalt oxide, lithium manganese oxide, lithium iron phosphate, and lithium nickel oxide batteries, respectively. For ease of description, equation (4) is abstracted as:
[0075] aA+bB=cC+dD (5)
[0076] Among them, A and B are oxidized reactants, C and D are oxidized products, and a, b, c and d represent reaction coefficients. They can be substituted into the Nernst equation for calculation:
[0077]
[0078] Among them, E represents the battery voltage when the reaction is balanced, E0 represents the standard electromotive force, T′ represents the chemical reaction temperature, R represents the ideal gas constant, F represents the Faraday constant, and n represents the number of electrons gained or lost in the redox reaction.
[0079] Equation (6) indicates that the open circuit voltage during battery operation is the voltage generated by the internal reaction of the battery. Therefore, the relationship between the battery terminal voltage and the internal reaction activity can be established based on the Nernst equation:
[0080]
[0081] Among them, U L is the battery terminal voltage, α red , α ox They represent the activities of substances with high and low oxidation numbers in the electrode reaction, E0 represents the standard electromotive force, T′ represents the chemical reaction temperature, R represents the ideal gas constant, F represents the Faraday constant, and n represents the number of electrons gained and lost in the redox reaction. Using the battery's state of charge as its parameter approximation, the relationship between the battery terminal voltage and the state of charge can be constructed:
[0082] U L =E0-I L R in -K2lnSOC+K3ln(1-SOC) (8)
[0083] Among them, U L is the battery terminal voltage, E0 represents the standard electromotive force, I L is the load current, R in is the battery internal resistance (including the equivalent internal resistance of ohmic internal resistance and polarization internal resistance), SOC is the battery charge state, K2 and K3 are the current I L The proportional coefficient with SOC which has no physical meaning.
[0084] Under constant temperature conditions, E0, K2, and K3 are considered to be constant values, so K1 can be written as E0, and the simplified relationship between the battery terminal voltage and the state of charge in the above formula (1) is obtained.
[0085] In one embodiment of the present invention, obtaining the operating parameters of the battery based on the first-order Nernst equivalent circuit model may include: obtaining the operating parameters of the battery through HPPC testing and simulated operating condition testing in sequence, including the battery's voltage sequence, current sequence, temperature sequence and SOC sequence.
[0086] Specifically, step S2 may include the following steps:
[0087] Sub-step 2.1: Perform a static capacity test on the battery, charge the battery with constant current and constant voltage, and then perform a standard discharge test after it is fully charged to obtain the static capacity of the battery;
[0088] Sub-step 2.2: Perform HPPC (Hybrid Pulse Power Characterization) test, use MATLAB to perform offline parameter identification on the first-order Nernst equivalent circuit model, and obtain the relationship between open circuit voltage, ohmic internal resistance, polarization internal resistance, polarization capacitance and SOC;
[0089] Sub-step 2.3: Perform a simulated operating condition test to obtain the battery's voltage sequence U(t), current sequence I(t), temperature sequence T(t), and SOC sequence.
[0090] In one embodiment of the present invention, step S3, i.e., using the FFRLS algorithm to perform parameter identification on the first-order Nernst equivalent circuit model, may specifically include the following steps:
[0091] Sub-step 3.1: Construct the following state-space equations for dynamic parameter identification using the FFRLS algorithm:
[0092] Simplifying the Nernst equivalent circuit model, we can get:
[0093] U L (k) = c1 + c2U L (k-1)+c3lnSOC(k)+c4ln(1-SOC(k))+c5I L (k)+c6I L (k-1) (9)
[0094] Where k is the discrete time index, U L (k) is the terminal voltage of the battery at time k, U L (k-1) is the terminal voltage of the battery at time k-1, SOC(k) is the state of charge of the battery at time k, I L(k) is the load current of the battery at time k, I L (k-1) is the load current of the battery at time k-1, c1, c2, c3, c4, c5 and c6 are all coefficients to be identified in the least squares method, which are specifically:
[0095]
[0096] Where T represents the sampling interval of the discrete time state.
[0097] Sub-step 3.2: Define the parameter vector θ and the input vector by the following formula In order to be applied to the FRRLS algorithm:
[0098]
[0099] Sub-step 3.3: Use the FRRLS algorithm to perform dynamic parameter identification on the first-order Nernst equivalent circuit model:
[0100]
[0101] Among them, K and P are the gain matrix and covariance matrix respectively, λ is the forgetting factor, E is the system error matrix, and y(k+1) is the system mathematical model of k+1 time step, that is, U t (k+1) is the battery terminal voltage collected by the sensor at the k+1 time step.
[0102] Sub-step 3.4: Inversely solve the relevant parameters of the first-order Nernst equivalent circuit model. The specific expression is:
[0103]
[0104] After the parameter identification, step S4 is executed, that is, based on the first-order Nernst equivalent circuit model after the parameter identification, the SOC estimation is performed using a filtering algorithm to obtain a first SOC estimation value. Specifically, the following steps may be included:
[0105] Sub-step 4.1: Using the unscented Kalman filter to estimate SOC requires the establishment of a state space model of a first-order equivalent circuit model:
[0106]
[0107] Where f(·) is the state space equation, h(·) is the observation equation, x(k+1) is the state vector at time k+1, and x(k+1)=[U L (k+1),SOC(k+1)] T , x(k) is the state vector at time k, x(k)=[U L(k),SOC(k)] T , I L (k) is the load current at time k, w(k) is the process noise at time k, U L (k) is the battery terminal voltage at time k, SOC(k) is the state of charge at time k, U OC [SOC(k)] is the open circuit voltage of the battery at time k. The open circuit voltage is determined by the state of charge at time k. cd For R cd R is the internal resistance during charging and discharging c or R d , when the battery is in the discharge process, R cd =R d , R c , R d are the hysteresis resistors simulating the charge and discharge hysteresis voltages, v(k) is the observation noise at time k, Δt is the time interval between adjacent discrete moments, and C N is the initial capacity of the battery.
[0108] Sub-step 4.2: System initial state variables and their covariance matrix P0:
[0109]
[0110] in, represents the expectation of the initial state vector, E[·] represents the expected calculation, x0 represents the initial state vector, x0=[U L,0 ,SOC0],U L,0 represents the initial battery terminal voltage, SOC0 represents the initial battery state of charge, P0 is the initial covariance matrix of the state variables, and T represents the matrix transpose operation.
[0111] Sub-step 4.3: Calculate the Sigma point set:
[0112]
[0113] in, represents the first point in the Sigma point set at discrete time k-1, It represents the i-th point in the Sigma point set at discrete time k-1. The subscript of the Sigma point represents the discrete time, and the superscript (i) represents the number of the Sigma point. The brackets in the superscript only serve to emphasize and have no operational significance. represents the estimated value of the state vector at discrete time k-1, It is a Sigma point set generation method based on unscented transformation in unscented Kalman filtering. n is the dimension of the state vector. The Sigma point set contains 2n+1 points in total. λ is the diffusion parameter used to adjust the distribution and weight of the Sigma point set. k-1is the covariance matrix of the state vector at time k-1.
[0114] Sub-step 4.4: Predict the next sampling point:
[0115]
[0116] in, It represents the prediction of the state vector at time k based on the i-th point in the Sigma point set at discrete time k-1. The subscript k|k-1 of the Sigma point represents the estimate of the state vector at time k based on the estimated value of the state vector at discrete time k-1. ·|· represents the conditional probability. The superscript (i) represents the number of the Sigma point. The brackets in the superscript only serve to emphasize and have no operational significance. represents the i-th point in the Sigma point set at discrete time k-1. The subscript of the Sigma point represents the discrete time, the superscript (i) represents the number of the Sigma point, and the brackets in the superscript only serve to emphasize and have no operational meaning. f(·) represents the state space equation of the system.
[0117] Sub-step 4.5: Obtain the predicted value and covariance matrix of the state variable by weighted summing the predicted values of the sampling points:
[0118]
[0119] in, represents the estimated value of the state vector at time k calculated based on the updated Sigma point set at time k-1, represents the prediction of the state vector at time k based on the i-th point in the Sigma point set at discrete time k-1. The subscript k|k-1 of the Sigma point represents the estimate of the state vector at time k based on the estimated value of the state vector at discrete time k-1. ·|· represents the conditional probability, ω (i) Represents the weight corresponding to the i-th point in the Sigma point set, P x,k represents the covariance matrix of the system state vector x at time k, Q k represents the process noise of the system at time k, n represents the dimension of the state vector, and T represents the matrix transpose operation.
[0120] Sub-step 4.6: Generate new sampling points using UT transformation based on the one-step prediction value:
[0121]
[0122] in, represents the first point in the Sigma point set at discrete time k, It represents the i-th point in the Sigma point set at discrete time k. The subscript of the Sigma point represents the discrete time, and the superscript (i) represents the number of the Sigma point. The brackets in the superscript only serve to emphasize and have no operational significance. represents the estimated value of the state vector at time k calculated based on the updated Sigma point set at time k-1, It is a Sigma point set generation method based on unscented transformation in unscented Kalman filtering. n is the dimension of the state vector. The Sigma point set contains 2n+1 points in total. λ is the diffusion parameter used to adjust the distribution and weight of the Sigma point set. k-1 is the covariance matrix of the state vector at time k-1.
[0123] Sub-step 4.7: Get the predicted value of the observed quantity:
[0124]
[0125] in, is the Sigma point set of the estimated value of the quantity measurement at time k calculated based on the Sigma point generated by formula (19), the superscript i is the label, and the subscript indicates that the estimated value of the quantity measurement at time k is calculated based on the prior estimate at time k-1, h(·) is the system observation equation, It represents the i-th point in the Sigma point set at discrete time k. The subscript of the Sigma point represents the discrete time, and the superscript (i) represents the number of the Sigma point. The brackets in the superscript only serve to emphasize and have no operational significance.
[0126] Sub-step 4.8: Perform a weighted summation of the predicted values of the observed values to obtain the predicted mean and covariance of the system:
[0127]
[0128] in, represents the estimated value of the observed quantity at time k. The subscript k|k-1 indicates that the estimated value of the quantity measured at time k is calculated based on the prior estimate at time k-1. (i) Represents the weight corresponding to the i-th point in the Sigma point set. The weights of the observation quantity and the state quantity Sigma point set are the same. y,k represents the covariance matrix of the observation vector at time k, is the Sigma point set of the estimated value of the quantity measurement at time k calculated based on the Sigma point generated by formula (19). The superscript i is the label, and the subscript indicates that the estimated value of the quantity measurement at time k is calculated based on the prior estimate at time k-1. k represents the observation noise at time k, P xy,k represents the covariance matrix between the state vector and the observation vector at time k, It represents the prediction of the state vector at time k based on the i-th point in the Sigma point set at discrete time k-1. The subscript k|k-1 of the Sigma point represents the estimate of the state vector at time k based on the estimated value of the state vector at discrete time k-1. ·|· represents the conditional probability. The superscript (i) represents the number of the Sigma point. The brackets in the superscript only serve to emphasize and have no operational meaning. T represents the matrix transpose operation.
[0129] Sub-step 4.9: Update the Kalman gain matrix, system state, and system covariance matrix.
[0130]
[0131] Where K represents the Kalman gain, P xy,k represents the covariance matrix between the state vector and the observation vector at time k, P y,k represents the covariance matrix of the observation vector at time k, represents the estimated value of the state vector at time k, y k represents the actual value of the observation vector at time k, P k is the covariance matrix of the system at time k, and T is the matrix transpose operation.
[0132] In one embodiment of the present invention, the neural network includes two layers of one-dimensional CNN structures, two layers of bidirectional BiLSTM structures and one fully connected layer, which are connected in sequence.
[0133] Furthermore, the loss function of the neural network includes MSE loss function and knowledge loss function.
[0134] In order to fully extract the temporal and spatial information in the sensor data, in the CNN-BiLSTM network, the sequence data is sequentially input into the one-dimensional CNN and BiLSTM, and finally the classification or prediction is achieved through the fully connected layer. Specifically, CNN is used to extract local features, that is, short-term features, from the sequence data, while BiLSTM is used to capture the long-term and bidirectional dependencies in the sequence data. By combining the outputs of CNN and BiLSTM, a more comprehensive and accurate feature representation can be obtained, thereby improving the performance and effect of the model.
[0135] It should be noted that, based on the traditional CNN-BiLSTM network, the embodiment of the present invention not only optimizes the network structure, but also proposes a new loss function by integrating physical information to ensure that the network output conforms to the physical meaning.
[0136] In order to eliminate the outlier phenomenon that violates physical rules in the process of guiding the gradient descent of the state of charge estimation by the conventional MSE loss function, a new loss function L is proposed in combination with the physical meaning of SOC.KC (Knowledge-Constraint Loss Function), which includes MSE loss L M and the knowledge loss L determined by the prior knowledge of the state of charge K It consists of two parts. Its specific definition is:
[0137]
[0138] Among them, θ represents the network parameters, L KC is the loss function designed in the embodiment of the present invention, and L M and L K Composition, λ M and λ K The normalized weights of the two respectively; and is the estimated SOC of the neural network at the sth and s-1th steps.
[0139] Knowledge loss function L K It is built based on the definition of battery SOC, namely:
[0140]
[0141] Among them, SOC s Indicates the battery charge state at step s, C r Indicates the remaining battery power at time r, C N Indicates the initial capacity of the battery.
[0142] According to the physical meaning of SOC, when the model estimation value is accurate, the following conditions should be met:
[0143]
[0144] Therefore, the embodiment of the present invention designs an additional loss function based on prior knowledge, which is called the knowledge loss function L K ,Right now:
[0145]
[0146] Among them, L K is the knowledge loss function, and are the estimated SOC values of the neural network at the sth step and the s-1th step, respectively. is the theoretical value of the SOC change between the sth step and the s-1th step, η is the coulomb efficiency, I L,S-1 is the load current at step s-1, Δt is the time interval between adjacent discrete time steps, C N is the initial capacity of the battery.
[0147] After building the neural network, the following steps are used to train the neural network:
[0148] Sub-step 5.1: Simulate the working conditions of lithium-ion batteries in the laboratory and collect current, voltage, temperature and SOC sequences;
[0149] Sub-step 5.2: pre-process the collected data using methods such as maximum-minimum normalization and sliding time window;
[0150] Sub-step 5.3: Take the battery voltage, current, and temperature as inputs and the SOC as the output of the network. Figure 3 As shown in the figure, the neural network structure is a 2-layer one-dimensional CNN structure, a 2-layer bidirectional BiLSTM structure, a 1-layer fully connected layer, and the activation function is ReLU.
[0151] Sub-step 5.4: Use the preprocessed data to train the CNN-BiLSTM network. The loss function of the neural network is MSE and knowledge loss function, and the optimizer is Adam.
[0152] In one embodiment of the present invention, step S6 is to perform a fusion calculation on the first SOC estimation value and the second SOC estimation value. A fusion formula can be constructed using a particle filter algorithm with maximum likelihood estimation as a priori estimation, and the fusion formula is used to perform a fusion calculation on the first SOC estimation value and the second SOC estimation value.
[0153] Specifically, first, we define the particle to represent the SOC estimate, assuming that both estimation errors conform to the normal distribution:
[0154]
[0155] Wherein, L1 is the error distribution of the first SOC estimation value, L2 is the error distribution of the second SOC estimation value, y is the true value of the state variable SOC, and are the first SOC estimation value and the second SOC estimation value, respectively. σ1 and σ2 are the variances of the errors of the first SOC estimation value and the second SOC estimation value, respectively.
[0156] For the first SOC estimate and the second SOC estimate, construct a joint distribution:
[0157]
[0158] And take the log-likelihood function:
[0159]
[0160] By calculating the partial derivative of the joint distribution function with respect to y, we find the maximizing parameter:
[0161]
[0162] Solve to get the estimated SOC value of the fused battery
[0163]
[0164] When performing fusion calculations, based on maximum likelihood estimation, the importance density function of each particle is calculated using the following formula: and weights
[0165]
[0166] in, is the importance density function of the ith particle in the sth step, is the weight of the ith particle in the sth step, L1 is the estimated error distribution of the first SOC estimate, L2 is the estimated error distribution of the second SOC estimate, y S is the state variable to be estimated at the sth step, and are the first and second estimates at step s-1, respectively, and z S is the observed value of the state variable SOC at step s, and are the first and second estimates at step s, respectively. is the SOC estimation value of the battery in the sth step obtained by fusion, σ1 and σ2 are the variances of the estimation errors of the first SOC estimation value and the second SOC estimation value, respectively.
[0167] In summary, the advantages of the embodiments of the present invention are:
[0168] (1) Improved accuracy: By using the particle filter algorithm, the state of charge of the lithium-ion battery can be estimated more accurately. Particle filtering can effectively handle nonlinear and time-varying battery characteristics and improve the accuracy of the estimation.
[0169] (2) Enhanced generalization capability: The multi-model fusion strategy enables the estimation method to adapt to different types of data and working conditions. By integrating the estimation results of multiple models, it can generalize to unseen data and new working conditions, improving the robustness and adaptability of the estimation.
[0170] (3) Flexibility and scalability: The multi-model fusion method can introduce different estimation models as needed to flexibly respond to different battery characteristics and operating conditions. This makes the method scalable and adaptable to different types of lithium-ion battery systems.
[0171] Corresponding to the battery state of charge estimation method of the above embodiment, the present invention further provides a battery state of charge estimation device.
[0172] Figure 4 FIG. 4 is a block diagram of a battery state of charge estimation device according to an embodiment of the present invention.
[0173] like Figure 4 As shown, the battery state of charge estimation device includes a construction module 10 , a determination module 20 , an identification module 30 , a first estimation module 40 , a second estimation module 50 and a fusion module 60 .
[0174] Among them, the construction module 10 is used to construct a first-order Nernst equivalent circuit model of the battery; the determination module 20 is used to obtain the operating parameters of the battery based on the first-order Nernst equivalent circuit model; the identification module 30 is used to perform parameter identification on the first-order Nernst equivalent circuit model using the FFRLS algorithm; the first estimation module 40 is used to perform SOC estimation based on the first-order Nernst equivalent circuit model after parameter identification and using a filtering algorithm to obtain a first SOC estimation value; the second estimation module 50 is used to construct and train a neural network for SOC estimation, and perform SOC estimation through the neural network to obtain a second SOC estimation value; the fusion module 60 is used to perform a fusion calculation on the first SOC estimation value and the second SOC estimation value to obtain the SOC estimation value of the battery.
[0175] It should be noted that the specific implementation of the battery state of charge estimation device can refer to the specific implementation of the battery state of charge estimation method mentioned above, and to avoid redundancy, it will not be described in detail here.
[0176] The battery state of charge estimation device of the embodiment of the present invention obtains the SOC estimation value by multi-model fusion based on the first-order Nernst equivalent circuit model, which is beneficial to improving the accuracy, generalization ability and robustness of the SOC estimation.
[0177] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "example", "specific example", or "some examples" etc. means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Although the embodiments of the present invention have been shown and described above, it can be understood that the above embodiments are exemplary and cannot be construed as limitations on the present invention, and those of ordinary skill in the art can change, modify, replace and modify the above embodiments within the scope of the present invention.
Claims
1. A method for estimating a battery state of charge, characterized in that: The following steps are involved: Construct the first-order Nernst equivalent circuit model of the battery; Obtaining operating parameters of the battery based on the first-order Nernst equivalent circuit model; Using the FFRLS algorithm to perform parameter identification on the first-order Nernst equivalent circuit model; Based on the first-order Nernst equivalent circuit model after parameter identification, the SOC is estimated by using a filtering algorithm to obtain a first SOC estimation value; Constructing a neural network, and training it by using the operating parameters of the battery, and performing SOC estimation by using the trained neural network to obtain a second SOC estimation value; The first SOC estimation value and the second SOC estimation value are fused and calculated to obtain an SOC estimation value of the battery.
2. The battery state of charge estimation method according to claim 1, characterized in that: The expression of the first-order Nernst equivalent circuit model is: Among them, R0 is the ohmic internal resistance, R cd R is the internal resistance during charging and discharging c or R d , when the battery is in the discharge process, R cd =R d , during the charging process, R cd =R c , R c , R d are the hysteresis resistances for simulating the charge and discharge hysteresis voltages, R p is the polarization resistance, C p is the polarization capacitance, U p is the capacitance C p Voltage across the terminals, U L is the battery terminal voltage, U OC is the open circuit voltage, I L is the battery load current, K1, K2, K3 are U which has no physical meaning OC Fitting parameters, SOC is the battery state of charge.
3. The battery state of charge estimation method according to claim 1, characterized in that: The operating parameters of the battery include a voltage sequence, a current sequence, a temperature sequence and a SOC sequence of the battery.
4. The battery state of charge estimation method according to claim 2, characterized in that: The FFRLS algorithm is used to perform parameter identification on the first-order Nernst equivalent circuit model, including: The following state-space equations for dynamic parameter identification using the FFRLS algorithm are constructed: <h2 style=";text-align:left;direction:ltr">U<h2 style=";text-align:left;direction:ltr"> L <h2 style=";text-align:left;direction:ltr"> (k) = c1 + c2U<h2 style=";text-align:left;direction:ltr"> L <h2 style=";text-align:left;direction:ltr"> (k-1)+c3lnSOC(k)+c4ln(1-SOC(k))+c5I<h2 style=";text-align:left;direction:ltr"> L <h2 style=";text-align:left;direction:ltr"> (k)+c6I<h2 style=";text-align:left;direction:ltr"> L <h2 style=";text-align:left;direction:ltr"> (k-1) Where k is the discrete time index, U L (k) is the terminal voltage of the battery at time k, U L (k-1) is the terminal voltage of the battery at time k-1, SOC(k) is the state of charge of the battery at time k, I L (k) is the load current of the battery at time k, I L (k-1) is the load current of the battery at time k-1, c1, c2, c3, c4, c5 and c6 are all coefficients to be identified in the least squares method, which are specifically: Where T represents the sampling interval of the discrete time state; The parameter vector θ and the input vector are defined by the following formula In order to be applied to the FFRLS algorithm: θ(k)=[c1c2c3c4c5c6] Using the FRRLS algorithm to perform dynamic parameter identification on the first-order Nernst equivalent circuit model; The relevant parameters of the first-order Nernst equivalent circuit model are obtained by inverse solution, and the specific expression is:
5. The battery state of charge estimation method according to claim 1, characterized in that: The neural network includes two layers of one-dimensional CNN structures, two layers of bidirectional BiLSTM structures and one fully connected layer.
6. The battery state of charge estimation method according to claim 5, characterized in that: The loss function of the neural network includes an MSE loss function and a knowledge loss function, wherein the knowledge loss function is: Among them, L K is the knowledge loss function, and are the estimated SOC values of the neural network at the sth step and the s-1th step, respectively. is the theoretical value of the SOC change between the sth step and the s-1th step, η is the coulomb efficiency, I L,s-1 is the load current at step s-1, Δt is the time interval between adjacent discrete time steps, C N is the initial capacity of the battery.
7. The battery state of charge estimation method according to claim 1, characterized in that: The first SOC estimation value and the second SOC estimation value are fused and calculated by the following formula: in, is the estimated SOC value of the battery obtained by fusion, are the first SOC estimation value and the second SOC estimation value, respectively. σ1 and σ2 are the variances of the estimation errors of the first SOC estimation value and the second SOC estimation value, respectively.
8. The battery state of charge estimation method according to claim 7, characterized in that: When performing fusion calculations, the importance density function of each particle is calculated using the following formula: and weights in, is the importance density function of the ith particle in the sth step, is the weight of the ith particle in the sth step, L1 is the estimated error distribution of the first SOC estimate, L2 is the estimated error distribution of the second SOC estimate, y S is the state variable to be estimated at the sth step, and are the first and second estimates at step s-1, respectively, and z S is the observed value of the state variable SOC at step s, and are the first and second estimates at step s, respectively. is the SOC estimation value of the battery in the sth step obtained by fusion, σ1 and σ2 are the variances of the estimation errors of the first SOC estimation value and the second SOC estimation value, respectively.
9. A battery state of charge estimation device, characterized in that: include: A building block for building a first-order Nernst equivalent circuit model of a battery; A determination module, configured to obtain operating parameters of a battery based on the first-order Nernst equivalent circuit model; An identification module, used for performing parameter identification on the first-order Nernst equivalent circuit model using an FFRLS algorithm; A first estimation module, used for performing SOC estimation based on a first-order Nernst equivalent circuit model after parameter identification and using a filtering algorithm to obtain a first SOC estimation value; A second estimation module, used for constructing and training a neural network for SOC estimation, and performing SOC estimation through the neural network to obtain a second SOC estimation value; A fusion module is used to perform a fusion calculation on the first SOC estimation value and the second SOC estimation value to obtain the SOC estimation value of the battery.