## 3 Energy Management Strategy
### Proposed EMS
#### 3.2.1 High-Level Control  
In the proposed strategy, FLRs are realized by the following parts: fuzzification interface, reasoning machine, rule base, and defuzzification interface with the fuzzy module provided by Matlab/Simulink. The FLR's objectives are to increase the PEMFC efficiency and minimize hydrogen consumption as well as maintain SOC\({}_{\text{BAT}}\) within the desired range of 0.6-0.9. The FLRs are inherited from previous our study in [38], which are composed of two input variables (P\({}_{\text{load}}\), SOC\({}_{\text{BAT}}\)) and one output variable (P\({}_{\text{FC\_ref}}\)). The input linguistic P\({}_{\text{load}}\) has seven membership functions (MFs) including NH (Negative High), NM (Negative  
Figure 6: Proposed energy control strategy. Medium), NL (Negative Low), Z (Zero), PL (Positive Low), PM (Positive Medium), PH (Positive High) with the fuzzy field scope [\(-\)1, 1]. The input SOC\({}_{\text{BAT}}\) is characterized by five MFs as VL (Very Low), L (Low), M (Medium), H (High), and VH (Very High) within the range of [0.6, 0.9]. The output P\({}_{\text{FC\_ref}}\) is defined through five MFs including Min (Minimum), ML (Medium-Low), M (Medium), MH (Medium-High), and Max (Maximum). The inhomogeneous MFs of inputs and output are presented in Figure 7a of MFs for P\({}_{\text{load}}\), Figure 7b of MFs for SOC\({}_{\text{BAT}}\), and Figure 7c of MFs for reference PEMFC power. The operating mode of the FC is defined regarding its MFs and rule table (Table 1), with the Mamdani Inference method applied for conducting the fuzzy reasoning rules. During the operation, the proposed EMS appropriately distributes the required power to each energy source to not only sufficiently satisfy the workload demand but also maintain the SOC supplement. These parameters should be properly determined to avoid the state of overcharging or deep discharging. For the charging process, if the BAT has high SOC, the injected power is lower and vice versa. Meanwhile, in the discharging process, if the SOC\({}_{\text{BAT}}\) is at a high level, the BAT will release more output power and vice versa. Furthermore, if the SOC capacity of the BAT reaches the upper bound or lower bound, the disconnected action is executed and this device will wait for the next discharging or charging process, respectively. \begin{table}
\begin{tabular}{c c c c c c c c c} \hline \hline \multirow{2}{*}{**P\({}_{\text{FC\_ref}}\)**} & \multicolumn{8}{c}{**P\({}_{\text{load}}\)**} \\ \cline{2-10}  & **NH** & **NM** & **NL** & **Z** & **PL** & **PM** & **PH** \\ \hline \multirow{5}{*}{SOC\({}_{\text{BAT}}\)} & VL & Min & Min & ML & M & M & MH & Max \\  & L & Min & Min & Min & ML & ML & M & MH \\ \cline{1-1}  & M & Min & Min & Min & Min & ML & M & MH \\ \cline{1-1}  & H & Min & Min & Min & Min & Min & M & MH \\ \cline{1-1}  & VH & Min & Min & Min & Min & Min & ML & M \\ \hline \hline \end{tabular}
\end{table} 
Table 1: Fuzzy reasoning rules. Figure 7: MFs of the FLRs. (**a,b**) MFs of inputs; (**c**) MFs of output; (**d**) Graph of inputs and output. Besides the power distribution requirements, DC bus voltage control is also a critical challenge for maintaining the system's stability because of voltage fluctuation in the DC bus when load power increases or decreases abruptly. Thus, an adaptive PID controller is designed to control the bus output voltage, as shown in Figure 8 [38]. Herein, the deviation between a reference DC bus voltage (\(\text{V}_{\text{DC\_ref}}\)) and the measured DC output voltage (\(\text{V}_{\text{DC}}\)) is used as an input value of the adaptive PID controller to generate the BAT power \(\text{P}_{\text{BAT2}}\). The formulations of this controller are given by [38]:  
\[\text{e}=\text{V}_{\text{DC\_ref}}-\text{V}_{\text{DC}} \tag{18}\]  
\[\dot{\text{K}}_{\text{P}}=\left\{ \begin{array}{l}\eta_{\text{P}}(\delta+| \text{e}|)\text{sign}(|\text{e}|-\gamma)\text{sign}\text{N}(|\text{e}|-\gamma), \quad\quad\dot{\text{K}}_{\text{P}}>0\\ \eta_{\text{P}}(\delta+|\text{e}|),\quad\dot{\text{K}}_{\text{P}}=0\end{array} \right.