# A Hybrid Method for SOC Estimation of Power Battery

Authors: Jiliang Yi; Xuechun Zhou; Jin Zhang; Zhongqi Li
Journal: Journal of Control Science and Engineering
 (2021)

---

## Abstract

The accuracy of battery state of charge (SOC) is crucial for solving the problems such as overcharge, overdischarge, and mileage anxiety of electric vehicle power battery. In this study, an SOC estimation method using a hybrid method (HM) based on threshold switching is proposed, which combines the advantages of the extended Kalman filter (EKF) and the ampere hour integration (AHI) to improve the estimation accuracy and convergence speed. First, the parameters of the second-order RC equivalent model are identified using the least square. Then, the equation of EKF for updating the state variable is reconstructed by using the identified parameters to solve the problem of multiple iterations caused by the uncertainty of the initial value. Finally, the difference between the estimated voltage and the sampling voltage is used as the threshold value for switching between the AHI and the EKF to estimate the SOC of the battery. Simulation results show that the estimated SOC error of the proposed algorithm is less than 1.6% and the convergence time is within 70 s. Experiments under different SOC initial values are carried out to prove the advantages of the proposed method.


---

## Body

## 1. Introduction

The new energy vehicles, especially pure electric vehicles, have become one of the solutions to energy crisis and environmental pollution. Many governments have realized the importance of new energy vehicles, identified them as strategic emerging industries, and announced that fuel vehicles will be banned in the near 20 years [1]. Almost all automobile manufacturers are keeping up with the trend of the times and hope to make breakthroughs in key technologies of electric vehicles. However, battery technology is still one of the main factors restricting the development of electric vehicles [2].The power battery directly provides energy for the electric vehicle, and its SOC is an important parameter of intelligent control strategy. The lithium batteries are the first choice for the energy storage system in the field of electric vehicles and robots because of its excellent high energy density and power density [3, 4]. However, the SOC cannot be measured directly, and its accuracy has an important influence on overcharge, overdischarge, and mileage anxiety of power battery. Therefore, accurate estimation of SOC has important practical significance for the safe driving and prolonging the battery life [5, 6].The existing SOC estimation methods include the AHI method, internal resistance method, open circuit voltage method, load voltage method, neural network method, and Kalman filter (KF) method [7, 8]. The AHI method can be realized simply, but it needs to estimate the initial value accurately, and the estimation result has accumulated error [9]. The open circuit voltage of power battery has a clear monotonous relationship with SOC, so the open circuit voltage method can be used to estimate SOC, but the battery needs a long time to stand, so it cannot be used in the real-time system [10]. The neural network method can continuously improve the estimation accuracy through learning, but it needs huge sample data and large amount of calculation [11]. KF is used to update the estimation of state variables by iterating the estimated value of the previous time and the observed value of the current time. KF is highly dependent on the system model, and it is designed for linear system, so the estimation accuracy of the nonlinear system cannot be guaranteed [12, 13]. Although the unscented Kalman filter (UKF) is used to solve this problem through system transformation, it is sensitive to the initial value and easy to be affected by the system noise [14–16]. EKF enables KF to be applied in the nonlinear field and is widely used in SOC estimation, which is essentially a nonlinear system [17, 18]. However, when the initial parameters deviate greatly from the real values, the estimation accuracy and convergence rate of EKF are not ideal [19, 20].In recent years, some other SOC estimation methods have been developed. Multistage alternative current (AC) strategy has been proposed for quickly heating the battery under test without negative impact on battery health [21]. A novel data-driven method that can estimate SOC and SOE simultaneously is investigated based on a long short-term memory (LSTM) deep neural network [22]. A cell inconsistency evaluation model of series-connected battery systems using real-world EV operation data is used for practical applications [23]. A HEESS with appropriate sizing and enabling energy management make the battery degradation rate of the battery be greatly reduced, and the cost of the system can be controlled [24]. In addition, uncertainty management is also very important for battery state estimation. However, some estimation methods developed in recent years are mainly used in battery health and life management [25–27]. Machine learning has been reported in the field of lithium battery manufacturing, and it should also have development potential in SOC estimation [28, 29].In this study, several different equivalent models are compared and the advantages of different models are discussed and selected. According to the appropriate equivalent model, the state equation is established, and the parameters of the state equation are identified. Combined with the advantages of EKF and AHI, a hybrid method (HM) algorithm is formed by taking the difference voltage as the control threshold to switch between EKF and AHI methods. Therefore, the proposed method has the advantages of both the EKF method and AHI method. The estimation accuracy and convergence speed are improved by optimizing the model coefficients, and the problem of long time iteration caused by giving inaccurate initial values is solved.The remainder of this study is organized as follows. The equivalent model of power battery is introduced in Section2. The SOC estimation based on HM is reported in Section 3. The simulations and result analysis making to verify the performance of the technique are documented in Section 4. Finally, the whole work is summarized in Section 5.


## 2. Equivalent Model of Power Battery

### 2.1. Model Selection

The performance of the battery is affected nonlinearly by factors such as current, power, SOC, and temperature. The accurate battery equivalent model is the basis for accurate prediction of real-time state of external characteristics of the battery, and the current commonly used battery equivalent models include the Rint model, Thevenin model, and PNGV model. The Rint model is relatively simple and easy to implement, but its low accuracy leads to a poor simulation effect. The Thevenin model introduces the polarization part into the Rint model, which makes the simulation for the dynamic process of charge and discharge more accurate. However, the phenomena of open circuit voltage change, overcharge, and self-discharge caused by current accumulation are not considered in the Thevenin model. Based on the Thevenin model, the PNGV model considers the dynamic change of open circuit voltage caused by the dynamic change of load side current, which can more closely simulate the dynamic performance of the battery, but increases the model complexity and the difficulty of parameter identification. Considering the complexity and accuracy of the above models, the Thevenin second-order RC model is adopted in this study, as shown in Figure1.Figure 1
Thevenin second-order RC equivalent model.The parameters relationship of the model in Figure1 can be expressed as(1)U=Uoc−U0−U1−U2,(2)i=U1R1+C1dU1dt=U2R2+C2dU2dt,where UOC is the open circuit voltage, i is the current, R1 and C1 are the internal resistance and capacitance of electrochemical polarization, R2 and C2 are the internal resistance and capacitance of concentration polarization, U1 is the voltage of R1 and C1, U2 is the voltage of R2 and C2, R0 is the ohmic internal resistance, and U is the terminal voltage.The concept of SOC is defined according to the change of electric quantity. SOC of a battery can be expressed as(3)SOC=QCQN,where QC is the remaining battery capacity, and QN is the rated capacity of battery.SOC cannot be measured directly, and it can only be estimated by detecting battery parameters. SOC can be expressed as(4)SOC=SOC0−1Er∫t0tηitdt×100%,where SOC0 is the initial value of battery SOC, Er is the rated capacity of battery, η is the working efficiency of the battery, and t0 is the initial time.


### 2.2. Parameter Identification

The OCV-SOC curve is usually used to identify the parameters of battery model, and the simultaneous equations of relevant parameters are obtained by mathematical model transformation, and the parameters are obtained by solving the equations.


#### 2.2.1. Obtaining OCV-SOC Curve

Parameter identification, model validation, and SOC estimation are all related to the OCV-SOC curve. Taking a certain type of 3.6 v/3.4 Ah lithium battery as an example, at room temperature, when the battery is in a long-standing state, the open circuit voltage of the battery is approximately equal to the terminal voltage of the battery. Therefore, the OCV-SOC curve can be obtained by the following steps.(1)
Discharge the battery to the lower cutoff voltage of 2.5 V and leave the battery for a period of time(2)
The battery was charged at a charge rate of 0.2 C. When SOC increased by 10%, the battery was allowed to stand for 4 minutes and the battery voltage was measured. The above operation process was repeated until SOC = 95%.(3)
When the battery port voltage reaches the upper limit cutoff voltage of 4.2 V, leave the battery for a period of time(4)
Discharge the battery at a discharge rate of 0.2 C. When the SOC drops by 10%, leave the battery standing for 4 minutes.(5)
Measure the battery voltage and repeat the above operation until SOC = 5%(6)
The recorded SOC value and battery terminal voltage are fitted, as shown in Figure2, and the polynomial of the fitting curve can be expressed as(5)Uoc=p1×soc5+p2×soc4+p3×soc3+p4×soc2+p5×soc+p6,where p1 = 15.929, p2 = −47.522, p3 = 54.639, p4 = −29.543, p5 = 7.9023, and p6 = 2.7738.Figure 2
OCV-SOC relationship curve.It is found that the approximation degree of the curve end is not accurate enough if the polynomial fitting lower than 4th order is used. However, if polynomial of more than 6th orders is adopted, the computational burden is greatly increased.


#### 2.2.2. Identification of Model Parameters

As shown in Figure1, the parameters to be identified are R0, R1, R2, C1, and C2. In this study, the least square method is used to identify the above parameters of the second-order equivalent model. After Laplace transform, formula (2) can be expressed as(6)UOC=U+iR0+R11+τ1s+R21+τ2s,where τ1=R1C1,τ2=R2C2.The transfer function can be obtained from (6) and expressed as(7)Gs=UOC−Ui=R0+R11+τ1s+R21+τ2s=R0+R1+R2+R0τ1+R0τ2+R2τ1+R1τ2s+R0τ1τ2s21+τ1+τ2s+τ1τ2s2.AfterZ transformation, the above formula can be expressed as(8)Gz−1=α0+α1z−1+α2z−21+β0z−1+β1z−2,where α0,α1,α2,β0,β1 are the coefficients related to the parameters to be identified.G(s) can also be obtained by the bilinear transformation of G(z), which can be expressed as(9)Gs=Gz−1|z=c+s/c−s=α0+α1c+s/c−s−1+α2c+s/c−s−21+β0c+s/c−s+β1c+s/c−s−2=α0+α1+α2/1+β0+β1+2α0−α2/c1+β0+β1s+α0−α1+α2/c21+β0+β1s21+21−β1/c1+β0+β1s+1−β0+β1/c21+β0+β1s2.where c = 2/T, T is the sampling period.Comparing with (7) and (9), the following equations can be obtained:(10)R0+R1+R2=α0+α1+α21+β0+β1R0τ1+R0τ2+R2τ1+R1τ2=2α0−α2c1+β0+β1R0τ1τ2=α0−α1+α2c21+β0+β1τ1+τ2=21−β1c1+β0+β1τ1τ2=1−β0+β1c21+β0+β1.After identifying the system coefficientsα0,α1,α2,β0,β1, the parameters R0,R1,R2,τ1,τ2 are solved by (10). Then, C1 and C2 can be solved by τ1 and τ2.


## 2.1. Model Selection

The performance of the battery is affected nonlinearly by factors such as current, power, SOC, and temperature. The accurate battery equivalent model is the basis for accurate prediction of real-time state of external characteristics of the battery, and the current commonly used battery equivalent models include the Rint model, Thevenin model, and PNGV model. The Rint model is relatively simple and easy to implement, but its low accuracy leads to a poor simulation effect. The Thevenin model introduces the polarization part into the Rint model, which makes the simulation for the dynamic process of charge and discharge more accurate. However, the phenomena of open circuit voltage change, overcharge, and self-discharge caused by current accumulation are not considered in the Thevenin model. Based on the Thevenin model, the PNGV model considers the dynamic change of open circuit voltage caused by the dynamic change of load side current, which can more closely simulate the dynamic performance of the battery, but increases the model complexity and the difficulty of parameter identification. Considering the complexity and accuracy of the above models, the Thevenin second-order RC model is adopted in this study, as shown in Figure1.Figure 1
Thevenin second-order RC equivalent model.The parameters relationship of the model in Figure1 can be expressed as(1)U=Uoc−U0−U1−U2,(2)i=U1R1+C1dU1dt=U2R2+C2dU2dt,where UOC is the open circuit voltage, i is the current, R1 and C1 are the internal resistance and capacitance of electrochemical polarization, R2 and C2 are the internal resistance and capacitance of concentration polarization, U1 is the voltage of R1 and C1, U2 is the voltage of R2 and C2, R0 is the ohmic internal resistance, and U is the terminal voltage.The concept of SOC is defined according to the change of electric quantity. SOC of a battery can be expressed as(3)SOC=QCQN,where QC is the remaining battery capacity, and QN is the rated capacity of battery.SOC cannot be measured directly, and it can only be estimated by detecting battery parameters. SOC can be expressed as(4)SOC=SOC0−1Er∫t0tηitdt×100%,where SOC0 is the initial value of battery SOC, Er is the rated capacity of battery, η is the working efficiency of the battery, and t0 is the initial time.


## 2.2. Parameter Identification

The OCV-SOC curve is usually used to identify the parameters of battery model, and the simultaneous equations of relevant parameters are obtained by mathematical model transformation, and the parameters are obtained by solving the equations.


### 2.2.1. Obtaining OCV-SOC Curve

Parameter identification, model validation, and SOC estimation are all related to the OCV-SOC curve. Taking a certain type of 3.6 v/3.4 Ah lithium battery as an example, at room temperature, when the battery is in a long-standing state, the open circuit voltage of the battery is approximately equal to the terminal voltage of the battery. Therefore, the OCV-SOC curve can be obtained by the following steps.(1)
Discharge the battery to the lower cutoff voltage of 2.5 V and leave the battery for a period of time(2)
The battery was charged at a charge rate of 0.2 C. When SOC increased by 10%, the battery was allowed to stand for 4 minutes and the battery voltage was measured. The above operation process was repeated until SOC = 95%.(3)
When the battery port voltage reaches the upper limit cutoff voltage of 4.2 V, leave the battery for a period of time(4)
Discharge the battery at a discharge rate of 0.2 C. When the SOC drops by 10%, leave the battery standing for 4 minutes.(5)
Measure the battery voltage and repeat the above operation until SOC = 5%(6)
The recorded SOC value and battery terminal voltage are fitted, as shown in Figure2, and the polynomial of the fitting curve can be expressed as(5)Uoc=p1×soc5+p2×soc4+p3×soc3+p4×soc2+p5×soc+p6,where p1 = 15.929, p2 = −47.522, p3 = 54.639, p4 = −29.543, p5 = 7.9023, and p6 = 2.7738.Figure 2
OCV-SOC relationship curve.It is found that the approximation degree of the curve end is not accurate enough if the polynomial fitting lower than 4th order is used. However, if polynomial of more than 6th orders is adopted, the computational burden is greatly increased.


### 2.2.2. Identification of Model Parameters

As shown in Figure1, the parameters to be identified are R0, R1, R2, C1, and C2. In this study, the least square method is used to identify the above parameters of the second-order equivalent model. After Laplace transform, formula (2) can be expressed as(6)UOC=U+iR0+R11+τ1s+R21+τ2s,where τ1=R1C1,τ2=R2C2.The transfer function can be obtained from (6) and expressed as(7)Gs=UOC−Ui=R0+R11+τ1s+R21+τ2s=R0+R1+R2+R0τ1+R0τ2+R2τ1+R1τ2s+R0τ1τ2s21+τ1+τ2s+τ1τ2s2.AfterZ transformation, the above formula can be expressed as(8)Gz−1=α0+α1z−1+α2z−21+β0z−1+β1z−2,where α0,α1,α2,β0,β1 are the coefficients related to the parameters to be identified.G(s) can also be obtained by the bilinear transformation of G(z), which can be expressed as(9)Gs=Gz−1|z=c+s/c−s=α0+α1c+s/c−s−1+α2c+s/c−s−21+β0c+s/c−s+β1c+s/c−s−2=α0+α1+α2/1+β0+β1+2α0−α2/c1+β0+β1s+α0−α1+α2/c21+β0+β1s21+21−β1/c1+β0+β1s+1−β0+β1/c21+β0+β1s2.where c = 2/T, T is the sampling period.Comparing with (7) and (9), the following equations can be obtained:(10)R0+R1+R2=α0+α1+α21+β0+β1R0τ1+R0τ2+R2τ1+R1τ2=2α0−α2c1+β0+β1R0τ1τ2=α0−α1+α2c21+β0+β1τ1+τ2=21−β1c1+β0+β1τ1τ2=1−β0+β1c21+β0+β1.After identifying the system coefficientsα0,α1,α2,β0,β1, the parameters R0,R1,R2,τ1,τ2 are solved by (10). Then, C1 and C2 can be solved by τ1 and τ2.


## 2.2.1. Obtaining OCV-SOC Curve

Parameter identification, model validation, and SOC estimation are all related to the OCV-SOC curve. Taking a certain type of 3.6 v/3.4 Ah lithium battery as an example, at room temperature, when the battery is in a long-standing state, the open circuit voltage of the battery is approximately equal to the terminal voltage of the battery. Therefore, the OCV-SOC curve can be obtained by the following steps.(1)
Discharge the battery to the lower cutoff voltage of 2.5 V and leave the battery for a period of time(2)
The battery was charged at a charge rate of 0.2 C. When SOC increased by 10%, the battery was allowed to stand for 4 minutes and the battery voltage was measured. The above operation process was repeated until SOC = 95%.(3)
When the battery port voltage reaches the upper limit cutoff voltage of 4.2 V, leave the battery for a period of time(4)
Discharge the battery at a discharge rate of 0.2 C. When the SOC drops by 10%, leave the battery standing for 4 minutes.(5)
Measure the battery voltage and repeat the above operation until SOC = 5%(6)
The recorded SOC value and battery terminal voltage are fitted, as shown in Figure2, and the polynomial of the fitting curve can be expressed as(5)Uoc=p1×soc5+p2×soc4+p3×soc3+p4×soc2+p5×soc+p6,where p1 = 15.929, p2 = −47.522, p3 = 54.639, p4 = −29.543, p5 = 7.9023, and p6 = 2.7738.Figure 2
OCV-SOC relationship curve.It is found that the approximation degree of the curve end is not accurate enough if the polynomial fitting lower than 4th order is used. However, if polynomial of more than 6th orders is adopted, the computational burden is greatly increased.


## 2.2.2. Identification of Model Parameters

As shown in Figure1, the parameters to be identified are R0, R1, R2, C1, and C2. In this study, the least square method is used to identify the above parameters of the second-order equivalent model. After Laplace transform, formula (2) can be expressed as(6)UOC=U+iR0+R11+τ1s+R21+τ2s,where τ1=R1C1,τ2=R2C2.The transfer function can be obtained from (6) and expressed as(7)Gs=UOC−Ui=R0+R11+τ1s+R21+τ2s=R0+R1+R2+R0τ1+R0τ2+R2τ1+R1τ2s+R0τ1τ2s21+τ1+τ2s+τ1τ2s2.AfterZ transformation, the above formula can be expressed as(8)Gz−1=α0+α1z−1+α2z−21+β0z−1+β1z−2,where α0,α1,α2,β0,β1 are the coefficients related to the parameters to be identified.G(s) can also be obtained by the bilinear transformation of G(z), which can be expressed as(9)Gs=Gz−1|z=c+s/c−s=α0+α1c+s/c−s−1+α2c+s/c−s−21+β0c+s/c−s+β1c+s/c−s−2=α0+α1+α2/1+β0+β1+2α0−α2/c1+β0+β1s+α0−α1+α2/c21+β0+β1s21+21−β1/c1+β0+β1s+1−β0+β1/c21+β0+β1s2.where c = 2/T, T is the sampling period.Comparing with (7) and (9), the following equations can be obtained:(10)R0+R1+R2=α0+α1+α21+β0+β1R0τ1+R0τ2+R2τ1+R1τ2=2α0−α2c1+β0+β1R0τ1τ2=α0−α1+α2c21+β0+β1τ1+τ2=21−β1c1+β0+β1τ1τ2=1−β0+β1c21+β0+β1.After identifying the system coefficientsα0,α1,α2,β0,β1, the parameters R0,R1,R2,τ1,τ2 are solved by (10). Then, C1 and C2 can be solved by τ1 and τ2.


## 3. SOC Estimation Based on HM

### 3.1. The Principle of EKF

KF is an algorithm for optimal estimation of system state using the linear system state equation. Because KF is suitable for the linear system, it is necessary to introduce EKF into the nonlinear system of lithium battery. Taylor series is used in EKF to linearize the nonlinear system, and then, KF frame is used to process the signal. The state equation of the nonlinear system can be expressed as(11)xk+1=Akxk+BkIk+wk,yk=Ckxk+DkIk+vk,where xk is the system state variable, yk is the system output, Ik is the system input, Ak, Bk, Ck, Dk are the coefficient matrices of the state equation, wk is the system noise, and vk is the measurement noise, they are Gaussian white noise with zero mean value.According to the battery equivalent model, the state and input vector can be described as(12)xk=SOCk,U1,k,U2,kT,Ik=ik.From (1), (4), (11), and (12), the equations of state of the battery equivalent model can be obtained as follows:(13)SOCkU1,kU2,k=1000a000bSOCk−1U1,k−1U2,k−1+ηTErcdIk−1+w,where η is the working efficiency of the battery, and a=e−T/τ1,b=e−T/τ2,c=R11−e−T/τ1,d=R21−e−T/τ2. The corresponding output equation can be expressed as(14)Uk=UOCVSOCk−IkR0−U1,k−U2,k+v.By synthesizing (11)–(14), the coefficient matrix of the state equation can be obtained as(15)Ak=1000a000b,Bk=ηTErcdT,Ck=UOCVSOCk−1−1,Dk=−R0.


### 3.2. SOC Estimation Using HM

Although the state of the linear system can be optimally estimated by traditional EKF, it does not need to estimate the initial value very accurately. However, there is inevitably a linear error for battery SOC estimation because of nonlinearity. In addition, if the initial error is very large, the EKF method needs a long time of iteration to converge to the normal value. To overcome the shortcomings mentioned above, the SOC estimation method based on HM is proposed in the study. In the method, the residual voltage is used as the threshold, by which the EKF method and AHI method are switched. In this way, the convergence speed and estimation accuracy can be optimized. The SOC estimation process based on HM is shown in Figure3.Figure 3
Flowchart of SOC estimation using HM.As shown in Figure3, eight steps are required to estimate SOC using HM. In step (1), the initialization values x0 and p0 are expressed as(16)x0=SOC0,0,0Tp0=100010001.In step (2), the predicted values of the state variablex˜k and the covariance matrix p˜k are calculated by the following formula:(17)x˜k=Akx˜k−1+Bkik,p˜k=Ak−1Pk−1Ak−1T+w.In step (3), Kalman filter gainGkand covariance matrix p^k are updated by the following formula:(18)Gk=P˜kCkTCkP˜kCkT+v−1,P^k=1−GkCkP˜k,where CkT is the transpose of Ck in (15).In step (4), the residual voltageεk refers to the difference between the sampling voltage and the port voltage calculated by the battery model, and Vset is used as the threshold of εk to select the updated mode of state variable x^k, which is updated in step (5) when εk>Vset. Otherwise, x^k remains the predicted value, as described in step (6). The state variable x^k in step (5) can be expressed as(19)x^k=x˜k+Gkεk.The SOC estimatedSOC^k is one of the elements of x^k, so it can be output directly from x^k. When the number of cycles of the algorithm reaches the preset value, the whole algorithm is completed.


## 3.1. The Principle of EKF

KF is an algorithm for optimal estimation of system state using the linear system state equation. Because KF is suitable for the linear system, it is necessary to introduce EKF into the nonlinear system of lithium battery. Taylor series is used in EKF to linearize the nonlinear system, and then, KF frame is used to process the signal. The state equation of the nonlinear system can be expressed as(11)xk+1=Akxk+BkIk+wk,yk=Ckxk+DkIk+vk,where xk is the system state variable, yk is the system output, Ik is the system input, Ak, Bk, Ck, Dk are the coefficient matrices of the state equation, wk is the system noise, and vk is the measurement noise, they are Gaussian white noise with zero mean value.According to the battery equivalent model, the state and input vector can be described as(12)xk=SOCk,U1,k,U2,kT,Ik=ik.From (1), (4), (11), and (12), the equations of state of the battery equivalent model can be obtained as follows:(13)SOCkU1,kU2,k=1000a000bSOCk−1U1,k−1U2,k−1+ηTErcdIk−1+w,where η is the working efficiency of the battery, and a=e−T/τ1,b=e−T/τ2,c=R11−e−T/τ1,d=R21−e−T/τ2. The corresponding output equation can be expressed as(14)Uk=UOCVSOCk−IkR0−U1,k−U2,k+v.By synthesizing (11)–(14), the coefficient matrix of the state equation can be obtained as(15)Ak=1000a000b,Bk=ηTErcdT,Ck=UOCVSOCk−1−1,Dk=−R0.


## 3.2. SOC Estimation Using HM

Although the state of the linear system can be optimally estimated by traditional EKF, it does not need to estimate the initial value very accurately. However, there is inevitably a linear error for battery SOC estimation because of nonlinearity. In addition, if the initial error is very large, the EKF method needs a long time of iteration to converge to the normal value. To overcome the shortcomings mentioned above, the SOC estimation method based on HM is proposed in the study. In the method, the residual voltage is used as the threshold, by which the EKF method and AHI method are switched. In this way, the convergence speed and estimation accuracy can be optimized. The SOC estimation process based on HM is shown in Figure3.Figure 3
Flowchart of SOC estimation using HM.As shown in Figure3, eight steps are required to estimate SOC using HM. In step (1), the initialization values x0 and p0 are expressed as(16)x0=SOC0,0,0Tp0=100010001.In step (2), the predicted values of the state variablex˜k and the covariance matrix p˜k are calculated by the following formula:(17)x˜k=Akx˜k−1+Bkik,p˜k=Ak−1Pk−1Ak−1T+w.In step (3), Kalman filter gainGkand covariance matrix p^k are updated by the following formula:(18)Gk=P˜kCkTCkP˜kCkT+v−1,P^k=1−GkCkP˜k,where CkT is the transpose of Ck in (15).In step (4), the residual voltageεk refers to the difference between the sampling voltage and the port voltage calculated by the battery model, and Vset is used as the threshold of εk to select the updated mode of state variable x^k, which is updated in step (5) when εk>Vset. Otherwise, x^k remains the predicted value, as described in step (6). The state variable x^k in step (5) can be expressed as(19)x^k=x˜k+Gkεk.The SOC estimatedSOC^k is one of the elements of x^k, so it can be output directly from x^k. When the number of cycles of the algorithm reaches the preset value, the whole algorithm is completed.


## 4. Simulations and Result Analysis

To verify the performance of the proposed method, a 3.6 V/3.4 Ah lithium battery was selected for the experiment at room temperature, the algorithms based on HM and EKF are used in the MATLAB simulations, and the results are compared. This proposed method is simulated in MATLAB and processed according to the flow shown in Figure3.


### 4.1. Estimation Error Analysis

The battery model in Section2 is used as the experimental object for simulation, and considering that the estimation performance of SOC in each stage needs to be considered, the initial value SOC0 is set randomly between 95% and 85%. The sampling values of voltage and current are obtained randomly under the conditions of charging, discharging, quiescence, and load variation. A large number of simulations show that the HM-based algorithm has higher estimation accuracy. Considering the space limitation, only the simulation results under the condition of SOC0 = 90% are explained in detail.Figure4 shows the estimated battery voltage results and their errors obtained by EKF and HM, respectively. From Figure 4(a), it can be seen that the estimated voltages of EKF and HM are close to the actual voltage, and from Figure 4(b), it can be seen that the errors of the two algorithms are within 0.08 V.Figure 4
Estimated voltage results and their errors. (a) The estimated voltage. (b) The estimated voltage errors.
(a)(b)Figure5 shows the estimated SOC results and their errors. It can be seen from Figure 5(a) that the SOC estimated by HM can closely track the change of the actual SOC, while there is a big gap between the SOC estimated by EKF and the actual SOC. It can be seen from Figure 5(b) that the errors of SOC estimated by HM are between 0.2% and 1.6%, while the estimation results estimated by EKF fluctuate greatly, and the errors are between −4.1% and 4.3%, and the large error area is concentrated in the middle part and the end part. Therefore, HM is better than EKF in both estimation accuracy and whole process stability, and it also shows that HM has a better noise suppression effect.Figure 5
Estimated SOC results and their errors. (a) The estimated SOC. (b) The estimated SOC errors.
(a)(b)


### 4.2. Analysis of Convergence Speed

In practice, SOC0 is usually unknown. If SOC0 is given arbitrarily, whether the algorithms are robust or not is an important problem to be verified. Without losing generality, set the real SOC0 = 1, and when executing the algorithm, three different SOC0s are set to simulate, namely, SOC0 = 90%, SOC0 = 60%, and SOC0 = 20%, respectively. The convergence speed of the HM algorithm under different SOC0s conditions is shown in Figure 6. It can be seen from Figure 6 that when SOC0 is set to 90%, 60%, and 20%, the HM algorithm is used for SOC estimation, and the corresponding estimation error is converged to less than 5% after 37 s, 55 s, and 61 s, respectively. It can be seen from the results that HM can make the estimation result converge to the normal value quickly even when the deviation of SOC0 is large. At the same time, the smaller the deviation of SOC0 is, the faster the convergence is. Through a lot of simulations, no matter how large the deviation of SOC0 is, HM can make the estimation result converge to the normal value within 70 s.Figure 6
The convergence speed of HM under different SOC0s.It can be seen from Figure7 that the time for EKF to converge to the normal value is about 1000 s when SOC0 is set to 60% and 20%, while the time for HM to converge to the normal value is within 70 s. Obviously, the convergence speed of HM is much faster than that of EKF.Figure 7
The convergence speed of EKF under different SOC0s.As shown in Figure8, when SOC0 = 90%, i.e., the initial value deviation is small, the SOC estimates obtained by HM and EKF methods converge quickly. At the same time, it is obvious that the HM method can always stick to the true value after convergence, while the EKF method has unstable deviation in the whole process and does not show a trend of approaching the true value. Therefore, the proposed method has better robustness.Figure 8
The convergence speed of EKF and HM under SOC0 = 0.9.


## 4.1. Estimation Error Analysis

The battery model in Section2 is used as the experimental object for simulation, and considering that the estimation performance of SOC in each stage needs to be considered, the initial value SOC0 is set randomly between 95% and 85%. The sampling values of voltage and current are obtained randomly under the conditions of charging, discharging, quiescence, and load variation. A large number of simulations show that the HM-based algorithm has higher estimation accuracy. Considering the space limitation, only the simulation results under the condition of SOC0 = 90% are explained in detail.Figure4 shows the estimated battery voltage results and their errors obtained by EKF and HM, respectively. From Figure 4(a), it can be seen that the estimated voltages of EKF and HM are close to the actual voltage, and from Figure 4(b), it can be seen that the errors of the two algorithms are within 0.08 V.Figure 4
Estimated voltage results and their errors. (a) The estimated voltage. (b) The estimated voltage errors.
(a)(b)Figure5 shows the estimated SOC results and their errors. It can be seen from Figure 5(a) that the SOC estimated by HM can closely track the change of the actual SOC, while there is a big gap between the SOC estimated by EKF and the actual SOC. It can be seen from Figure 5(b) that the errors of SOC estimated by HM are between 0.2% and 1.6%, while the estimation results estimated by EKF fluctuate greatly, and the errors are between −4.1% and 4.3%, and the large error area is concentrated in the middle part and the end part. Therefore, HM is better than EKF in both estimation accuracy and whole process stability, and it also shows that HM has a better noise suppression effect.Figure 5
Estimated SOC results and their errors. (a) The estimated SOC. (b) The estimated SOC errors.
(a)(b)


## 4.2. Analysis of Convergence Speed

In practice, SOC0 is usually unknown. If SOC0 is given arbitrarily, whether the algorithms are robust or not is an important problem to be verified. Without losing generality, set the real SOC0 = 1, and when executing the algorithm, three different SOC0s are set to simulate, namely, SOC0 = 90%, SOC0 = 60%, and SOC0 = 20%, respectively. The convergence speed of the HM algorithm under different SOC0s conditions is shown in Figure 6. It can be seen from Figure 6 that when SOC0 is set to 90%, 60%, and 20%, the HM algorithm is used for SOC estimation, and the corresponding estimation error is converged to less than 5% after 37 s, 55 s, and 61 s, respectively. It can be seen from the results that HM can make the estimation result converge to the normal value quickly even when the deviation of SOC0 is large. At the same time, the smaller the deviation of SOC0 is, the faster the convergence is. Through a lot of simulations, no matter how large the deviation of SOC0 is, HM can make the estimation result converge to the normal value within 70 s.Figure 6
The convergence speed of HM under different SOC0s.It can be seen from Figure7 that the time for EKF to converge to the normal value is about 1000 s when SOC0 is set to 60% and 20%, while the time for HM to converge to the normal value is within 70 s. Obviously, the convergence speed of HM is much faster than that of EKF.Figure 7
The convergence speed of EKF under different SOC0s.As shown in Figure8, when SOC0 = 90%, i.e., the initial value deviation is small, the SOC estimates obtained by HM and EKF methods converge quickly. At the same time, it is obvious that the HM method can always stick to the true value after convergence, while the EKF method has unstable deviation in the whole process and does not show a trend of approaching the true value. Therefore, the proposed method has better robustness.Figure 8
The convergence speed of EKF and HM under SOC0 = 0.9.


## 5. Conclusions

The estimation accuracy of SOC is affected by the model parameters and initial value deviation. In this study, the least square online parameter identification is used to overcome the error problem caused by inaccurate parameters. By introducing residual voltage as the threshold for switching between EKF and AHI methods, the HM algorithm is proposed to improve SOC estimation performance. The estimation error of the proposed algorithm is between 0.2% and 1.6%, and the estimation accuracy is significantly improved compared with EKF. The convergence speed of the proposed algorithm is within 70 s, which is much faster than that of the EKF algorithm, and has better stability. The proposed algorithm can obtain SOC estimation quickly and accurately, so it can provide a more reliable reference value of port voltage for the battery model.In this study, the influence of different experimental conditions such as temperature on SOC estimation results is not considered, and the uncertainty analysis is not fully carried out. At the same time, there is a lack of physical experiments to verify the adaptability of the proposed method in practical application, which needs to be solved in the future work. In addition, an adjustable Kalman coefficient adopted to improve the performance of the proposed method and new tools such as machine learning employed in SOC estimation is worthy of further research.



---

*Source: 6758679-2021-11-19.xml*