Lithium ion battery health state estimation method based on time-frequency domain feature decoupling and dynamic compensation mechanism
Through time-frequency domain feature decoupling and dynamic compensation mechanism, combined with 2D convolutional neural network and cross attention mechanism, the multi-physics field coupling problem in lithium-ion battery health state estimation is solved, and high-precision and robust SOH prediction is achieved.
Patent Information
- Application Number
- CN202510755241.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-06
- Publication Date
- 2025-10-17
AI Technical Summary
Existing lithium-ion battery health status estimation methods have limitations in time-frequency feature decoupling and dynamic compensation, making it difficult to effectively capture the multi-physical field coupling effects within the battery. In particular, characteristic signal confusion and overfitting in high-noise scenarios lead to insufficient model generalization and accuracy.
Through the decoupling of time-frequency domain features and dynamic compensation mechanism, combined with the time-frequency characteristics of battery operation data, and using 2D convolutional neural networks and cross-attention mechanism, a lithium-ion battery health status estimation model is constructed to achieve accurate modeling of battery capacity degradation and internal state.
The accuracy and robustness of lithium-ion battery health status estimation have been significantly improved, especially under complex working conditions, with an error of less than 2%. This has broken through the limitations of traditional methods and increased sensitivity to early micro-degradation and noise resistance.
Smart Images

Figure CN120802037A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of lithium ion battery health management, and in particular to a lithium ion battery state of health estimation method based on time-frequency domain feature decoupling and dynamic compensation mechanism. BACKGROUND
[0002] As the core power source in the fields of electric vehicles, energy storage systems, etc., the precise estimation of the state of health (SOH) of lithium ion batteries is directly related to the safety, economy and reliability of the equipment. Currently, SOH prediction mainly relies on time-domain operation data (such as voltage, current time series curve) to construct degradation models. However, the performance degradation of the battery is essentially the result of the coupling of internal electrochemical characteristics (such as active lithium ion loss, electrode material phase change) and external dynamic working conditions (such as charge-discharge rate, temperature fluctuation). Traditional methods face significant limitations: on the one hand, time-domain signals are not sensitive enough to early micro-degradation (such as SEI film growth, lithium deposition), and are easily disturbed by high-frequency noise, leading to a decrease in model generalization under complex working conditions; on the other hand, although frequency-domain data (such as electrochemical impedance spectroscopy, noise spectrum) can reflect the internal impedance characteristics and side reaction process of the battery, existing technologies lack effective decoupling and dynamic compensation mechanisms for time-frequency features, making it difficult to achieve deep fusion of cross-domain information. In addition, existing deep learning methods are mostly based on single domain features or shallow feature concatenation, and cannot model the nonlinear coupling relationship between time-frequency feature signals, especially in high-noise scenarios, which easily leads to feature signal confusion and overfitting.
[0003] Therefore, there is a need for an SOH estimation method that can cooperatively mine multi-dimensional degradation features in the time-frequency domain, explicitly decouple the coupling effects of multiple physical fields, and has anti-interference robustness, to meet the high-precision and high-reliability requirements under dynamic working conditions. SUMMARY
[0004] The present application proposes a lithium ion battery state of health (SOH) estimation method based on time-frequency domain feature decoupling and dynamic compensation mechanism. This method fuses time-domain signals (such as voltage, current) and frequency-domain features (such as impedance spectrum, noise spectrum) in battery operation, combines decoupling feature extraction and time-frequency compensation learning mechanism, and realizes accurate modeling of battery capacity degradation and internal state evolution, which can be applied to battery health monitoring and life prediction of electric vehicles, energy storage systems and consumer electronic devices.
[0005] The technical solution adopted by the present application is as follows: The lithium ion battery state of health estimation method based on time-frequency domain feature decoupling and dynamic compensation mechanism comprises the following steps: Step 1: Collect the actual data of multiple charge-discharge of lithium ion batteries as the initial data set; Step 2: Feature modal decomposition is performed on the initial data set to obtain frequency domain data by decoupling; Step 3: The decoupled frequency domain data and the original time domain data obtained in step 2 are input into the trained model to obtain the predicted lithium ion battery capacity. Step 4: The real-time capacity and maximum capacity of the lithium ion battery are fed back to the trained model, and after training, the predicted value of the capacity is obtained, realizing the estimation of the state of health of the lithium ion battery.
[0006] Step 5: Based on the results predicted by the trained model, the Mean Absolute Error (MAE), Root Mean Square Error (RMSE), and Coefficient of Determination (R2) are used to evaluate the results.
[0007] In step 2, the feature modal decomposition of the initial data set includes the following steps: S2.1. Frequency band segmentation and filter initialization: The frequency band is uniformly divided into CutNum sub-bands, and the normalized frequency boundary of the initial data set is: (1); In equation (1), represents the normalized starting frequency boundary of the sub-band; represents the number of frequency band segmentation; represents the normalized sub-band bandwidth; represents the bandwidth of two sub-bands; A Hanning window FIR filter is designed for each sub-band: (2); In equation (2), represents the Hanning window coefficient; represents generating a Hanning window of length FilterSize and returning it as a column vector; FilterSize represents the filter order; represents the filter coefficient corresponding to the nth sub-band; represents the current sub-band number; represents the normalized frequency passband lower limit; represents the normalized frequency passband upper limit; represents the normalized passband boundary; ; Represents the MATLAB repeated matrix function: Repeat once in the row direction and CutNum times in the column direction; Time domain data representing the initial data; Indicates the battery n Charge and discharge times; represents the candidate modal signal matrix.
[0008] S2.2. Initial mode extraction based on MCKD algorithm: Objective function: Maximize Correlated Kurtosis (CK): (3); In formula (3), Indicates the length of the initial data set; is the number of time shifts, indicating that the multi-cycle delay product of the signal is considered when calculating the correlation kurtosis; is a discrete time index, indicating the first Sampling points, the value range is 1 ≤ ≤ ; is the time-shift index variable, with a value range of 0 ≤ ≤ , used to calculate the signal product under different delays; is the interval period of periodic shocks in the initial dataset; Indicates output signal At the time point The value at It is time domain data The deconvolution output signal after filter processing; The calculation of the MCKD algorithm includes the following steps: a1: Signal delay construction: Constructing the delay matrix , time domain data containing initial data and its delay T, 2T, …, MT by M samples; (4); In formula (4), Represents a multi-channel delayed signal matrix; is a discrete time index, indicating the first Sampling points, the value range is 1 ≤ ≤ ; is the time-shift index variable, with a value range of 0 ≤ ≤ , for computing signal products at different delays; denotes the value of the mTsample points before the time point t in the time domain data ; is the interval period of the periodic impact in the initial data set; a2: iteratively update filter coefficients: output signal: (5); in equation (5), is the time domain data after filter processing; denotes the transpose of the filter coefficient vector.
[0009] kurtosis gradient calculation: update the filter through the product term : (6); in equation (6), denotes the new filter coefficient vector; ; wherein, denotes the first channel slice of the three-dimensional delay signal matrix; denotes the transpose of the first channel slice of the three-dimensional delay signal matrix.
[0010] ; wherein, denotes the product term; denotes the initial data set length; is a discrete time index, denoting the thsample point of the signal, with a value range of 1 ≤ ≤ ; ; wherein, denotes the weighted delay input matrix; is the number of time shifts, indicating the multi-period delay product of the signal when calculating the correlation kurtosis; is an index variable of the time shift, with a value range of 0 ≤ ≤ , for computing signal products at different delays; denotes the m+1channel slice of the three-dimensional delay signal matrix; ; wherein, denotes the diagonal weight matrix; denotes taking the diagonal elements of the matrix.
[0011] a3: Period T adaptive update of the initial data set: The period is estimated by Hilbert transform of the signal envelope as follows: step1: Yes Perform Hilbert transform and calculate the envelope signal ; (7); In formula (7), is the Hibert transform operator, is the mean operation; Express Perform Hilbert transform.
[0012] Step 2: Through the envelope signal Autocorrelation function of the initial period ; (8); In formula (8), Indicates signal The autocorrelation function of is the delay parameter, indicating The position compared with itself after being shifted on the time axis; Represents the envelope signal exist The value of the moment; Indicates the length of the initial data set; Calculated After that, find the first one that satisfies and of ,in, Indicated in time The value of Indicated in time The value of Represents the autocorrelation function The first zero crossing position of Again Find the largest , while taking When the maximum value value, let for , the formula is as follows: (9); In formula (9), represents the initial period estimate; Represents the autocorrelation function The first zero crossing position of Indicates the independent variable corresponding to the maximum value of the function; Representation function The independent variable corresponding to the maximum value; step3: Define search scope within a field , Represents the search radius; use formula (3) to calculate all candidate cycles in the range The CK value formula is as follows: (10); In formula (10), Indicates CK value at the time point; Indicates output signal At the time point The value at Indicates the length of the initial data set; is the number of time shifts, indicating that the multi-cycle delay product of the signal is considered when calculating the correlation kurtosis; is the time-shift index variable, with a value range of 0 ≤ ≤ , used to calculate the signal product under different delays; Step 4: Select the cycle that maximizes the CK value as the optimization result: (11); In formula (11), represents the newly generated period estimate; Representation function The independent variable corresponding to the maximum value; like , then update the cycle parameters ; Step 5: Iterative convergence: Repeat step 3 and step 4 until one of the following conditions is met: ①. (12); ②. Reach the maximum number of iterations in: is the convergence threshold; S2.3. Modal iterative selection, specifically including the following steps: b1: Calculate the correlation coefficient matrix: (13); In formula (13), represents the correlation coefficient moment; represents the Pearson correlation coefficient matrix of every two columns of the matrix temp_sig; is a MATLAB built-in function that calculates the Pearson correlation coefficient matrix, if the input is A (N x M), the output is a M x M symmetric matrix R, where R(i,j) ∈ [-1, 1]; represents the Pearson correlation coefficient matrix takes the absolute value; represents the upper triangular part of the Pearson correlation coefficient matrix, that is, the part where (j > i), where j is the column number, j = 1 is the first column, i is the row number, i = 1 is the first row, and the rest is set to 0.
[0013] b2: Select the most relevant modal pair: find the position of the largest correlation coefficient in the matrix (i, j), and calculate the CK value at and two positions using formula (3), and keep the one with the larger CK value.
[0014] where: represents the i-th column of ; represents the j-th column of .
[0015] S2.4. Iterative update: Each time through S2.1~S2.3, a new is obtained, where c is S2.3 , that is, i or j.
[0016] Take the new as the new input signal, that is, use instead of as the input signal to perform the calculation of S2.1~S2.3 again. Each time the calculation is completed, the modal number M is reduced by one and the next iteration is performed. The above actions are repeated until the following conditions are met to stop the iteration: ①. The number of iterations ; ②. The CK value converges (14); where: represents the function CK iteration th time; represents the CK iteration -1th time; represents the number of iterations, =1 represents that one iteration is performed; is the number of times of iteration termination.
[0017] S2.5. Output the final mode: the column with the maximum CK value obtained by iteration is sequentially subjected to Hilbert transform, windowing, and Fourier transform to the frequency domain data , comprising the following steps: 1) Hilbert transform ; wherein: represents the envelope signal; is subjected to Hilbert transform; represents the value of the output signal at the time of iteration termination. 2) Windowing:
[0018] ; wherein: represents the output value obtained by windowing operation; represents the Hanning window coefficient; represents the current sub-band number; 3) Fourier transform: ; wherein: represents the Fourier transform performed on .
[0019] The step 3 comprises the following steps: S3.1. Input the frequency domain data obtained by decoupling and the initial time domain data into a 2D convolutional neural network for processing, specifically as follows: (15); In formula (15), represents the frequency domain data; is the i-th convolution kernel; represents the time domain data convolution result in the time domain of all channels; represents the time domain data convolution result in the time domain of the i-th channel; represents the frequency domain data convolution result in the time domain of all channels; represents the frequency domain data convolution result in the frequency domain of the i-th channel; respectively represent the first channel to the i-th channel of the time domain data; respectively represent the first channel to the i-th channel of the frequency domain data; represents a channel; represents the total number of output channels in a convolution layer; represents a two-dimensional convolution layer in a convolutional neural network; represents two-dimensional convolution processing on time domain data; represents an activation layer in a convolutional neural network; represents nonlinear transformation on the product of time domain data and convolution kernel; represents two-dimensional convolution processing on frequency domain data; represents nonlinear transformation on the product of frequency domain data and convolution kernel; S3.2. Two groups of results output based on S3.1 and results output by the frequency domain data through the 2D-CNN model cross attention mechanism processing, the specific calculation of the cross attention mechanism is as follows: (16); In formula (16), represents the value of calculating attention output; is a query matrix, representing the features to be retrieved, ; represents transpose; represents query projection weight; is a key matrix, representing the features to be retrieved, ; represents transpose; represents key projection weight; is a value matrix, representing the actual value corresponding to the key, ; represents value projection weight; is the embedding dimension of the query and the key, ; represents the number of attention heads, which is a self-set parameter; represents the overall feature dimension of the model, which is a self-set parameter in the model; represents the transpose of the key matrix, i.e., the transpose of the features to be retrieved; represents a normalization layer, i.e., normalizing the input, the value is controlled within the interval (0, 1), i.e., normalizing ; (17); In formula (17), represents the output of the first attention head under represents the output of the i-th attention head under , and each head calculates attention independently; represents the value of the output of the linear transformation of the result of splicing all heads under represents data splicing, and the data of the first to h-th heads of the head are connected side by side in the last dimension; represents the projection matrix of the multi-head attention output, which projects the spliced multi-head output to the final dimension; represents the value of the attention output calculated by the i-th head under represents the value of the i-th channel of represents the value of the i-th channel of represents the value of the i-th channel of
[0020] (18); In formula (18), represents the data output after layer normalization processing; represents the layer normalization operation in deep learning; represents the layer normalization processing on the sum of and represents the data output after activation processing; represents the weight matrix of the first linear mapping in the feedforward sublayer; represents the weight matrix of the second linear mapping in the feedforward sublayer; represents the bias vector of the first linear mapping in the feedforward sublayer; represents the bias vector of the second linear mapping in the feedforward sublayer.
[0021] (19); In formula (19), cross-attention mechanism output data; represents the data output after layer normalization processing; represents the layer normalization processing on the sum of and The sum of the two is normalized by layer; At the same time of processing the frequency domain data, the result output by the 2D-CNN model from the time domain data The processing of the multi-head 1D-CNN is carried out separately.
[0022] The specific calculation content is as follows: (20); In formula (20): represents the result of convolution calculation output; represents the pair of Two-dimensional convolution processing is carried out.
[0023] (21); In formula (21): represents the two-dimensional batch normalization layer in the neural network; represents the data after normalization processing. (22); In formula (22): ReLU represents the activation layer in the neural network; Z represents the data obtained after activation processing.
[0024] (23); In formula (23): represents the adaptive two-dimensional maximum pooling layer in the neural network; represents the data obtained after maximum pooling operation; (24); In formula (24): represents the reassignment of the dimension layout of the tensor under the premise that the element order remains unchanged; The data output after multi-head 1D-CNN processing; S3.3. The results output by the two paths are linearly added, that is, the and are linearly added, and the specific calculation steps are as follows: (25); In formula (25): represents the data obtained by adding the output results of the two paths; The data output by the cross-attention mechanism.
[0025] S3.4. The data linearly added is input into the transformer for processing, and the specific steps are as follows: The input of the multi-head self-attention mechanism is , whose calculation formula is: (26); In formula (26): represents the value of calculating attention output; represents a normalization layer, that is, the input is normalized, and the value is controlled in the interval (0, 1), that is, the value is normalized to ; (27); In formula (27): represents the data obtained by adding the output results of the two paths; represents the query projection weight; represents the key projection weight; represents the value projection weight; Still a query matrix, but its calculation is no longer as usual , but as shown in formula (27), that is, the calculation data is modified, and is replaced by ; Still a key matrix, but its calculation is no longer as usual , but as shown in formula (27), that is, the calculation data is modified, and is replaced by ; Still a value matrix, but its calculation is no longer as usual , but as shown in formula (27), that is, the calculation data is modified, and is replaced by .
[0026] The output of the multi-head self-attention mechanism is the splicing result of multiple attention heads, and is obtained through linear transformation: (28); (29); In formula (28) (29): represents the output of the first attention head under , , ; represents the output of the i-th attention head under , , , that is, each head calculates attention independently; represents the value of splicing all heads under , , and linearly transforming the output; denotes data concatenation, and the data of the first to the h-th head of denotes a projection matrix of multi-head attention output, and projects the concatenated multi-head output to the final dimension; denotes the value of the attention output calculated by the i-th head, denotes the value of the i-th channel of ; denotes the value of the i-th channel of ; denotes the value of the i-th channel of .
[0027] The output of the multi-head self-attention mechanism is added to the input feature, and layer normalization is performed: (30); In formula (30): denotes the data output after layer normalization processing; denotes the layer normalization operation in deep learning; denotes the sum of and .
[0028] The input of the feedforward neural network is , and its calculation formula is: (31); In formula (31): denotes the data output after activation processing; The output of the feedforward neural network is added to , and layer normalization is performed: (32); In formula (32): denotes the data output after layer normalization processing; denotes the sum of .
[0029] Formulas (26) to (32) are the calculation process of an encoder layer. In practice, 4 encoder layers are used, and the output of each encoder layer is used as the input of the next encoder layer: (34); In formula (34): denotes the data output after transformer training processing; denotes the data The output data is calculated once through formulas (26) to (32); Indicates that Then the output data is calculated through formulas (26) to (32); Indicates that Then the output data is calculated through formulas (26) to (32); Indicates that The output data is then calculated through formulas (26) to (32); in simple terms, the entire process is iterated four times.
[0030] S3.5. A regressor is used to transform the output of Transformer Mapped to predicted values, as follows: Directly take The last time step of is used as the capacity prediction value: (35); In formula (35): Indicates the predicted value of capacity; express The value of the last time step in ; In step 4: 4.1: Calculate predicted values using mean squared error (MSE) and the true value The loss function between them is calculated as follows: (37); In formula (37): Indicates the loss value; is the batch size; 4.3: Calculate the gradient of the loss function with respect to the model parameters. The calculation formula is as follows (38); In formula (38): represents the gradient of the parameter; are model parameters; 4.4: Use the optimizer to update the model parameters. The calculation formula is as follows (39); In formula (39): Represents the learning rate.
[0031] In the step 5, (40); (41); (42); In the above formula, is the sample number; wherein the smaller the MAE and RMSE, the better the model fitting effect, and the larger the R2, the better the model fitting effect.
[0032] The technical effects of the lithium ion battery health state estimation method based on time-frequency domain feature decoupling and dynamic compensation mechanism are as follows: 1) The present application breaks through the bottleneck of single data source by jointly analyzing time domain dynamic data (voltage, current time sequence) and frequency domain steady state data (impedance spectrum, noise spectrum), fully captures the multi-physical field coupling characteristics of the evolution of electrochemical characteristics, thermodynamic disturbance and mechanical stress response in the battery degradation process, and significantly improves the sensitivity of the model to early micro degradation (such as SEI film growth and active lithium loss).
[0033] 2) The present application designs a time-frequency feature compensation learning module, uses wavelet transform to perform multi-scale decomposition on frequency domain data, explicitly separates the contribution of charge transfer impedance (mid-frequency band) and diffusion impedance (low-frequency band), and introduces a cross-domain attention mechanism to dynamically allocate time-frequency feature weights, and compensate for the insufficient representation of time domain signals to weak degradation patterns. Experiments show that the prediction error of this method in the early stage of capacity attenuation (capacity loss <5%) is reduced by about 40% compared with traditional models.
[0034] 3) FMD is mainly used for mechanical fault extraction, and is rarely used for battery capacity prediction. Secondly, FMD decouples and separates multi-physical field coupling degradation characteristics through a dynamic compensation mechanism, solving the problem of insufficient sensitivity of traditional methods to micro degradation. Combined with time-frequency attention modeling and anti-noise training strategy, it realizes high-robust SOH prediction with an error of less than 2% under complex working conditions, and improves the accuracy of existing time domain models. The present application uses the algorithm for mechanical fault extraction, i.e. FMD (feature processing), in the field of electrical engineering, which has better feature extraction effect than traditional filters, and greatly improves the effect of subsequent training models.
[0035] 4) In step 3 of the present application, the influence of considering the comprehensiveness of separate input of frequency domain or time domain is considered, specifically: separate use of time domain or frequency domain data will cause the information dimension of battery health state estimation to be incomplete and the degradation mode to be misjudged. Through the time-frequency domain cooperative decoupling and compensation mechanism, the limitation of single data source is broken through, providing reliable technical support for high-precision SOH estimation under complex working conditions. BRIEF DESCRIPTION OF DRAWINGS
[0036] The present application will be further described below in conjunction with the drawings and examples: Figure 1 is the flow framework diagram of the entire training model.
[0037] Figure 2 Actual vs predicted battery capacity plot.
[0038] Figure 3 Loss plot during original model training.
[0039] Figure 4 Loss plot during improved model training.
[0040] Figure 5 Fitting index comparison plot for improved model vs model using traditional filter. DETAILED DESCRIPTION
[0041] The lithium-ion battery state of health estimation method based on time-frequency domain feature decoupling and dynamic compensation mechanism includes the following steps: based on frequency domain mode decomposition (FMD), the original operation data (voltage, current time series) of the battery are decoupled to extract frequency domain auxiliary data (such as SEI film impedance, lithium deposition noise spectrum) reflecting electrochemical degradation; a double-path feature fusion network is constructed, time domain dynamic features and frequency domain steady state features are extracted through convolution network respectively, and cross-domain feature adaptive compensation and fusion are realized through time-frequency cross attention module; a degradation dynamic modeling framework based on Transformer is designed, the long-range time series dependence relationship of capacity attenuation is captured by using multi-head self-attention mechanism, and high-precision state of health estimation results are output through a lightweight regressor.
[0042] The lithium-ion battery state of health estimation method based on time-frequency domain feature decoupling and dynamic compensation mechanism includes the following steps: Step 1: collect the actual data of multiple charge-discharge of lithium-ion battery as initial data set; Step 2: considering the influence of insufficient accuracy of current traditional filter (MEL filter, etc.), feature mode decomposition (Feature Mode Decomposition) is performed on the initial data set, and frequency domain data is obtained by decoupling; Step 3: considering the incomprehensiveness of inputting frequency domain or time domain alone, the frequency domain data obtained in step 2 and the original time domain data are input into the training model to obtain the single predicted lithium-ion battery capacity; Step 4: considering the poor results of single or limited number of calculations, the real-time capacity and maximum capacity of the lithium-ion battery are fed back to the training model, and the predicted value of the capacity is obtained after training to realize the estimation of the state of health of the lithium-ion battery.
[0043] Considering the impact of single or limited number of calculations, specifically: the training model parameters cannot be fully optimized through multiple backpropagation, which will lead to insufficient convergence and difficulty in capturing deep data features, while lacking a continuous learning mechanism, unable to dynamically correct the initial weight update, easily amplifying the impact of noise interference or data bias; parameter space exploration is limited during calculation, making it difficult to escape local optimal solution, especially in non-convex optimization problems; finally, the feature extraction level is shallow, making it difficult to build multi-layer nonlinear representation, limiting the modeling ability of complex patterns; such calculation paradigm is often forced to be adopted in real-time systems or resource-limited scenarios, but at the cost of model performance.
[0044] Step 5: Based on the results predicted by the trained model, use Mean Absolute Error (MAE), Root Mean Square Error (RMSE), and Coefficient of Determination (R2) to evaluate.
[0045] In step 2, the feature modal decomposition of the initial data set includes the following steps: S2.1. Frequency band segmentation and filter initialization: Divide the frequency band uniformly into CutNum subbands, and the boundary of the entire signal frequency band (initial data set) is normalized frequency: (1); In equation (1), denotes the normalized starting frequency boundary of the subband; denotes the number of frequency band segmentation; denotes the normalized subband bandwidth; denotes the bandwidth of two subbands; Design a Hanning window FIR filter for each subband: (2); In equation (2), denotes the Hanning window coefficient; denotes generating a Hanning window (Hanning Window) of length FilterSize and returning it as a column vector; FilterSize denotes the filter order, order = FilterSize-1; denotes the filter coefficient corresponding to the nth subband; denotes the current subband number; denotes the normalized frequency passband lower limit; represents the upper limit of the normalized frequency passband; represents the normalized passband boundary; , ; represents the MATLAB repeat matrix function: repeats 1 time in the row direction and CutNum times in the column direction; represents the time-domain data of the initial data; represents the first n time charging and discharging of the battery; represents the candidate modal signal matrix: each column is a copy of the same original signal, which is used for initialization for subsequent sub-band filtering and MCKD adaptive iteration.
[0046] S2.2. Initial modal extraction based on the MCKD algorithm: Objective function: maximize the correlated kurtosis (CK): (3); In equation (3), represents the length of the signal (initial data set); is the number of time shifts, indicating that the product of the multiple periods of the signal is considered when calculating the correlated kurtosis; is the discrete time index, representing the th sampling point of the signal, with a value range of 1≤ ≤ ; is the index variable of the time shift, with a value range of 0 ≤ ≤ , used to calculate the signal product under different delays; is the interval period of the periodic impact in the signal (initial data set); represents the value of the output signal at time point ; is the deconvolution output signal after filter processing of the time-domain data ; The calculation of the MCKD algorithm includes the following steps: a1: Signal delay construction: Construct a delay matrix containing M samples of the time-domain data of the initial data and its delays T, 2T, …, MT; (4); In equation (4), represents the multi-channel delay signal matrix; is a discrete time index representing the th sample point of the signal with the range 1 ≤ ≤ ; ; is an index variable for time shifts with the range 0 ≤ ≤ , used to calculate signal products at different delays; denotes the value of the mT sample points before the time point t in the time domain data ; is the period of the periodic impulse in the signal (initial data set); a2: iterative update of filter coefficients: output signal: (5); In equation (5), is the deconvolution output signal (frequency domain data) of the time domain data after filter processing; denotes the transpose of the filter coefficient vector.
[0047] Kurtosis gradient calculation: The filter is updated by the product term : (6); In equation (6), denotes the new filter coefficient vector; ; wherein denotes the first channel slice of the three-dimensional delay signal matrix, i.e. the first layer of the three-dimensional delay signal matrix, x and y in the three-dimensional data x, y, z represent the entire plane, z = 1; denotes the transpose of the first channel slice of the three-dimensional delay signal matrix.
[0048] ; wherein denotes the product term; denotes the length of the signal (initial data set); is a discrete time index representing the th sample point of the signal with the range 1 ≤ ≤ ; ; wherein denotes the weighted delay input matrix; is the number of time shifts, indicating the multi-period delay product of the signal when calculating the correlation kurtosis; is an index variable for time shifts with the range 0 ≤ ≤ , for calculating the signal product under different delays; represents the m+1 channel slice of the three-dimensional delay signal matrix, that is, the m+1 layer of the three-dimensional delay signal matrix (x and y in three-dimensional data x, y, z represent the entire plane, and z represents the delay); ; wherein, represents a diagonal weight matrix; takes the diagonal elements of the matrix, and sets the other elements to 0 except the diagonal elements; represents taking the diagonal elements of the matrix.
[0049] a3: signal (initial data set) period T adaptive update: The period is estimated by signal envelope Hilbert transform, as follows: step1: perform Hilbert transform on , and calculate the envelope signal ; (7); In formula (7), is a Hibert transform operator, is a mean operation; represents performing Hilbert transform on .
[0050] step2: obtain the initial period by the autocorrelation function of the envelope signal ; (8); In formula (8), represents the autocorrelation function of the signal ; is a time delay parameter, representing the comparison position of after shifting on the time axis; represents the value of the envelope signal at moment; represents the length of the signal (initial data set); After calculating , find the first that satisfies and , wherein, represents the value of at moment; represents the value of time The value of Represents the autocorrelation function The first zero crossing position of Again Find the largest , while taking When the maximum value value, let for , the formula is as follows: (9); In formula (9), represents the initial period estimate; Represents the autocorrelation function The first zero crossing position of Indicates the independent variable corresponding to the maximum value of the function; Representation function The independent variable corresponding to the maximum value; step3: Define search scope within a field , Represents the search radius; use formula (3) to calculate all candidate cycles in the range The CK value formula is as follows: (10); In formula (10), Indicates CK value at the time point; Indicates output signal At the time point The value at Indicates the length of the signal (initial data set); is the number of time shifts, indicating that the multi-cycle delay product of the signal is considered when calculating the correlation kurtosis; is the time-shift index variable, with a value range of 0 ≤ ≤ , used to calculate the signal product under different delays; Step 4: Select the cycle that maximizes the CK value as the optimization result: (11); In formula (11), represents the newly generated period estimate; Representation function The independent variable corresponding to the maximum value; like , then update the cycle parameters ; Step 5: Iteration convergence: Repeat Step 3 and Step 4 until one of the following conditions is met to stop the iteration: ①. (12); ②. Maximum iteration number is reached Wherein: is the convergence threshold; S2.3. Modal iteration selection, specifically including the following steps: b1: Calculate the correlation coefficient matrix: (13); In formula (13), represents the correlation coefficient matrix; represents the Pearson correlation coefficient matrix of each two columns of signals in the matrix temp_sig; is a MATLAB built-in function that calculates the Pearson correlation coefficient matrix. If the input is A (N × M), the output is an M × M symmetric matrix R, where R(i,j) ∈ [-1,1]; represents the Pearson correlation coefficient matrix Take the absolute value; represents taking the strictly upper triangular part of the Pearson correlation coefficient matrix with absolute value, i.e. the (j>i) part, where j is the column number, j=1 is the first column, i is the row number, i=1 is the first row, and the rest is set to 0.
[0051] 2) Select the most relevant modal pair: Find the position (i,j) of the largest correlation coefficient in the matrix, calculate the CK value at positions and and , and keep the one with the larger CK value.
[0052] Wherein: represents the i-th column of ; represents the j-th column of .
[0053] S2.4. Iterative update: Each time through S2.1~S2.3 calculation will get a new , wherein c is S2.3 the value that is kept, i.e. i or j.
[0054] The new As a new input signal, i.e. when iterating for the second time Instead of , the calculation of the three steps S2.1-S2.3 is performed again as an input signal, and each time one calculation is completed, the next iteration is performed after the modal number M is reduced by one, and the above actions are repeated until the iteration is stopped when the following conditions are met: ①. The number of iterations ; ②. CK value convergence (14); Wherein: Indicates the function CK iteration for the th time; Indicates the CK iteration for the -1th time; Indicates the number of iterations, =1 indicates that one iteration has been performed; Is the number of iteration termination, a self-set parameter, set to several, then stop iteration when iteration to the several times.
[0055] S2.5. Output the final mode: The largest column of CK values obtained by iterative calculation , in turn, Hilbert transform, windowing, Fourier transform to frequency domain data , including the following steps: 1) Hilber transform ; Wherein: Indicates the envelope signal; Hilbert transform is performed on ; Indicates the value of the output signal (frequency domain data) when the iteration is stopped.
[0056] 2) Windowing: ; Wherein: Indicates the output value obtained by windowing operation; Indicates the Hanning window coefficient; Indicates the current sub-band number; 3) Fourier transform: ; Wherein: Indicates the Fourier transform is performed on ; For Fourier transform operation, The step 3 includes the following steps: S3.1. The frequency domain data obtained by decoupling and the initial time domain data are input into a 2D convolution neural network for processing, specifically as follows: (15); In formula (15), represents frequency domain data; is the ith convolution kernel; represents time domain data convolution result in the time domain of all channels; represents time domain data convolution result in the time domain of the ith channel; represents frequency domain data convolution result in the time domain of all channels; represents frequency domain data convolution result in the frequency domain of the ith channel; respectively represent the first channel to the ith channel of the time domain data; respectively represent the first channel to the ith channel of the frequency domain data; represents a channel; represents the total number of output channels in the convolution layer; represents a two-dimensional convolution layer in the convolutional neural network; represents two-dimensional convolution processing on the time domain data; represents an activation layer in the convolutional neural network; represents a nonlinear transformation on the product of the time domain data and the convolution kernel; represents two-dimensional convolution processing on the frequency domain data; represents a nonlinear transformation on the product of the frequency domain data and the convolution kernel; S3.2. Based on the output of S3.1 Two groups of results and , the result output by the frequency domain data through the 2D-CNN model cross attention mechanism processing, the specific calculation of the cross attention mechanism is as follows: (16); In formula (16), represents the value of calculating attention output; is the query matrix, which represents the features to be searched, ; represents transpose; represents query projection weight; is the key matrix, which represents the features to be searched, ; represents transpose; represents key projection weight; is a value matrix, representing the actual value corresponding to the key, ; represents the value projection weight; is the embedding dimension of the query and the key, ; represents the number of attention heads, which is a parameter set by oneself; represents the overall feature dimension of the model, which is a parameter set by oneself in the model; represents the transpose of the key matrix, that is, the transpose of the feature to be retrieved; , and is not a fixed constant directly calculated by a certain formula, but a trainable parameter automatically learned by the neural network in the training process through random initialization→back propagation→iterative optimization; represents the normalization layer, that is, the input is normalized, the value is controlled in the interval (0, 1), that is, the normalization processing is performed on ; (17); In formula (17), represents the output of the first attention head under ; represents the output of the i-th attention head under , and the attention of each head is calculated independently; represents the value output by concatenating the results of all heads under and linear transformation; represents data concatenation, which connects the data of the first to the h-th head of the head in the last dimension side by side; represents the projection matrix of the multi-head attention output, which projects the concatenated multi-head output to the final dimension; represents the value of the i-th head attention output under , represents the value of the i-th channel of ; represents the value of the i-th channel of ; represents the value of the i-th channel of .
[0057] (18); In formula (18), represents the data output after layer normalization processing; represents the layer normalization operation in deep learning; denotes the layer normalization processing on the sum of and ; denotes the data output after the activation processing; denotes the weight matrix of the first linear mapping in the feedforward sublayer; denotes the weight matrix of the second linear mapping in the feedforward sublayer; denotes the bias vector of the first linear mapping in the feedforward sublayer; denotes the bias vector of the second linear mapping in the feedforward sublayer.
[0058] , , and are not fixed constants directly calculated by some formula, but trainable parameters automatically learned by the neural network in the training process through random initialization→backpropagation→iterative optimization.
[0059] (19); In formula (19): denotes the data output after the cross-attention mechanism processing; denotes the data output after the layer normalization processing; denotes the layer normalization processing on the sum of and ; At the same time of processing the frequency domain data, the result output by the 2D-CNN model from the time domain data is processed by the deep convolutional neural network (multi-head 1D-CNN) alone.
[0060] The specific calculation content is as follows: (20); In formula (20): denotes the result output by the convolution calculation; denotes the two-dimensional convolution processing on .
[0061] (21); In formula (21): denotes the two-dimensional batch normalization layer in the neural network; denotes the data after the normalization processing. (22); ReLU represents an activation layer in the neural network; Z represents data obtained after activation processing.
[0062] (23); In formula (23): represents an adaptive two-dimensional max-pooling layer in the neural network; represents data obtained after max-pooling operation; (24); In formula (24): represents reassigning the dimension layout of the tensor on the premise that the element order is unchanged; data output after multi-head 1D-CNN processing; S3.3. Linearly add the results output by the two paths, that is, linearly add and The specific calculation steps are as follows: (25); In formula (25): represents data obtained by adding the results output by the two paths; data output by the cross-attention mechanism.
[0063] S3.4. Linearly add the data after linear addition to the transformer for processing, specifically as follows: The input of the multi-head self-attention mechanism is The calculation formula is: (26); In formula (26): represents the value of the attention output; represents a normalization layer, that is, the input is normalized, the value is controlled in the interval (0, 1), that is, the normalization processing is performed on ; (27); In formula (27): represents data obtained by adding the results output by the two paths; represents query projection weight; represents key projection weight; represents value projection weight; , and Not a fixed constant directly calculated by some formula, but a trainable parameter automatically learned by neural network in the training process through random initialization→back propagation→iterative optimization; Still query matrix, but its calculation is no longer as usual , but as shown in equation (27), that is, the calculation data is modified, and is replaced by ; Still key matrix, but its calculation is no longer as usual , but as shown in equation (27), that is, the calculation data is modified, and is replaced by ; Still value matrix, but its calculation is no longer as usual , but as shown in equation (27), that is, the calculation data is modified, and is replaced by .
[0064] The output of the multi-head self-attention mechanism is the splicing result of multiple attention heads, and is obtained through linear transformation: (28); (29); In equations (28) and (29): represents the output of the first attention head under , , ; represents the output of the i-th attention head under , , , and each head calculates attention independently; represents the value obtained by splicing all heads under , , and linearly transforming the output; represents data splicing, and the data of the first to h-th heads of are connected side by side in the last dimension; represents the projection matrix of the multi-head attention output, which projects the spliced multi-head output to the final dimension; represents the value of the i-th head calculating attention output, represents the value of the i-th channel of ; represents the value of the i-th channel of ; represents the value of the i-th channel of .
[0065] The output of the multi-head self-attention mechanism is added to the input features, and layer normalization is performed: (30); In formula (30): represents the data output after layer normalization processing; represents the layer normalization operation in deep learning; represents the sum of and layer normalization processing.
[0066] The input of the feedforward neural network is , and the calculation formula is: (31); In formula (31): represents the data output after activation processing; The output of the feedforward neural network is added to , and layer normalization is performed: (32); In formula (32): represents the data output after layer normalization processing; represents the sum of and layer normalization processing.
[0067] Formulas (26) to (32) are the calculation process of an encoder layer. In practice, 4 encoder layers are used, and the output of each encoder layer is used as the input of the next encoder layer: (34); In formula (34): represents the data output after transformer training processing; represents the data output after one calculation of formulas (26) to (32); represents the data output after another calculation of formulas (26) to (32) as output; represents the data output after another calculation of formulas (26) to (32) as output; represents the data output after another calculation of formulas (26) to (32) as output; in short, the entire process is iteratively calculated four times.
[0068] S3.5. A regressor is used to map the output of the Transformer to the predicted value, as follows: The last time step of is taken as the capacity prediction value: (35); In equation (35): represents the predicted value of the capacity; represents the value of the last time step in ; and Step 4 includes the following steps: S4.1: Calculate the loss function between the predicted value and the true value using the mean squared error (MSE), as follows: (37); In equation (37): represents the loss value; is the batch size; S4.3: Calculate the gradient of the loss function with respect to the model (the entire process of step 3) parameters, as follows: (38); In equation (38): represents the gradient of the parameters; is the model parameter; S4.4: Update the model (the entire process of step 3) parameters using the optimizer, as follows: (39); In equation (39): represents the learning rate.
[0069] In step 5, (40); (41); (42); In the above equation, is the sample number; where the smaller the MAE, RMSE, the better the model fitting effect, and the larger the R2, the better the model fitting effect.
[0070] Verification example: The NASA dataset is verified, and B0045 is selected as the experimental data in the NASA dataset. First, the actual data of 1500mAh battery 700mA charging 280mA discharging is collected, and the input features such as voltage, current, power, relative time and real-time capacity are collected as training data.
[0071] Then, the MAE index, RMSE index and R² index are used for model evaluation. Since the data has randomness, the model is repeated five times, and the best effect is taken. The results are shown in Table 1 or Figure 4 .
[0072] Table 1 MAE index, RMSE index and R² index evaluation results of different models
[0073] The results show that the new model has the highest prediction accuracy on the test data, 0.9915 means that it can correctly predict the short-term trend of the power system inertia, and the prediction curve is as shown in Figure 3 . The data results of Table 1 show that the prediction accuracy of the new model on the test data is higher than that of the original model, 0.9915 means that it can correctly predict the battery capacity, and the prediction curve is as shown in Figure 2 . At the same time, the average absolute error of the new model is 1.42%, and the root mean square error is 3.57%, which is significantly better than the original model.
[0074] From the training loss graphs of Figure 3 and Figure 4 , it can be seen that the model using MEL filter appears several peaks, while the number of such cases in the new model is much smaller than it, and the whole process is relatively flat, indicating that the decoupling ability of the new model for data is better than the original model, which also makes the latter have better prediction effect.
Claims
1. A lithium-ion battery health status estimation method based on time-frequency domain feature decoupling and dynamic compensation mechanism is characterized by The steps include: Step 1: Collect actual data of multiple charge and discharge cycles of lithium-ion batteries as the initial data set; Step 2: Perform eigenmode decomposition on the initial data set and obtain frequency domain data through decoupling; Step 3: Decouple the frequency domain data obtained in step 2 and the original time domain data and input them into the training model to obtain the predicted lithium-ion battery capacity; Step 4: Feed the real-time capacity and maximum capacity of the lithium-ion battery back to the training model. After training, the predicted value of the capacity is obtained to estimate the health status of the lithium-ion battery.
2. The lithium-ion battery health status estimation method based on time-frequency domain feature decoupling and dynamic compensation mechanism according to claim 1 is characterized by: It also includes step 5: Based on the results predicted by the training model, the mean absolute error (MAE), root mean square error (RMSE) and coefficient of determination (R2) are used for evaluation; (40); (41); (42); In the above formula, is the sample number; the smaller the MAE and RMSE, the better the model fitting effect, and the larger the R2, the better the model fitting effect.
3. The lithium-ion battery health status estimation method based on time-frequency domain feature decoupling and dynamic compensation mechanism according to claim 1 is characterized by: In step 2, performing eigenmode decomposition on the initial data set includes the following steps: S2.
1. Band splitting and filter initialization: S2.
2. Initial mode extraction based on MCKD algorithm: Objective function: Maximize Correlated Kurtosis (CK): (3); In formula (3), Indicates the length of the initial data set; is the number of time shifts, indicating that the multi-cycle delay product of the signal is considered when calculating the correlation kurtosis; is a discrete time index, indicating the first Sampling points, the value range is 1 ≤ ≤ ; is the time-shift index variable, with a value range of 0 ≤ ≤ , used to calculate the signal product under different delays; is the interval period of periodic shocks in the initial dataset; Indicates output signal At the time point The value at It is time domain data The deconvolution output signal after filter processing; S2.
3. Modal iteration selection; S2.
4. Iterative Update: S2.
5. Output the final mode: The column with the largest CK value obtained by iterative calculation , perform Hilbert transform, windowing, and Fourier transform to frequency domain data in sequence .
4. The lithium-ion battery health status estimation method based on time-frequency domain feature decoupling and dynamic compensation mechanism according to claim 3 is characterized by: In S2.1, the frequency band is evenly divided into CutNum sub-bands, and the normalized frequency of the initial data set boundary is: (1); In formula (1), Indicates the normalized sub-band starting frequency boundary; Indicates the number of frequency band divisions; represents the normalized sub-band bandwidth; represents the bandwidth of the two sub-bands; Design a Hanning window FIR filter for each subband: (2); In formula (2), represents the Hanning window coefficient; Indicates generating a Hanning Window of length FilterSize and returning it as a column vector; FilterSize represents the filter order; Represents the filter coefficient corresponding to the nth sub-band; Indicates the current sub-band number; represents the lower limit of the normalized frequency passband; represents the upper limit of the normalized frequency passband; represents the normalized passband boundary; , ; Represents the MATLAB repeated matrix function: Repeat once in the row direction and CutNum times in the column direction; Time domain data representing the initial data; Indicates the battery n Charge and discharge times; represents the candidate modal signal matrix.
5. The lithium-ion battery health status estimation method based on time-frequency domain feature decoupling and dynamic compensation mechanism according to claim 3 is characterized by: In S2.2, the calculation of the MCKD algorithm includes the following steps: a1: Signal delay construction: Constructing the delay matrix , time domain data containing initial data and its delay T, 2T, …, MT by M samples; (4); In formula (4), Represents a multi-channel delayed signal matrix; is a discrete time index, indicating the first Sampling points, the value range is 1 ≤ ≤ ; is the time-shift index variable, with a value range of 0 ≤ ≤ , used to calculate the signal product under different delays; Representing data in the time domain The value of mT sampling points before time point t in ; is the interval period of periodic shocks in the initial dataset; a2: Iteratively update the filter coefficients: Output signal: (5); In formula (5), It is time domain data Deconvoluted frequency domain data after filtering; represents the transpose of the filter coefficient vector; Kurtosis gradient calculation: Through the product term , update the filter : (6); In formula (6), represents the new filter coefficient vector; ;in, represents the first channel slice of the three-dimensional delayed signal matrix; represents the transpose of the first channel slice of the three-dimensional delayed signal matrix; ;in, represents the product term; Indicates the length of the initial data set; is a discrete time index, indicating the first Sampling points, the value range is 1 ≤ ≤ ; ;in, represents the weighted delayed input matrix; is the number of time shifts, indicating that the multi-cycle delay product of the signal is considered when calculating the correlation kurtosis; is the time-shift index variable, with a value range of 0 ≤ ≤ , used to calculate the signal product under different delays; represents the m+1th channel slice of the three-dimensional delayed signal matrix; ;in, represents the diagonal weight matrix; Express The matrix takes the diagonal elements; a3: Period T adaptive update of the initial data set: The period is estimated by Hilbert transform of the signal envelope as follows: step1: Yes Perform Hilbert transform to calculate the envelope signal ; (7); In formula (7), is the Hibert transform operator, is the mean operation; Express Perform Hilbert transform; Step 2: Through the envelope signal Autocorrelation function of the initial period ; (8); In formula (8), Indicates signal The autocorrelation function of is the delay parameter, indicating The position compared with itself after being shifted on the time axis; Represents the envelope signal exist The value of the moment; Indicates the length of the initial data set; Calculated After that, find the first one that satisfies and of ,in, Indicated in time The value of Indicated in time The value of Represents the autocorrelation function The first zero crossing position of Again Find the largest , while taking When the maximum value value, let for , the formula is as follows: (9); In formula (9), represents the initial period estimate; Represents the autocorrelation function The first zero crossing position of Indicates the independent variable corresponding to the maximum value of the function; Representation function The independent variable corresponding to the maximum value; step3: Define search scope within a field , Represents the search radius; calculates all candidate cycles in the range The CK value formula is as follows: (10); In formula (10), Indicates CK value at the time point; Indicates output signal At the time point The value at Indicates the length of the initial data set; is the number of time shifts, indicating that the multi-cycle delay product of the signal is considered when calculating the correlation kurtosis; is the time-shift index variable, with a value range of 0 ≤ ≤ , used to calculate the signal product under different delays; Step 4: Select the cycle that maximizes the CK value as the optimization result: (11); In formula (11), represents the newly generated period estimate; Representation function The independent variable corresponding to the maximum value; like , then update the cycle parameters ; Step 5: Iterative convergence: Repeat step 3 and step 4 until one of the following conditions is met: ①. (12); ②. Reach the maximum number of iterations in: is the convergence threshold.
6. The lithium-ion battery health status estimation method based on time-frequency domain feature decoupling and dynamic compensation mechanism according to claim 3 is characterized by: In S2.3, the modal iteration selection specifically includes the following steps: b1: Calculate the correlation coefficient matrix: (13); In formula (13), represents the correlation coefficient moment; Indicates that the Pearson correlation coefficient matrix is calculated for every two columns of the matrix temp_sig; It is a built-in function in MATLAB that calculates the Pearson correlation coefficient matrix. If the input is A (N × M), the output is an M × M symmetric matrix R, where R(i,j)∈[-1,1]; Represents the Pearson correlation coefficient matrix Take the absolute value; It means taking the strictly upper triangular part of the Pearson correlation coefficient matrix with absolute value, that is, the (j>i) part, where: j is the number of columns, j=1 is the first column, i is the number of rows, i=1 is the first row, remove the part with j>i, and set the rest to 0; b2: Select the most relevant modal pair: turn up The position (i, j) with the maximum correlation coefficient in the matrix is calculated using formula (3) and The CK value at two positions, retain the larger CK value; in: Indicates taking Column i of Indicates taking The jth column of .
7. The lithium-ion battery health status estimation method based on time-frequency domain feature decoupling and dynamic compensation mechanism according to claim 3 is characterized by: In S2.4, iterative updates are as follows: Each time S2.1~S2.3 is calculated, a new , where c is S2.3 The value retained in is i or j; The new As the new input signal, that is, in the second iteration, replace , and then perform the calculations of steps S2.1 to S2.3 as the input signal. After each calculation, the modal number M is reduced by one and the next round of iteration is performed. The above steps are repeated until the following conditions are met and the iteration stops: ①. Number of iterations ; ②.CK value converges (14); in: Indicates the function CK iteration Second-rate; Indicates the CK iteration -1 time; represents the number of iterations, =1 means one iteration is performed; is the number of iterations to terminate.
8. The lithium-ion battery health status estimation method based on time-frequency domain feature decoupling and dynamic compensation mechanism according to claim 3 is characterized by: S2.5 includes the following steps: 1) Hilber transform ; in: represents the envelope signal; right Perform Hilbert transform; The value of the output signal when the iteration stops; 2) Windowing: ; in: Represents the output value obtained by the windowing operation; represents the Hanning window coefficient; Indicates the current sub-band number; 3) Fourier transform: ; in: Express Perform a Fourier transform.
9. The lithium-ion battery health status estimation method based on time-frequency domain feature decoupling and dynamic compensation mechanism according to claim 1 is characterized by: The step 3 comprises the following steps: S3.
1. The decoupled frequency domain data and the initial time domain data are fed into a 2D convolutional neural network for processing as follows: (15); In formula (15), Represents frequency domain data; is the i-th convolution kernel; Represents time domain data Convolution results in the time domain of all channels; Represents time domain data Convolution result in the time domain of the i-th channel; Represents frequency domain data Convolution results in the time domain of all channels; Represents frequency domain data Convolution result in the frequency domain of the i-th channel; Respectively represent the first channel to the i-th channel of the time domain data; Respectively represent the first channel to the i-th channel of the frequency domain data; Indicates channel; Represents the total number of output channels in the convolutional layer; Represents a two-dimensional convolutional layer in a convolutional neural network; Indicates two-dimensional convolution processing of time domain data; Represents the activation layer in a convolutional neural network; Indicates a nonlinear transformation of the product of time domain data and the convolution kernel; Indicates two-dimensional convolution processing of frequency domain data; Indicates a nonlinear transformation of the product of frequency domain data and the convolution kernel; S3.
2. Two sets of results based on the output of S3.1 and , the result of the frequency domain data output by the 2D-CNN model Perform the cross-attention mechanism. The specific calculation of the cross-attention mechanism is as follows: (16); In formula (16), Represents the value of calculating the attention output; is the query matrix, which represents the features to be retrieved, ; express The transpose of Represents the query projection weight; is the key matrix, representing the features to be retrieved, ; express The transpose of represents the key projection weight; is a value matrix, representing the actual values corresponding to the keys, ; Represents the value projection weight; is the embedding dimension of query and key, ; Indicates the number of attention heads, which is a parameter set by yourself; Represents the overall characteristic dimension of the model, which is a parameter set in the model; represents the transpose of the key matrix, i.e. the transpose of the features being retrieved; Represents the normalization layer, which normalizes the input and controls the value within the range of (0,1). Perform normalization processing; (17); In formula (17), Indicates The output of the first attention head under ; Indicates The output of the i-th attention head under , each head also calculates attention independently; Indicates Next, concatenate the results of all the headers and linearly transform the output values; Indicates data concatenation, concatenating the data from the first to the hth head side by side according to the last dimension; The projection matrix representing the multi-head attention output projects the concatenated multi-head output to the final dimension. Indicates The i-th head under Calculate the value of the attention output, express The value of the i-th channel; express The value of the i-th channel; express The value of the i-th channel; (18); In formula (18), Represents the data output after layer normalization; Represents the layer normalization operation in deep learning; Express and The sum of the two is layer normalized; express Data output after activation processing; Represents the weight matrix of the first linear mapping in the feedforward sublayer; Represents the weight matrix of the second linear mapping in the feedforward sublayer; Represents the bias vector of the first linear mapping in the feedforward sublayer; Represents the bias vector of the second linear mapping in the feedforward sublayer; (19); In formula (19): Data output by the cross-attention mechanism; Represents the data output after layer normalization; Express and The sum of the two is layer normalized; While processing the frequency domain data, the results output by the time domain data through the 2D-CNN model are Perform multi-head 1D-CNN processing separately; The specific calculation contents are as follows: (20); In formula (20): Represents the result of convolution calculation output; Expressed right Perform two-dimensional convolution processing; (21); In formula (21): Represents a two-dimensional batch normalization layer in a neural network; represents the data after normalization. (22); In formula (22): ReLU represents the activation layer in the neural network; Z represents the data obtained after activation processing; (23); In formula (23): Represents an adaptive two-dimensional max pooling layer in a neural network; Represents the data obtained after the maximum pooling operation; (24); In formula (24): Indicates that the dimension layout of the tensor is re-specified while keeping the order of elements unchanged; Data output after multi-head 1D-CNN processing; S3.
3. Add the outputs of the two paths linearly, that is, and Perform linear addition, and the specific calculation steps are as follows: (25); In formula (25): Represents the data obtained by adding the output results of the two paths; Data output by the cross-attention mechanism; S3.
4. Add the linearly added data Input to transformer for processing, the specific steps are as follows: The input of the multi-head self-attention mechanism is , and its calculation formula is: (26); In formula (26): Represents the value of calculating the attention output; Represents the normalization layer, which normalizes the input and controls the value within the range of (0,1). Perform normalization processing; (27); In formula (27): Represents the data obtained by adding the output results of the two paths; Represents the query projection weight; represents the key projection weight; Represents the value projection weight; It is still a query matrix, but its calculation is no longer the same as Generally, as shown in formula (27), the calculation data is modified and Replace with ; It is still a key matrix, but its calculation is no longer the same as Generally, as shown in formula (27), the calculation data is modified and Replace with ; It is still a value matrix, but its calculation is no longer the same as Generally, as shown in formula (27), the calculation data is modified and Replace with ; The output of the multi-head self-attention mechanism is the concatenation of multiple attention heads and is obtained through linear transformation: (28); (29); In formula (28) and (29): Indicates , , The output of the first attention head under ; Indicates , , The output of the i-th attention head under , each head also calculates attention independently; Indicates , , Next, concatenate the results of all the headers and linearly transform the output values; Indicates data splicing, The data from the first to the hth head are concatenated side by side along the last dimension; The projection matrix representing the multi-head attention output projects the concatenated multi-head output to the final dimension. Indicates the value of the attention output calculated by the i-th head, express The value of the i-th channel; express The value of the i-th channel; express The value of the i-th channel; Add the output of the multi-head self-attention mechanism to the input features and perform layer normalization: (30); In formula (30): Represents the data output after layer normalization; Represents the layer normalization operation in deep learning; Express and The sum of the two is layer normalized; The input of the feedforward neural network is , and its calculation formula is: (31); In formula (31): Represents the data output after activation processing; The output of the feedforward neural network Add and perform layer normalization: (32); In formula (32): Represents the data output by layer normalization processing; Express and The sum of is normalized at the layer level; Formula (26) to Formula (32) are the calculation process of an encoder layer; in practice, four encoder layers are used, and the output of each encoder layer serves as the input of the next encoder layer: (34); In formula (34): Representation data The output data is processed by transformer training; Representation data The output data is calculated once through formulas (26) to (32); Indicates that Then the output data is calculated through formulas (26) to (32); Indicates that Then the output data is calculated through formulas (26) to (32); Indicates that Then the output data is calculated by formula (26) to (32); in simple terms, the whole process is iterated four times; S3.
5. A regressor is used to transform the output of Transformer Mapped to predicted values, as follows: Directly take The last time step of is used as the capacity prediction value: (35); In formula (35): Indicates the predicted value of capacity; express The value of the last time step in .
10. The lithium-ion battery health status estimation method based on time-frequency domain feature decoupling and dynamic compensation mechanism according to claim 1, characterized in that: In step 4: Calculate the predicted value using mean squared error (MSE) and the true value The loss function between them is calculated as follows: (37); In formula (37): Indicates the loss value; is the batch size; Calculate the gradient of the loss function with respect to the model parameters. The calculation formula is as follows (38); In formula (38): represents the gradient of the parameter; are model parameters; Use the optimizer to update the model parameters. The calculation formula is as follows: (39); In formula (39): Represents the learning rate.
Citation Information
Cited By
Lithium battery capacitance prediction method based on two-way feature fusion and space-time modeling
CN121410586A
A lithium battery capacity prediction method based on dual-path feature fusion and spatiotemporal modeling
CN121410586B
A method for optimizing the operational stability of lithium batteries based on multi-parameter sensing
CN122410329A