1. Introduction
Owing to their high energy density, long cycle life, and non-polluting advantages, lithium-ion batteries are widely used in energy storage stations [
1]. Through series and parallel connections, a lithium battery can be formed into a battery pack and achieve the required capacity and voltage, meeting the requirements of actual application scenarios [
2,
3]. The processes and materials used in the production of battery cells make it impossible for them to be completely consistent from the start. As lithium-ion batteries are used over time, this inconsistency will cause increasingly significant differences in capacity and voltage among battery cells, leading some battery cells to reach the end of their lives prematurely. This triggers an overall capacity loss, shortens the overall lifespan of the battery pack, and even leads to overheating, thermal runaway, and other accidents [
4], affecting the performance and safety of the battery pack. Furthermore, the voltage data of battery cells in a battery pack generally consist of valid measurement data and measurement errors. The presence of measurement errors is a normal phenomenon in experiments, mainly due to the sensor drift and random noise in the sensor output data, obscuring the actual measurement data. However, when measurement errors are large and deviate from normal measurement data, they are considered abnormal voltage data. Such abnormal voltage data occur because the battery has experienced over-charging, over-discharging, imbalance, thermal runaway, and other faults [
5,
6], causing voltage changes abnormally. Consistency anomaly detection of the battery voltage can help to achieve early warning of battery faults and avoid safety accidents in energy storage stations.
A large number of scholars have conducted research on the detection of abnormal voltage in battery cells, mainly including data-driven approaches and statistical analysis approaches [
7]. Data-driven approaches can select machine learning models based on the characteristics of the dataset and then use the model to obtain the historical regression of the voltage time series, identifying batteries that exhibit abnormal external signal characteristics under the same operating conditions [
8]. Data-driven approaches usually include Local Outlier Factor (LOF) algorithms [
9], K-means algorithms [
10], neural network algorithms [
11], Gaussian Process Regression (GPR) [
12], etc. Since the K-means clustering algorithm is less efficient when dealing with large amounts of data, reference [
13] proposes a fault identification method for inconsistent voltage in battery cells based on K-means++ clustering with dynamic
k-values, which can identify abnormal cells up to 6 days earlier. Reference [
14] uses the BP neural network and 3σ-MSS strategy to detect and calculate the abnormal changes in battery voltages within the battery pack and then verifies the calculation results using the LOF algorithm and clustering algorithms. Based on the EV data collected by NMMP-NEV, reference [
15] proposes an improved GPR-based method for recognizing abnormal charging capacities and uses a Box-Cox transform with the value of 3σ to determine the threshold. However, some data-driven approaches compare detected parameters with preset thresholds, which may lead to errors or misjudgments. Others require a large amount of training data, and the calculation cost of manually preprocessing and training data is high. Moreover, the data quality, which is affected by various factors, can also affect the calculation accuracy and robustness of data-driven models.
Statistical analysis approaches estimate the probability distribution of data, identifying values with low probability density as outliers [
16,
17]. Common approaches include the 3σ criterion, boxplots, information entropy, and measures describing data variability such as the mean squared error, standard deviation, coefficient of variation, and interquartile range. Reference [
18] uses the mean squared error (MSE) between the experimental voltage and the simulated voltage from a first-order RC equivalent circuit model to describe the characteristics of battery voltages, determining whether there are voltage anomalies, and uses an improved Z-score method to quantitatively evaluate voltage faults. Reference [
19] proposes a voltage abnormal detection method for electric vehicle batteries based on modified Shannon entropy and standard deviation, which can predict the exact times and locations of faulty batteries in battery packs ahead of time. Reference [
20] uses the modified Shannon entropy to describe the voltage evolution of each battery, diagnoses faulty batteries by observing and analyzing the entropy values of individual batteries, and then evaluates the degree and level of failure through the Z-score and anomaly coefficient. Reference [
21] proposes a hybrid fault diagnosis method that combines Multiscale Permutation Entropy (MPE) and the Coefficient of Variation (CV), using the 3σ principle as the threshold for battery failure. Statistical analysis approaches are suitable for univariate datasets, enabling the rapid and effective identification of outliers while also representing the informational characteristics contained in the data. However, interpreting outliers detected by these methods can be challenging, and data distributions, probability models, and parameters are hard to determine, constraining their use. Moreover, as the data dimensions and volumes increase, the efficiency of these anomaly detection approaches decreases.
Robust Principal Component Analysis (RPCA) [
22] is an unsupervised feature machine learning method that can effectively extract the main information from the observed data with sparse noise and severe outliers, successfully denoising the observed data. Conducting the RPCA using the Alternating Direction Method of Multipliers (ADMM) can ensure calculation accuracy while achieving a faster computational speed [
23].
In summary, to solve the problem of data quality affecting the accuracy of anomaly detection in battery cells, this article proposes a method for data denoising and anomaly detection in series-connected battery cells based on historical operation and maintenance data from a large domestic energy storage station. This method combines RPCA with mathematical statistical methods to achieve screening, identification, and consistency assessments of abnormal battery cells. Firstly, the RPCA is used for the extreme denoising of the voltage observation data, obtaining a baseline charging state curve for a battery cell consistency assessment, which also resolves the problem of the sensor output data being affected by random noise. To further detect and identify abnormal battery cells, the RPCA is used to extract outlier components. Based on the Average Deviation-3σ principle and utilizing Gaussian distribution probability characteristics, battery cells are conducted to screen and the serial numbers of the anomaly cells can be obtained. Finally, by replacing the calculation of the average deviation with variance, range, Euclidean distance, and signal energy, the effectiveness and accuracy of this anomaly detection method for battery cells are compared and verified. Therefore, this article is organized as follows:
Section 2 introduces the source and describes the preprocessing of the data.
Section 3 describes the process of the anomaly detection method for battery cells.
Section 4 provides the experimental analysis and verifications of the proposed method. Finally,
Section 5 presents the conclusion.
2. Source and Preprocessing of Data
The data in this article are derived from historical operation and maintenance data of a certain energy storage station, which consists of seven battery packs connected in parallel, as shown in
Figure 1.
Cell monitoring technology is one of the core functions of a Battery Management System (BMS) that is used to collect the voltage and temperature of a battery cell as well as detect the current of the battery pack. These data are collected using sensors and stored in Log Files, which facilitate extraction when conducting a data analysis. A Power Conversion System (PCS) is used to control the charging and discharging process of battery cells/battery packs, performing AC/DC conversion.
The subject of this experiment is a large-scale lithium battery pack within the station, consisting of 238 series-connected battery cells.
Table 1 lists the battery specifications.
Voltage and current changes are monitored through voltage and current sensors with a sampling frequency of 10 s. The voltage and current of this battery pack on 30 June 2023 are as follows.
The data are conducted to segment using the point at which a drop in current during the charging end leads to a change in the working conditions and an increase in the battery capacity as the threshold, and then a segment of charging data for battery cells (the red areas shown in
Figure 2) is extracted, as shown in
Figure 3. Due to the large number of battery cells, their labels are not displayed.
Based on this set of data, the anomaly detection method for battery cells is introduced in
Section 3.
3. Anomaly Detection Process for Battery Cells
Based on the results of data preprocessing in
Section 2, the anomaly detection process of battery cells is shown in
Figure 4. Initially, the RPCA technique is employed for data processing, followed by the application of the Average Deviation-3σ principle to filter out anomalous battery cells and output their serial numbers. Subsequently, a consistency assessment is conducted on them.
3.1. The Principle of RPCA
RPCA decomposes the observation data matrix
D into a low-rank matrix
A and a sparse matrix
E, as shown in
Figure 5. Here, the low-rank matrix
A retains the main components of the data, while the sparse matrix
E contains random noise in the observed data. Using RPCA can identify the most essential elements and structures within the data effectively, simplifying the original data. The principle is shown below.
The decomposition problem of an observed data matrix can be modeled as the following convex optimization problem.
Here, .
Equation (1) is solved by using the ADMM, and an augmented Lagrangian function is constructed.
Here,
is the Lagrange multiplier. When
and
, the alternating method is used to solve the block optimization problem:
For
k = 1, 2, 3, …, the ADMM iteratively updates
A and
E until convergence is achieved.
Here, is the singular value threshold operator, and is the soft threshold operator.
is specifically designed to handle the low-rank approximation problems of matrices, which is implemented through Singular Value Decomposition (SVD), as shown in Equation (6).
Here, , , , U, and V are orthogonal matrices, while Σ is a diagonal matrix. Here, Σ is the singular value matrix with min (m, n) singular values.
, as a nonlinear operation, processes each element in a vector or matrix by setting a threshold. It sets elements with an absolute value less than the threshold to zero, and it shrinks elements with an absolute value greater than the threshold towards the origin.
The updated matrix
Y is given by Equation (7).
The updated parameter
is given by Equation (8).
Here, > 1, which is a constant, and > 0, which is a small positive number.
The characteristics of series-connected battery cells should be consistent, and the rows of the voltage data matrix composed of battery cells should have strong similarities; therefore, the data matrix should have a low rank. In an ideal state, the rank of this data matrix should be 1. However, abnormal voltages caused by inconsistency among battery cells and random noise destroy this low-rank property. Therefore, to restore the low-rank structure of the battery cell voltage data, the RPCA is used to denoise and extract the anomaly components.
3.2. Consistency Assessment for Battery Cells
In the singular value matrix Σ obtained through the RPCA, the size of the singular values reflects the weight of every component in the data matrix D. The larger the singular values are, the more corresponding components contribute when reconstructing the original data. Usually, the first singular value is the largest. Moreover, the ranking of the singular values also determines the nuclear norm of the low-rank matrix (the sum of the singular values), which is used in optimization problems to measure low rankness.
The first singular value
in the singular value matrix
Σ represents the most significant component in the data matrix
D. Only
is retained, and all other singular values are set to 0, as shown in Equation (9).
Then, the original data matrix is reconstructed through Equation (10), and the matrix
can be obtained. At this point, the rank of matrix
is 1, which is equivalent to extreme denoising on the original data matrix.
Here, .
Taking the average curve of 238 battery cell charging curves obtained through extreme denoising using RPCA assesses the consistency of the charging state of battery cells. A battery cell is considered normal when its charging curve remains approximately parallel to the average curve, whereas a battery cell is considered abnormal when its charging curve has a clear deviation from the average curve.
Next, a method of screening and identifying abnormal battery cells will be introduced by setting the threshold value of the charging voltage for battery cells.
3.3. Sceening and Identification
By only retaining
in matrix
Σ, a reconstructed matrix
that contains the most significant information can be obtained. The low-rank matrix derived from the RPCA decomposes matrix
, separating all noise and outliers. Normal measurement errors within the data, collected by sensors when suffering from random noise pollution, are assigned lower weights and rankings in matrix
Σ. In order to eliminate the impact of sensor measurement errors and obtain as much abnormal components as possible in the data matrix composed of battery cell voltages, the singular values
in
Σ are retained while setting the others to 0, resulting in a new singular value matrix
, as shown in Equation (11).
The reconstructed matrix
is given by Equation (12).
Then, the RPCA is used to decompose the matrix
into a low-rank matrix
and a sparse matrix
, as shown in Equation (13).
Here, contains outliers and a small amount of noise in the matrix A.
The average deviation is the average of the absolute values of the deviations of each item from their arithmetic mean in a series. When the sample is a set of curves, the fluctuation of a curve can be evaluated by calculating the average distance of each point between the curve and their average curve. The average deviation is commonly represented as
A.D., given by Equation (14).
Here, X represents the sample points on the curve, represents the points on the average curve, and n is the number of sample points.
The differences among cell voltages are caused by two reasons: systematic reasons and random errors. If the cell voltages are only influenced by random errors, the statistical distribution should obey the Gaussian distribution. Therefore, the average deviation of battery cell voltages in matrix
can be considered as the Gaussian distribution, as shown in Equation (15).
Here, i = 1, 2, 3, …, represents the i-th battery cell, is the mean, and is the variance.
Then, the 3
principle is used as the threshold to screen abnormal battery cells, as shown in Equation (16).
When A.D.i is within the 3 range, the battery cell is considered normal; when A.D.i is outside the 3 range, the battery cell is considered abnormal. Finally, on the basis of the threshold, the serial numbers of the abnormal battery cells can be identified.