1. Introduction
The burgeoning proliferation of portable electronic devices, ranging from smartphones to electric vehicles, especially in the process of industrial production operations and when users use industrial products, means that efficient energy technology is particularly important, underscoring the indispensability of batteries as a primary power source [
1]. As such, the state-of-charge (SOC) estimation assumes paramount importance in ensuring efficient and optimal utilization of battery resources [
1,
2]. While conventional SOC estimation methods, such as the discharge test method and open circuit voltage method, have served as stalwarts in the field, emerging methodologies, including the least squares method, Kalman filtering method, and neural network method, present promising avenues for enhanced accuracy and versatility [
3]. The estimation method is related to various mathematical models and physical models. This project studies batteries in real life from a more professional and deeper perspective. There are all kinds of portable (non-wire connected) electronic devices in our life, with small power electronic devices that include all kinds of electric toys, smart phones, portable computers, etc., and large power devices that include all kinds of batteries used in electric vehicles and aerospace equipment [
4,
5]. These devices all need a large number of batteries as their power supply for mechanical movement or operation calculation. It can be seen that battery is an indispensable and important energy supply device in real life, and a relatively complete battery management system (BMS) has also been derived, which provides a good environment for the human management, control, and upgrading of batteries [
6].
At present, most SOC estimation methods in the world are based on the discharge test method, open circuit voltage method, and ampere hour integration method, which are more traditional methods and have a relatively fixed range of use [
7]. However, relatively new methods include the least squares method, Kalman filtering method, neural network method, etc. [
8]. The purpose of these algorithms is to develop a model that can describe the behavior of lithium batteries based on one or more algorithms in order to meet the requirements of BMS management [
9]. The OCV method can estimate the SOC value by measuring the open-circuit voltage of the battery [
10]. Since this method requires a long time to obtain a stable OCV value, it is not suitable for SOC estimation in cases where the battery current changes drastically. The Ah integral method is currently the most commonly used for EVs, and it estimates the SOC by the integration of the load current against time [
11]. The drawback is that it cannot automatically determine the initial value of SOC and has a large cumulative error [
11].
This paper proposed the self-adaptive parameter system for the modified EKF method. Firstly, the voltage estimation error caused by the EKF method when performing SOC estimation decreased through the modified EKF method. We established an accurate battery model and improved the accuracy of battery voltage estimation without affecting the battery SOC estimation. Specifically, the Kalman gain and noise were focused on and studied in the estimation of the battery voltage. By designing the Kalman gain formula and voltage estimation formula at the points where the current changes, the error of the estimated voltage can be effectively reduced. The self-adaptive parameter system based on the modified EKF method was tested under the working current, and the errors of the SOC and voltage were both reduced. This means that in the production estimation direction related to batteries, our proposed improved EKF method for estimating batteries can effectively achieve real-time monitoring and accurate estimation of batteries, providing an effective solution for BMS to monitor battery SOC.
2. Materials and Methods
2.1. Experimental Materials
The battery itself is a closed and complex chemical system, especially lithium-ion batteries [
12,
13]. Its working principle is different from ordinary dry batteries, and its basic components include the positive and negative electrode materials, the electrolyte, and the separator [
14]. The positive and negative electrode materials can ensure the reversible insertion and removal of lithium ions in it, achieving the purpose of storing and releasing energy [
15]. The separator is used to form a channel for the movement of lithium ions, and the electrolyte ensures the movement of lithium ions [
16,
17,
18]. By ensuring that electrons can move in one direction externally to form a stable current, power can be supplied to the device [
19].
The materials we prepared during the experiment included (1) a lithium polymer battery (model: 103565, Guangzhou Shengyuan Technology Co., Guangzhou, China); (2) a battery charge and discharge tester (GeLingDe Co., Foshan, China); and (3) the BTS 8.0 software. This set of experimental equipment is often used to measure the parameters of lithium batteries in small electrical appliances and is widely applicable for measuring batteries in underwater robots, drones, and small, self-programming robots.
2.2. Overall Experimental Methods
Due to the discharge characteristics of lithium batteries [
20], we can divide the entire discharge experiment process of lithium batteries into the following three steps.
In the initial stage, the terminal voltage of the battery drops rapidly, and the larger the discharge rate, the faster the voltage drops. Then, the battery voltage enters a stage of slow change, which is called the platform area of the battery. The lower the discharge rate, the longer the platform area lasts; the higher the platform voltage, the slower the voltage drop. When the battery is nearly discharged, the battery load voltage starts to drop sharply until it reaches the discharge cutoff voltage.
Here, the constant current discharge method was adopted because it can obtain the HPPC curve for the subsequent calculation. During discharge testing, the device applied a certain load to the battery and recorded the evolution of voltage over time and the current over time, based on the set data recording conditions.
2.2.1. Experimental Model
In the equivalent circuit of a battery cell, the circuit typically consists of a voltage source, a series resistor, and one or more parallel resistor capacitor pairs. The voltage source provides open circuit voltage, while other components simulate the internal resistance and time-dependent behavior of the battery. Here, we considered the efficiency and computational burden of the algorithm, so we adopted a second-order RC equivalent circuit model.
Figure 1 shows the schematic diagram of the second-order RC circuit model, which is characterized by its physical model containing two sets of parallel capacitors and resistors. At the same time, it included the open circuit voltage and the internal resistance R
0 of the battery. The main reasons for this are as follows.
When dealing with complex power devices such as lithium battery packs, we usually break them down into small battery cells or cells, which can significantly reduce computational complexity and avoid the accumulation of errors caused by the mutual influence between battery cells. The higher the order, the higher the complexity of the calculation, which is not conducive to the online estimation of SOC. At the same time, it is also possible to fit too much noise data, resulting in over fitting. It is much more accurate than the first-order model but not much different from the third-order model.
2.2.2. Offline Parameter Identification
In order to gain a deeper understanding of the characteristics of resistance and capacitance in the equivalent circuit model in
Figure 1, we used a typical pulse current discharge mode to analyze the voltage response curve of the pulse current discharge.
Figure 2 shows a partially enlarged image of the pulse current discharge experiment. The diagram is divided into four stages from the discharge state to the static state.
Phase AB: When the battery changes from a stationary state to a discharging state, the voltage value drops sharply. Phase BC: As the battery continues to load current pulses, the capacitors gradually charge. Due to the presence of their respective resistances, the voltage exponentially decreases slowly, resulting in a zero-state response. Phase CD: The battery experiences a sharp increase in voltage when the current pulse is removed. Phase DE: When the battery loses its pulse and slowly recovers, the capacitors will produce a slow discharge effect through their respective resistors, causing the voltage to slowly rise. This state is the zero-input state. The AB and CD phases are based on a second-order equivalent circuit, and the terminal voltage of the capacitor will not suddenly change.
The overall experimental process can be divided into the following steps: (1) Determining the physical model of the battery corresponding to the experiment: this step is crucial, as it will directly affect the number of parameters and results in the subsequent parameter identification; (2) offline parameter identification: it is mainly carried out by centrally processing the data to obtain the estimated model parameters and then inputting them into the online parameter identification algorithm. The relationship between SOC and OCV is identified during the estimation of battery capacity in real-time; (3) online parameter identification: the principle of online parameter identification is to use the recursive real-time updating of model parameters during system operation using EKF; (4) this step compares the estimated data with the original data and analyzes the robustness, convergence, and accuracy of EKF in the production estimation process.
Based on this characteristic, we can use calculations and fitting to obtain the parameters we need:
At point B, the battery begins to load the current for a short period of time, so we consider point B as the time t = 0. At this point, we can use Formulas (1), (3), and (4) to obtain a new formula:
Finally, using the fitting formula in Matlab R2021a, we can obtain the parameters
,
,
,
, and
using the recursive least square method [
9] or other methods. By importing experimental data into Cftool in Matlab and selecting an appropriate fitting function, we can approximate the previously obtained data into a continuous function curve. By comparing this curve with the standard HPPC curve, we can see that it conforms to a certain segment of “zero correspondence”.
In the actual operation, we only need to perform the following steps to achieve the above parameter identification: (1) selecting the zero-response state or zero-input state in the pulse curve; (2) realizing the fitting of experimental data through Cftool in MATLAB; and (3) obtaining the parameter identification results of resistance and capacitance in the lithium battery.
Finally, the main parameters are obtained, including open circuit voltage, resistance, and capacitance.
2.2.3. Online Parameter Identification
Our idea is that the initial SOC value is calculated using the open-circuit voltage method, and we hope to achieve the optimal estimation and approximate the true value through a period of iteration under the special algorithm.
The relationship between the variables of the classical Kalman filter algorithm is linear, so the classical Kalman filter algorithm is only applicable to the state estimation of linear systems. Lithium batteries are a complex system, and the relationship between their parameters is not a simple linear relationship. Therefore, SOC estimation requires the use of a derivative algorithm of the Kalman filtering algorithm. The basic idea of the EKF algorithm is to linearize the equation through Taylor expansion.
Scheme 1 represents the process of reproducing EKF in MATLAB. It strictly followed the following process [
3]: (1) preparing the experimental equipment; (2) initializing the experimental data; (3) importing the existing data; and (4) using the extended Kalman algorithm to process the data for accurate estimation.
Overall, based on the voltage difference and filtering gain, the extended Kalman filtering method was used to correct the Kalman filtering gain. At the same time, the initial value of SOC (t1) was used to obtain the corrected value of SOC at time t2, represented by SOC (t2). At the next moment, the corrected SOC value SOC (t2) was used as the initial value to calculate the SOC and input it, and then the extended Kalman filter method was used to correct it so as to continuously cycle it. To put it another way, it meant the Kalman filtering algorithm of this algorithm followed the order of “prediction correction prediction”.
5. Conclusions
This article focuses on lithium batteries and establishes a second-order RC model that includes internal resistance in the estimation model using EKF. Meanwhile, EKF was used to estimate SOC values. A second-order RC model with high accuracy was obtained through the offline parameter identification method. At the same time, under HPPC conditions, the EKF algorithm was used in conjunction with existing equivalent circuit models to estimate the battery SOC. In particular, the noise variance caused by current and voltage accuracy issues was analyzed, and the maximum error was only 7.7779%, which demonstrates better stability in estimation accuracy [
5,
9]. Moreover, better estimation results were obtained by adjusting the relevant noise matrix. This indicates that the extended Kalman filtering algorithm can be used to solve the problem of the real-time performance of algorithms, such as the open voltage method and the low accuracy of the ammeter integration method. The EKF algorithm has high accuracy, good convergence, and robustness when used for SOC estimation. It was also explicitly stated in other literature that the algorithm has a strong adaptability and low computational complexity. Through constant correction, the algorithm has a good convergence and a good suppression of Gaussian white noise.
This research achievement largely interprets some of the ideas in the Industry 4.0 process [
20,
21], using models and simulations to create transparency in product architecture for engineers, and can explain and describe existing systems. Estimating from the production end to the user end can enable products to achieve end-to-end matching in the overall architecture of Industry 4.0. This industrial estimation is no longer limited to estimating the economic value of the product but is more representative of the product’s own value. It can reflect the excellent performance of the product at a deeper level.
Returning to the value of research, the estimation of battery SOC is of great significance for battery management, as it is an important part of the development of new energy and an indispensable part of various industrial industries. Mobile phones, laptops, and intelligent robots are all inseparable from lithium-ion batteries at present. Whether it is a small capacity battery or a large storage battery, estimating their SOC is very important because this method allows us to know the charge state of the battery in real-time, without the needs for measurement instruments. In both the Kalman filtering algorithm and the neural network algorithm, we can estimate the next state of the battery based on the observed state at the current stage and improve its estimation accuracy through correction. Because of this advantage, there will be more and more Kalman algorithms in the future, and their types will also become more and more diverse. Due to its excellent performance in BMS, extended Kalman filtering algorithms, double-extended Kalman filtering algorithms, and adaptive extended Kalman algorithms are emerging.
Industry 4.0 emphasizes decision-making by data-driven and intelligent manufacturing. In the future, this also means that production estimation will increasingly rely on big data analysis and machine learning algorithms. In this study, we optimized the production process in Industry 4.0 using EKF. The future development strategy aims to incorporate production estimation controlled by digital twin technology to enhance efficiency, accuracy, and adaptability in manufacturing processes. Digital twin technology, which creates a virtual replica of physical assets, processes, and systems, will play a pivotal role in revolutionizing production estimation and management [
22] in Industry 4.0, based on this initial concept. This technology allows for the continuous monitoring of equipment performance, identifying potential issues before they cause disruptions and providing insights for proactive maintenance. The real-time feedback loop between the physical and digital counterparts will ensure that production estimation is always based on the most current and accurate data, reducing downtime and improving overall productivity.
Furthermore, digital twin technology will facilitate advanced analytics and machine learning applications, enabling predictive modeling and decision-making processes that adapt to changing conditions. This adaptive capability will enhance our ability to respond to market demands swiftly and efficiently, ensuring that production schedules and resource allocations are optimized for maximum output and minimal waste. Implementing this strategy involves several key steps.
(1) The first step is the monitoring of production equipment. One idea of digital twin technology is to “monitor the status of production equipment in real-time during production, predict potential faults and maintenance needs, reduce downtime and maintenance costs.” For industrial production in highly complex environments, it is difficult for a single sensor and traditional physical monitoring methods to monitor the status of the entire equipment in real-time, accurately and comprehensively. In the future, combining EKF, UKF, PF, and other algorithms with deep learning models can achieve data fusion [
23] between multiple sensors and improve data reliability and real-time performance. (2) The second step is to dynamically optimize the production process. Through the digital twin model, the implementer can simulate different production strategies, evaluate their effectiveness, and find the optimal production plan. The production process can be estimated and dynamically adjusted based on real-time data to optimize the production process. (3) The final step is the virtual simulation of products. In the process of developing new products, we hope to use real-time production data and user feedback historical data to achieve virtual simulation, test product performance and reliability, and reduce the development cost of physical prototypes through estimation and simulation.