electronics An Adaptive Prediction Model for the Remaining Life of an Li-Ion Battery Based on the Fusion of the Two-Phase Wiener Process and an Extreme Learning Machine

: Lithium-ion batteries (LiBs) are the most important part of electric vehicle (EV) systems. Because there are two different degradation rates during LiB degradation, there are many two-phase models for LiBs. However, most of these methods do not consider the randomness of the changing point in the two-phase model and cannot update the change time in real time. Therefore, this paper proposes a method based on the combination of the two-phase Wiener model and an extreme learning machine (ELM). The two-phase Wiener model is used to derive the mathematical expression of the remaining useful life (RUL), and the ELM is implemented to adaptively detect the changing point. Based on the Poisson distribution, the distribution of the changing time is derived as a gamma distribution. To evaluate the theoretical results and practicality of the proposed method, we perform both numerical and practical simulations. The results of the simulations show that due to the precise and adaptive detection of changing points, the proposed method produces a more accurate RUL prediction than existing methods. The error of our method for detecting the changing point is about 4% and the mean prediction error of RUL in the second phase is improved from 4.39 cycles to 1.61 cycles.


Introduction
Due to their ability to decrease environmental pollution, electric vehicles (EVs) have become a research hotspot [1]. An EV system consists of a differential, a mechanical transmission system, an electric motor, a power converter, a battery management system (BMS), and a battery pack [2]. In EV systems, batteries are the most important component [3,4]. Although there are many types of batteries that can be used in EVs, lithium-ion batteries (LiBs) are the most widely used due to their high energy density and long cycle life [2]. When using a battery, its state of health (SOH) will decrease over time. However, due to current engineering practice, the SOH of LiB typically decreases faster than intended due to random effects in real projects. When the SOH of the battery is too low for EVs to use, EVs may stop functioning, which may lead to property damage and casualties. Therefore, we must know the remaining useful life (RUL) of lithium-ion batteries in advance to avoid potential dangers and losses.
The methods used to obtain the RUL of a lithium-ion battery can be divided into three categories: Physical models; data-driven models; and hybrid models [5]. To build a physical model for LiB, we must know the internal electrochemical process of LiB. However, due to the complex structure of LiB, it is difficult to observe its internal electrochemical process [6]. Therefore, it is better to use a data-driven model to obtain the RUL of LiB. There are two types of data-driven models: Machine learning techniques and stochastic techniques. time. Therefore, the methods of Wang and Kong could not adaptively eliminate the difference between the different units.
In this paper, we primarily focus on the changing point detection of TPWPMs. We combine the ELM with the TPWPM and propose a method called ELM-TPWPM to monitor the changing point adaptively in the degradation trajectory of LiB. First, the distribution of the changing time is inferred by the Poisson distribution. Then, we obtain the health index (HI) of LiB based on the one-step prediction by ELM. Therefore, we can determine the degradation phase using the HI. Then, we can update the RUL prediction of the TPWPM adaptively based on the identified degradation phase.
The remainder of this paper is organized as follows. Section 2 describes the problem. The mathematical expression of RUL for TPWPM is derived in Section 3. The parameter estimation of the TPWPM is proposed in Section 4. The experiment is presented in Section 5. Section 6 provides the conclusion to the study.

Problem Description
Based on the analysis of Burgess [23], there are two different degradation rates in the degradation of batteries: A slow degradation process, followed by a faster degradation process. For example, Figure 1 shows the degradation data of the LiB used in [27][28][29].
tor the changing point adaptively in the degradation trajec tion of the changing time is inferred by the Poisson distr health index (HI) of LiB based on the one-step prediction b termine the degradation phase using the HI. Then, we can the TPWPM adaptively based on the identified degradation The remainder of this paper is organized as follows. Se The mathematical expression of RUL for TPWPM is derive estimation of the TPWPM is proposed in Section 4. The expe 5. Section 6 provides the conclusion to the study.

Problem Description
Based on the analysis of Burgess [23], there are two dif degradation of batteries: A slow degradation process, foll process. For example, Figure 1 shows the degradation data The ordinate of Figure 1 indicates the lost capacity of L of the experiment. The LiB data in Figure 1 were obtained land, and the four LiBs were subjected to the same experim Figure 1, the degradation rate in the period of 0 to 70 cycles radation rate after 70 cycles, which shows the specific char dation. Moreover, many researchers have already started t thus, it is better to describe the degradation of LiB by a T TPWPM consists of two LWPMs with different degradation cussed, the mathematical expression of TPWPM is defined The ordinate of Figure 1 indicates the lost capacity of LiB and the abscissa is the time of the experiment. The LiB data in Figure 1 were obtained from the University of Maryland, and the four LiBs were subjected to the same experimental conditions. As shown in Figure 1, the degradation rate in the period of 0 to 70 cycles is much slower than the degradation rate after 70 cycles, which shows the specific characteristic of two-phase degradation. Moreover, many researchers have already started the TPWPM of LiB [20,[24][25][26], thus, it is better to describe the degradation of LiB by a TPWPM than an LWPM. The TPWPM consists of two LWPMs with different degradation rates. As Wang et al. [30] discussed, the mathematical expression of TPWPM is defined as follows: where µ 1 and µ 2 are drift coefficients in the first and second phases, respectively; σ 1 and σ 2 are diffusion coefficients in the first phase and second phase, respectively; B(t) is the standard Brownian motion; τ is the time of the changing point; x 0 is the initial state in the first phase; and x τ is the state at time τ. Then, with the concept of the first passage time (FPT), we can obtain the mathematical expression of the LiB lifetime as follows: where T is the lifetime of LiB and ω is the failure threshold of LiB. To describe the uncertainty in the degradation of LiB, let f T (t) represent the probability density function (PDF) of T.
Based on the discussion in [22], the lifetime of the LWPM obeys an inverse Gaussian distribution. The TPWPM is composed of two LWPMs in two different periods of time; thus, the lifetime of the TPWPM also obeys an inverse Gaussian distribution in two different periods of time. If all parameters of the TPWPM are known in advance, the PDF of the TPWPM is as follows: Equation (3) shows that the changing time τ influences the lifetime in both the first and second degradation phase. Therefore, if we want an accurate lifetime prediction, it is important to have an accurate estimation of τ. The degradation data shown in Figure 1 demonstrate that different LiBs have different changing times. Therefore, before the arrival of τ, we should regard it as a random variable, and when τ arrives, we should detect it adaptively so that the proposed TPWPM can be more widely applicable in the field of LiB.
From the description above, the following issues will be researched in this paper: (1) How to obtain a precise estimation of changing time τ.
(2) How to derive a suitable distribution for τ.

RUL of TPWPM
As we discussed above, we must know the value of all parameters in Equation (3) to determine the lifetime of LiB using Equation (3). It is impossible to know the true value of τ in advance; thus, we cannot know the true value of x τ in advance. Therefore, to obtain f T (t), we must obtain the PDF of x τ first. Let g τ (x τ ) denote the PDF of x τ . To obtain the g τ (x τ ), Lemma 1 is as follows: Lemma 1. If X(t) = µ t + σ B(t) denotes a linear Brownian motion with the initial value x 0 = 0, its transition density function with an absorbing boundary ξ has the following form [31]: Based on (4), we can obtain the mathematical expression of g τ (x τ ) as follows: Then, we must determine the other parameters in Equation (3). Based on Figure 1, although the four LiBs are the same type of battery and are tested under the same experimental conditions, their degradation trajectories are different, which indicates that their µ 1 , µ 2 , and τ vary. Therefore, to describe the uncertainty of the parameters, we typically think of µ 1 , µ 2 , and τ as random variables. Based on [20][21][22], µ 1 and µ 2 are assumed to be normally distributed; thus, we assume that µ 1 ∼ N µ 1p , σ 2 1p and µ 2 ∼ N µ 2p , σ 2 2p , where µ 1p and σ 2 1p are the mean value and variance of µ 1 , respectively, and µ 2p and σ 2 2p are the mean value and variance of µ 2 , respectively. Then, we use the Poisson distribution to infer the PDF of τ and provide Theorem 1 as follows: Theorem 1. When there are n measurements of degradation before the changing point, and n obeys a Poisson distribution, the time of the changing point obeys a gamma distribution.
Due to space limitations, the derivation of Theorem 1 is shown in Appendix A. Typically, the RUL of a LiB at time t k has more engineering significance than the lifetime shown in Equation (2). Based on the concept of Equation (2), the RUL of a LiB at time t k has the following form: where L k denotes the RUL of an LiB at time t k . Similar to f T (t), we let f L (l k ) represent the PDF of L k . Based on Equations (3), (5) and (6), and considering the distribution of µ 1 and µ 2 , the conditional PDF of the RUL of the TPWPM at time t k is as follows [20]: where Then, considering the distribution of τ, we can determine the PDF of the RUL in TPWPM by Bayesian theory. The PDF is calculated by the following formula: (9) where p(τ) is the PDF of τ, which obeys the gamma distribution. The integral in Equation (9) is difficult to calculate; however, we can obtain the numerical solution of f L (l k ) using certain mathematical methods.

Parameter Estimation of TPWPM
In this section, we estimate the parameter of TPWPM by combining offline estimation with online estimation. Specifically, the ELM is used during online estimation to monitor the arrival of changing points in real time, which can decrease the error caused by the offline estimation.

Offline Method of Parameter Estimation
Let the parameter of the ith LiB be θ 1 and µ i,2 are the drift coefficients of the first phase and second phase, respectively; σ 2 i,1 and σ 2 i,2 are the diffusion coefficients of the first phase and second phase, respectively; and τ i is the changing time of the ith LiB. We assume that we have acquired n sets of LiB degradation data, which are obtained under the same conditions. The degradation data of the ith LiB are where k i is the total number of degradation data of the ith LiB. Therefore, the time of the degradation data can be described as T i = t i,1 , t i,2 . . . . . . t i,k i . To analyse and dispose of the data more conveniently, the following hypotheses are introduced: Hypothesis 1 (H1). The time in T i has the same interval.

Hypothesis 2 (H2). τ i belongs to T i .
Then, we use the maximum likelihood estimation (MLE) to estimate θ i . Because τ i is the changing time, X i,1:τ i = x i,1 , x i,2 . . . . . . x i,τ i and X i,τ i +1:k i = x i,τ i +1 , x i,τ i +2 . . . . . . x i,k i are the data in the first and second phase, respectively. Their measurement times are T i,1:τ i = t i,1 , t i,2 . . . . . . t i,τ i and T i,τ i +1:k i = t i,τ i +1 , t i,τ i +2 . . . . . . t i,k i , respectively. Based on Equation (1), X(t) is normally distributed. Therefore, the likelihood function of the ith LiB under the condition of X i,1:k i is as follows: where ϕ i,1 and ϕ i,2 are the covariance matrices of X i,1:τ i and X i,τ i +1:k i , respectively, and where x i,0 is the initial value of the first phase of the ith LiB, and x i,τ i is the degradation state of the ith LiB at time τ i . When lnL θ i X i,1:k i in Equation (10) is the largest, θ i is the parameter we want. Therefore, we can obtain the largest θ i by the following formula: Electronics 2021, 10, 540

Remark 1.
For the ith LiB, its degradation data from the initial state to failure have been collected so that µ i,1 , µ i,2 , and τ i are constant rather than random variables.

Online Method of Parameter Estimation
In this part, we propose a method to monitor the working condition of LiB in real time so that we can decrease the estimation error by updating µ 1 , µ 2 , and τ in time.

Monitoring the Changing Point by ELM
The structure of ELM is shown in Figure 2.

Online Method of Parameter Estimation
In this part, we propose a method to monitor the working con time so that we can decrease the estimation error by updating , ,

Monitoring the Changing Point by ELM
The structure of ELM is shown in Figure 2.
, … … and {ℎ input layer and hidden layer of the ELM, respectively, and the weigh random values. { , … … } represents the weights between the hi put layer and can be obtained mathematically. We use the ELM to build the health index (HI) of a LiB to dete point. First, we use the LiB degradation data in the first phase to train degradation feature of LiB in the first phase is learned by the ELM. Th is used to perform one-step prediction for the LiB that is working. T with the following formula: where : = ( , … … ) is the output of the trained ELM and is the real degradation data of the LiB. Because the trained ELM has l tion feature of LiB in the first phase, if the input is the data from th output will deviate significantly from normal, and the HI will be la construct the evaluation index of HI to adaptively detect the changin the evaluation index is as follows: We use the ELM to build the health index (HI) of a LiB to determine the changing point. First, we use the LiB degradation data in the first phase to train the ELM so that the degradation feature of LiB in the first phase is learned by the ELM. Then, the trained ELM is used to perform one-step prediction for the LiB that is working. The HI is constructed with the following formula: where Y 1:m = (y 1 , y 2 . . . . . . y m ) is the output of the trained ELM and X 1: is the real degradation data of the LiB. Because the trained ELM has learned the degradation feature of LiB in the first phase, if the input is the data from the second phase, the output will deviate significantly from normal, and the HI will be larger. Therefore, we construct the evaluation index of HI to adaptively detect the changing point. The form of the evaluation index is as follows: In the degradation model of Equation (1), X(t) is normally distributed; thus, we assume that HI is also normally distributed. Therefore, we use the '3σ criterion' in a normal distribution to detect the changing point. When we obtain the new data x m+1 , its HI is hi m+1 . If hi m+1 / ∈ [mean H I 1:m − 3sigma H I 1:m , mean H I 1:m + 3sigma H I 1:m ], x m+1 will be classified as suspicious data. Let the number of inputs of ELM be n; when all of the data from x m+1 . to x m+n . are suspicious data, we judge that LiB has entered the second degradation phase starting from data x m+1 . Therefore, we mark the changing time as τ = m + 1. Because the one-step prediction of ELM is precise, we can always detect the changing point accurately.

Updating the Drift Coefficient by Bayesian Theory
We know from Section 2 that the µ 1 and µ 2 in TPWPM are random variables with distributions of µ 1 ∼ N µ 1p , σ 2 1p and µ 2 ∼ N µ 2p , σ 2 2p , respectively. However, for a specific LiB, µ 1 and µ 2 are a certain number. Therefore, for a working LiB, we use Bayesian theory to update its µ 1 and µ 2 adaptively to determine the estimation of µ 1 and µ 2 as accurately as possible.
When the current time t m is below τ, we update the distribution parameters of µ 1 . When t m > τ, we update the distribution parameters of µ 2 . The updating formula is as follows: When t m < τ: where µ 1p,m and σ 2 1p,m are the posterior estimations of µ 1p and σ 2 1p , respectively; µ 1p,0 and σ 2 1p,0 are obtained from offline estimation and are the a priori estimations of µ 1p and σ 2 1p , respectively; T 1:m = (t 1 , t 2 . . . . . . t m ) is the time of degradation data X 1:m ; and is the covariance matrix of X 1:m .
When t m > τ : where µ 2p,m and σ 2 2p,m are the posterior estimations of µ 2p and σ 2 2p , respectively; µ 2p,0 and σ 2 2p,0 are obtained from offline estimation and are the a priori estimations of µ 2p and σ 2 2p , respectively; T τ:m = (τ, τ + 1 . . . t m ) is the time of degradation data X τ:m ; and is the covariance matrix of X τ:m . The proofs of Equations (14) and (15) are shown in Appendix B. Based on Equations (14) and (15) and the method proposed in Section 4.2.1, we can describe accurate and adaptive RUL prediction of a working LiB. According to the method shown above, we provide the procedure of our algorithm in Table 1. Table 1. Implementation procedures of remaining useful life (RUL) estimation for LiB.
Use the offline estimation method in Section 4.1 to obtain the priori estimation of parameters.
Train the ELM using the LiB degradation data from the first phase.
Online estimation begins; obtain new degradation data of LiB.
Step 4. Construct the health index (HI) using the trained ELM from Step 2 and the new data from Step 3.
Use the evaluation index in Equation (13) and the HI from Step 4 to judge whether a changing point is coming or not.
If a changing point appears, update the parameters in the second phase with Equation (15); otherwise, update the parameters in the first phase with Equation (14).
If a changing point appears, calculate the RUL of LiB with Equation (8); otherwise, calculate the RUL of LiB with Equation (7).
If the current LiB degradation data reaches the failure threshold, the algorithm ends; otherwise, loop the algorithm from Step 3.

Case Study
To verify the accuracy of the proposed algorithm, we provide two examples: (1) A numerical example with data created by a computer and (2) a practical example with data from [27][28][29].
If a changing point appears, calculate the RUL of LiB with Equa culate the RUL of LiB with Equation (7).
If the current LiB degradation data reaches the failure threshol otherwise, loop the algorithm from Step 3

Case Study
To verify the accuracy of the proposed algorithm, we provide numerical example with data created by a computer and 2) a practic from [27][28][29].

Numerical Example
Because we cannot know the real parameters of realistic LiB d used a computer to stimulate the degradation data of the TPWPM Then, we used these data to verify the online parameter estimation a method. These parameters were set as follows: = 0.005; 10 ; = 4.5 × 10 ; = 1 × 10 ; = 3 × 10 ; = 140; and and are the parameters of changing time , and ~( , 1/ ). of data, and there were 300 data points in each set. The data we ob Figure 3. First, we used the ELM, which is shown in Section 4.2.1, to detect the changing point. The input dimensions and hidden nodes are important for ELM: Too many input dimensions will cause long time delays for changing point detection, and too many hidden nodes may cause overfitting. Therefore, to determine the number of input dimensions and hidden nodes in the ELM, we performed experiments with different numbers of input dimensions and hidden nodes, and used the relative error of changing time estimation (RECTE) to evaluate them. The formula of RECTE is as follows: where τ real and τ detection are the real changing time and the changing time detected by the ELM, respectively, and q is the number of changing times detected by the ELM. For τ ∼ Ga(140, 1), p(τ ≤ 100) ≈ 0.01%, which indicates that the probability of the degradation data from time 1 to 100 belonging to the first phase is 99.99%. Therefore, we used the data from time 1 to 100 to train the ELM, and the number of trained sets was 70.
To reduce the randomness of the experiment and prove the robustness of our method, we performed 100 experiments for the same input dimensions and hidden nodes. Then, we took the mean RECTE of 100 trials as the final RECTE. The final RECTE is shown in Figure 4.
ics 2021, 10, 540  Figure 4 shows that when we choose five hidden nodes and the RECTE is the smallest. However, the RECTE of three input dim den nodes is near the RECTE of five input dimensions and five h fewer input dimensions there are, the shorter the delay of changing fore, it is better to choose three input dimensions and four hidd structure.
Then, to prove the robustness of changing point detection, w data using the parameters shown above and used the ELM with t and four hidden nodes to detect the changing point. We created a to train the ELM, and 1000 sets of data were used as test data. We viation between the detection time and real time of the changing   Figure 4 shows that when we choose five hidden nodes and five input dimensions, the RECTE is the smallest. However, the RECTE of three input dimensions and four hidden nodes is near the RECTE of five input dimensions and five hidden nodes; thus, the fewer input dimensions there are, the shorter the delay of changing point detection. Therefore, it is better to choose three input dimensions and four hidden nodes for the ELM structure.
Then, to prove the robustness of changing point detection, we created 1000 sets of data using the parameters shown above and used the ELM with three input dimensions and four hidden nodes to detect the changing point. We created another 100 sets of data to train the ELM, and 1000 sets of data were used as test data. We used the detection deviation between the detection time and real time of the changing point to evaluate the accuracy of the ELM. The probability of each detection deviation is shown in Figure 5. Then, we compared the proposed method with Zhang's method [20], and the results shown in Figure 5 indicate that the proposed method for detecting the changing point is more efficient and accurate. The viation between the detection time and real time of the changing point to evaluate the accuracy of the ELM. The probability of each detection deviation is shown in Figure 5. Then, we compared the proposed method with Zhang's method [20], and the results shown in Figure 5 indicate that the proposed method for detecting the changing point is more efficient and accurate. The mean relative error of our method for detecting the changing point is about 4%. Compared with Figure 5b, the result of our method shows a strong robustness. To update other parameters in real time, we created a set of degradation data, as shown in Figure 6. The real parameters of the data shown in Figure 6  To update other parameters in real time, we created a set of degradation data, as shown in Figure 6. The real parameters of the data shown in Figure 6 are defined as follows: µ 1,sample = 0.0059; µ 2,sample = 0.0202; σ 2 1,sample = 1 × 10 −4 ; σ 2 2,sample = 3 × 10 −4 ; and τ sample = 128. Then, we used (14) and (15) to update the parameters, and the initial values were calculated using 20 samples created in N µ 1p , σ 2 1p and N µ 2p , σ 2 2p : µ sample,1p,0 = 0.0053; µ sample,2p,0 = 0.0206; σ sample,1p,0 = 1.1 × 10 −3 ; and σ sample,2p,0 = 5.5 × 10 −3 . Then, we used the data in Figure 6 to estimate the parameters in real time. The process of parameter updating is shown in Figure 7.   parameter updating, and move closer to , and , , resp and also decrease, which indicates that and become increasingly The changing time we obtained is 126, and its deviation with is 2. There proposed method of parameter online estimation is efficient and precise.

Practical Example
We used the model shown in Equation (1) to predict the RUL of real LiBs a the method described in Section 4 to estimate the parameter of these real LiBs. the algorithm procedure shown in Table 1, we used realistic LiB degradation d the Center for Advanced Life Cycle Engineering (CALCE) of Maryland Univer lege Park, MD, USA [27][28][29] (CS2-35, CS2-36, CS2-37, and CS2-38) to perform a experiment. The cell chemistry of these LiBs is as follows: LiCoO2 cathode, and ED also showed trace elements of manganese. Each of these LiBs has a capacity of 1 and they underwent the same charging profile, which was a standard cons rent/constant voltage protocol with a constant current rate of 0.5 C until the reached 4.2 V and then 4.2 V was sustained until the charging current dropped 0.05 A. The discharge cut off voltage for these batteries was 2.7 V. Each LiB w multiple times under the above conditions, and each cycle was about 30 h. All th were randomly numbered and named accordingly. The realistic LiB degradation  Figure 7 shows that as increasingly more degradation data are considered during parameter updating, µ 1p and µ 2p move closer to µ 1,sample and µ 2,sample , respectively. σ 1p and σ 2p also decrease, which indicates that µ 1p and µ 2p become increasingly certain. The changing time we obtained is 126, and its deviation with τ sample is 2. Therefore, the proposed method of parameter online estimation is efficient and precise.

Practical Example
We used the model shown in Equation (1) to predict the RUL of real LiBs and used the method described in Section 4 to estimate the parameter of these real LiBs. Based on the algorithm procedure shown in Table 1, we used realistic LiB degradation data from the Center for Advanced Life Cycle Engineering (CALCE) of Maryland University, College Park, MD, USA [27][28][29] (CS2-35, CS2-36, CS2-37, and CS2-38) to perform a practical experiment. The cell chemistry of these LiBs is as follows: LiCoO 2 cathode, and EDS results also showed trace elements of manganese. Each of these LiBs has a capacity of 1350 mAh and they underwent the same charging profile, which was a standard constant current/constant voltage protocol with a constant current rate of 0.5 C until the voltage reached 4.2 V and then 4.2 V was sustained until the charging current dropped to below 0.05 A. The discharge cut off voltage for these batteries was 2.7 V. Each LiB was cycled multiple times under the above conditions, and each cycle was about 30 h. All these cells were randomly numbered and named accordingly. The realistic LiB degradation data are shown in Figure 1. We eliminated the trend items of these data, and the results are shown in Figure 8. Figure 8 shows that the random items of the LiB are not monotonous; thus, we cannot use the inverse Gaussian process [17,18] or the gamma process [19] to describe the degradation of LiB. Then, based on the offline parameter estimation method shown in Section 4.1, we used the data in CS2-35, CS2-36, CS2-37, and CS2-38 to estimate the offline parameters of CS2-35, CS2-36, CS2-37, and CS2-38, respectively, which are shown in Table 2.
To demonstrate the efficiency of the proposed method for τ detection, we regarded the parameters of CS2-36, CS2-37, and CS2-38 as prior estimations, and the parameters of CS2-35 were estimated by the proposed online method. Then, we used the RECTE shown in Equation (16) to evaluate the performance of the ELM with different structures. We used the history degradation data of CS2-36, CS2-37, and CS2-38 to obtain the RECTE of ELM with different structures. The degradation data of CS2-36 in the first phase were used to train the ELM, and the degradation data of CS2-37 and CS2-38 were used to construct the HI and detect the changing point. The RECTE of different ELM are shown in Figure 9. shown in Figure 1. We eliminated the trend items of these data, and the results are shown in Figure 8.  Figure 8 shows that the random items of the LiB are not monotonous; thus, we cannot use the inverse Gaussian process [17,18] or the gamma process [19] to describe the degradation of LiB. Then, based on the offline parameter estimation method shown in Section 4.1, we used the data in CS2-35, CS2-36, CS2-37, and CS2-38 to estimate the offline parameters of CS2-35, CS2-36, CS2-37, and CS2-38, respectively, which are shown in Table 2. To demonstrate the efficiency of the proposed method for detection, we regarded the parameters of CS2-36, CS2-37, and CS2-38 as prior estimations, and the parameters of CS2-35 were estimated by the proposed online method. Then, we used the RECTE shown in Equation (16) to evaluate the performance of the ELM with different structures. We used the history degradation data of CS2-36, CS2-37, and CS2-38 to obtain the RECTE of ELM with different structures. The degradation data of CS2-36 in the first phase were used to train the ELM, and the degradation data of CS2-37 and CS2-38 were used to construct the HI and detect the changing point. The RECTE of different ELM are shown in Figure 9.   Figure 9. RECTE of ELM with different input dimensions and hidden nodes. Figure 9 shows that the RECTE of ELM with four input dimensions and six hidden nodes is the smallest; therefore, we chose this type of ELM to detect the changing point. Then, we began the real-time estimation using the degradation data of CS2-35. The degradation data of CS2-36, CS2-37, and CS2-38 in the first phase were used to train the ELM with four input dimensions and six hidden nodes. With the trained ELM, we used Equa-  Figure 9 shows that the RECTE of ELM with four input dimensions and six hidden nodes is the smallest; therefore, we chose this type of ELM to detect the changing point. Then, we began the real-time estimation using the degradation data of CS2-35. The degradation data of CS2-36, CS2-37, and CS2-38 in the first phase were used to train the ELM with four input dimensions and six hidden nodes. With the trained ELM, we used Equation (12) to construct the HI of CS2-35, and the HI at different times is shown in Figure 10.  Figure 9 shows that the RECTE of ELM with four input dimensions and six hidden nodes is the smallest; therefore, we chose this type of ELM to detect the changing point. Then, we began the real-time estimation using the degradation data of CS2-35. The degradation data of CS2-36, CS2-37, and CS2-38 in the first phase were used to train the ELM with four input dimensions and six hidden nodes. With the trained ELM, we used Equation (12) to construct the HI of CS2-35, and the HI at different times is shown in Figure 10. With the obtained HI, we could determine the position of by the evaluation index shown in Equation (13), and we found that = 62 cycles, which is the same as the offline estimation of . Therefore, the estimation of shows that the proposed method is accurate. Based on , we could update the distribution parameters of the drift coefficients ~( , , , ) and ~( , , , ) with Equations (14) and (15), and these results are shown in Figure 11. With the obtained HI, we could determine the position of τ by the evaluation index shown in Equation (13), and we found that τ = 62 cycles, which is the same as the offline estimation of τ. Therefore, the estimation of τ shows that the proposed method is accurate. Based on τ, we could update the distribution parameters of the drift coefficients µ 1 ∼ N µ 1,p , σ 2 1,p and µ 2 ∼ N µ 2,p , σ 2 2,p with Equations (14) and (15), and these results are shown in Figure 11. µ 1,p and µ 2,p in Figure 11 change with the degradation data, which shows that the proposed method of parameter updating has a fast response to the arrival of new degradation data. Conversely, when more degradation data are considered in the process of parameter updating, σ 2 1,p and σ 2 2,p decrease, which shows that the more degradation data we obtain, the more accurate the estimation of µ 1 and µ 2 will be. Then, based on the results of Figures 10 and 11, we used Equations (7)- (9) to predict the RUL of CS2-35. We assumed that when the lost capacity of CS2-35 arrives at 0.75 Ah, the RUL of CS2-35 becomes 0. Therefore, according to the degradation data shown in Figure 1, the real lifetime of CS2-35 is 85 cycles. To demonstrate the accuracy of the proposed method, the methods of Razavi et al. [12], Li et al. [21], and Zhang et al. [20] were compared, and the results of the RUL prediction are shown in Figure 12. Figure 12a shows that the proposed method for detecting the changing point can provide the real-time performance. As soon as the ELM detects the arrival of a changing point, the proposed model enters the second degradation phase so that the RUL prediction becomes much more accurate. The changing time of CS2-35 is much earlier than the others shown in Table 2, and when we predict the RUL of CS2-35 before the arrival of the changing time, we can only estimate the changing time of CS2-35 based on the changing time of the others. Therefore, it is inevitable that there is a relatively large error of the RUL in the first phase. , and , in Figure 11 change with the degradation data, which shows that the proposed method of parameter updating has a fast response to the arrival of new degradation data. Conversely, when more degradation data are considered in the process of parameter updating, , and , decrease, which shows that the more degradation data we obtain, the more accurate the estimation of and will be. Then, based on the results of Figures 10 and 11, we used Equations (7)- (9) to predict the RUL of CS2-35. We assumed that when the lost capacity of CS2-35 arrives at 0.75 Ah, the RUL of CS2-35 becomes 0. Therefore, according to the degradation data shown in Figure 1, the real lifetime of CS2-35 is 85 cycles. To demonstrate the accuracy of the proposed method, the methods of Razavi et al. [12], Li et al. [21], and Zhang et al. [20] were compared, and the results of the RUL prediction are shown in Figure 12. , and , in Figure 11 change with the degradation data, which shows that the proposed method of parameter updating has a fast response to the arrival of new degradation data. Conversely, when more degradation data are considered in the process of parameter updating, , and , decrease, which shows that the more degradation data we obtain, the more accurate the estimation of and will be. Then, based on the results of Figures 10 and 11, we used Equations (7)- (9) to predict the RUL of CS2-35. We assumed that when the lost capacity of CS2-35 arrives at 0.75 Ah, the RUL of CS2-35 becomes 0. Therefore, according to the degradation data shown in Figure 1, the real lifetime of CS2-35 is 85 cycles. To demonstrate the accuracy of the proposed method, the methods of Razavi et al. [12], Li et al. [21], and Zhang et al. [20] were compared, and the results of the RUL prediction are shown in Figure 12.  Figure 12a shows that the proposed method for detecting the changing point can provide the real-time performance. As soon as the ELM detects the arrival of a changing point, the proposed model enters the second degradation phase so that the RUL prediction becomes much more accurate. The changing time of CS2-35 is much earlier than the others shown in Table 2, and when we predict the RUL of CS2-35 before the arrival of the changing time, we can only estimate the changing time of CS2-35 based on the changing time of the others. Therefore, it is inevitable that there is a relatively large error of the RUL in the first phase. Figure 12b shows the RUL at different times obtained by different methods. To demonstrate the improved accuracy of RUL prediction due to the proposed changing point detection method, we used the mean error of RUL prediction (MERULP) to evaluate the accuracy of these methods in the second degradation phase. The calculation of MER-ULP is as follows: where is the th real RUL in Figure 12b and is the th RUL prediction value of different methods. There is a large error when we use Li's method to obtain the RUL prediction, which shows that the linear Wiener model cannot describe the degradation path of LiB. Although the RUL prediction obtained by Razavi's method appears better than the result of Li's method, there is a drawback that the RUL prediction of Razavi's method cannot be obtained early in the degradation path. This phenomenon can be attributed to the degradation speed being too slow for the ELM early in the degradation path. Therefore, the ELM is likely to create a negative degradation speed so that the degradation data can never arrive at the failure threshold. Compared to the two-phase Wiener model of Zhang, the proposed method yields a better performance in the second degradation phase due to the proposed changing point detection method.
To describe the error in the RUL prediction visually, we show the difference between the RUL prediction and the real RUL at different times in Figure 12c, which demonstrates  Figure 12b shows the RUL at different times obtained by different methods. To demonstrate the improved accuracy of RUL prediction due to the proposed changing point detection method, we used the mean error of RUL prediction (MERULP) to evaluate the accuracy of these methods in the second degradation phase. The calculation of MERULP is as follows: where RUL real i is the ith real RUL in Figure 12b and RUL predict i is the ith RUL prediction value of different methods. There is a large error when we use Li's method to obtain the RUL prediction, which shows that the linear Wiener model cannot describe the degradation path of LiB. Although the RUL prediction obtained by Razavi's method appears better than the result of Li's method, there is a drawback that the RUL prediction of Razavi's method cannot be obtained early in the degradation path. This phenomenon can be attributed to the degradation speed being too slow for the ELM early in the degradation path. Therefore, the ELM is likely to create a negative degradation speed so that the degradation data can never arrive at the failure threshold. Compared to the two-phase Wiener model of Zhang, the proposed method yields a better performance in the second degradation phase due to the proposed changing point detection method.
To describe the error in the RUL prediction visually, we show the difference between the RUL prediction and the real RUL at different times in Figure 12c, which demonstrates that the RUL prediction of the proposed method is markedly better than those of the other methods in the second degradation phase. Based on Table 2, the changing time of CS2-35 is 62 cycles; thus, we started the calculation of MERULP at 62 cycles. The results of MERULP are shown in Table 3. Table 3 demonstrates that, due to the proposed changing point detection method, the accuracy of the RUL prediction in the second phase improves considerably. Overall, based on the results of the numerical and practical experiments, both the theoretical and practical results of the proposed method have been explained explicitly.
The data created by the computer and the practical data were used to prove the validity of our method, which means the robustness of our method is good. The high accuracy of the proposed method for RUL prediction and changing point detection has been demonstrated, highlighting the ability of the proposed method to be applied in practical engineering.

Conclusions
This paper primarily considers the changing point detection and RUL prediction of the two-phase Wiener process model (TPWPM) for LiBs. We used ELM to construct the HI of a LiB and detect the changing point of the LiB by the HI. Then, based on the concept of FPT, we obtained the PDF of the RUL of the LiB and determined its formula. Finally, we investigated numerical and practical cases to determine the theoretical and practical results of the proposed method. Based on a comparison with other methods, the higher accuracy of the proposed method has been demonstrated. The error of our method for detecting the changing point is about 4% and the mean prediction error of RUL in the second phase is improved from 4.39 cycles to 1.61 cycles. However, there are several directions for future research: (1) The accuracy of RUL prediction in the first degradation phase must be improved.
(2) The accuracy of changing point detection could be improved.

Conflicts of Interest:
The authors declare no conflict of interest.

Appendix A. Proof of Theorem 1
Let W n be the waiting time of the nth degradation data, F W n (t) be the cumulative distribution function (CDF) of W n , and f W n (t) be the PDF of W n . We assume that the number of degradation data points during time t is N(t) and that N(t) obeys the Poisson distribution with parameter λ. We can thus obtain the following formula: Then, the derivation of F W n (t) is as follows: f W n (t) = F W n (t) = λe −λt (λt) n−1 (n − 1)! (A2) If we assume that there are n degradation data points before the changing point, the changing time τ will be the same as W n . Therefore, we can obtain the PDF of τ as follows: p(τ) = f W n (t) = λe −λt (λt) n−1 (n − 1)! (A3) where τ ∼ G(n, 1/λ), where G(n, 1/λ) is a gamma distribution with parameters n and 1/λ. Therefore, the proof of Theorem 1 is complete.