State of Charge Estimation Algorithm for Unmanned Aerial Vehicle Power-Type Lithium Battery Packs Based on the Extended Kalman Filter

: The lack of endurance is an important reason restricting further development of unmanned aerial vehicles (UAVs). Accurately estimating the state of charge (SOC) of the Li-Po battery can maximize the battery energy utilization and improve the endurance of UAVs. In this paper, the main current methods for estimating the SOC of vehicles were explored and discussed to unveil their advantages and disadvantages. In addition, the extended Kalman ﬁlter algorithm based on an equivalent circuit model was used to estimate SOC of power-type Li-Po batteries at di ﬀ erent temperatures. The result showed that the closed-loop control method can e ﬀ ectively improve the battery life of small-sized electric UAVs.


Introduction
Small-sized unmanned aerial vehicles (UAVs) are widely used in various fields (including personal, commercial, and military fields) due to a series of advantages, i.e., small volume, light weight, flexibility, and low cost. A majority of small-sized UAVs apply an electric propulsion system and show a high practical application value due to having various characteristics, including simplicity in operation, high reliability, and ease of maintenance, storage, and transportation [1]. However, the energy density (about 185 W·h/kg) of a battery is far lower than that (about 10 kW·h/kg) of fuel oil. As a result, the battery life of electric UAVs is short [2]. Electric UAVs keep their mass unchanged during the entire mission period, which is different from oil engines, and the discharge voltage of the batteries constantly declines [3]. The discharge time of a battery is related to various factors, including discharge rate, power, and voltage [4]. Therefore, the accurate estimation of the state of the batteries is crucial for improving the utilization rate and increasing the battery life of electric UAVs.
Compared with lead-acid or nickel-metal batteries, lithium (Li) ion batteries show the following advantages, such as high specific energy, long cycle life, low self-discharge rate, no memory effect, and no pollution [5]. At present, Li-ion batteries are one of the most primary energy storage systems for small-sized UAVs with an electric propulsion system. However, Li-Po batteries still exhibit many shortcomings in practical applications. For example, Li-ion batteries with non-ideal security are prone to be affected by temperature (changing discharge rate), the service life of batteries is reduced due to deep discharges (lower than its nominal value) and according to the number of charge-discharge cycles, and then their performances are attenuated after aging. Single batteries show inconsistency after forming battery packs [6]. To solve these problems, it is necessary to favorably manage current battery packs. This is in addition to making improvements and development in these aspects, i.e., battery materials and manufacturing processes. Therefore, battery management systems (BMS) are emerging as a topic of research. BMS can effectively manage and control battery packs, ensure the safety and reliability of batteries during use, and prolong the practical service life of batteries while delivering their optimal performance [7].
Among the numerous functions of BMS, the estimation of the battery state is fundamental and crucial. The common battery states involve the state of charge (SOC), state of power (SOP), state of health (SOH), and state of energy (SOE). SOC reflects the remaining capacity of batteries, which can generally be defined as the ratio of the remaining charge to the capacity (charge of a battery at full state of charge). SOC is an important internal state influencing the performance of batteries. The open-circuit voltage (OCV), internal resistance, output power, remaining capacity, etc., are all closely related to SOC of the battery. Therefore, attaining accurate SOC is the basis for BMS to realize other related functions [8].

Methods
At present, there have been numerous researches on SOC estimation, which are mainly divided into six types.
(1) The ampere-hour (Ah) integration method is simple and easy to apply, so it is frequently used in BMS in the early stages. However, the method generally shows low estimation accuracy in practical application. The main reasons are summarized as follows: inaccurate initial value of the SOC will constantly influence the estimated result; the measurement error of the current sensors and the error of Coulombic efficiency lead to an accumulative error for the SOC; there is a large SOC estimation error when battery capacity parameters show errors. Thus, the SOC obtained by utilizing the Ah integration method alone exhibits a large error [9].
(2) The OCV method: owing to it requiring long-term standing, the simple OCV method is not applicable for dynamically estimating SOC online. Instead, it is usually used to assist and correct other methods (such as the Ah integration method). The OCV method based on models solves the problem. However, OCV estimation is greatly influenced by measurement noises of the measured current and voltage and model error. Therefore, there is low estimation accuracy in practical application [10,11].
(3) Typical estimation methods based on the machine learning model include the neural network model [12] and the support vector regression model [13]. The machine learning model shows its superior universality, that is, it is unnecessary to consider types of batteries and the practical physical relationship between input and output values. However, the machine learning model depends on a large amount of data training, so it is only applicable within the original training data range. Where the practical application environment greatly differs from the training data, it fails to guarantee model accuracy and practical SOC estimation accuracy.
(4) Estimation methods based on an electrochemical model that concerns the electrochemical mechanism in batteries describes the dynamic characteristics of batteries from a microscopic scale. Compared with the equivalent circuit model that only describes external characteristics of batteries, the electrochemical model can offer more internal information on batteries and realize a high accuracy theoretically. Han [14] briefly introduced two commonly used electrochemical models-the single-particle (SP) model and pseudo-two-dimensional (P2D) model. As a battery model, the electrochemical model is more accurate theoretically compared with the equivalent circuit model. However, due to having more model parameters that make it difficult to conduct parameter matching, the electrochemical model is complex, less practically applied, and shows low accuracy.
(5) As a commonly used voltage model for batteries, the equivalent circuit model can describe the external characteristics of batteries by using basic components (including capacitors and resistors) to make up circuits based on the principle of batteries. Hu et al. [15] compared the accuracy, complexity, and robustness of 12 commonly used equivalent circuit models, which include the combined model, Rint model, first-order RC (resistor and capacitor) model, first-order RC model considering state delay, second-and third-order RC models. The research results showed that the first-order RC model is applicable for ternary Li-ion batteries (LiNixMnyCo1-x-yO 2 ), while the first-order RC model, which considers a state delay, can satisfy the requirements of a lithium iron phosphate (LiFePO 4 ) battery. Nejad et al. [16] compared ten battery models. By taking a ternary Li-ion battery and LiFePO 4 battery as objects, the state estimation accuracies obtained by using different models were validated. The results revealed that the RC model exhibited better dynamic characteristics. For a majority of batteries, the second-order RC model is more applicable; the first-order RC model with a state delay is more suitable for LiFePO 4 batteries. Overall, the equivalent circuit model, which is simple and accurate, is applicable to the practical environment.
(6) The extended Kalman filter algorithm (EKF) is a model-based closed-loop estimation method. As it regards the battery as a power system, the KF algorithm is used to estimate SOC as an internal state of the system. SOC estimation by using the KF algorithm can be divided into two links: priori estimation on the SOC of the battery by applying the Ah integration method; comparison of the terminal voltage predicted through the model with the measured terminal voltage. The difference between the two values is used for the posterior correction of the estimated result of the SOC. According to the process noise and observation noise of the system, the weight during posterior correction is automatically adjusted, that is, the level of Kalman gain. The common KF algorithm is suitable for linear systems. Cheng et al. [17] estimated the SOC of batteries by using the Rint model and the KF algorithm, and the estimation accuracy of their result significantly increases compared with that obtained through the Ah integration method based on OCV. However, the system of batteries is nonlinear. To apply a more accurate nonlinear battery model, it is necessary to use the EKF algorithm. Plett [18,19] first proposed an estimation algorithm for the SOC based on the EKF. Afterward, SOC estimation was also conducted based on the EKF in many literatures. By taking ternary batteries and LiFePO 4 batteries as research objects, Hu et al. [20] carried out SOC estimation by employing the EKF algorithm separately based on the first-order RC model and the first-order RC model with a state delay. They tested the robustness of the algorithm under different loads, temperatures, and degrees of attenuation. In the EKF algorithm, simple linearization mode is used; that is, first-order Taylor expansion is utilized to approximate nonlinear function. The sigma-point Kalman filter (SPKF) [21] and unscented Kalman filter (UKF) [22] improve the linearization process, and therefore, show better convergence and estimation accuracy in terms of optimal estimation of a highly nonlinear model. Additionally, to increase the applicability of algorithms, the corresponding adaptive Kalman filter (AKF) algorithm was also developed [23].
On the premise of having high model accuracy, this kind of closed-loop estimation method based on the equivalent circuit model, including the KF algorithm, exhibits high estimation accuracy for the SOC. For example, according to the results of previous research [24], SOC estimation accuracy can reach 2.5% when using a Luenberger observer. Zeng et al. [25] obtained the root-mean-square error within 0.5% for the estimated result of SOC by employing the AKF algorithm. Nevertheless, it is hard to guarantee the high estimation accuracy stated in the literature when practically applying the algorithms for the SOC. This is mainly because the performance and environment of batteries, the hardware of the BMS, etc., are not in an ideal state in practical applications; for example, various factors (such as battery aging, low-temperature environment, and measurement error of sensors) all likely lead to a reduction of actual SOC estimation accuracy. At present, only a part of the literature considers these influencing factors in SOC estimation. For example, some studies consider changes in model parameters and capacity after battery aging so as to synchronously estimate the SOC of the battery and capacity/model parameters by applying combined the KF or double KFs algorithm [26]. By utilizing recursive least squares, Xia et al. [27] realized the online identification of model parameters and applied the identification results to an SOC estimation. Table 1 compares several methods that are commonly used at present. The above studies are mainly aimed at estimating the battery life of electric vehicles while research on SOC estimation of batteries for UAVs is hardly reported. In comparison, it can be seen that the closed-loop estimation method of the Kalman filter is relatively accurate and reliable, and the amount of calculation is moderate. It is the current mainstream method, but to improve the accuracy of actual SOC estimation in complex environments, it is also necessary to consider the influence of battery aging on model parameters such as capacity and internal resistance. In the study, the SOC estimation of Li-Po batteries of UAVs was conducted by utilizing an extended Kalman filter (EKF) algorithm-a closed-loop estimation method based on the equivalent circuit model.

Modeling and Parameter Identification
In this section, the power battery system was first modeled. Afterward, a hybrid pulse power characterization (HPPC) test was conducted, and parameters were identified based on the first-order RC model (equivalent circuit model). Finally, the principle of the EKF and its application in the established model were introduced.

Modeling of Battery System
According to Section 2, there are many studies on SOC estimation. The closed-loop estimation algorithm based on the equivalent circuit model with a moderate computational burden is applicable for practical application and shows advantages of accuracy and reliability, so it is a widely used method at present. According to numerous studies, in an ideal state, the closed-loop estimation algorithm based on the equivalent circuit model can reach a high estimation accuracy and can satisfy requirements of practical application. Shen [7] conducted parameter identification and verified the results based on the first-order and second-order RC models. It revealed that the estimation accuracy of the second-order RC model for voltage is slightly higher than that of the first-order RC model. However, the two models can both accurately simulate the voltage characteristics of batteries and show an insignificant difference in estimation accuracy. While taking the complexity of models into account, the first-order RC model lacks one RC parallel structure compared with the second-order RC model. Therefore, the first-order RC model is simpler and shows lower computation complexity. For consumptive flight control systems, the computing power is limited, and therefore, the first-order RC model (equivalent circuit model) was selected.
According to previous research results, for a ternary-graphite Li-ion battery, the circuit structure of the first-order RC model is shown in Figure 1.
The first-order RC model consists of an ideal voltage source (represented by OCV), an Ohmic resistor R 0 and a parallel link of a resistor R 1 and a capacitor C 1 . Where, R 1 and C 1 refer to the internal polarization resistor and polarization capacitor; the RC link is used to describe the concentration polarization and electrochemical polarization characteristics of the battery. The current going through the Ohmic resistor is recorded as I, being positive during discharge. The voltage between the two ends of the internal polarization resistor and the output terminal voltage is recorded as U 1 and U out , respectively; The time constant is τ 1 = R 1 C 1 . The formula for defining SOC and the equation for external characteristics of the first-order RC model can be expressed as follows: where η denotes Coulombic efficiency, which generally approximates to 1; C bat stands for the capacity (A·h) of the battery under standard conditions; SOC t and SOC t 0 , respectively, represent the value at the time t and t 0 .
Energies 2019, 12, x FOR PEER REVIEW 5 of 17 show an insignificant difference in estimation accuracy. While taking the complexity of models into account, the first-order RC model lacks one RC parallel structure compared with the second-order RC model. Therefore, the first-order RC model is simpler and shows lower computation complexity. For consumptive flight control systems, the computing power is limited, and therefore, the first-order RC model (equivalent circuit model) was selected. According to previous research results, for a ternary-graphite Li-ion battery, the circuit structure of the first-order RC model is shown in Figure 1.
where η denotes Coulombic efficiency, which generally approximates to 1;

HPPC Test and Parameter Identification
By using a Li-ion battery as the research object, the fundamental performance parameters of the batteries used in the test are shown in Table 2.

HPPC Test and Parameter Identification
By using a Li-ion battery as the research object, the fundamental performance parameters of the batteries used in the test are shown in Table 2.
By utilizing an improved HPPC test method, a single battery was tested [28]. To be specific, a charge or discharge pulse was applied in the interval of 5% or 10% of the SOC (In particular, all SOCs in this experiment refer to relative SOC, that is, SOC = removable charge/actual battery capacity) in the process when the SOC of battery was changed from 100% to 0%. As shown in Figure 2a, after adjusting to a SOC point and keeping the battery standing for 1 h, discharge pulse was successively applied for 30 s; after standing for 40 s, charge pulse was applied for 10 s; afterward, the battery was discharged to the next SOC point, as shown in Figure 2b. To acquire characteristics of the battery at different temperatures, the HPPC test was separately carried out at 40 • C, 25 • C, 15 • C, and 5 • C. different temperatures, the HPPC test was separately carried out at 40 °C, 25 °C, 15 °C, and 5 °C.
In the test process of the battery, the charge and discharge were conducted on a Neware BTS-5V100A [29] test bench, and the test temperature was controlled by using an experimental temperature-controlled box produced by DROIDE Instrument (Beijing) Co., Ltd. For example, Figure  3: The steps of the HPPC test are displayed in Figure 2. A charge or discharge pulse was applied to the battery at the interval of 5% or 10% of the SOC. Given a charge or discharge pulse can only trigger a small variation in the SOC, the SOC in each charge or discharge pulse can be considered as fixed. Therefore, by utilizing experimental data on voltage and current in a charge or discharge pulse, the model parameters at the corresponding SOC can be identified based on the optimal estimation method.
(1) During the HPPC test, the battery stood at each SOC point, and therefore, it was feasible to directly read the voltage after standing as the OCV of the battery. Figure 4 presents the OCV-SOC curves at different temperatures obtained based on test data. It can be seen that the OCV of the Li- In the test process of the battery, the charge and discharge were conducted on a Neware BTS-5V100A [29] test bench, and the test temperature was controlled by using an experimental temperature-controlled box produced by DROIDE Instrument (Beijing) Co., Ltd. For example, Figure 3:  The steps of the HPPC test are displayed in Figure 2. A charge or discharge pulse was applied to the battery at the interval of 5% or 10% of the SOC. Given a charge or discharge pulse can only trigger a small variation in the SOC, the SOC in each charge or discharge pulse can be considered as fixed. Therefore, by utilizing experimental data on voltage and current in a charge or discharge pulse, the model parameters at the corresponding SOC can be identified based on the optimal estimation  The steps of the HPPC test are displayed in Figure 2. A charge or discharge pulse was applied to the battery at the interval of 5% or 10% of the SOC. Given a charge or discharge pulse can only trigger a small variation in the SOC, the SOC in each charge or discharge pulse can be considered as fixed. Therefore, by utilizing experimental data on voltage and current in a charge or discharge pulse, the model parameters at the corresponding SOC can be identified based on the optimal estimation method.
(1) During the HPPC test, the battery stood at each SOC point, and therefore, it was feasible to directly read the voltage after standing as the OCV of the battery. Figure 4 presents the OCV-SOC curves at different temperatures obtained based on test data. It can be seen that the OCV of the Li-ion batteries used in the test insignificantly varied with temperature. However, it can be found that with the reduction in temperature, the corresponding voltage of the same SOC point slightly declined. It was worth noting that the HPPC test was ended owing to the capacity of battery being reduced to 5% of the SOC at 15 • C, while HPPC had ended at 10% of SOC at 5 • C.  (2) According to the change in voltages of batteries before and after applying charge and discharge pulses during the HPPC test, it was easy to calculate the direct-current (DC) internal resistance of the batteries during charge and discharge. Figure 5 shows the DC internal resistances of the batteries at different temperatures after discharge for 1 s. As shown in Figure 5, the internal resistance of the batteries significantly changed with temperature: The internal resistance of the batteries obviously rose with decreasing temperature. For the condition with a large SOC (20% < SOC < 100%), the internal resistance insignificantly changed with SOC; at low SOC (< 20%), the internal resistance of the batteries remarkably increased with reducing SOC.
(a) (2) According to the change in voltages of batteries before and after applying charge and discharge pulses during the HPPC test, it was easy to calculate the direct-current (DC) internal resistance of the batteries during charge and discharge. Figure 5 shows the DC internal resistances of the batteries at different temperatures after discharge for 1 s. As shown in Figure 5, the internal resistance of the batteries significantly changed with temperature: The internal resistance of the batteries obviously rose with decreasing temperature. For the condition with a large SOC (20% < SOC < 100%), the internal resistance insignificantly changed with SOC; at low SOC (< 20%), the internal resistance of the batteries remarkably increased with reducing SOC.  (2) According to the change in voltages of batteries before and after applying charge and discharge pulses during the HPPC test, it was easy to calculate the direct-current (DC) internal resistance of the batteries during charge and discharge. Figure 5 shows the DC internal resistances of the batteries at different temperatures after discharge for 1 s. As shown in Figure 5, the internal resistance of the batteries significantly changed with temperature: The internal resistance of the batteries obviously rose with decreasing temperature. For the condition with a large SOC (20% < SOC < 100%), the internal resistance insignificantly changed with SOC; at low SOC (< 20%), the internal resistance of the batteries remarkably increased with reducing SOC.
(a)  (3) SOC estimation was carried out by using the first-order RC model. Based on HPPC test data at different temperatures, the model parameters at different temperatures can be identified by conducting 15-order polynomial fitting, thus finally attaining the 3D Map between model parameters SOC and temperature. Figures 6 and 7 show the identification results of polarization internal resistance and capacitance, respectively.

EKF Algorithm
A dynamic nonlinear system generally can be described by using the following state space model.
where, Formulae (4) and (5) separately refer to the state and output equations of the system; k x , k u and k y denote the state vector in system at the time k , input and output vectors of system, respectively; k w represents random process noise or disturbance, which reflects some unmeasured inputs influencing the state of system, and k v stands for sensor noise, reflecting the measurement error of system output. The KF algorithm, as an optimal estimation algorithm, makes the optimal estimation on the internal state of the system in the sense of minimum variance by using the state equation according to observed input and output data of the system. The common KF algorithm is only applicable for a linear system; however, a battery belongs to a nonlinear system. Therefore, the SOC estimation was conducted by applying the EKF algorithm. Plett [18,19] made a detailed introduction and analysis very early on the EKF algorithm and its application in the estimation of the battery state. The initialization process and iterative estimating equation of the KF algorithm are displayed in Table 3.

EKF Algorithm
A dynamic nonlinear system generally can be described by using the following state space model.
where, Formulae (4) and (5) separately refer to the state and output equations of the system;x k , u k and y k denote the state vector in system at the time k, input and output vectors of system, respectively; w k represents random process noise or disturbance, which reflects some unmeasured inputs influencing the state of system, and v k stands for sensor noise, reflecting the measurement error of system output. The KF algorithm, as an optimal estimation algorithm, makes the optimal estimation on the internal state of the system in the sense of minimum variance by using the state equation according to observed input and output data of the system. The common KF algorithm is only applicable for a linear system; however, a battery belongs to a nonlinear system. Therefore, the SOC estimation was conducted by applying the EKF algorithm. Plett [18,19] made a detailed introduction and analysis very early on the EKF algorithm and its application in the estimation of the battery state. The initialization process and iterative estimating equation of the KF algorithm are displayed in Table 3.

Initialization:
Under k = 0, it is supposed that,

Iterative Calculation:
Under k = 1, 2 · · · Update of state vector:x − k = f x + k−1 , u k−1 Update of time of error covariance matrix: Updating measurement of state vector:x + k =x − k + L k y k − g x − k , u k Updating measurement of error covariance matrix: Where,Â k andĈ k separately refer to the first-order Taylor expansion coefficients of state and output equations, called coefficient matrixes; L k denotes Kalman gain, and Σ w and Σ v separately stand for covariance matrixes of input and output measurement noises w k and v k ; Σ x,k represents the covariance matrix of error of state estimation, showing the uncertainty of state estimation. For discrete KF algorithm, state vector and its covariance matrix are subjected to two updates in each iterative step. The first update of time is priori estimation based on state equation, in which the estimated results are expressed asx − k and Σ − x,k , respectively; the second update of measurement is posterior correction based on measured values and the corrected states are represented asx + k and Σ + x,k , respectively. For SOC estimation of batteries, SOC is an internal state which needs to be estimated. Generally, it is thought that current is input and terminal voltage is output of the system. Therefore, based on Equation (1) to (3), the state Equation (6) about SOC and the output Equation (7) of the system are attained, where, w k and v k denote input and output noises, respectively. where: w k is the input noise matrix, caused by the error of the model; v k is the measure noise matrix, caused by battery voltage measurement error; T is the sampling period; w k and v k are irrelevant.
According to the state space model for general systems and the calculation formula for coefficient matrix in Table 3, the state vector x k , system output y k and input u k as well as corresponding coefficient matrixesÂ k andĈ k for SOC estimation by using EKF algorithm are shown as follows: As a result, the models and corresponding equations for estimating the SOC of power-type Li batteries are established.

Experimental Verification and Discussion
According to the iterative formulae in Table 3, the state vectors, including SOC, are subjected to iterative estimation, and the estimation process is shown in Figure 8. It can be easily seen that SOC estimation using the EKF algorithm is essentially the preliminary estimation of the SOC value according to current integration, followed by a closed-loop correction of the estimated SOC taking voltage as feedback signals based on the battery model. The feedback coefficient is exactly the Kalman gain, which is automatically determined according to the optimal control theory by using the EKF algorithm. According to the aforementioned estimation algorithms for the SOC, the estimation model for SOC can be established in the MATLAB/Simulink platform. To verify the accuracy of estimation algorithms for the SOC, the tests on dynamic working conditions at four temperatures (40 °C, 25 °C, 15 °C, and 5 °C) were carried out, and SOC estimation was validated based on test data [29].
The results of offline bench testing on simulated working conditions are presented in Figure 9. According to the aforementioned estimation algorithms for the SOC, the estimation model for SOC can be established in the MATLAB/Simulink platform. To verify the accuracy of estimation algorithms for the SOC, the tests on dynamic working conditions at four temperatures (40 • C, 25 • C, 15 • C, and 5 • C) were carried out, and SOC estimation was validated based on test data [29].
The results of offline bench testing on simulated working conditions are presented in Figure 9. SOC estimation was carried out based on measured data, and the obtained estimated results are shown in Figure 10. The reference value of the SOC was calculated according to the Ah integration method. It was worth noting that the Ah integration method showed a low estimation accuracy in practical application because it was greatly influenced by errors of initial value and capacity as well as the accumulative error of current measurement. By contrast, in a laboratory environment, the accuracy of the current measurement was high; experimental equipment was BTS-5V100A of Neware. The accuracy of the current measurement was within ±0.1% [30], and Shen Ping's research on the current measurement error of equipment shows that when the relative error of the current measurement is 1%, the theoretical error of the SOC error in the EKF is below 0.2% [31]; therefore, the accuracy of the current measurement can be ignored. The initial value and capacity of the SOC were known. Therefore, the part of the error can be ignored. In this case, the SOC calculated by applying the Ah integration method was accurate, which can be used as a reference value. According to the aforementioned estimation algorithms for the SOC, the estimation model for SOC can be established in the MATLAB/Simulink platform. To verify the accuracy of estimation algorithms for the SOC, the tests on dynamic working conditions at four temperatures (40 °C, 25 °C, 15 °C, and 5 °C) were carried out, and SOC estimation was validated based on test data [29].
The results of offline bench testing on simulated working conditions are presented in Figure 9. SOC estimation was carried out based on measured data, and the obtained estimated results are shown in Figure 10. The reference value of the SOC was calculated according to the Ah integration method. It was worth noting that the Ah integration method showed a low estimation accuracy in practical application because it was greatly influenced by errors of initial value and capacity as well as the accumulative error of current measurement. By contrast, in a laboratory environment, the accuracy of the current measurement was high; experimental equipment was BTS-5V100A of Neware. The accuracy of the current measurement was within ±0.1% [30], and Shen Ping's research on the current measurement error of equipment shows that when the relative error of the current measurement is 1%, the theoretical error of the SOC error in the EKF is below 0.2% [31]; therefore, the accuracy of the current measurement can be ignored. The initial value and capacity of the SOC were known. Therefore, the part of the error can be ignored. In this case, the SOC calculated by applying the Ah integration method was accurate, which can be used as a reference value. The SOC errors during the offline bench testing on practical working conditions are shown in Figure 11.  The SOC errors during the offline bench testing on practical working conditions are shown in Figure 11.
The SOC errors during the offline bench testing on practical working conditions are shown in Figure 11. Figure 11. SOC estimation errors. Figure 11. SOC estimation errors.
According to the verification results on practical and simulated working conditions, it can be seen that the maximum SOC estimation errors during high-temperature tests at 40 • C, 25 • C, 15 • C, and 5 • C were 0.215%, 0.8627%, 1.5712%, and 2.807%, respectively.
Through analysis, it can be seen that at high ambient temperatures and room temperature, the capacities and model parameters obtained by using various estimation algorithms for the SOC were all accurate on the condition that batteries were not aged. Therefore, there was a high estimation accuracy of the SOC, with the error within 1%. At a low temperature, the batteries were significantly polarized so that the accuracy of the battery model was low. Therefore, the estimation accuracy for SOC slightly decreased, with a maximum error of about 2.8%.

Conclusions
At present, research on SOC estimation of power-type Li batteries, the power source of small-sized UAVs, is hardly reported. In the current study, the currently widely used methods for SOC estimation of Li batteries for vehicles were explored and compared to analyze their advantages and disadvantages. Afterward, by using the EKF algorithm, a closed-loop estimation method based on the equivalent circuit model, the SOC of power-type Li batteries was estimated.
By conducting offline bench testing at different temperatures and different working conditions, it was found that at high ambient pressures or room temperatures, the capacities and model parameters obtained by using estimation algorithms for the SOC based on the EKF were all accurate on the condition that batteries were not aged. Therefore, the estimation accuracy of the SOC was high, with the error below 1%. At a low temperature, batteries were subjected to significant polarization, so that the battery model exhibited low accuracy. Thus, the estimation accuracy of the SOC slightly reduced, with the maximum error of about 2.8%. EKF can still estimate the SOC of batteries relatively accurately. Therefore, EKF can be practically applied to estimate the SOC of power-type Li batteries of small-sized UAVs, thus improving the battery life of UAVs.
However, compared with offline bench experiments, the application of SOC estimation practically with EKF is difficult and it is not possible to guarantee high estimation accuracy due to battery aging, a wide range in temperature, initial value uncertainty, and inaccurate voltage and current measurement. Therefore, subsequent work should focus on analyzing the possible sources of error and the exact impacts on the SOC estimate to minimize errors.
Author Contributions: H.Z. independently completed theoretical calculations, system design, and experimental verification. H.Z. carried out the research and analyzed the numerical data with guidance from M.Z. and X.L. H.Z. prepared the manuscript.