Fault Detection, Diagnosis, and Isolation Strategy in Li-Ion Battery Management Systems of HEVs Using 1-D Wavelet Signal Analysis

Nowadays, the wavelet transformation and the 1-D wavelet technique provide valuable tools for signal processing, design, and analysis, in a wide range of control systems industrial applications, audio image and video compression, signal denoising, interpolation, image zooming, texture analysis, time-scale features extraction, multimedia, electrocardiogram signals analysis, and financial prediction. Based on this awareness of the vast applicability of 1-D wavelet in signal processing applications as a feature extraction tool, this paper aims to take advantage of its ability to extract different patterns from signal data sets collected from healthy and faulty input-output signals. It is beneficial for developing various techniques, such as coding, signal processing (denoising, filtering, reconstruction), prediction, diagnosis, detection and isolation of defects. The proposed case study intends to extend the applicability of these techniques to detect the failures that occur in the battery management control system, such as sensor failures to measure the current, voltage and temperature inside an HEV rechargeable battery, as an alternative to Kalman filtering estimation techniques. The MATLAB simulation results conducted on a MATLAB R2020a software platform demonstrate the effectiveness of the proposed scheme in terms of detection accuracy, computation time, and robustness against measurement uncertainty.


Introduction
The most viable way to achieve clean and efficient transport is to boost the automotive industry to be concerned with developing advanced battery technologies, especially lithium-ion (Li-ion), to increase the number of electric and hybrid electric vehicles (EVs/HEVs) to dominate the vehicle market. An essential internal parameter of the Li-ion battery is the state of charge (SOC), defined as the available capacity of the cell that changes according to the current profile of the driving cycle. Due to its crucial role in keeping the battery safe for various operating conditions and significantly extending battery life, SOC is a topic of great interest, as evidenced by an impressive number of research papers published in the literature. In the absence of a measurement sensor, the SOC must be estimated since its calculated value is not accurate enough. The most used model-based Kalman filters can estimate the battery SOC with a high grade of accuracy [1][2][3][4]. The Li-ion battery is an important component integrated into battery management system (BMS) that performs tasks regarding the safe operation and reliability of the battery, protecting battery cells and battery systems against damage, as well as battery efficiency and service life [2][3][4]. The BMS "plays a significant role in fault diagnosis because it houses all diagnostic subsystems and algorithms" [2,3]; thus it monitors the battery system through sensors and state estimation, such that to detect any abnormalities during the battery system operation" [2,5]. A signal processing-based method using wavelet transforms proved to be a viable alternative to conventional Kalman filter state estimators, for designing and implementation of real-time FDI strategies. The new FDI approach avoids battery modeling difficulties and is more straightforward with better dynamic performance [7]. The drawback of this method is the difficulty experienced in dealing with the early faults and fault isolation. Its application also requires a large amount of calculations compared to the model-based methods. An intelligent fault detection scheme for microgrid based on wavelet transform and deep neural networks is used in [6] to "provide fast fault type, phase, and location information for microgrid protection and service recovery" [6]. Similar, a waveletbased transient fault detection and analysis is used successfully in [7] for a microgrid connected power. In this research, our motivation of using 1-D wavelet analysis comes from the preliminary results obtained for similar investigations on the impact of nonlinearities and uncertainties of actuators (electro-pneumatic valves), such as hysteresis, dead zone, dead band, on a healthy pH neutralization plant [8]. An example of multisignal 1-D wavelet analysis is found in [9], and a useful tutorial of using wavelet transforms presented in [10]. In [11] is shown a generic Simscape model of Li-ion Cobalt battery model used to build a SOC AEKF estimator robust to three different driving cycles profile tests, such as UDDS, EPA-UDDS and FTP-75, the last one also used in the case study of this research. For FDI techniques based on 1-D wavelet analysis are used specific MATLAB commands provided by MATLAB Wavelet Toolbox [12]. A strong theoretical background on wavelet transform and their applications is provided by the fundamental work [13]. In [14] is presented an interesting fault isolation technique based on wavelet transform, and a detailed data-based FDI techniques for a nonlinear ship propulsion system are developed in [15]. Several multimedia applications of wavelet transform can be found in [16], and a better understanding of wavelet transform analysis, design and implementation of features extraction methods, for filtering, denoising, decomposition and reconstructing signals is given in [17][18][19][20][21][22][23]. From our most recent preliminary results in Li-ion battery field, modeling and SOC estimators disseminated in [11,24,25], an interesting state-of-art analysis of similar SOC AEKF estimators performance reported in the literature is done in terms of statistical performance criteria values, such as root mean square error (RMSE), mean square error (MSE), mean absolute error (MAE), standard deviation (std), mean absolute percentage error (MAPE) and R2 (R-squared). Among three SOC Li-ion battery estimators AEKF, adaptive unscented Kalman filter (AUKF) and particle filter SOC estimators the AEKF proved that is the most suitable for HEVs applications.
Let why is used the AEKF SOC estimator of Li-ion battery in the first part of our research for FDI control strategies, excelling by its simplicity, SOC accuracy, realtime implementation capability and robustness. The robustness is tested for four different scenarios, such as to changes in SOC initial values (guess values), from 70-40%, 20%, 90% and 100%, to FTP-75 driving cycle profile test, changes in measurement level noise (from 0.001 to 0.01), to changes in the battery capacity value from 6 Ah to 4.8 Ah due to aging effects, and changes in internal resistance due to temperature effects, and also for simultaneous changes [11,23]. Based on a rigorous performance analysis of SOC residuals error compared to the similar results reported in the literature with a typically 2% error, in some situations the AEKF estimator SOC residual error reached values smaller than 1%, such as shown in [25]. Since of the lack of data in the literature field for similar situations developed in our research for Li-ion battery, it is not easy to make a state-of-art analysis of the results reported in the literature related to the FDI techniques design and implementation based on 1-D wavelet analysis. The efficiency of 1-D analysis is proved in this paper based on extensive MATLAB simulations to extract the features of input-output signals such as the energy, skewness, kurtosis, and to compute the MSE statistical criteria performance. Finally, the MATLAB simulation results can provide useful information on detection accuracy, computation time, and robustness against measurement uncertainty, thus showing simply the effectiveness of the FDI proposed scheme. The temperature fault is detected without doubt inside the Li-ion battery based on the significant values reached by the details (D1, D2, and D3) and analysis coefficient (A3) of the output terminal battery voltage residual level three decomposition, represented by the following sets of values (4.46, 2.7, 5.349, 87.5) for energy feature, (0.063, À3.92, 13, À1.33) for skewness signal feature, respectively (5.8, 71.4, 389.13, 56) for kurtosis signal feature. Also, the statistic RMSE performance criterion indicates significant values for D1 coefficient in the presence of the of temperature fault for energy feature (4.4654) and skewness and kurtosis features are the same as for current fault. To detect both faults, a multiresolution analysis (MRA) is performed, capable of extracting a smooth trend term, which provides a valuable information to localize transient changes in the fault injection window [500, 1500] seconds [23].
Thus, the presence of the bias current fault and bias temperature fault is detected and localized as a transient significant change in the nonstationary Li-ion output voltage residual signal. For an appropriate choice of the thresholds' values, both faults can be detected with a high accuracy detection times directly from S8 graph; thus, the presence of the false alarms is completely removed compared to Kalman filter FDI estimation techniques. The fault signature and considering the variation trend in SOC residual and internal resistance of the battery also provides a piece of useful information for fault isolation.
acceptable range of performance. The reason for using these models is their simplicity, low number of parameters to adjust and easy implementation in a friendly MATLAB simulation environment. Therefore, a compromise we need to make between the accuracy of the battery SOC and the complexity of the model related to the choice of Li-ion battery, so that, for simulation purpose and "proof concept", we adopt a simple Rint ECM Li-ion battery model, as a reasonably simplified version of RC ECM developed in [1], and in [11] for a Li-ion Cobalt battery, as is shown in Figure 1.
The Rint ECM Li-ion battery model is an equivalent Thevenin electrical circuit consisting of an open circuit-controlled voltage (OCV) source and an internal resistance designated by Rin. The OCV source strongly depends on the state of charge (SOC), i.e. a dependency described by an extremely nonlinear function OCV = f (SOC), represented by different combinations of models reported in the literature such as Shepherd, Nernst and Unnewehr universal model [1,3,4]. The dynamics complexity and the accuracy of ECM increase by adding an RC polarization cell (first-order RC model), two RC cells (second-order ECM) respectively three RC cells (third ECM order model), as those developed in [1][2][3]11]. The main input-output and intermediate signals in Figure 1 are I batt is the input battery instantaneous value of the direct current (DC) flowing through the open circuit controlled-voltage source, and V batt denotes the measured output terminal battery instantaneous value DC voltage that are nonlinear dependent of OCV, as intermediate signal. The internal resistance of the battery is affected by several factors. Still, a significant impact has conductor resistance, electrolyte resistance, ion mobility, separator efficiency, reactive electrode rates, polarization, temperature, and aging effects, and SOC changes, as is mentioned in [11]. Since the SOC of the battery is defined as [1][2][3][4]11]: with Q denoting the rating battery capacity, in the schematic shown in Figure 1, the controlled voltage source E (open circuit voltage (OCV)) can be modeled by: The battery terminal voltage Vbatt is related to OCV according to following nonlinear equation: ECM Rint Li-ion battery model (see [11]).
] is a 1 Â 4 dimensional vector, whose components have the given values suggested in [1], and h SOC ð Þ¼ À 1 SOC À SOC ln SOC ð Þ Â ln 1 À SOC ð Þ T is a 4 Â 1 dimensional vector nonlinear function. However, for the implementation of the proposed FDI techniques, a highprecision model is not required, because the extraction of ECM parameters is beneficial to monitor the battery SOC, rather than to model the battery performance.

Rint ECM Li-ion battery model dynamics represented in continuous and discrete time state space representation
For a discharging current cycle, when u t ð Þ ¼ i t ð Þ ≥ 0, and for a charging current cycle u t ð Þ < 0 the dynamics in continuous time t of an ECM Rint Li-ion battery model is described by the following three Equations [1][2][3][4]11]: where η is the coulombic efficiency that has different values for charging and discharging cycles, E 0 , K 1 , K 2 , K 3 , and K 4 are the OCV battery characteristic curve coefficients, whose values are given in [1], "chosen to fit accurately the Li-ion battery model to manufacture's data by using a least squares curve fitting estimation method" [1][2][3]. Similar, the equivalent battery model in discrete time can be written in the following form: where T s ¼ 1 second ð ÞÀis sampling time, k ∈ Z used to denote the discrete time instant t k = kT s .
Because the internal resistance Rin is an essential parameter of the battery that is affected much more by the temperature than other parameters of the cell, it is necessary to attach to the Li-ion battery model a thermal model, described in continuous time by a first order differential equation: where: P loss ¼ R amb u t ð Þ 2 , and u t ð Þ ¼ i t ð Þ. In discrete time the Eq. (7) becomes: (11) and T c ¼ 2000 [s] is the thermal resistance, T amb ¼ 293:15 K ½ signifies the ambient temperature in degree Kelvin (T is the most used to denote the absolute temperature in degree Kelvin), and P loss denotes the power losses dissipated on the internal resistance Rin, and T cell is the temperature of the battery cell in degree Kelvin.

The Rint ECM Li-ion battery healthy model: Residual generation and MATLAB simulations
The healthy ECM battery model (free faults model) MATLAB simulations to an input driving cycle Federal Test Procedure (FTP-75) for a city, are shown in Figure 2. In

The adaptive extended Kalman filter Li-ion battery SOC estimator for fault detection and isolation
For Li-ion batteries, the aspects such as accuracy performance of the SOC estimation and the prediction of the terminal voltage are essential to be analyzed, thus ensuring the safe operation of the cell, and thus maintaining a long life. Therefore, a brief presentation of an appropriate estimation technique is of real use. Moreover, for any battery, whether it is a Li-ion battery, SOC cannot be measured accurately, so it is necessary to estimate it. The most popular estimation algorithm reported in the literature is the Kalman filter (KF) with its improved version for models with extremely nonlinear dynamics, such as an extended Kalman filter (EKF) /adaptive extended Kalman filter (AEKF) [1][2][3][4]11].

The adaptive extended Kalman filter Li-ion battery SOC estimator-brief presentation
Since the preliminary results obtained in [11] convinced us about the efficiency of applying the AEKF SOC estimator for a Simscape model of Li-ion battery, quite well documented in [4], then the same estimator is used in this paper. For the adopted battery model, the SOC estimator adaptation consists in changing the dimensionality of the state space and the values of the adjustment parameters. For good documentation, the reader can see, in Appendix A, a brief presentation of the steps of AEKF estimation algorithm. Furthermore, the choice of using the AEKF for condition monitoring purposes is explained in this subsection. As is mentioned in the first section, the BMS, through its hardware and software components, plays a vital role in an HEV integrated structure for supervision, control and monitoring all the internal battery parameters. In a BMS, time-based monitoring and FDI techniques based on Kalman filter state and parameters estimators are implementing, and the faults in a system are detected only when measured values exceeded their normal limits [5,26]. Furthermore, since the Li-ion battery SOC is non-measurable and a critical internal parameter of the battery, the use of AEKF SOC estimator for its estimation is wholly justified.

AEKF SOC estimator of Rint ECM Li-ion battery healthy model: Residue generation and evaluation
For a healthy Li-ion battery (free faults), the MATLAB simulations result of applying AEKF SOC estimator, whose steps are briefly presenting in Appendix A, is shown in  The residues of battery SOC and for internal resistance are calculated by using the Eqs. (13) and (14): For a healthy battery model, the residual is inside the minimum and maximum values of two thresholds, calculated as [5]: where Thr ymin and Thr ymax denote the minimum value and respectively maximum value of the threshold, m y is the mean of the clean battery terminal voltage residual values, and σ y means the standard deviation of the clean battery terminal voltage residual values. In Figure 3(c) is depicted the battery AEKF SOC estimate values versus the battery model SOC true values, and in Figure 3(d) is showing the battery SOC residual calculated in the same manner as the battery terminal voltage. The MATLAB simulations result reveals an excellent SOC accuracy, and for a clean battery model the SOC residual is inside the band delimited by the minimum respectively maximum values of the SOC threshold calculated by using a similar formula as in Eq. (9). In Figure 4(a) is shown the robustness of AEKF SOC estimator to a change in the initial value of SOC from default value 70% to a SOCini = 40%. A level of the noise in measurements is more realistic in HEVs applications since the initial value of SOC must be guessed, and due to contamination of the measurements with noise. The SOC residual that is showing in Figure 4(b) remains inside the band delimited by the same minimum and maximum values of SOC threshold, and in Figure 4(c) the battery terminal voltage residual also remains inside the band.

Fault injection mechanism and fault detection based on AEKF SOC estimator -scenarios and residual generation and evaluation
The fault injection mechanism based on AEKF fault estimation and residual generation consists of injecting additive bias sensors faults in the input-output Li-ion battery Rint ECM model, as following: where f u denotes the current sensor fault, f y is the terminal voltage sensor fault, and f T signifies the temperature fault. The Eq. (12) is useful to measure the impact , as is shown in [26]. As it can be seen in Eqs. (10)- (12) in this research paper are presented only three scenarios for fault injection.
At the instance 500 seconds is injected a fault in the Voltage measurement sensor of magnitude 1 V, and after 500 seconds the fault is removed, as shown in Figure 5(a).
In Figure 5(b) is shown the impact of the injected fault on battery terminal voltage, real and estimated values. The MATLAB simulation result reveals an abnormal behavior of terminal voltage estimate inside the same window of fault injection. The detection of the event is faster at the beginning of the window, persisting only 500 seconds, until the fault is removing. The residual battery terminal voltage is showing in Figure 5(c). It exceeds the band of the clean terminal voltage signal inside the fault window; thus, the same fault is detecting. An abnormal behavior of battery SOC is revealed in Figure 5(d) inside the fault window and persists inside the window until the fault is removed at instance 1000. The SOC residual generated by injecting the bias voltage in the Li-ion cell sensor terminal voltage is shown in Figure 5(e) that also detects the occurrence of the fault inside the same window. After the fault is removed the SOC residual enters inside of the band and indicates a normal SOC behavior. In Figure 5(e) the MATLAB simulations result reveals the fact that the injected fault has not a significant impact on the internal resistance Rin.  Figure B1(b), and its residual depictured in Figure B1(c) detects the presence of the fault at the beginning of the window injection. In this scenario, compared to the first scenario, the fault persists until the end of the driving cycle; so its evolution after removing the fault is misclassified and can be considered as a false alarm, that is useful for constructing the FDI logic of fault localization (isolation). A similar situation appears for battery SOC shown in Figure B1(d) and for its residual in Figure B1(e). In Figure B1(f) the internal resistance Rin has the same evolution as in the first scenario. These last aspects are beneficial also for creating the FDI logic for isolation.
• Third scenario: injection of bias temperature sensor fault In the temperature sensor, a fault of magnitude 10°C is injected in the same window, similar for first and second scenario, as is shown in Figure B2(a) from Annex B. The MATLAB simulations result from the impact on the temperature profile of the fault injected is showing in a Figure B2(b). Also, the internal battery resistance is showing in the Figure B2(c), and the battery SOC is disclosed in Figure B2(d) together to its residual in Figure B2(e). The battery terminal voltage is showing in Figure B2(f) together to its residual depicted in Figure B2(g). This scenario of point view of fault detection is the same as the first scenario with the fault persistent only inside the window and removed at the end of the same window. Only the internal resistance of the battery withstands a significant impact inside the window, a valuable indication for fault localization.

The residual evaluation and FDI logic isolation
Residual evaluation supposes to define "proper functions for the generated residue evaluation so that fault occurring in the system can be detected correctly", as is stated in [5]. Roughly, in the ideal case, "if no fault occurs, the residue will be zero and otherwise, it will be non-zero" [5]. More precisely, in a general formulation, the residue evaluation can be defined as: if R k ¼ 0, the battery is fault free, otherwise the battery is faulty (21) where R k might be R y k ð Þ, R SOC k ð Þ and R Rcell k ð Þ, as defined in Eqs. (9)- (11). It is possible that in many cases, "the residue might be non-zero even though no fault has occurred; therefore, the evaluation function of Eq. (18) will not be proper. For this purpose, a statistical evaluation function can be defined as [5]: Ifm y À μσ y ≤ R k ≤ m y þ μσ y the Li-ion battery is fault free (22) otherwise: for which the values of the parameter μ, i.e. μ ¼ 1, 2 and 3, regarding the evaluation function is a trade-off between maximizing the probability of fault detection and minimizing the probability of wrong fault alarm. If μ ¼ 3 then the probability: p{m y À 3σ y ≤ R k ≤ m y þ 3σ y g ¼ 98:5% is maximum possible. The fault signature for AEKF SOC estimator based diagnostic scheme is shown in Table 1.
For the second scenario the isolation of the fault can be done based on the tendency of SOC, i.e. for first scenario the SOC increases (Res_SOC >0) after the fault injection, while for second scenario it decreases (Res_SOC < 0) and persists until the end of driving cycle, generating a false alarm.

1-D wavelet transform signal analysis used to extract the faults features in Li-ion batteries
This section investigates the use, in a new approach, of 1-D wave signal analysis, a valuable tool for determining the essential characteristics of faults that occur in a Li-ion battery, a useful basic principle for developing a simple detection of their defects. These techniques are based on detecting changes that occur abruptly in the variation of the residual signal due to a faulty current sensor or a defective temperature measurement sensor, such as those developed in the previous section. Therefore, a similar method of residual generation and evaluation is useful to provide a valuable information to use the wavelet transformation ability to extract the essential features (patterns) of the faults from the output voltage residual of the battery. These faults visibly affect the performance of the Li-ion battery, such as the output voltage and SOC. The dynamics of the battery model under investigation is shown in Section 2. Note that SOC plays a critical role in locating faults (isolation).

Wavelet transform: Brief presentation and description
Over time, Fourier transform (FT) has proven to be a useful tool for analyzing signal frequency components in a wide variety of applications. However, it has a significant disadvantage, because when it covers the entire time axis, it is impossible to see when a frequency increase. Instead, the short-term Fourier transform (STFT) uses a sliding window to find the spectrogram, which provides complete information on both time and frequency. A small impediment when using STFT in applications is due to the length of the window that limits the frequency resolution [10]. In these situations, the wavelet transforms (WT) seems to be a feasible solution, since it can be applied on a small wavelet of limited duration. Specifically, the wavelet provides local frequency information compared to FT, which captures the global features such as the harmonic components of the entire signal. Besides, the scaled wavelets allow to analyze the signal on different scales. The essential functions designate the "wavelets," which are nothing else than scaled and shifted copies of the same "mother wavelet." With a proper choice of the mother wavelet, the basis wavelets can be orthonormal, or at least linearly independent. Thus, the wavelets form a complete basis, and the wavelet transforms are designed to be reversible.

Continuous and discrete wavelet transforms
A wavelet is a waveform of effectively limited duration that has an average value of zero and nonzero norm, as is stated in [12]. The wavelets compared to sine waves, as the basis of Fourier analysis, "tend to be irregular and asymmetric, while sinusoids are smooth, predictable, and their duration is not limited" [12]. Thus, a wavelet is a wave-like oscillation with an amplitude that starts at zero, increases, and then decreases back to zero. Furthermore, the majority of signals and images of interest "exhibit piecewise smooth behavior punctuated by transients", and the "signals with sharp changes might analyze with an irregular wavelet than with a smooth sinusoid", thus an excellent idea for applying it to develop the detection techniques of the faults [12]. A fundamental work recommended to readers to obtain an excellent theoretical background on the wavelets is the reference [13]. Let us consider the wavelet analyzing function, also called "mother wavelet," and a continuous wavelet transform (CWT). The CWT compares the signal under investigation, denoted by y(t), to shifted and scaling (compressed or stretched) versions of the wavelet function [12]. Since the physical signal y(t), which can be the output of the plant or a residual error, is real-valued, then also the CWT is a real-valued as a function of scale and position. For a scale parameter, a > 0, and location, b, a possible representation of a 1-D CWT can be the same as in [12,13]: where ψ t ð Þ * is the conjugate function of ψ t ð Þ, and CWT a, b; y t ð Þ, ψ t ð Þ ð Þ denotes the coefficients of the wavelet transform CWT. They are affected by the values of scaled and shifting position parameters a, respectively b, as well as by the choice of wavelet function ψ t ð Þ. A "mother wavelet" is a waveform for which the most energy is restricted to a finite duration [8]. It is defined as, where 1/a denotes the frequency and 1/ ffiffiffi a p is a normalizing constant of each scale parameter. Anyway, there are an infinite number of the functions that can be considered as a "mother wavelet". In Eqs. (24) and (25) the variable a is called also "scale" or "dilation" variable since performs a stretching or compressing action on the "mother wavelet", while the variable b is referred as "time shifting" or "translation" that delays or accelerates the signal start [5]. The CWT a, b; y t ð Þ, ψ t ð Þ ð , as result of wavelet transform on signal y(t) is the wavelet coefficients vector of length L (number of samples) and components as  function of scale a, and translation b, i.e., a function: Each coefficient of the vector c a, b ð Þ (A i , D i , i ¼ 1, NÞ "represents how closely correlated a scaled wavelet is with the portion of the signal y(t) which is determined by translation" [12]. In fact, the c(a, b) coefficients are the time-scale view of the signal y(t), and so the CWT is an important analysis tool capable to "offers insight into both time and frequency domain signal properties" [12]. The results of this interpretation lead to the following useful observations that will be considered for developing the proposed wavelet signals processing and analysis strategy [16]: • The higher scales correspond to the "most" stretched wavelets, furthermore "the more stretched the wavelet, the longer the portion of the signal with which is compared, and thus the coarser the signal patterns features measured by the wavelet coefficients." • The coarser features capture the low frequency components (A i , i ¼ 1, NÞ called "approximations" that provide basic shapes and properties of the original signal y(t) • The low scale components (D i , i ¼ 1, NÞ are called "details" and capture the high frequency information. • The CWT is computationally inefficient, since it requires to calculate the c(a, b) coefficients at every single scale, so computationally expensive.
An alternative to the CWT is the discrete wavelet transform DWT, much more efficient and of high accuracy, defined in a similar way that CWT in Eq. (24) [14]: For a parameter (a 0 , b 0 ) setting to the values: a 0 = 2, b 0 = 1 is obtained a particular dyadic sampling of the time-frequency plane (a set of coefficients per octave), as is mentioned in [14]. Thus, for this particular sampling, it is possible to obtain for the set ψ j,k an orthonormal basis with a "mother wavelet" ψ t ð Þ, well localized both in time and frequency, such as the wavelets Morlet, Haar and Daubechies have shown in Figure 6 [14]. The DWT is based on the wavelet analysis at scales and translations that are power of two, such as 2, 4, 6, 16, and so on [12][13][14], and wavelet approximations A ψ j 0 , k À Á and detailed D ψ j, k ð Þcoefficients at stage k, are defined as in [10], Finally, according to Eqs. (28) and (29) the original signal can be approximated as, or simpler, starting from last stage N toward the first stage in decomposition, and recursively, at stage level k, it can be writing: In [16] is mentioned the "approximations" of the signals under investigation "provide basic trends and characteristics of the original signals, whereas the details provide the flavor signal". The result of the applying DWT on the original signal y is the socalled wavelet decomposition around both key coefficient vectors, [A] ("approximation" coefficient vector), and [D] ("detail" coefficient vector). The decomposition is repeating on the approximations in each stage. The multiple stage DWT will break down the original signal into many successively lower resolution components, as is described in [15]. According to [15] "at each stage, the approximation coefficients vector [A] represents the basic trends of the original signal characteristics, while the details coefficients vector [D] provides the flavor of the signal". The inverse process opposite to decomposition is the signal reconstruction by using an inverse discrete wavelet transform (IDWT). More details about sample wavelet definitions known as Haar, Morlet and Daubechies wavelets, the reader can find in [8,13,17]. As is shown in Figure 6, in control systems applications is preferred the Morlet wavelet function for continuous analysis using CWT [13,14], compared to Haar and the Daubechies wavelet family functions that are very useful for DWT [8][9][10]. Using the MATLAB/ SIMULINK Wavelet and Processing Toolboxes in real-time, the proposed 1-D wavelet analysis strategy is implementing by following the guidelines from [8, 10-12].

Wavelet transform analysis of the faults features extraction in a rechargeable Li-ion battery -setups
Signal processing is a well-known tool to deal with fault diagnosis. It is useful to analyze directly the signals measured online, avoiding system modeling compared to Kalman filter techniques that are model-based. A wave transformation offers a new approach to the analysis of transient regimes that vary over time. It has a specific ability to analyze signals simultaneously in both time and frequency domains. Besides, it can automatically adjust the analysis windows according to frequency, namely, shorter windows for higher frequencies and vice versa. Therefore, the wavelet transform is very suitable for identifying the characteristics of the faults that occur in the Li-ion battery under investigation. However, the identification of such wavelet-based features in HEV Li-ion BMS applications is a novelty. Signal features, such as discontinuity or singularity, are easily detectable through a 1-D wavelet transform. Sudden signal transitions lead to wave coefficients with high absolute values. The changes in the evolution of the signal provide valuable information when something fundamental has occurred in the evolution of the signal. These features suggest an excellent idea in our case study on how to detect measurement sensor errors that often occur in a Li-ion battery used in HEV applications.
Step 1. Simulink model diagram of Li-ion battery and fault injection mechanism setup.
At this stage is investigated the capability of using 1-D wavelet analysis to detect some anomalies in a BMS of the Li-ion battery caused by two faults injected in a current, respectively temperature sensor. Figure 7 shows the Simulink diagram of a general model of the Li-ion battery, including the thermal model and fault injection mechanism in both healthy and thermal blocks.
Step 2. Healthy and faulty models of Li-ion battery setup. The Simulink diagrams of healthy and defective battery cell models are depictured in Figures 8 and 9. In these figures are visible also the fault injection blocks inside the battery (Figure 8) and thermal (Figure 9) models.

Wavelet transform analysis: MATLAB implementation and simulations
Step 1. Wavelet filter bank decomposition -Biorthogonal wavelet description. Based on a 1-D DWT signal decomposition, the analysis (decomposition) and synthesis (reconstruction) filters are of more interest than the associated scaling   with three vanishing moments in the reconstruction filter and five vanishing moments in the decomposition filter, very useful to be used in fault detection. More precisely, both phases analysis and synthesis require two low pass filters (LPF) to filtrate low frequencies signals, respectively two high pass filters (HPF), to filtrate the high frequencies signals [8,12,[18][19][20][21].
Furthermore, the orthogonal and biorthogonal filters banks are an arrangement of low pass, high pass, and bandpass filters that divide the signals data sets into sub-  bands [12,[17][18][19][20][21]. If the sub-bands are not modified, these filters enable perfect reconstruction of the original data. In most of applications, the data are processed differently in the different sub-bands and then reconstruct a modified version of the original data. Orthogonal filter banks do not have linear phase, compared to biorthogonal filter banks that have linear phase [12,[18][19][20]. The wavelet and scaling filters are specifying by the number of the vanishing moments, which allows removing or retaining polynomial behavior in the signals data sets.
In addition, lifting allows designing perfect reconstruction filter banks with specific properties. To obtain and use the most common orthogonal and biorthogonal wavelet filters can be used Wavelet Toolbox™ functions [20]. The design of custom perfect reconstruction filter bank is performing through elementary lifting steps. Besides, can also be added own custom wavelet filters. By using the wavelet filter bank architecture depicted in Figure 11, it is possible to obtain residues that change noticeably in order to offer precious information about the timely detection of the faults and its severity [20,21]. A sub-band model is suggesting in [18,19] of the form: where s is an integer number, and a, b are real numbers. In [18] is used the 'db8' wavelet for wavelet filter bank design of level 3 decomposition for a Single-Input Single-Output (SISO) plant extended in [19] for a multiple inputs and multiple outputs (MIMO) plant. Besides, in same reference is developed a wavelet basedfrequency sub-band analytical redundancy scheme to calculate the residuals for different faults that uses for wavelet filter bank synthesis and analysis a level three decomposition, as is shown in Figure 11. The same wavelet filter bank is adopted in our case study, even if the decomposition resolution can increase by increasing the number of levels. Nevertheless, in our case study, the focus is only on the "concept of proof" and to demonstrate the effectiveness of the proposed error detection technique, based on the use of the multi 1-D signal waveform analysis tool. In Figure 11, G(z) and H(z) represent the z-transforms of the low pass filter (LPF) and high pass filter (HPF) respectively. A two-channel critically sampled filters bank play an important role to filtrate the input signal, i.e. the output battery voltage residual, by using a pair of low pass filter (LPF) and high pass filter (HPF) [18,19,21]. The subband outputs of the filters are downsampling by two to preserve the overall number of samples. To reconstruct the input, upsampling by two and then interpolate the results using the low pass and high pass synthesis filters. If the filters satisfy specific properties, a perfect reconstruction of the input is achieved [18][19][20][21]. In Figure 12 (a) and (b) are presented the schematic of a Wavelet Filter Bank decomposition on two levels (a), respectively a simple interpretation of the DWT coefficients in frequency domain [14].
The schematic from Figure 12(a) give us the idea of a recursive numerical algorithm for the DWT coefficients computation based on digital filters at all levels j = 1:N, which take advantage of using a digital signal processor (DSP): Step 2. Fault injection scenarios presentation: For simulation and "proof-concept" purpose, only two scenarios for error injection are developed in this section, namely a 2A bias fault injected into the current sensor, and a 10°C bias temperature fault injected into the thermal model of Li-ion BMS. The faults are injected separately, in the same window [500,1500] seconds, and their impact on the battery output voltage is analyzed by using the same Li-ion battery residual generation and evaluation method, like in the previous section.
Step 2.1 Scenario 1: Bias current fault MATLAB implementation. As first scenario is considered a 2A bias fault injected in the current sensor inside the window (500,1500) seconds.
Step 2.1.1 Li-ion output voltage and MATLAB SOC residual generation-original and reconstructed signals.  The MATLAB simulations results are shown in the Figures 13 and 14 for battery SOC (healthy, faulty and residual), respectively for battery voltage residuals, (healthy and faulty) original and reconstructed, using the analysis (approximation) and details wavelets filters (in reconstruction).
In Figure 15 is used the denoising capability of 1-D wavelet synthesis filters 'sym4' to reduce as much as possible the noise level in the healthy and faulty signals. In [22,23] is showing how to use wavelets to denoise signals and images. Because wavelets localize features in measurement dataset to different scales, an important signal or image features can be preserved while removing noise [22]. The "basic idea behind wavelet denoising, or wavelet thresholding, is that the wavelet transform leads to a sparse representation for many real-world signals and images" [22]. Thus,  the wavelet transform concentrates the signal and image features in a few largemagnitude wavelet coefficients [22]. Wavelet coefficients which are small in value are typically noise and can be "diminished" those coefficients or much better can be removed without affecting the signal or image quality. Thresholding operation of the coefficients is followed by the reconstruction of the data using the inverse wavelet transform. The denoising operation of the input-output signals can be performed by using an average moving method [23], or decimated ("wdenoise" MATLAB command) and undecimated ("wden" MATLAB command) wavelet transforms [22]. In Figure 15 is shown the residual between the noisy and denoise signals, where wavelet denoising has removed a considerable amount of the noise while preserving the sharp features in the signal, which is also a challenge for Fourier-based denoising or filtering. The Fourier-based denoising, or filtering, is using a low pass filter (LPF) to remove the noise. However, "when the data has high-frequency features such as spikes in a signal or edges in an image, the low pass filter smooths these out", as is stated in [22]. Moreover, the wavelets can be used to denoise signals in which the noise is nonuniform [22].
Step 2.1.3. Fault detection features: In Figure 13, it easy to see the impact of the injected fault in the windows (500,1500) seconds, where the SOC change by maximum 10%. The information extracted from SOC residual in Figure 13 and output voltage residual in Figure 15, is valuable to detect the incipient moment of the fault, its duration and severity if a threshold value is chosen. The presence of the fault inside the window [500,1500] is visible since sudden changes in the SOC and output voltage of residual levels is easy to visualize. The fault removal at the end of the injected window is noticeable due to a sudden change of the signals' levels in the opposite direction at the initiating time instant of the fault injection. In Figure 16(a) and (b) is depicted the output voltage residuals noisy and denoised originals and their perfect reconstruction. An impressive result is showing in Figure 17, where the presence of the fault inside the injected window is without doubt detecting by analyzing the wavelet variance in signal by scale before injected fault, inside the window and after removing the fault, in bar representation. For the proposed fault detection strategy design, a discrete wave transformation is useful to apply on the output voltage signal of the Li-ion battery. It is equivalent to the analysis branch (with downsampling) of the two-channel filter bank (decomposition) using LPFs, and HPFs suggested in [17,18]. They are used for downsampling the input signal up to level 3, as shown in Figure 18 for all three levels the details of the wave coefficient D1, D2 and D3 and the analysis coefficient A3.
Step 2.1.4. 1-D wavelet transform analysis used for battery voltage residual three levels decomposition -Approximation coefficient A4, and Details coefficients D1, D2 and D3:  In Figure 18 is presented the MATLAB simulation result of the battery voltage residual decomposition on three level based on the wavelet filter banks shown in Figures 11 and 12.
For decomposition is used a Symlet wavelet transform 'sym4' with four vanishing moments. The feature extracted from the wavelet coefficients are summarized in Table 2 and interpreted at the end of this section, in comparison with the second fault.
Step 2.2. Scenario 2 MATLAB implementation: As a second fault is investigated a 10°C bias fault injected in the temperature sensor inside the window (500,1500) seconds.
Step 2.2.1 Li-ion output voltage and MATLAB SOC residual generation-original and reconstructed denoised signals: Like for the first scenario, the same information is extracted from the Figures 19 and 20. In Figure 19(a) is shown the battery SOC with almost a zero impact of the injected temperature fault since we assumed in this research that SOC does not change significantly if the temperature inside the battery changes. This assumption is not realistic, since in "real life" the SOC and internal resistance of Li-ion battery are dependent on temperature. This assumption was adopted to simplify the Li-ion battery model substantially, since a battery model of high complexity is beyond the topic developed in this research work. Moreover, the assumption is also justified by the fact that the fault detection analysis by using a 1-D wavelet analysis tool is performing online. A model is not required, that is a significant advantage of the new approach compared with the model based Kalman filter technique approach developed in the previous section, for which the SOC accuracy of the battery model is critical. Besides, the main objective of this paper is to provide a "proof concept" and to demonstrate the effectiveness of the use of 1-D wavelet analysis of finding the essential features in the output voltage residual variance for MATLAB design and implementation of the investigated fault detection technique. In Figure 19 (b), (c) and (d) are visualized the healthy, faulty and the battery temperature residual (b), the healthy, In faulty and the output voltage residual (c), respectively the use of 1-D wavelet 'Sym4' for denoising output voltage residual (d). The residual of denoised battery output voltage and its corresponding constructed wave are presenting in Figure 20(a).
The MATLAB simulation result shown in Figure 19 (b), (c) and (d) reveal that the presence of the temperature fault is noticeable by its effect on the output voltage residual at the beginning, inside and at the end of the injected window. and the coefficients D1, D2, D3 and A3 of the 'Sym4' wavelet are shown in Figure 20 (b). The features extracted from Figure 20(b) are summarized in Table 2 and analyzed at the end of this section.

Wavelet transform analysis of fault detection technique. Performance comparison
A rigorous performance analysis of using 1-D wavelet transform tool for fault detection strategy is accomplished based on the information extracted from the details' coefficients of output voltage residual decomposition for both scenarios. From the details coefficients values D1, D2, and D3 can be extracted the wavelet energy, skewness, and kurtosis features. These statistics can identify the types of faults based on their distinct value, as are defined in [14], MATLAB Wavelet Toolbox (for wavelet energy), respectively MATLAB Statistics and Machines Learning Toolbox for skewness and kurtosis).
• The wavelet energy is an important indicator that gives a valuable information about the presence of the fault inside a window that has a concentrated large value of the wavelet energy, defined as, • The skewness is a measure of the asymmetry of the data around the sample mean. If skewness is negative, the data spreads out more to the left of the mean than to the right. If skewness is positive, the data spreads out more to the right. It is defined as, • The kurtosis is a measure of whether the distribution is too peaked, i.e. a very narrow distribution with most of the responses in the center, and is defined as, where μ i is the mean of D ij , σ i is the standard deviation of D ij , and E(.) represents the expected value. The values of the three indicators defined in Eqs. (31)-(33) are entered in Table 2 for both error scenarios.
The excess kurtosis and skewness of every coefficient A3, D1, D2 and D3 in the dataset, can be interpreted as follows: a. For skewness, if the distribution of responses for a variable stretches toward the right or left tail of the distribution, then the distribution is referred to as skewed. A general guideline for skewness is that if the number is greater than +1 or lower than À1, this is an indication of a substantially skewed distribution.
b. For kurtosis, if the number is greater than +1, the distribution is too peaked. Otherwise, a kurtosis of less than À1 indicates a distribution is too flat.
c. When both skewness and kurtosis are zero, the pattern of responses is considered a normal distribution.
Besides, an assessment statistic criterion root mean square error (RMSE) is introduced in Table 2 for a particular analysis of the high frequency detail component D1 dataset.
The MATLAB simulation results analyzed from the perspective of the fault features extracted from Table 2 reveal the fact that the temperature fault shows significant values compared to a possible occurrence of current fault in Li-ion battery. Figures 21 and 22 show how multiresolution decomposition technique, such as 1-D wavelet analysis, allow us to study signal components in relative isolation on the same time scale as the original data [22]. Multiresolution analysis (MRA) refers to "breaking up a signal into components, which produce the original signal exactly when added back together" [22]. The components ideally decompose the variability of the data into physically meaningful and interpretable parts, as is stated also in [22].
The term MRA is often associated with wavelets, and in the "real life" the signals consist of a mixture of different components. Often the interest is focused only in a subset of these components. That is why the MRA allows us to restrict the analysis of the original signal, by separating it into components at different resolutions. Extracting signal components at different resolutions means a decomposition of variations in the data on different time scales, or equivalently in different frequency bands [22]. Consequently, the signal variability at different scales or frequency bands can be seen simultaneously.
In the Figures 21 and 22, using a wavelet MRA, the Li-ion battery output voltage residual signal is analyzed in MATLAB at eight resolutions or levels, following the procedure shown in [22] for both faults isolation.
Both graphs from Figures 21 and 22 starts from the uppermost plot and proceed down until is reached the plot of the original data and is worth noting that the components have become progressively smoother. D2 graph isolates the timelocalized high-frequency component, which can be seen and investigated as an essential signal feature practically in isolation. The next two graphs contain the lower frequency oscillation. It is worth to mention that "an important aspect of multiresolution analysis, namely important signal components may not end up isolated in one MRA component, but they are rarely located in more than two" [22]. Finally, from the S8 graph can be extracted a smooth trend term, which provides us a valuable information to localize transient changes, as it can see in the fault injection window [500, 1500] seconds. Thus, the presence of the bias current fault and bias temperature fault is detected and localized as a significant transient change in the nonstationary Li-ion output voltage residual signal. For an appropriate choice of the thresholds' values, both faults can be detected directly from the S8 graph, removing the presence of the false alarms completely.
Besides, the value of the RMSE statistical criterion of the energy feature extracted from the detail coefficient D1, for both faults, shown in Figures 18 and 20  (b), undoubtedly confirms the validation of the results obtained in Table 3, adequate to differentiate between the two faults. However, in Table 3 is shown the Fault signature of 1-D wavelet analysis transform, useful for fault isolation. To distinguish between both faults injected in Li-ion battery, i.e. current sensor bias fault, respectively, temperature bias fault a valuable information is provided by battery SOC and battery internal resistance residuals. It is showing in Table 3, like for based model AEKF FDI strategy developed in Section 2. An exciting piece of information is related to the "border effects of error injection", clearly visible when the temperature fault is removing, because the healthy signal emerges from the defective one in the window, before the corresponding time tf = 1500 seconds. These "frontier effects" require further investigation in future work.

Conclusions
In this research paper is opened a new research direction in HEV BMS applications field by performing many investigations on the use of multisignal 1-D wavelet analysis to improve the accuracy, robustness, the design and the implementation in real-time of Fault detection techniques. Among the most relevant contributions of the authors can be highlighted the following: • The selection of a suitable and straightforward Li-ion battery model, accurate enough for data generation, and to design and implement a robust adaptive extended Kalman filter SOC estimator to changes in SOC initial values, in the level of measurement noise that contaminate the input-output dataset, to changes in the battery capacity value due to aging effects, and changes in the internal resistance of the battery due to temperature effects • Representation of the battery model in continuous and discrete time state-space  Table 3.
• Develop the most appropriate thermal model of the battery for data generation and to setup the temperature mechanism fault injection • Adaptive Extended Kalman Filter SOC estimator with fading feature and covariance matrices of noises correction-brief presentation and MATLAB design and implementation.
• The battery SOC and output voltage residual generation and bias current fault injection mechanism • The fault detection and isolation estimation technique based on AEKF SOC estimator • Wavelets transform analysis of the faults features extraction in a rechargeable Li-ion battery • SOC and output voltage residual generation-original and reconstructed signals These investigations are performed for the case study, principally chosen to evaluate the impact of two bias faults injected in a current and temperature sensor on the output voltage of a BMS Li-ion rechargeable battery used in HEVs applications.
The effectiveness of fault detection strategy is demonstrated through an extensive number of simulations in a MATLAB R2020a software environment. The preliminary simulation results are encouraging, and extensive investigations will be done in future work to extend the applications area. The performance analysis from the last section reveals that 1-D wavelet analysis is a useful tool for signals processing, design and implementation based on wavelet transforms found in a wide range of control systems industrial applications. Compared to AEKF estimation technique described in Section 2, the 1-D wavelet analysis tool has a significant advantage to perform online. Also, it does not require the model of the battery, since it uses directly the input-output signals generated by the battery model. More precisely, it is based only on the measurement input-output dataset collected by a data acquisition (DAQ) system incorporated in BMS of HEVs. Besides, the battery SOC and output voltage signals' accuracy is not affected by noise as long as is using the signals denoising techniques, such in the case of AEKF fault detection and isolation technique during the noise correction step of the algorithm.