Abstract
The power battery is a key component of the electric vehicle, and its State of health (SOH) parameters directly affect the safety and reliability of the electric vehicle. Considering the problem of the reduced SOH estimation accuracy of Li-ion battery, this paper proposes a joint algorithm of the firefly algorithm-back propagation neural network K-means (FA-BPNN-K-means) for SOH estimation to alleviate the wide voltage platform and severe polarization. In particular, the BPNN model of the battery is first established. The ohmic resistance, polarization resistance, and polarization capacitance of the battery are used as the input parameters of the model, and SOH was used as the output parameters. Secondly, the firefly algorithm (FA) is used to optimize BPNN for SOH estimation of Li-ion battery, solving the problem that BPNN is easy to fall into the local minimum and the convergence rate is slow. Finally, the predicted output of the FA-BPNN model is substituted into the K-means algorithm for clustering, and the data points for evaluation are obtained to reduce the cumulative error caused by the battery model. Compared with the BPNN algorithm, FA-BPNN-K-means joint optimization algorithm, obtaining lower error in SOH estimation, and it has good convergence. Besides, it is accompanied by higher prediction accuracy, which can guarantee the stable operation of the battery management system.
Keywords
Introduction
With the increasingly serious environmental and energy problems, new energy electric vehicles gradually become the mainstream of future transportation because of their environmental friendliness, high energy efficiency, simple structure, low noise, and other advantages. Li-ion battery is the core power of electric vehicles with good features of high energy density and long cycle life. Since the performance of Li-ion batteries directly affects the stability and reliability of the entire system, it is very necessary to estimate the State of health (SOH) [1, 2]. Battery health is one of the important parameters for battery performance and fault diagnosis. It also reflects the degree of battery aging. In other words, SOH mainly reflects the change in the current performance of the battery relative to its initial state, determining the maintenance and replacement time of the battery, and provides protection for the battery. Therefore, accurate estimation of SOH is of great significance to ensure the performance of energy storage systems, reduce cost and improve safety [3].
In recent years, domestic and foreign scholars have carried out many studies in the field of SOH estimation and proposed a variety of methods, including direct measurement method, model-based method, and data-driven method [4]. Among them, data-driven SOH estimation of Li-ion battery can be achieved without considering the aging mechanism and internal electrochemical reaction of Li-ion battery through the data obtained from various aging tests of Li-ion battery. It mainly includes Support Vector Machine (SVM) [5], Fuzzy Logic (FL) [6], Gaussian Process Regression (GPR) [7], and neural network (NN) [8]. The data-driven method has attracted extensive attention because it can describe complex battery degradation process only by mining the potential laws of historical data instead of an in-depth mechanism study. Such methods mainly include the Kalman filter algorithm, neural network algorithm, deep learning, fuzzy logic algorithm, etc. [9].
Due to the frequent driving and parking of electric vehicles, the Li-ion battery has a high current during charging and discharging, resulting in a strong nonlinear degradation effect of the Li-ion battery. The back propagation neural network (BPNN), as a simple and effective method to solve nonlinear problems, is often used to estimate the SOH of Li-ion batteries online. Yang et al. used three-layer BPNN to estimate SOH [10]. However, the traditional BPNN is easy to make the weight fall into the local optimal value by adopting the fastest descent method. Dai et al. proposed a prior knowledge-based Neural Network and Markov Chain battery health state prediction method to solve the problem that it is difficult to accurately predict lithium-ion SOH of electric vehicles, and the existing prediction models are complex and require a large amount of calculations [11]. For the traditional BPNN online estimation of lithium-ion SOH, the weight is easy to fall into the local optimal solution, which results in the inaccuracy of SOH measurement. In combination with the simulated annealing algorithm, which can effectively converge to the global optimal, Talha et al. proposed an online SOH prediction method based on SA algorithm to optimize BPNN for Li-ion battery [12]. Sun and Wang used a multi-island genetic algorithm (MIGA) and gauss process regression (GPR) to optimize BP neural network for SOH estimation of Li-ion battery. By using the global optimization ability of the MIGA-GPR algorithm and the characteristics of fast convergence speed, the weights and thresholds of the BP neural network are optimized to solve the problems that BP neural network is easy to fall into the local minimum value and slow convergence speed [13]. To solve the problem of difficult health state estimation of lithium batteries under dynamic conditions, Feng et al. designed a health state estimation method based on a support vector regression machine [14]. To solve the problem in SOH prediction of Li-ion battery, a hybrid algorithm was adopted to model Li-ion battery based on ampere-hour integral method and the analysis of the external characteristics of Li-ion battery, but the cumulative error caused by the battery model was ignored [15]. All in all, the Li-ion battery SOH estimation is facing the problem of low accuracy [1, 2, 3, 4], poor timeliness [5, 6, 7, 8], and high complexity [11, 12, 13, 14, 15]. Therefore, a promising algorithm with global optimization ability and fast convergence speed was proposed to optimize the SOH by improving FA-BPNN and applying the K-means. However, the firefly algorithm-back propagation neural network K-means (FA-BPNN-K-means) algorithm was not applied to optimize the SOH estimation of the Li-ion battery because of its slow convergence speed and easily falling into local minimum. Overall, the main research highlights of this paper can be listed as follows.
Due to the serious polarization and the wide voltage platform being harmful to the SOH estimation of the Li-ion battery, this paper adopts the second-order resistor capacitance (RC) equivalent circuit model of the Li-ion battery and uses the FA-BPNN-K-means joint optimization algorithm to estimate the battery SOH in real-time. The weight and threshold of the BPNN algorithm are optimized by using the global optimization ability and fast convergence speed of the FA algorithm to avoid falling into local optimal. The FA-BPNN algorithm is used to model the Li-ion battery, and the model is substituted into the K-means algorithm to reduce the cumulative error caused by the battery model. The FA-BPNN-K-means algorithm has lower error, better convergence, and higher prediction accuracy than the BPNN algorithm in SOH estimation, which can guarantee the stable operation and safety of battery management systems for electric vehicles.
Battery input parameter identification
To construct the battery health indicator (HI) that is suitable for online estimation of electric vehicles, a lithium iron phosphate battery was taken as the research object. The working process of the battery is accompanied by complex physical and chemical changes and it is a nonlinear process. Therefore, the neural network needs to select appropriate battery characteristic parameters as input. Using only a single factor as the evaluation standard has large error, but choosing multiple factors as the input of the BP neural network will make the estimation results more accurate [16]. Given the characteristic of lithium iron phosphate battery with two poles, a set of parallel RC circuits is connected in series on the traditional Partnership for a New Generation of Vehicles (PNGV) equivalent circuit, which can better reflect the polarization phenomenon of the battery [17]. Based on the improved PNGV equivalent circuit model, the circuit model proposed in this paper is shown in Fig. 1.
Improved PNGV equivalent circuit model.
According to the equivalent circuit model of Li-ion battery, as shown in Fig. 1, the relationship between battery terminal voltage and current can be obtained as:
where
As is shown in the equations,
With the increase of the number of cycles,
It can be seen from Eq. (4) that with the continuous increase of Li-ion battery cycle times, the battery life continues to decay, and the changing trend
When a chemical change occurs in a lithium battery, the internal resistance of the battery will be generated due to the obstruction of the electrons to make the directional movement, and the SOH of the battery can be calculated by the attenuation of the internal resistance of the lithium battery [18]. The internal resistance of lithium batteries is generally composed of electrolyte resistance, diaphragm resistance, the resistance of electrode material, and resistance generated by the connection of electrode and electrolyte. The crystal in the electrode material will change constantly because of the deformation of the internal structure of the electrode, and the internal resistance of the material will become larger. The internal resistance of the connection between the electrode and the electrolyte and the internal resistance of the electrode material do not change during discharging, so it can be regarded as a constant value. As the reaction progresses, the contact area between the electrode and the electrolyte becomes smaller, and the internal resistance of the connection becomes larger [19]. Therefore, the estimated changes in battery health can be expressed by predicting internal resistance.
From the equation above,
The BPNN algorithm is a multi-layer feedforward network trained according to the error backpropagation algorithm. It uses the methods of gradient descent and means square error to modify the weight of the network connection. It is widely used and is one of the NN algorithms that have been studied. In addition, BPNN is a model that simulates brain neurons to deal with uncertain problems, and three-layer NN has better prediction results for highly uncertain problems. A three-layer BPNN can meet the design accuracy requirements and achieve the approximation of any nonlinear function [10]. Therefore, a three-layer BPNN is selected for the experiment to model the battery. The three-layer BPNN is composed of the input layer, the hidden layer, and the output layer. The number of nodes of the input neuron is related to the mapping model, so three HI are used as input independent variables, and the structure of BPNN is shown in Fig. 2.
Structure diagram of BPNN.
Because the predicted SOH value is a scalar, the neuron in the output layer has one node. The number of hidden layer neurons is related to the nonlinear mapping ability according to the three rules, i.e., (1) the number of hidden neurons should be between the number of the input layer and the number of the output layer, (2) the number of hidden neurons should be 2/3 of the number of the input layer neurons, plus the number of the output layer, and (3) the number of hidden neurons should be less than twice the number of the input layer. For the number of hidden nodes, the empirical equation is defined as follows.
According to the equation,
The output of the hidden layer is
The errors of output layer nodes and hidden layer nodes are calculated with
The error function is defined through the actual output of the network.
According to the principle of dynamic reverse error transfer algorithm, the connection weight is adjusted by the fastest descent method to make the error function reach the minimum value at the fastest speed. The basic equation of weight correction is:
To ensure the safe and reliable operation of electric vehicles, FA-BPNN-K-means was used to jointly optimize the SOH estimation of the Li-ion battery guaranteeing the stable operation of the battery management system.
FA optimization algorithm
FA has many similarities with other swarm intelligence algorithms, such as particle swarm optimization and artificial bee swarm optimization, but it is simpler in concept and implementation [20]. The principle of FA is that each point in space is treated as a firefly and the firefly with strong luminescence are used to attract the ones with weak luminescence. The process of the weak firefly moving to the strong firefly completes the position iteration to find the optimal position. In FA, there are three idealized rules: (1) Any firefly will be attracted to the brighter firefly, regardless of gender; (2) The attraction is proportional to the light intensity, and decreases with the increase of distance; (3) The state of the objective function determines the light intensity of the firefly.
(1) Light intensity and attraction
In FA, there are two important factors, namely the change of light intensity and the expression of attraction. The intensity of light varies with the inverse square law.
As we can see,
The attraction of fireflies is proportional to the light intensity seen by neighboring fireflies. Therefore, the attraction of fireflies
(2) Position distance
Any two fireflies
In the equation,
(3) Position iteration
The movement of the firefly
In which
(4) The convergence of fireflies to the globally optimal position
For any number of fireflies
Pseudocode of FA
The optimization of the BP neural network is mainly to optimize the initial weight and threshold of the BP network, improve the performance of network learning and avoid falling into the local optimal solution by using the fast iteration and global optimization of FA. The process of FA optimization of the BP neural network (FA-BPNN) algorithm is shown in Fig. 3.
Flow chart of FA-BPNN algorithm.
It is known that the number of neurons in the neural network input layer, hidden layer, and output layer is 3, 7, and 1, respectively. Therefore, the real number coding of individual firefly parameters is 36, and the weights and thresholds in the network are
The initial parameters of the BPNN are constructed, including the initial threshold, training times, etc. The initial values of firefly emission are set, including the number The objective function is calculated, namely, calculate the fitness function of the firefly. In FA-BPNN, the training accuracy is determined by the mean square error function
The attraction degree and relative light intensity between fireflies are determined. The attraction degree Position movement based on fitness function is in Eq. (19). To avoid the expansion of the effective distance of attraction caused by the irregular movement of fireflies, the lower limit of attraction
When the number of iterations reaches the maximum or the error converges, it ends. Otherwise, return to step 5. The global optimal position vector of firefly is mapped to BPNN, which is used as the initial weight and threshold of the NEURAL network after FA optimization. BPNN training is to meet, output the optimal parameters and complete the training.
In the SOH estimation, the Li-ion battery model is firstly built by using the FA-BPNN algorithm, then K-means algorithm achieves the clustering and reduces the cumulative error caused by the battery model. The K-means clustering algorithm is one of the most typical distance-based non-hierarchical clustering algorithms at present. Its main principles are as follows: Firstly,
Pseudocode of K-means clustering algorithm
Pseudocode of K-means clustering algorithm
If different clustering centers are selected initially, the global optimal classification will deviate seriously from the result. To get better results, it is usually necessary to run the K-means algorithm several times to get different initial clustering centers [21]. For continuous attributes, the values of each attribute must be zero-mean normalized before the distance calculation. In the K-means clustering algorithm, the commonly used methods to measure the distance between samples are Euclidean distance, Manhattan distance, and Minkowski distance. The distance between clusters is usually expressed by the distance of the cluster centers, and the distance between samples and clusters is usually expressed by the distance from the sample to the cluster center.
To solve the disadvantages of the traditional BPNN algorithm, such as easily falling into local minimum and slow convergence speed, the FA-BPNN K-means algorithm is proposed in this paper, we compare the proposed algorithm with the traditional BPNN algorithm in the SOH estimation of the Li-ion battery. More specially, the input of the FA-BPNN algorithm is current, SOH, and depth of discharge (DOD), and the output is OCV and internal resistance, meanwhile the predicted OCV and internal resistance is regarded as the input of the K-means clustering algorithm.
Setting of parameters
The test object is an 18650-type lithium iron phosphate positive Li-ion battery (made in Shenzhen) with a rated capacity of 1800 mAh and charging-discharge voltage of 2.7–3.6 V. The test was carried out on the experimental platform built by ARbin-BT200 multi-function battery test system (made in America) and GD-JS41 thermostat (made in Shanghai). The data was stored and read by the upper computer, and the test temperature was 25
The SOH estimation models of BPNN and FA-BPNN were built on MATLAB. The battery differential voltage
Results analysis
To verify the effectiveness of the FA-BPNN algorithm in the SOH estimation, the BPNN algorithm and the FA-BPNN algorithm are used to generate 500 groups of two-dimensional random numbers
Error before and after optimization with FA.
In our experimental setting, 180 groups of processed experimental data were selected, among which 105 groups were used as training sample data and 75 groups were used as test sample data. The processed experimental data were respectively input into the model for the simulation experiment as shown in Fig. 5. The mean square error
Performance curves of (a) BPNN and (b) FA-BPNN.
The battery differential voltage
OCV (a), SOH (b), and error (c) of FA-BPNN algorithm.
The voltage and internal resistance predicted by the FA-BPNN algorithm need to be clustered by the K-means algorithm to obtain the data points for the SOH estimation, i.e., the Li-ion battery model was built and substituted into the K-means algorithm by using the FA-BPNN algorithm based on the ampere-hour integral method. The modeled output OCV value and internal resistance value were substituted into the programmed K-means algorithm to obtain the prediction diagram as shown in Fig. 7, and the abscissa is the internal resistance, the ordinate is the two clustering points CTRS1 (0.03298, 3.33043) and CTRS2 (0.03299, 3.33043) of the OCV.
Prediction diagram of K-means algorithm.
The internal resistance data obtained from 100 groups of experiments was taken and the clustering points obtained were put into the experimental data to observe the accuracy of clustering. The combination of the experimental data and predicted clustering points were CTRS1 (0.032 94, 3.33) and CTRS2 (0.033, 3.33), and we found that the clustering points could accurately cluster the two clusters to be obtained.
In this paper, an estimation model based on FA-BPNN-K-means and an estimation model based on BPNN were established respectively, and the influence factors closely related to SOH of Li-ion battery, such as differential voltage, ohm internal resistance, and cycle number were taken as the input parameters of the model. MATLAB simulation results show that compared with BPNN, the FA-BPNN-K-means estimation model proposed in this paper has better convergence and higher estimation accuracy, and the average error is within 1.00%. It has high theoretical value and good practicability and has a good application value in SOH estimation of Li-ion batteries in electric vehicles. Using the measured lithium battery parameters to accurately and reliably estimate the health status of batteries has gradually become a research topic which electric vehicle and battery researchers pay attention to and want to invest in. However, due to the complex relationship between these battery parameters and SOH, more experiments are needed to obtain high accuracy and reliability which is difficult. It is of great practical significance to establish an accurate, reliable, and relatively concise SOH estimation method, this needs further study.
Footnotes
Acknowledgments
This work was supported by the National Key Research and Development Program of China (No. 2017YFC0804704) and the Shanghai Second University of Technology Foundation (No. EGD21QD20).
