Battery charge state prediction method and system based on HO-BP-Hammerstein model, and electronic equipment
By constructing the HO-BP-Hammerstein model and combining data preprocessing and model training, the problems of accumulated error and slow dynamic response in lithium-ion battery SOC prediction are solved, achieving high-precision and fast SOC estimation and improving the safety and reliability of the battery management system.
Patent Information
- Application Number
- CN202511130259.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-08-13
- Publication Date
- 2025-11-21
AI Technical Summary
Existing methods for predicting the state of charge (SOC) of lithium-ion batteries suffer from problems such as large cumulative errors, slow dynamic response, and neural network models being prone to getting trapped in local optima, especially under complex operating conditions where prediction accuracy drops significantly.
The HO-BP-Hammerstein model is adopted. Through data preprocessing and model training, the HO-BP-Hammerstein model driven by the Hippo Optimization (HO) algorithm is constructed. The weights are dynamically adjusted to optimize SOC prediction by combining the BP neural network and the Hammerstein model. The error correlation linear analysis method is used for adaptive optimization.
It significantly improves prediction accuracy and dynamic response speed under complex operating conditions, provides highly reliable safety warnings and life assessments, and provides high-precision SOC estimation for battery management systems (BMS).
Smart Images

Figure CN120993213A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of new energy battery management system technology, and in particular to a battery state of charge prediction method, system and electronic equipment based on the HO-BP-Hammerstein model. Background Technology
[0002] Electric vehicles, with their advantages of high efficiency, energy saving, and environmental friendliness, are gradually replacing traditional gasoline-powered vehicles and becoming an important direction for the low-carbon transformation of the global transportation sector. However, the cleanliness of electric vehicles is conditional: firstly, their environmental benefits directly depend on the power structure, with a more significant advantage in regions with a higher proportion of renewable energy; secondly, from a life-cycle perspective, the mining, manufacturing, and recycling of power batteries still face environmental challenges. Currently, with the improvement of power battery recycling systems and the increase in the proportion of clean electricity, the environmental benefits of electric vehicles are continuously improving. Continued efforts in technological innovation and industrial collaboration are needed to truly achieve the green and sustainable development of electric vehicles.
[0003] Accurate estimation of the state of charge (SOC) of lithium-ion batteries is crucial for assessing the safety and remaining driving range of electric vehicles, directly impacting battery safety, range, and lifespan. However, due to the complex and variable operating environment of batteries and the highly nonlinear nature of their internal mechanisms, traditional SOC prediction methods (such as the ampere-hour integration method and the open-circuit voltage method) suffer from large accumulated errors and slow dynamic response, especially under complex operating conditions (such as high-rate charging and discharging and wide temperature ranges), where prediction accuracy drops significantly. In recent years, model-based methods (such as Kalman filtering and neural networks) have made some improvements, but they still face challenges such as rigid model structures and low efficiency in parameter optimization. Achieving high-precision SOC prediction has become a core research challenge.
[0004] Therefore, proposing a battery state of charge prediction method, system, and electronic device based on the HO-BP-Hammerstein model to solve the problems existing in the prior art is an urgent problem to be solved by those skilled in the art. Summary of the Invention
[0005] In view of this, the present invention provides a battery state of charge prediction method, system and electronic device based on the HO-BP-Hammerstein model, which is used to solve the problems of large cumulative error, lag in dynamic response and easy trapping of neural network models in traditional SOC prediction methods.
[0006] To achieve the above objectives, the present invention adopts the following technical solution:
[0007] A method for predicting the state of charge of a battery based on the HO-BP-Hammerstein model includes the following steps:
[0008] S1 Data Acquisition Steps: Acquire data from the normal charging process of the electric vehicle and label it as historical charging data;
[0009] S2 data preprocessing steps: Preprocess historical charging data to obtain a standardized input dataset;
[0010] S3 model construction steps: Using electric vehicle charging voltage, charging current and historical SOC data as input features, construct the HO-BP-Hammerstein model driven by the HO algorithm;
[0011] S4 model training steps: During the training of the HO-BP-Hammerstein model, the BP optimization module dynamically adjusts the neural network weights through the backpropagation algorithm, with the objective function being to minimize the mean square error between the predicted SOC and the actual SOC. Finally, the HO-BP-Hammerstein model training is completed using the standardized input dataset, resulting in a trained HO-BP-Hammerstein model.
[0012] S5 model optimization steps: Adaptive optimization of the output value of the trained HO-BP-Hammerstein model using error correlation linear analysis to obtain the final data prediction model;
[0013] S6 Prediction Steps: Input the dataset to be predicted into the final data prediction model to obtain the predicted value of the electric vehicle battery state of charge, and use performance evaluation indicators to verify the prediction accuracy of the final data prediction model.
[0014] Optionally, the data in S1 during the normal charging process of the electric vehicle can be multi-dimensional real-time data, including: the initial SOC of the vehicle's power battery, the real-time SOC of the vehicle's power battery, the internal temperature of the vehicle's electric vehicle charger, the temperature of the vehicle's electric vehicle charging module, the highest / lowest / average voltage of the individual cells in the vehicle's on-board battery pack, the highest / lowest allowable voltage parameters for charging the vehicle's on-board battery pack, the highest / lowest current parameters, and the highest / lowest temperature parameters.
[0015] The above method, optionally, includes the following specific steps for S2 data preprocessing:
[0016] The historical charging data undergoes outlier removal, normalization, and feature engineering to generate a standardized input dataset; specifically, this includes the following steps:
[0017] S201 uses cubic spline interpolation to fill in abnormal voltage / current values in historical operating data;
[0018] S202 uses the range standardization method to normalize the data. The normalization formula is as follows:
[0019]
[0020] In the formula, data input This represents the normalized data value; data represents the original data; data max and data min This represents the maximum and minimum values in the original data; data min This represents the i-th value in the original data.
[0021] Optionally, in the S3 model construction step described above, the HO-BP-Hammerstein model driven by the HO algorithm adopts a composite architecture design:
[0022] The nonlinear static module is constructed by cascading a HO-BP neural network and a dynamic linear module, as defined below:
[0023] α(z)SOC(t)=β(z)S(t)+V(t)
[0024] In the formula, S(t) is the output of the nonlinear module and the input of the linear module, V(t) is random white noise, and α(z) and β(z) are known polynomials in Z;
[0025] The dynamic linear module describes the time-series characteristics of the battery's dynamic response based on the least squares method.
[0026] The above method, optionally, includes the following steps in the S3 model construction process:
[0027] S301. Construct a BP neural network architecture, including an input layer, hidden layers, and an output layer. The formula for the three-layer BP neural network structure is as follows:
[0028]
[0029] In the formula, H represents the number of hidden layers, n represents the number of input layers, m represents the number of output layers, and α is a variable in the range of 1 to 10;
[0030] S302, random neuron It is the j-th neuron in the m-th layer. We select n neurons for input analysis; the input is (x1, x2, x3, x4, ... xj). n ) T The corresponding variable weight matrix is:
[0031]
[0032] S303, Network Input The analysis is based on the formula for the variable weight matrix, as follows:
[0033]
[0034] S304, where the network output y j As shown in the formula f(*) is an activation function, and the network output y j The formula is as follows:
[0035]
[0036] The formulas for the S305 and sigmoid activation functions are:
[0037]
[0038] S306. The HO algorithm is used to optimize the structure of the BP neural network. During the initialization phase of the HO algorithm, a random initial solution needs to be generated. In this process, the decision variables are generated according to the following formula:
[0039] χ i :x ij =lb j +r(ub j -lb j )
[0040] In the formula, χ i This represents the position of the i-th candidate solution, where r is a random number in the range [0,1], and lb... j and ub j Let represent the lower and upper bounds of the j-th decision variable, respectively;
[0041] By optimizing HO, the position updates driven by random perturbations and fitness optimize the neural network weights and biases.
[0042] Optionally, in S6 of the above method, performance evaluation metrics are used to verify the SOC prediction accuracy of the final data prediction model, including the following:
[0043] Mean Squared Error (MSE): Reflects the squared mean of the differences between predicted and actual values, used to measure the overall error of the model's predictions. The formula is:
[0044]
[0045] Root Mean Square Error (RMSE): Reflects the degree of fluctuation in prediction error, and the formula is:
[0046]
[0047] Mean Absolute Error (MAE): The mean absolute error between the predicted SOC and the actual SOC, calculated using the following formula:
[0048]
[0049] Coefficient of determination R 2 The formula for evaluating the model's explanatory power for SOC change trends is:
[0050]
[0051] In the formula, n represents the number of samples of observation data, y i Represents the actual value of the data points. The model represents the χ² value. i The prediction results This represents the sample mean of the dependent variable y, which is the average of all actual values.
[0052] The above method, optionally, includes a nonlinear static module: using a BP neural network to establish a mapping relationship between current, voltage, and historical SOC sequence data;
[0053] Dynamic linear module: Based on least squares fitting to predict dynamic changes in SOC.
[0054] A battery state-of-charge prediction system based on the HO-BP-Hammerstein model, used to execute the battery state-of-charge prediction method based on the HO-BP-Hammerstein model described above, comprising:
[0055] Data acquisition module: Acquires data during the normal charging process of electric vehicles and labels it as historical charging data;
[0056] Data preprocessing module: preprocesses historical charging data to obtain a standardized input dataset;
[0057] Model building module: Using electric vehicle charging voltage, charging current and historical SOC data as input features, a HO-BP-Hammerstein model driven by the HO algorithm is built;
[0058] Model training module: During the training of the HO-BP-Hammerstein model, the BP optimization module dynamically adjusts the neural network weights through the backpropagation algorithm, with the objective function being to minimize the mean square error between the predicted SOC and the actual SOC. Finally, the HO-BP-Hammerstein model training is completed using the standardized input dataset, resulting in a trained HO-BP-Hammerstein model.
[0059] Model optimization module: Adaptively optimizes the output values of the trained HO-BP-Hammerstein model using error correlation linear analysis to obtain the final data prediction model;
[0060] Prediction module: Input the dataset to be predicted into the final data prediction model to obtain the predicted value of the electric vehicle battery state of charge, and use performance evaluation indicators to verify the prediction accuracy of the final data prediction model.
[0061] An electronic device, comprising:
[0062] The memory is used to store historical battery operating data, real-time operating data, and computer programs.
[0063] A processor, connected to a memory, is used to implement the battery state-of-charge prediction method as described above when executing a computer program.
[0064] As can be seen from the above technical solutions, compared with the prior art, the present invention provides a battery state of charge prediction method, system, and electronic device based on the HO-BP-Hammerstein model, which has the following beneficial effects:
[0065] By collecting historical battery operating data, a HO-BP-Hammerstein coupled model driven by the Hippo Optimization (HO) algorithm is constructed. This method uses the HO algorithm to dynamically adjust the weights and bias vectors of the BP neural network to capture the nonlinear characteristics of the battery. At the same time, the linear module of the Hammerstein model is used to predict and calculate the dynamic changes of SOC. Finally, the predicted SOC value and confidence interval are output, and the overcharge / over-discharge warning threshold is triggered. Compared with the traditional ampere-hour integration method and open circuit voltage method, this method significantly improves the prediction accuracy and dynamic response speed under complex operating conditions, and provides a highly reliable safety warning and life assessment basis for the battery management system (BMS). Attached Figure Description
[0066] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on the provided drawings without creative effort.
[0067] Figure 1 This is a flowchart of a battery state-of-charge prediction method based on the HO-BP-Hammerstein model disclosed in this invention.
[0068] Figure 2This is a flowchart illustrating a battery state-of-charge prediction method based on the HO-BP-Hammerstein model disclosed in this invention.
[0069] Figure 3 This is a schematic diagram of the BP neural network architecture disclosed in this invention;
[0070] Figure 4 This is a schematic diagram of the HO-BP-Hammerstein model structure disclosed in this invention. Detailed Implementation
[0071] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0072] In this application, relational terms such as "first" and "second" are used merely to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. The terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.
[0073] See Figure 1 and Figure 2 As shown, this invention discloses a method for predicting the state of charge of a battery based on the HO-BP-Hammerstein model, comprising the following steps:
[0074] S1 Data Acquisition Steps: Acquire data from the normal charging process of the electric vehicle and label it as historical charging data;
[0075] S2 data preprocessing steps: Preprocess historical charging data to obtain a standardized input dataset;
[0076] S3 model construction steps: Using electric vehicle charging voltage, charging current and historical SOC data as input features, construct the HO-BP-Hammerstein model driven by the HO algorithm;
[0077] S4 model training steps: During the training of the HO-BP-Hammerstein model, the BP optimization module dynamically adjusts the neural network weights through the backpropagation algorithm, with the objective function being to minimize the mean square error between the predicted SOC and the actual SOC. Finally, the HO-BP-Hammerstein model training is completed using the standardized input dataset, resulting in a trained HO-BP-Hammerstein model.
[0078] S5 model optimization steps: Adaptive optimization of the output value of the trained HO-BP-Hammerstein model using error correlation linear analysis to obtain the final data prediction model;
[0079] S6 Prediction Steps: Input the dataset to be predicted into the final data prediction model to obtain the predicted value of the electric vehicle battery state of charge, and use performance evaluation indicators to verify the prediction accuracy of the final data prediction model.
[0080] Furthermore, the data for the normal charging process of electric vehicles in S1 is multi-dimensional real-time data, including: the initial SOC of the vehicle's power battery, the real-time SOC of the vehicle's power battery, the internal temperature of the vehicle's electric vehicle charger, the temperature of the vehicle's electric vehicle charging module, the highest / lowest / average voltage of the individual cells in the vehicle's on-board battery pack, the highest / lowest allowable voltage parameters for charging the vehicle's on-board battery pack, the highest / lowest current parameters, and the highest / lowest temperature parameters.
[0081] Furthermore, the specific details of the S2 data preprocessing steps are as follows:
[0082] The historical charging data undergoes outlier removal, normalization, and feature engineering to generate a standardized input dataset; specifically, this includes the following steps:
[0083] S201 uses cubic spline interpolation to fill in abnormal voltage / current values in historical operating data;
[0084] S202 uses the range standardization method to normalize the data. The normalization formula is as follows:
[0085]
[0086] In the formula, data input This represents the normalized data value; data represents the original data; data max and data min This represents the maximum and minimum values in the original data; data min This represents the i-th value in the original data. All processed charge data are stored in [-1, 1].
[0087] In one specific embodiment, S3 uses the electric vehicle charging voltage, electric vehicle charging current, and battery historical SOC as inputs, and the SOC prediction value as the model output to construct a HO-BP-Hammerstein model. S4 uses the preprocessed historical charging data as the model input to train the nonlinear module and obtain a data fitting model for predicting the state of charge of the electric vehicle battery.
[0088] Furthermore, in the S3 model construction step, the HO-BP-Hammerstein model driven by the HO algorithm adopts a composite architecture design:
[0089] The nonlinear static module is constructed by cascading a HO-BP neural network and a dynamic linear module, as defined below:
[0090] α(z)SOC(t)=β(z)S(t)+V(t)
[0091] In the formula, S(t) is the output of the nonlinear module and the input of the linear module, V(t) is random white noise, and α(z) and β(z) are known polynomials in Z;
[0092] The dynamic linear module describes the time-series characteristics of the battery's dynamic response based on the least squares method.
[0093] Further, see Figure 3 As shown, the specific steps of building the S3 model include the following:
[0094] S301. Construct a BP neural network architecture, including an input layer, hidden layers, and an output layer. The formula for the three-layer BP neural network structure is as follows:
[0095]
[0096] In the formula, H represents the number of hidden layers, n represents the number of input layers, m represents the number of output layers, and α is a variable in the range of 1 to 10;
[0097] S302, random neuron It is the j-th neuron in the m-th layer. We select n neurons for input analysis; the input is (x1, x2, x3, x4, ... xj). n ) T The corresponding variable weight matrix is:
[0098]
[0099] S303, Network Input The analysis is based on the formula for the variable weight matrix, as follows:
[0100]
[0101] S304, where the network output y j As shown in the formula f(*) is an activation function, and the network output y j The formula is as follows:
[0102]
[0103] The formulas for the S305 and sigmoid activation functions are:
[0104]
[0105] S306. The Hippo Optimization Algorithm (HO) optimizes the structure of a backpropagation (BP) neural network. In the HO algorithm, the hippo is a candidate solution to the optimization problem, meaning that updating the position of each hippo in the search space represents an adjustment of the decision variable's value. Specifically, when using HO to optimize the structure of a BP neural network, the initialization phase of the HO algorithm requires generating a random initial solution. During this process, the decision variables are generated according to the following formula:
[0106] χ i :x ij =lb j +r(ub j -lb j )
[0107] In the formula, χ i This represents the position of the i-th candidate solution, where r is a random number in the range [0,1], and lb... j and ub j Let represent the lower and upper bounds of the j-th decision variable, respectively;
[0108] By simulating hippopotamus characteristics, a dynamic balance between exploration and development is achieved. Position updates driven by random perturbations and fitness are used to optimize neural network weights and biases, thereby improving model performance. Specifically, HO optimization, driven by random perturbations and fitness, optimizes neural network weights and biases through position updates.
[0109] Furthermore, in S6, performance evaluation metrics are used to verify the SOC prediction accuracy of the final data prediction model, including the following:
[0110] Mean Squared Error (MSE): Reflects the squared mean of the differences between predicted and actual values, used to measure the overall error of the model's predictions. The formula is:
[0111]
[0112] Root Mean Square Error (RMSE): Reflects the degree of fluctuation in prediction error, and the formula is:
[0113]
[0114] Mean Absolute Error (MAE): The mean absolute error between the predicted SOC and the actual SOC, calculated using the following formula:
[0115]
[0116] Coefficient of determination R 2 The formula for evaluating the model's explanatory power for SOC change trends is:
[0117]
[0118] In the formula, n represents the number of samples of observation data, y i This represents the true value of the actual data points, which is the target that the model needs to approximate. The model represents the χ² value. i The prediction results need to be optimized to reduce the correlation with y. i The quantity of the difference This represents the sample mean of the dependent variable y, which is the average of all actual values.
[0119] For further details, please see the appendix. Figure 4 As shown, the HO-BP-Hammerstein model is constructed, including: a nonlinear static module: using a BP neural network to establish the mapping relationship between current, voltage and historical SOC sequence data;
[0120] Dynamic linear module: Based on least squares fitting to predict dynamic changes in SOC.
[0121] and Figure 1 and 2 Corresponding to the method described above, this invention also discloses a battery state-of-charge prediction system based on the HO-BP-Hammerstein model, used to execute the battery state-of-charge prediction method based on the HO-BP-Hammerstein model described above, including:
[0122] Data acquisition module: Acquires data during the normal charging process of electric vehicles and labels it as historical charging data;
[0123] Data preprocessing module: preprocesses historical charging data to obtain a standardized input dataset;
[0124] Model building module: Using electric vehicle charging voltage, charging current and historical SOC data as input features, a HO-BP-Hammerstein model driven by the HO algorithm is built;
[0125] Model training module: During the training of the HO-BP-Hammerstein model, the BP optimization module dynamically adjusts the neural network weights through the backpropagation algorithm, with the objective function being to minimize the mean square error between the predicted SOC and the actual SOC. Finally, the HO-BP-Hammerstein model training is completed using the standardized input dataset, resulting in a trained HO-BP-Hammerstein model.
[0126] Model optimization module: Adaptively optimizes the output values of the trained HO-BP-Hammerstein model using error correlation linear analysis to obtain the final data prediction model;
[0127] Prediction module: Input the dataset to be predicted into the final data prediction model to obtain the predicted value of the electric vehicle battery state of charge, and use performance evaluation indicators to verify the prediction accuracy of the final data prediction model.
[0128] The present invention also discloses an electronic device, comprising: a memory for storing historical battery operating data, real-time operating data, and a computer program; and a processor connected to the memory for executing the computer program to implement the battery state of charge prediction method as described in any of the above claims.
[0129] To address the problems of large cumulative error, slow dynamic response, and susceptibility of neural network models to local optima in traditional SOC prediction methods, this invention proposes a HO-BP-Hammerstein composite model. This model uses an optimized neural network to capture the nonlinear dynamic characteristics of the battery and combines this with the linear steady-state characteristics of the Hammerstein model to achieve high-precision SOC estimation. Experiments show that this method significantly reduces prediction errors over a wide temperature range and under complex operating conditions, meeting the high-precision, low-latency SOC prediction requirements of power battery management systems. It can be widely applied in electric vehicles, energy storage systems, and other fields.
[0130] For the system or system embodiments, since they are basically similar to the method embodiments, the description is relatively simple, and relevant details can be found in the description of the method embodiments. The systems and system embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Those skilled in the art can understand and implement this without creative effort.
[0131] The above description of the disclosed embodiments enables those skilled in the art to make or use the invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the invention. Therefore, the invention is not to be limited to the embodiments shown herein, but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. A battery state of charge prediction method based on HO-BP-Hammerstein model, characterized in that, The method comprises the following steps: S1, a data acquisition step, acquiring data of a normal charging process of an electric vehicle and calibrating the data as historical charging data; S2, a data preprocessing step, preprocessing the historical charging data to obtain a standardized input data set; S3, a model construction step, constructing a HO-BP-Hammerstein model driven by a HO algorithm, with the charging voltage, charging current and historical SOC data of the electric vehicle as input features; S4, a model training step, in the training process of the HO-BP-Hammerstein model, a BP optimization module dynamically adjusts the neural network weights through a back propagation algorithm, with the mean square error between the predicted SOC and the actual SOC as an objective function, and finally the HO-BP-Hammerstein model is trained using the standardized input data set to obtain a trained HO-BP-Hammerstein model; S5, a model optimization step, the output value of the trained HO-BP-Hammerstein model is subjected to error correlation linear analysis for adaptive optimization to obtain a final data prediction model; S6, a prediction step, inputting a to-be-predicted data set into the final data prediction model to obtain an electric vehicle battery state of charge prediction value, and verifying the prediction accuracy of the final data prediction model by using a performance evaluation index.
2. The battery state of charge prediction method based on the HO-BP-Hammerstein model according to claim 1, wherein the data of the normal charging process of the electric vehicle in S1 is multi-dimensional real-time data, including the initial SOC of the vehicle power battery, the real-time SOC of the vehicle power battery, the internal temperature of the vehicle electric vehicle charger, the temperature of the vehicle electric vehicle charging module, the highest / lowest / average voltage of the vehicle on-board battery pack single battery, the highest / lowest voltage parameter information of the vehicle on-board battery pack charging permission, the highest / lowest current parameter information, and the parameter information of the highest / lowest temperature.
3. The battery state of charge prediction method based on the HO-BP-Hammerstein model according to claim 2, wherein the specific content of the data preprocessing step S2 is: performing outlier rejection, normalization processing and feature engineering on the historical charging data to generate a standardized input data set, which comprises the following steps: S201, filling in the abnormal voltage / current values in the historical operation data by using a cubic spline interpolation method; S202, normalizing the data by using a range standardization method, and the normalization formula is as follows:
4. The battery state of charge prediction method based on the HO-BP-Hammerstein model according to claim 3, wherein in the model construction step S3, the HO-BP-Hammerstein model driven by the HO algorithm adopts a composite architecture design: the nonlinear static module adopts a HO-BP neural network and a dynamic linear module in cascade, and is defined as follows: In the formula, data input represents a normalized data value; data represents original data; data max and data min represent the maximum and minimum values in the original data; data min represents the i-th value in the original data. α(z)SOC(t)=β(z)S(t)+V(t) In the formula, S(t) is the output of the nonlinear module and the input of the linear module, V(t) is random white noise, and α(z) and β(z) are known polynomials in Z; The dynamic linear module describes the time-series characteristics of the battery's dynamic response based on the least squares method.
5. The battery state-of-charge prediction method based on the HO-BP-Hammerstein model according to claim 4, characterized in that, The specific steps involved in building an S3 model include the following: S301. Construct a BP neural network architecture, including an input layer, hidden layers, and an output layer. The formula for the three-layer BP neural network structure is as follows: In the formula, H represents the number of hidden layers, n represents the number of input layers, m represents the number of output layers, and α is a variable in the range of 1 to 10; S302、Random neurons is the jth neuron of the mth layer, and n is selected for input analysis; the input is (x1, x2, x3, x4,... x n ) T The corresponding variable weight matrix is: S303、network input Analysis is made according to the variable weight matrix formula, and the formula is as follows: S304、where y is the output of the network j As formula f(*) is an activation function, y is the output of the network j The formula is as follows: The formulas for the S305 and sigmoid activation functions are: S306. The HO algorithm is used to optimize the structure of the BP neural network. During the initialization phase of the HO algorithm, a random initial solution needs to be generated. In this process, the decision variables are generated according to the following formula: χ i :x ij = lb j +r(ub j -lb j ) where χ i represents the position of the i-th candidate solution, r is a random number in [0, 1], lb j and ub j respectively represent the lower and upper bounds of the j-th decision variable; By optimizing HO, the position updates driven by random perturbations and fitness optimize the neural network weights and biases.
6. The battery state-of-charge prediction method based on the HO-BP-Hammerstein model according to claim 5, characterized in that, In S6, performance evaluation metrics are used to verify the SOC prediction accuracy of the final data prediction model, including the following: Mean Squared Error (MSE): Reflects the squared mean of the differences between predicted and actual values, used to measure the overall error of the model's predictions. The formula is: Root Mean Square Error (RMSE): Reflects the degree of fluctuation in prediction error, and the formula is: Mean Absolute Error (MAE): The mean absolute error between the predicted SOC and the actual SOC, calculated using the following formula: Coefficient of determination R 2 : assess the explanatory power of the model for the trend of SOC, formula: where n denotes the number of samples of the observation data, y i denotes the true value of the actual data point, denotes the prediction of the model for χ i , and denotes the sample mean of the dependent variable y, i.e. the average of all actual values.
7. The battery state-of-charge prediction method based on the HO-BP-Hammerstein model according to claim 6, characterized in that, Nonlinear static module: A BP neural network is used to establish the mapping relationship between current, voltage and historical SOC sequence data; Dynamic linear module: Based on least squares fitting to predict dynamic changes in SOC. 8.A battery state of charge prediction system based on HO-BP-Hammerstein model, characterized in that, A method for predicting the state of charge of a battery based on the HO-BP-Hammerstein model as described in any one of claims 1-7 includes: Data acquisition module: Acquires data during the normal charging process of electric vehicles and labels it as historical charging data; Data preprocessing module: preprocesses historical charging data to obtain a standardized input dataset; Model building module: Using electric vehicle charging voltage, charging current and historical SOC data as input features, a HO-BP-Hammerstein model driven by the HO algorithm is built; Model training module: During the training of the HO-BP-Hammerstein model, the BP optimization module dynamically adjusts the neural network weights through the backpropagation algorithm, with the objective function being to minimize the mean square error between the predicted SOC and the actual SOC. Finally, the HO-BP-Hammerstein model training is completed using the standardized input dataset, resulting in a trained HO-BP-Hammerstein model. Model optimization module: Adaptively optimizes the output values of the trained HO-BP-Hammerstein model using error correlation linear analysis to obtain the final data prediction model; Prediction module: Input the dataset to be predicted into the final data prediction model to obtain the predicted value of the electric vehicle battery state of charge, and use performance evaluation indicators to verify the prediction accuracy of the final data prediction model.
9. An electronic device, comprising: include: The memory is used to store historical battery operating data, real-time operating data, and computer programs. A processor, connected to a memory, for executing a computer program to implement the battery state-of-charge prediction method as described in any one of claims 1-7.