Abstract
An appropriate energy management strategy is crucial to achieving energy-saving and emission-reduction goals for plug-in hybrid electric buses (PHEB). This study proposes an adaptive equivalent consumption minimization strategy (A-ECMS) considering the driving cycle recognition based on the P2 configuration to achieve dynamic real-time adjustment of the equivalent factor (EF). First, local driving conditions are collected and preprocessed using an intelligent transportation system (ITS). Second, features are extracted from the speed window using the sliding window method, and an algorithm combining Particle Swarm Optimization and a Support Vector Machine (PSO-SVM) is used for driving cycle data classification prediction and relevant parameter optimization. Moreover, three key parameters-EF, the penalty factor, and the transmission ratio of the main reducer-are optimized using the Grey Wolf Optimizer (GWO) to reduce operating costs, and model simulations are conducted for verification. The comparison between the simulation results and the hardware-in-the-loop (HIL) test results shows that the proposed strategy can achieve excellent fuel economy, which is consistent with the expected results.
Keywords
Introduction
To address the global energy crisis and environmental pollution, hybrid electric vehicles (HEVs) have emerged as highly effective alternatives to replace traditional fuel vehicles.1–4 The advancement of electrification and hybridization technologies has enabled the electric motor to become a primary power source, comparable to the internal combustion engine.5,6 P2 configuration plug-in hybrid electric vehicles (PHEVs) have become the most popular hybrid configuration due to their ability to achieve better performance and fuel economy with minimal modifications. 7 With the increasing recognition of new energy vehicles by the public, many new energy buses have also emerged in public transportation. Similar to how advanced motor control methods can improve the steady-state and transient performance of motors, 8 an effective energy management strategy (EMS) can fully utilize the performance advantages of HEVs, improve fuel economy,9,10 reduce operating costs, and enhance the service life of various components.
Due to the characteristics of multiple energy sources, an effective energy management strategy plays a vital role in the rational allocation of energy use in hybrid power systems. 11 Compared to rule-based strategies, optimization-based and learning-based control strategies have gained significant prominence in recent research. Optimization-based methods can be further divided into global optimization and instantaneous optimization approaches. Dynamic programming (DP) is a representative global optimization method; however, due to its discrete backward-solving nature and the curse of dimensionality, it is typically unsuitable for real-time online applications. On the other hand, Pontryagin’s Minimum Principle (PMP) 12 and equivalent consumption minimization strategy (ECMS)13,14 are commonly used for instantaneous optimization. Instantaneous optimization approximates the cost function using rolling optimization and iterative methods to seek optimal control variables. For example, 15 compared DP with PMP and ECMS while considering battery aging, reporting fuel consumption differences of 2.1% and 2.8%, respectively. Additionally, 16 proposed an adaptive ECMS approach with neural network-trained shifting, which increased fuel consumption by only 3.23% compared to DP while significantly reducing computational effort. It is evident that different strategies are typically evaluated based on their proximity to DP in terms of effectiveness. Learning-based strategies have gradually become mainstream energy management strategies with the rise of artificial intelligence. 17 Researchers often employ this strategy to predict vehicle states and learn optimal control behaviors.18–21 Due to its high accuracy and strong adaptability, it exhibits significant advantages in highly nonlinear control scenarios. 22 proposed a hierarchical control framework for HEVs by combining numerical optimization with deep learning, enabling real-time joint optimization of vehicle driving cycles and powertrain energy management. 23 innovatively utilized Q-learning to investigate the adaptability of supervised control for HEVs, demonstrating good fuel economy under different driving conditions. Meeting the increasingly diverse control requirements for HEVs proves challenging for a single control strategy. Various complex road conditions necessitate vehicles to possess adaptive capabilities, while ever-changing driving environments require vehicles to utilize internal and external information for online data prediction. This calls for control strategies that can integrate real-time data processing with computers. Moreover, addressing nonlinear optimization with multiple variables and constraints requires suitable methods. Therefore, there is a need to combine artificial intelligence with instantaneous optimization of vehicles to form a more efficient and precise control strategy.
The acquisition and processing of driving cycles fundamentally determine the distribution and control of internal energy in HEVs. The ability to obtain future driving cycle information in advance enables real-time online vehicle control, achieving near-DP global optimization performance. There are generally two methods for obtaining future driving cycle information: 24 utilizing established future speed prediction models based on historical vehicle speed data,25–27 or collecting surrounding driving environment and traffic information through increasingly advanced intelligent transportation system (ITS)28,29 and emerging technologies such as V2X. 30 With the support of driving cycle data, driving cycle classification recognition can be introduced to realize the adaptive control strategy and improve the sensitivity of driving conditions. For instance, 31 divided driving cycles based on the actual station distribution of PHEBs and established a lookup table using the EF optimization results to achieve real-time online control. Zhang et al. 32 proposed a novel A-ECMS by combining parameter optimization and driving cycle recognition while ensuring good fuel economy and stable battery state of charge (SOC). Considering that equivalent factor (EF) varies according to changes in the actual driving conditions, online ECMS strategies and driving cycle recognition predictions should be combined to further enhance the performance of ECMS under real driving conditions compared to its lower generality and real-time capability in offline ECMS. 33
This paper proposes an adaptive equivalent consumption minimization strategy (A-ECMS) based on driving cycle recognition and factor optimization. First, the local condition data is collected using the on-board speed testing system, and the actual condition of the bus in the city is obtained after preprocessing. Second, machine learning and intelligent algorithm are combined to classify and predict the driving cycle using the algorithm combined particle swarm optimization and support vector machine (PSO-SVM). Then, the balance between the actual SOC and the reference SOC is considered in the cost function to ensure that the battery energy is reduced to a lower limitation. Finally, grey wolf optimization (GWO) is used to optimize the three parameters, and the optimal control sequence is applied to the vehicle. The primary contributions of this paper are summarized as:
This paper proposes an innovative energy management strategy that integrates driving cycle recognition with parameter optimization, targeting the enhancement of fuel economy for plug-in hybrid electric buses across diverse road conditions. This approach addresses the issue of poor adaptability in energy management strategies under varying driving conditions.
Actual operational data from local urban bus routes were collected and a sample database was established based on both domestic and international standard operating conditions. Employing feature extraction techniques, the data were input into a Particle swarm optimization-Support vector machine model for training, enabling effective identification of driving cycles and providing valuable data resources for subsequent research.
The Grey Wolf Optimizer algorithm was applied to optimize selected parameters, with the outcomes reflected in three classified standard cycles, thereby further enhancing the effectiveness of the energy management strategy. Experimental validation demonstrated that, compared to traditional Equivalent Consumption Minimization Strategy and GWO-ECMS, the proposed strategy significantly reduces fuel consumption. Moreover, HIL testing indicated that this strategy can optimize torque distribution performance, demonstrating its potential for practical applications.
The remainder of this paper is organized as follows. Section II introduces the system model of P2 PHEB, which is the basis of subsequent simulation. Section III presents the driving cycle recognition and optimization algorithm in A-ECMS. In section IV, the theoretical results are simulated based on MATLAB/Simulink platform. Finally, conclusions are given in section V.
Hybrid system analysis and introduction
Currently, various configurations of hybrid electric buses exist worldwide. This study specifically focuses on the P2 configuration, as depicted in Figure 1. The P2 configuration adopts a coaxial parallel layout, incorporating an electric motor and a clutch between the engine and the AMT. A common drive shaft combines the power outputs of the engine and the electric motor. Typically, the electric motor functions as an auxiliary to the internal combustion engine, primarily providing additional power output and startup assistance. It can operate as both a motor and a generator, utilizing the stored electrical energy from the battery to power the vehicle, thereby reducing dependence on the internal combustion engine and enabling energy recuperation and fuel efficiency gains. The relevant parameters for the investigated PHEB are presented in Table 1.

The architecture of the investigated PHEB.
Parameters of powertrain components.
Vehicle longitudinal dynamics
The vehicle’s lateral dynamics and steering dynamics are typically analyzed to ensure handling stability and driving comfort. Fuel economy is typically the primary research objective in the energy management of PHEBs, which is fundamentally tied to the vehicle’s longitudinal dynamics. Therefore, this paper neglects lateral and steering dynamics and focuses exclusively on the longitudinal dynamic equation, expressed as follows:
where F is the driving force, fr is the rolling resistance coefficient, CD is the air resistance coefficient, and it is normally expressed as a function of Reynolds number, θ is the road gradient, Af is the frontal area, ρair is the density of the air, δ is the vehicle rotation mass conversion coefficient, and va is the current vehicle speed.
Engine mathematical model
In the engine modeling of HEVs, it is usually not necessary to conduct a detailed investigation of the individual engine subsystems but rather treated it as integral parts of the overall system. Given the intricacy of the internal systems within an engine, this paper assumes it to be a perfect actuator capable of instantaneously responding to commands, thereby establishing a quasi-static engine model. For the engine, the instantaneous fuel consumption can be expressed as
where Te is the actual torque of the engine; ωe is the rotational speed of the engine; ρf denotes the density of the fuel; be represents the fuel consumption rate.
EM mathematical model
The motor used in this paper is a permanent magnet synchronous motor (PMSM),34–36 which can be modeled in a similar way to the engine, based on the PMSM efficiency map. The desired motor power or torque value can be used as a control input. Depending on whether it operates as a traction motor or a generator, the desired motor power can be mathematically expressed as follows:
where Pelec is the electric power of the motor, Tem and ωem are the torque and angular velocity of the motor, respectively; ηem can be obtained by the Tem and ωem.
Battery model
Electrochemical energy storage systems, such as batteries and capacitors, play a crucial role in storing and recovering energy for powering electric motors. In vehicle simulators, the objective of battery models is typically to predict the variation of SOC under given electrical loads (Figure 2).

The simplified diagram of the battery.
Considering that the number of battery parameters to be identified increases with the model order, this paper simplifies the battery model to an equivalent internal resistance model that only considers efficiency, while disregarding the dynamic characteristics of voltage. The SOC of the battery can be represented as follows:
where I denotes the battery current, Pb, Eb, Rb, and Qb represent the battery power, open-circuit voltage, internal resistance, and battery charge capacity, respectively. The variables t1 and t2 correspond to the start and end times, respectively. Notably, the SOC significantly affects the internal resistance and open-circuit voltage, which considerably impacts fuel economy. Experimental methods are primarily employed to quantify this relationship, as depicted in Figure 3.

The schematic diagram of battery characteristics.
While the simplified equivalent internal resistance model is adopted in this study, it is worth qualitatively discussing the potential impacts of an advanced battery model. In reality, incorporating battery dynamics, temperature dependencies, and capacity aging could further improve the theoretical precision of the ECMS. For instance, temperature variations directly alter the internal resistance, thereby affecting the optimal equivalent factor; meanwhile, considering battery aging allows the strategy to balance instantaneous fuel economy against long-term battery degradation costs. 37 Furthermore, dynamic voltage limits can prevent over-current during sudden accelerations. However, integrating such advanced multi-physics models into online machine learning algorithms and real-time platforms inevitably introduces massive computational burdens and memory footprints. This severe computational overhead can lead to control latency, thereby compromising the real-time feasibility and responsiveness of the A-ECMS. Therefore, to ensure the real-time execution and control stability of the vehicle, the simplified macroscopic model is prioritized in this work as an optimal trade-off.
Energy management strategy and mode switching strategy
Driving cycle recognition is a technique based on vehicle data acquisition and analysis. It aims to identify the driving characteristics of HEVs under various conditions and optimize control strategies accordingly, thereby improving fuel economy and operational efficiency. The holistic control strategy block diagram is depicted in Figure 4.

The proposed driving cycle recognition method.
Construction of local driving cycles and standard driving cycle database
To better evaluate the economy and practicability of the vehicle in real-world applications, this study utilizes the actual operational route of Bus Line 19 in a local city to represent the local driving conditions. This route is a representative operating line in the city, which is demonstrated in Figure 5. Its operation range includes a variety of different functional areas, such as commercial areas, residential neighborhoods, hospitals, schools, and railway stations, covering the smooth road conditions in the suburbs, the congested road conditions in the city center, and the complex and changeable road conditions at the station hub. This route’s operating hours span peak morning and evening periods, offering insights into the daily patterns of human mobility within the city. This system utilizes ground reference station differential data to achieve real-time carrier phase differential positioning, with a positioning accuracy of ±2 cm. Additionally, the integrated GPS navigation module within the system effectively provides real-time GPS data. The sampling frequency selected in the test is 1 Hz.

Testing route in the city.
A fundamental step in implementing the driving cycle recognition algorithm is selecting an appropriate sample database; representative samples significantly enhance the robustness of the ECMS. The studied model of the paper focuses on the P2 hybrid electric bus, with operating routes primarily encompassing urban and suburban conditions within the city, excluding driving scenarios on highways. Therefore, a wide range of driving cycles from both domestic and international sources are extensively chosen to constitute the sample database, as indicated in Table 2.
Domestic and international bus driving cycles.
The standard driving cycle is insufficient to support the required data for training the model. Therefore, the current paper adopts a sliding time window approach to divide the dataset. For each standard driving cycle, window size Δw and step Δs are set. As the window progressively moves from the starting point to the ending point with the step, a segment of data is formed for the kinematic features at each moment within the standard driving cycle, overcoming the problem of insufficient sample size. The schematic representation of the method is illustrated in Figure 6.

The schematic diagram of sliding time window.
To better extract the kinematic segment features, this study selects six representative evaluation parameters from the 62 driving pattern parameters proposed in:38,39 average speed Va, maximum speed Vmax, speed standard deviation Vsd, average acceleration aa, maximum acceleration aamax, and maximum deceleration admax. The selection criteria for these six specific features are based on their strong correlation with the vehicle’s power demand and their ability to minimize data redundancy. Specifically, the speed-related parameters (Va, Vmax, Vsd) effectively reflect the steady-state load and overall kinetic energy, while the acceleration-related parameters (aa, aamax, admax) characterize the transient dynamic demands and the potential for regenerative braking. Together, these six features can comprehensively and concisely depict the actual operating states of the bus without causing the curse of dimensionality during the algorithm training. The specific descriptions and formulas of these parameters are given in Table 3. In these equations, n represents the total number of sampling data points within a specific kinematic segment, i denotes the time index of the sampling point, Vi and ai represent the instantaneous vehicle speed and acceleration at the ith sampling point, respectively.
Kinematic segment characteristic parameters.
Prior to being fed into the SVM model, these extracted features were verified using PCA and a Pearson correlation study. The analysis confirmed that the selected features exhibit minimal multi-collinearity and retain over 80% of the cumulative variance contribution of the original dataset, thereby ensuring computational efficiency and classification accuracy without requiring further high-dimensional feature reduction. The characteristic parameters of driving cycles in the sample database are calculated, and the 11 samples are divided into 3 categories in Table 4 by K-means clustering method, corresponding to three different road conditions in the local driving cycles.
Different categories for sample database.
Driving cycle recognition structure based on PSO-SVM
A Support Vector Machine (SVM) is a generalized linear classifier employing supervised learning for binary classification. The selection of SVM as the primary online classification algorithm in this study is driven by its excellent generalization capability and computational efficiency, which are crucial for real-time vehicular control systems.40,41 While advanced deep learning methods exist, they typically require extensive computational overhead and memory footprints, limiting their feasibility on embedded vehicle controllers. Unsupervised learning methods, such as the K-means algorithm, are highly effective for offline data clustering and were therefore utilized in Section III-A to establish the fundamental driving cycle categories without predefined labels. However, K-means lacks the predictive mapping mechanisms required for real-time instantaneous state identification. 42 In contrast, supervised learning methods like SVM are specifically designed for online predictive classification. It aims to find the optimal separation hyperplane that correctly partitions the training dataset while maximizing the geometric margin. By combining offline K-means clustering with online SVM classification, the proposed strategy achieves an optimal balance between robust category definition and real-time recognition accuracy. Given a set of samples Dn={(xi,yi), i=1,2,…,n}, the distance d from the support vector to the hyperplane can be expressed as:
where w and b represent weight vector and weight bias, respectively. Hard margin SVM can be transformed into an equivalent quadratic convex optimization problem for solving:
Due to the challenge of finding completely linearly separable data in practical applications, a new optimization problem can be constructed by introducing a loss function on the basis of maximizing margins. The relaxation variable ξ and penalty factor C are introduced to evaluate its softness and hardness, and the original optimization problem is rewritten as:
The optimization problem of soft margin SVM is defined as the primal problem, and the dual problem of the primal problem can be obtained by introducing Lagrange multipliers:
If the data are not linearly separable in the original vector space, they must be mapped to a higher-dimensional space. The kernel function is introduced instead of the inner product calculation to prevent the dimensionality of the mapped vector space from being too large.
Particle swarm optimization (PSO) is a heuristic algorithm combining evolutionary algorithm and artificial life ideology, which has the characteristics of few parameters and fast convergence. Considering that the hyperparameters C and g in SVM greatly impact the model’s recognition and prediction ability, the paper utilizes the PSO algorithm to optimize the hyperparameters in SVM to achieve the optimal performance of the model. The parameter C serves as a penalty coefficient in SVM, facilitating the control of the degree of punishment for misclassified samples. On the other hand, the parameter g represents a parameter of the kernel function, exerting an influence on the scope of the radical basis function kernel (RBF kernel). The flow chart of the PSO-SVM algorithm is depicted in Figure 7.

Flow chart of PSO-SVM algorithm.
Figure 8 demonstrates the principle of the driving cycle recognition algorithm under the application of PSO-SVM. Data sampled over the past duration constitute a sampling window used to calculate characteristic parameters in real time at the current time. Based on the analysis of the sampling window, the future time tp constitutes the prediction window, and the driving cycle category is reflected in this window. The sampling window and prediction window together constitute the process of a driving cycle recognition. 43 Upon completion of all driving cycle recognitions, the set of predicted cycles constitutes the final recognition result, with the entire local driving cycle being composed of three pre-defined categories.

Schematic diagram of driving cycle recognition.
The optimal control strategy
As a heuristic method to solve the optimal control problem, the basic principle of ECMS is to allocate a part of the energy consumption cost to electrical energy, so that electrical energy is an equivalent substitute for fuel consumption. In the ECMS definition, instantaneous equivalent fuel consumption can be divided into actual instantaneous fuel consumption and electric equivalent fuel consumption:
where
Meanwhile, the equivalent factor s(t) is introduced to evaluate the average overall efficiency of the electric path under specific driving cycles. Consequently, the electrical equivalent fuel consumption can be expressed using the equation containing the equivalent factor:
where Qlhv is the low heating value of the fossil fuel and Pbatt(t) is the battery’s power; SOCref is the reference value of battery SOC, and λp depicts the scale factor of the penalty function. In the penalty function p(SOC), the paper considers that reliable online SOC estimation can be achieved when a = 3. The reference SOC of the vehicle is obtained from the model via DP algorithm.
The equivalent fuel consumption rate under instantaneous conditions can be solved through EF in ECMS, while optimizing the instantaneous optimal output power of the engine and motor involves calculating the instantaneous power demand and constraining the power control range of the engine and motor. The constraint range is determined based on the given system state. After discretizing the upper and lower limits of the control variables into a set of discrete control variable candidates, the corresponding instantaneous fuel consumption can be calculated. Finally, the optimal control sequence under the cost function is calculated. The vehicle state and control variables can be constrained as
where
Parameter optimization based on GWO
Research on HEVs typically focuses on fuel economy as the primary optimization objective. Furthermore, it is imperative to utilize real-time SOC to track the reference SOC to attain the battery depletion curve, which closely aligns with DP principle, thereby achieving optimal fuel consumption. The selection of equivalent factor (s) in ECMS will greatly influence fuel economy. An excessively large s would increase the vehicle’s electricity consumption cost, leading to a preference for using the engine and consuming fuel. Conversely, a smaller s would incline the vehicle toward using the electric motor, resulting in rapid battery depletion. In addition, considering the transmission system, the change of the transmission ratio of the main reducer fd will also impact the vehicle’s performance. HEVs are greatly affected by external environmental factors during the driving process. A single parameter setting is insufficient to meet the requirements of different road conditions, necessitating real-time adjustments for enhanced adaptability under complex driving cycles. Therefore, the state variables and the cost function are defined as:
where xp represents optimization variables, J is the fitness function, ω1 and ω2 are the weight factors. In this paper, ω1 is 0.6, and ω2 is 0.4. The rationale for selecting these specific weight values lies in balancing the prioritization of the multi-objective optimization.
The GWO algorithm44–46 simulates wolf leadership and hunting methods, utilizing hierarchical alpha, beta, and delta wolves to perform prey tracking, encircling, and attacking activities. Wolves search for the best solution by gradually approaching and encircling their prey. The location of potential prey is identified by the alpha, beta, and delta wolf guidance during the hunt. The three gray wolves of the best fitness, alpha, beta, and delta, are retained to update the locations of the other search agents for each iteration, and the other wolves are under their command to hunt. The optimal result after the final iteration is the optimal value of alpha. GWO is used to optimize ECMS in three typical driving cycles, and the corresponding parameter combinations are obtained. The optimized parameter combinations are stored in a parameter library. During real-time operation, the corresponding parameters are extracted based on the driving cycle recognized by the PSO-SVM algorithm, thereby improving the vehicle’s fuel economy.
Simulation results and discussion
Local driving cycle construction result
To accurately determine the actual driving cycle of PHEBs, the paper conducts driving cycle construction on a local representative bus route through the collection, preprocessing, and synthesis of raw driving data. A vehicle tracking methodology utilizing inertial navigation systems is employed on typical local bus routes to obtain speed information. To mitigate the noise in the collected data, a Savitzky-Golay filter is applied to smooth the velocity signal, thereby aligning it more closely with the requirements of experimental processing.
Figure 9 shows the result of a local cycle after processing. In the driving cycle, the acceleration of the vehicle in the accelerating state is not less than 0.15 m/s2, the acceleration of the vehicle in the decelerating state is not higher than 0.15 m/s2, and the vehicle’s uniform motion maintains accelerations within the range of [−0.15,0.15] m/s2. In order to be close to the real driving environment of the station, the driving cycles between the stations are regarded as kinematic segments, and the influence of a few types of kinematic segments is ignored to some extent. Parameters such as average vehicle speed, average acceleration, and velocity standard deviation in the operating conditions show errors within 5% compared to the raw data, indicating that the driving cycle can reflect the bus route’s driving characteristics, close to the real-world driving cycle.

Processed local driving cycle.
Driving cycle recognition result
This study utilizes a sliding time window to extract features from all samples in the database, which comprises 11 standard bus driving cycles, and the samples are divided into 1,079 kinematic segments. The window size Δw is set to 150 s with a step Δs of 10 s. All kinematic segments are trained in PSO-SVM, 70% are used for learning and training the model, and the remaining 30% are used for data validation and testing. The training results are depicted in Figure 10. The errors of each category are within 10%, and the overall training and test accuracy reach 99.0278% and 94.7531%, respectively, which reflects the reliability of the model performance.

(a) Training set result; (b) classification results for the testing set.
Based on the assumption that the driving conditions will not change suddenly in a short period, the driving cycles in the future are predicted by extracting information from past driving cycles online. To ensure recognition accuracy, it is not appropriate to use too long or short recognition segments. An acceptable range is generally between 100–200 s. The historical data extraction window ts of 150 s is selected for recognition, while the driving cycle prediction window length tp is set at 10 s. Regarding the sensitivity of the recognition accuracy to the historical data extraction window, preliminary analyses indicated a clear trade-off. A shorter window (ts < 100 s) makes the model overly sensitive to transient noise and reduces accuracy due to insufficient kinematic feature accumulation. Conversely, an excessively long window (ts > 200 s) incorporates outdated driving conditions, leading to recognition lag and diminished sensitivity to actual cycle transitions. Consequently, ts = 150 s was determined to be the optimal threshold, yielding robust accuracy. Furthermore, regarding the internal parameters of the SVM, their sensitivity was autonomously managed and optimized globally by the PSO algorithm, ensuring that the classifier avoids local optima and remains robust. A combined driving cycle is selected from the three categories in the sample database to verify the rationality of the parameter settings. Three driving cycles are CYC_MANHATTAN, CHTC_B, and CHTC_C_SUB, respectively. The recognition results, as shown in Figure 11, indicate an accuracy of 89.89% using the PSO-SVM-based method, demonstrating excellent performance.

Recognition results under standard combination driving cycles.
The trained model is used to identify the local driving cycle constructed in Section III-A, and the recognition results are illustrated in Figure 12. Based on the classification and recognition results presented above, category 3 signifies suburban bus driving cycles, typically characterized by higher average and maximum speeds and relatively smaller acceleration variations. In the local driving cycle, the vehicle’s speed mostly remains below 45 km/h. However, frequent acceleration variations are observed at some traffic intersections, deviating from the requirements of category 3. Consequently, the local driving cycles predominantly exhibit urban bus cycles represented by categories 1 and 2, with only occasional instances of category 3 driving cycles occurring within the initial 500 s of the whole driving process.

Recognition results under local driving cycles.
Optimization results
The paper employs MATLAB/Simulink platform to simulate the model, and the step size is set to 0.1 s to ensure the accuracy of the simulation. Based on the identified driving cycles, representative standard cycles are selected from the database to optimize key parameters. Each of the three selected cycles (CYC_MANHATTAN, CHTC_B, and CHTC_C_SUB) is repeated five times consecutively for the simulation. The final optimization results are listed in Table 5.
The optimization results under three representative driving cycles.
Figures 13 to 15 respectively depict schematic diagrams of vehicle performance before and after optimization under three representative driving cycles. The initial SOC of the vehicle battery is set to 90%, and each driving cycle repeats five times to ensure that the battery energy is completely depleted to the minimum value of 30%. The vehicle models employed in the three driving cycles effectively track the required vehicle speeds, demonstrating the accuracy and applicability of the models. Moreover, when battery energy is ensured to reach the minimum limit in all three driving cycles, fuel consumption is reduced by 10.6%, 11.7%, and 7.4%, respectively.

Simulation results of the CYC_MANHATTAN: (a) velocity; (b) engine; (c) motor; (d) SOC.

Simulation results of the CHTC-B: (a) velocity; (b) engine; (c) motor; (d) SOC.

Simulation results of the CHTC_C_SUB: (a) velocity; (b) engine; (c) motor; (d) SOC.
The paper uses the local driving cycles of five operation shifts of the PHEB to verify the effectiveness of the driving cycle recognition strategy. Based on the recognition results shown in Figure 13, the optimized key parameters corresponding to each recognized standard driving condition are updated in real-time. The speed tracking effect and torque distribution obtained are shown in Figure 16. The accurate speed tracking results verify the effectiveness of the constructed local driving cycles and demonstrate a well-optimized torque distribution.

The (a) speed tracking effect; (b) details for speed tracking effect; (c) engine torque distribution under the local driving cycle; (d) motor torque distribution under the local driving cycle.
Figure 17 illustrates that in normal ECMS implementation, PHEB cannot adjust EF based on real-world driving cycles, leading to a noticeably oversized default setting of EF under the local driving cycle. The higher electrical cost of the vehicle inclines it toward fuel usage, resulting in elevated fuel consumption, while the battery capacity cannot be depleted to 30%. By contrast, although the GWO-ECMS ensures battery depletion, its charge depleting (CD) mode ends prematurely at approximately 10,800 s, at which point the vehicle enters the charge sustaining (CS) mode. In the CS mode, the PHEB is unable to further adjust engine operating efficiency and relies solely on the energy recovered through regenerative braking. Consequently, fuel consumption during this mode increases rapidly. Figure 18 shows the comparison of several strategies. Compared to the conventional ECMS, the proposed strategy reduces fuel consumption by 14.18%, achieving results that are only 3.02% higher than those of the DP algorithm. The proposed strategy adeptly tracks and closely approximates the reference SOC trajectory of DP, indicating its efficacy in meeting expected outcomes.

Comparison of (a) battery SOC; (b) fuel consumption under different strategies.

The fuel consumption with different strategies.
HIL test experiment
To ensure the reliability and accuracy of the simulation results, a hardware-in-the-loop (HIL) test is conducted to verify the proposed strategy. The schematic diagram of the HIL platform is shown in Figure 19.

Diagram of the HIL simulation.
The platform is configured using VeriStand software, including the configurations of digital I/O boards, analog I/O boards, and CAN signals. The controlled object model of the hybrid electric vehicle is initially compiled by MATLAB/Simulink platform, and Dynamic Link Library (DLL) files are generated and embedded into VeriStand. The communication protocol matrix (DBC) file is written to realize the connection between the vehicle controller CAN signal and the controlled object model. The schematic diagram of the HIL test platform is shown in Figure 20.

HIL test platform.
The PHEB energy management controller is the most critical part of the HIL experiment. The construction of the controller in this paper is mainly based on the MotoHawk module library developed on the Simulink platform. Firstly, the corresponding project file needs to be created according to the controller communication protocol and the model of the controller board. Secondly, the control program is written into the project file, and the controller simulation step size is preset. Finally, the project file is compiled and flashed onto the physical controller via the host PC. Through the above steps, the construction of the HIL controller can be completed.
The paper selects the local driving cycle for the HIL test to verify the torque distribution. Figure 21 shows the torque distribution of both the engine and motor under the local driving cycle, from 4,765 s to 4,805 s. While the overall test results align closely with simulation tests, localized torque exhibits slight oscillations around the simulation results, indicating the difference between the physical controller and simulation.

Results of the HIL test: (a) engine torque; (b) motor torque.
To improve readability and clearly demonstrate the transient differences, magnified local views of the engine and motor torque distribution during the HIL test are additionally provided in Figure 22. Furthermore, computational efficiency is a critical metric for evaluating real-time viability. During the HIL testing, the control step size of the energy management controller was configured to 10 ms. Monitoring via the host PC revealed that the average execution time for the proposed A-ECMS algorithm was approximately 5.2 ms to 6.5 ms per control cycle. Since the execution time is strictly well below the 10 ms task cycle threshold, it guarantees that no task overruns occur. This test underscores that the proposed energy management strategy can adequately meet the vehicle’s dynamic demands in real-time hardware environments.

Details of total torque distribution in HIL test.
Conclusion
This paper proposed an ECMS strategy that combines driving cycle recognition and parameter optimization to improve the fuel economy of PHEB by addressing the poor adaptability of vehicles under different road conditions. To demonstrate the effectiveness of this strategy, actual data from a bus route in a local city were collected. A sample database was established based on domestic and international standard operating conditions for buses. Following feature extraction, the sample data were fed into the PSO-SVM model for training, achieving accurate driving cycle recognition. Furthermore, the optimized results of selected parameters under GWO were reflected in the three standard cycles obtained through classification. Compared to ECMS and GWO-ECMS, fuel consumption is reduced by 3.3 L and 0.78 L, respectively. Lastly, HIL test results indicated that the proposed strategy could optimize torque distribution performance.
This work still has some limitations. The accuracy of the driving cycle recognition still needs further improvement. Meanwhile, more factors can be considered as the basis for identification in the future, such as driver style and safe driving. Furthermore, as the complexity of energy management increases, managing the computational burden becomes a critical challenge. To address this, advanced optimization techniques, such as distributed optimization algorithms, 47 could be investigated in future work.
Footnotes
Handling Editor: Aarthy Esakkiappan
Funding
The authors disclosed receipt of the following financial support for the research, authorship, and/or publication of this article: This work was supported by the “Smart Fruit” Action Plan (Guangxi Science and Technology Achievement Transformation Plan) under Project ZG2503980022.
Declaration of conflicting interests
The authors declared no potential conflicts of interest with respect to the research, authorship, and/or publication of this article.
