Keywords

1 Introduction

The transportation industry is actively developing hydrogen-fuelled hybrid trains to reduce pollution emission levels due to the green and efficient nature of new energy sources and the shift in energy layout. When used as a power source in vehicles, fuel cells have soft output characteristics and poor dynamic performance, so they are slow to transmit power and need to be used in conjunction with auxiliary energy sources such as batteries [1]. Hybrid systems offer high energy and power densities and better vehicle dynamics, but they also require energy management systems to distribute energy between multiple sources for optimum efficiency and performance [2]. Current hybrid energy management strategies have evolved into two main categories, namely rule-based control and optimization-based control.

The rule-based algorithm relies on knowledge of the operating characteristics of the hybrid system components as well as relevant engineering experiences, such as State Machine Control (SMC) and the Wavelet-fuzzy Logic Control (WFLC) type of strategy. Zhang et al. [3] proposed a power allocation algorithm based on wavelet decomposition for energy management. Caux et al. [4] tested an online fuzzy logic algorithm, and Erdinc et al. [5] built upon this research by integrating the algorithms of wavelet decomposition and fuzzy logic.

Optimization-based algorithms include Dynamic Programming (DP), Equivalent Consumption Minimization Strategy (ECMS), and Pontryagin’s Minimum Principle (PMP), in which ECMS and PMP are instantaneous optimization algorithms and DP is a global optimization algorithm. Motapon et al. [6] discuss a comparative analysis between different optimal power allocation methods. A popular selection technique for optimal power allocation in hybrid vehicles is dynamic programming (DP). This method is widely used to control the degree of mixing between sources of vehicles, whether they are internal combustion engine (ICE) based or purely electric [7]. This algorithm is used to solve recursive problems, guarantees optimality within a certain tolerance range, and is easy to implement [8]. The main problem with DP is the dimensional catastrophe, where the number of states grows exponentially with time [9]. In [10], DP was used to test the impact of battery weight and storage capacity on the cost of operation.

2 Efficient Energy Management Strategies Based on Dynamic Programming Algorithms

2.1 General Formulas for Dynamic Programming

This paper investigates the problem of distributing the power of the fuel cell and the battery so that the cost function is minimized subject to constraints. The entire run time is discretized into T phases by step ∆t, which are equally spaced along the length of the driving cycle.

The power of the fuel cell or the power of the battery can be considered as the control vector. By fixing one, the other can be derived from the power balance equation, so this power fixing method helps to solve the problem more easily and is easy to program. In this case, the fuel cell power is chosen as the control vector, and the control vector x consists of a range from the lower fuel cell power limit PfcL to the upper fuel cell power limit PfcH discretized in equal steps. The cell then satisfies the residual capacity requirement within the SOC constraint.

The total number of nodes is S × T, which depends on the number of selected states and time samples. Each of these nodes can be indexed according to its current stage position and corresponding state. For example, node Niuj corresponds to the node at step N and state uj. Equation (1) shows that the total Fiuj cost associated with each node at a certain time step is the sum of its node cost and the minimum value of all transition costs at the node from the previous time step.

$$ F_{{{\text{iuj}}}} = C_{{{\text{iu}}_{{\text{j}}} }} + \min_{k} \left[ {R_{{{\text{u}}_{k} ,{\text{iu}}}} } \right]\quad i = 1:T;j,k = 1:{\text{S}} $$
(1)

2.2 Equation Establishment and Constraint Implementation Method

To simplify the problem, the power required for the vehicle driveline, Preq = Pele + Paux, is first calculated and used as input to the optimization problem. Pdc is the control variable and SOC is the state variable.

Nodal costs and transition costs are defined. The nodal cost shown in (2) calculates the cost of the energy from the fuel cell and the battery. It also treats the braking energy as equivalent to the fuel cell energy. This is because the dissipated energy initially comes from the fuel cell. The cost of the fuel cell considers primarily the cost of hydrogen consumption. This cost also takes into account the cost of electricity in the charging and discharging phases of the battery.

$$ J = \min \sum\limits_{k = 0}^{N - 1} {C_{{{\text{fc}},{\text{k}}}} } + C_{{{\text{bat}},{\text{k}}}} $$
(2)

where Cfc and Cbat are the fuel cell and battery pack costs respectively. These two cost variables can be expressed as in Eq. (3).

$$ \left\{ {\begin{array}{*{20}l} {C_{{{\text{fc}}}} = M_{{{\text{h}}2}} b_{{\text{e}}} P_{{{\text{fc}}}} \Delta t} \hfill \\ {C_{{\text{bat }}} = M_{{\text{ele }}} P_{{\text{bat }}} \left( {\eta_{{{\text{disavg}}}} \eta_{{{\text{chgavg}}}} } \right)^{{ - {\text{sgn}} \left( {P_{{\text{bat }}} } \right)}} \Delta t} \hfill \\ \end{array} } \right. $$
(3)

Mh2 and Mele are the prices of hydrogen and electricity in $/g and $/kWh.

Transition costs are associated with the feasibility of moving from one node to another. When a hop from node to node is infeasible, a very large cost is added to the switching cost. Conversely, if the link is feasible from node to node, the transition costs are low. For the hydrogen fuel cell hybrid system, the power of the fuel cell must be between its lower power limit \({P}_{fc,min}\) and upper power limit \({P}_{fc,max}\), and the rate of change of its power \({\Delta P}_{fc}\) must not be greater than the allowed range of the battery system. The battery also has a lower power limit \({P}_{bat,min}\) and upper power limit \({P}_{bat,max}\), and the power allocated to the battery must be within this range. The battery also has a limit on SOC, which should be between its permissible lower boundary \({SOC}_{L}\) and upper boundary \({SOC}_{H}\). The introduction of the SOC end value constraint, which allows the battery SOC to be the same at the start and end moments to avoid additional charging processes, is important for the control of the power cell SOC during the operating cycle. Equation (4) lists all constraints.

The implementation of the constraint on the final SOC relies on imposing a large transition cost on the paths that deviate from the set value at the final moment T, and this transition cost increases with the degree of deviation, and is expressed as (5).

$$ s.t.\left\{ {\begin{array}{*{20}l} {SOC_{0} = SOC_{E} = SOC_{N} } \hfill \\ {SOC_{L} < SOC < SOC_{H} } \hfill \\ {P_{fc,\min } < P_{fc} < P_{fc,\max } } \hfill \\ {P_{bat,\min } < P_{bat} < P_{bat,\max } } \hfill \\ {\left| {\Delta P_{fc} } \right| < \Delta P_{dc,lmt} } \hfill \\ \end{array} } \right. $$
(4)
$$ C_{{{\text{SOC}}_{ - } {\text{N}},{\text{k}}}} = 10^{\gamma } \left| {SOC - SOC_{{\text{N,k}}} } \right| $$
(5)

The implementation of the constraint on the battery SOC boundary and the constraint on the fuel cell power rate of change relies on imposing a large transition cost at each moment on all nodes that are outside the boundary, forcing the algorithm to find alternative paths, with the expressions as (6–8).

$$ C_{{{\text{SOC}}_{ - } {\text{H}},{\text{k}}}} = \alpha \left( {SOC - SOC_{{\text{H}}} } \right),\quad SOC > SOC_{{\text{H}}} $$
(6)
$$ C_{{{\text{SOC}}_{ - } {\text{L}},{\text{k}}}} = \beta \left( {SOC_{{\text{L}}} - SOC} \right),\quad SOC < SOC_{{\text{L}}} $$
(7)
$$ C_{{{\text{fc}},{\text{ var }},{\text{k}}}} = \begin{array}{*{20}c} {\theta \left( {\left| {\frac{{P_{{{\text{dc}},{\text{k}} + 1}} - P_{{{\text{dc}},{\text{k}}}} }}{\Delta t}} \right| - \Delta P_{{{\text{dc}},{\text{lmt}}}} } \right)^{2} } & {\frac{{P_{{{\text{dc}},{\text{k}} + 1}} - P_{{{\text{dc}},{\text{k}}}} }}{\Delta t} > \Delta P_{{{\text{dc}},{\text{lmt}}}} } \\ \end{array} $$
(8)

The constraint on fuel cell power and the battery is achieved by relying on limiting the decision space to the power of the fuel cell only, which can be achieved indirectly through the power balance relationship on the busbar in Eq. (9).

$$ \begin{gathered} x_{LB} = \max (P_{fc\_\min } ,P_{load} - P_{bat,\max } ) \hfill \\ x_{UB} = \min (P_{fc\_\max } ,P_{load} + P_{bat,\min } ) \hfill \\ \end{gathered} $$
(9)

3 Simulation Validation and Comparative Analysis

3.1 Simulation Model Construction

In order to obtain valid simulation results, the electrical and mechanical parts of the power system of the new-energy hybrid trolley train need to be modeled, consisting of at least five different subsystems as shown in Table 1.

Table 1. Power system subsystems and their description

3.1.1 Fuel Cell System Modeling

The fuel cell model is calculated as follows: the system input variable is the fuel cell power and the output variables are the fuel cell voltage and the instantaneous hydrogen consumption. The fuel cell voltage can be obtained from the polarization curve and the efficiency corresponding to the current power can also be obtained (Fig. 1).

Fig. 1.
figure 1

Fuel cell characteristic curves. (a) FC voltage-current curve. (b) FC efficiency-current curve. (c) FC power-current curve. (d) FC hydrogen flow-current curve.

According to the power efficiency curve and (12), the instantaneous hydrogen flow rate can be found, and the instantaneous hydrogen consumption mH2, LHV is the low heat value of hydrogen, which is taken as 120 kJ/g.

$$ \Delta m_{{{\text{H}}_{2} }} = \frac{{P_{{{\text{fc}}}} }}{{LHV\eta_{{{\text{fc}}}} }},m_{{{\text{H}}_{2} }} = \int \Delta m_{{{\text{H}}_{2} }} dt $$
(10)

3.1.2 DC/DC Model

The DC/DC contains non-linear components. When studying the dynamic characteristics near the steady-state operating point, the system can be seen as approximately linear by means of small signal analysis methods. In this paper, the internal dynamics of the DC/DC are not studied and the joint model is solved by treating the DC/DC as a fixed efficiency.

3.1.3 Battery System

The battery is modeled using the Rint model, where the open circuit voltage, internal resistance, and battery power are functions of the SOC.

The current parameters of the equivalent circuit are calculated from the quadratic equation relating the open circuit voltage, the internal resistance, and the actual power, see (13).

$$ I_{BT} = \frac{{V_{oc} - \left( {\sqrt {V_{oc}^{2} - 4R_{BT} P_{BT} } } \right)}}{{2R_{BT} }} $$
(11)

The SOC is updated according to the current value entered into the block as shown in (14).

$$ {\text{SOC}} \left( {t_{k} } \right) = {\text{SOC}} (0) - \frac{1}{{C_{BT} }}\int_{{t_{0} }}^{{t_{k} }} {I_{BT} } dt $$
(12)

Calculating the open-circuit voltage and internal resistance of the battery from the current SOC value and the temperature value by looking at the table. The battery parameters are shown in Fig. 2.

Fig. 2.
figure 2

Battery characteristics curve. (a) Discharge resistance curve. (b) Charge resistance curve. (c) Open circuit voltage curve. (d) Internal resistance–temperature curve.

3.2 Simulation Results and Comparison

In this paper, the power-time curve of a specific 20 km experimental line, derived using the minimum time operation approach discussed earlier, is used as the optimization object. The optimal strategy aims to minimize the hydrogen consumption cost of the line, and the effectiveness and applicability of the method are demonstrated by a large number of simulations and comparative experiments. The proposed method is compared with the SOC balancing strategy, which was proposed and tested by Zhang et al. [11].

3.2.1 The Impacts on Hydrogen Consumption Costs and Power Performance

The power distribution derived from the optimization algorithm and the SOC algorithm is shown in Fig. 3.

Fig. 3.
figure 3

Algorithm power allocation comparison chart. (a) Power distribution under the DP algorithm. (b) Power distribution under SOC balancing algorithm.

Fig. 4.
figure 4

Comparison of hydrogen consumption costs and battery power. (a) Comparison of hydrogen consumption costs. (b) Battery power distribution details.

Using the hydrogen consumption cost and the system power index as the evaluation criteria, the cost of hydrogen consumption for the optimization algorithm for the whole working condition is about $34.13, while the cost of the SOC equalization algorithm is about $43.26. The optimization algorithm saving of about 21%, as shown in Fig. 4(a). For the power distribution case, the SOC balancing algorithm has more aggressive requirements for the upper limit of power battery charging power, which can only be solved by limiting the power performance of the train or by means of braking resistors when the upper limit of power battery charging power cannot be met, whereas the optimization algorithm can achieve the characteristics of each system component through algorithmic constraints, as shown in Fig. 4(b). Therefore, the optimization algorithm has advantages over the SOC balancing algorithm, both in terms of cost savings and power performance.

3.2.2 Study of the Strength of the Terminal Value Constraint

Many scholars have proposed to make the initial SOC and the end-state SOC equal, but for a hydrogen-fuelled train, the cost of hydrogen is much higher than that of the battery, and an appropriate relaxation of the end-state SOC constraint can reduce the cost.

Fig. 5.
figure 5

Final value constraint effects. (a) Effect on cost. (b) Effect on SOC.

Where γ is the weighting factor presenting the degree of strain. A smaller weighting factor γ indicates a weaker degree of constraint. The SOC end-state value deviates downward from the preset value and the hydrogen cost decreases as shown in Fig. 5. At different levels of constraint, the optimization algorithm finds the path that minimizes the total cost. Rely on adjusting γ to find a balance between the game objectives of hydrogen cost and SOC end-state value.

Fig. 6.
figure 6

Effect of different initial SOC. (a) Effect on SOC. (b) Effect on cost.

3.2.3 Effect of Different Initial SOC

The effect of different initial SOC on the hydrogen cost is also more significant, as can be seen from Fig. 6(a), where the algorithm can make the final SOC all converge to the same point for different initial SOC. As the SOC of the initial state increases, the hydrogen consumption cost will then decrease. The reason for this is that when returning to the same final SOC, the battery in the group with a higher initial SOC will discharge more, resulting in the need for the fuel cell to deliver less energy, so its overall cost shows a decreasing trend.

3.2.4 Comparison of Different Average Demand Powers

For the 20 km power-time line data, the mean power is 95.75 kW, beyond which the train has an auxiliary power portion that can be considered a constant power rating, which varies greatly in magnitude depending on the season and electrical equipment on board, and whose trend is analyzed by applying an offset of x kW to the 20 km time-power data. The curves for SOC under both algorithms shift from high to low as the average power increases, but the optimization algorithm’s final state SOC is more biased toward being less than 60, whereas the SOC balancing algorithm is more biased toward being greater than 60, and it is clear that the curve of the optimization algorithm favors the choice of control sequence with lower costs of hydrogen consumption. Figure 7(c) shows that the optimization algorithm always has a lower hydrogen consumption than the SOC balancing algorithm at any mean power offset. The specific degree of improvement in hydrogen consumption cost of the optimization algorithm relative to the SOC balancing algorithm is presented in Fig. 7, which ranges from 9% to 21%, demonstrating the significant effect of the optimization.

Fig. 7.
figure 7

Effect of different average demand powers. (a) Optimization algorithm. (b) SOC balancing algorithm. (c) Comparison of hydrogen consumption costs.

4 Conclusion

  1. a.

    The optimization strategy can be used to derive the optimal solution of the cost function that satisfies the power constraints of each power source when the target power demand is known. The optimization strategy proposed is significantly more cost-effective than the SOC balancing strategy and can better meet the power performance requirements of the vehicle.

  2. b.

    The effects of different end-value constraints of the optimization algorithm on the cost of hydrogen consumption and the final value of SOC are analyzed, and the results show that the optimization algorithm always obtains the control sequence that makes the cost-optimal for different weighting factors of the end-value constraints and the hydrogen consumption cost decreases with the weakening of the SOC end value constraint.

  3. c.

    The characteristics of the optimization strategy for different initial SOC and different average demand power are investigated, and the effectiveness and superiority of the optimization algorithm are demonstrated by comparing it with the SOC equalization algorithm under different average demand power.