## 2 Materials and Methods
### Baseline \(FE\)  
To quantify the improvement due to the DP-ECMS solution over a baseline, a human driver model is used based on the well-known intelligent driver model (IDM) [29; 30] modified to make the ego vehicle stop at stop signs and traffic lights. This is called the enhanced driver model (EDM) [31] and is expressed by the following equations:  
\[\frac{dv}{dt}=\begin{cases}a\Big{[}1-\Big{(}\frac{v}{v_{0}-\theta_{offert}} \Big{)}^{\delta}\Big{]}&\text{if $v<v_{0}$ [Freeway Driving]}\\ -b\Big{[}1-\Big{(}\frac{v_{0}-\theta_{offert}}{v}\Big{)}^{\delta}\Big{]}&\text {if $v>v_{0}$ [Freeway Driving]}\\ a\Big{[}1-\Big{(}\frac{v}{v_{long}}\Big{)}^{\delta}\Big{]}&\text{if $v<v_{ leader}$ [Car Following]}\\ -b\Big{[}1-\big{(}\frac{v_{long}}{v}\big{)}^{\delta}\Big{]}&\text{if $v>v_{ leader}$ [Car Following]}\\ -\frac{1}{b}\Big{(}\frac{v^{2}}{2s}\Big{)}&\text{[Stop]}\end{cases} \tag{14}\]  
\[s =x_{leader}-x_{ego}-x_{safe} \tag{15}\] \[s_{brake} =\Big{(}1+\frac{c_{1}}{\delta}\Big{)}\frac{v^{2}}{2b} \tag{16}\]  
where \(v,v_{0},\text{and }v_{leader}\) are the ego vehicle speed, speed limit, and lead vehicle speed, respectively, \(a\) and \(b\) are the maximum acceleration and deceleration, respectively, \(\delta\) defines driver aggressiveness, \(\theta_{offset}\) further models driver behavior where a relaxed driver would choose to drive slightly below the speed limit and an aggressive driver will get as close as possible to the speed limit, the term \(\big{(}\frac{c_{1}}{\delta}\big{)}\) is a calibration term which captures the dependence of braking distance on aggressiveness, \(x_{leader},x_{ego},\) and \(x_{safe}\) are the lead, ego, and safe distance, respectively. The safe distance ensures a safe gap to the lead vehicle.  
The EDM is used as a benchmark to compare the energy consumption over a trip driven by a human driver to a vehicle driven by the EMS developed in this research. The  
Figure 5: DP-ECMS timing diagram.  
driver is calibrated to match the aggressiveness of the optimal speed prediction to ensure that the comparison is fair. The term representing the trade-off between fuel consumption and travel time (\(\beta\) in Equation (10)) can be thought of as the driver aggressiveness since the vehicle will tend to either drive faster or slower, depending on the value chosen for \(\beta\). For the results presented in this research, a value of \(\beta=0.65\) is chosen which represents a moderate driver.  
The EDM calibration parameters are \([a,b,\delta,c_{1},\theta_{offset}]\) and are determined using a genetic algorithm to solve a least squares optimization problem which minimizes the root mean square error:  
\[RMS=\sqrt{\frac{1}{N}\sum_{j=1}^{N}\left(V_{EDM_{j}}-V_{data_{j}}\right)^{2}} \tag{17}\]  
where \(N\) is the number of samples, \(j\) is the current sample, \(V_{EDM_{j}}\) is the velocity calculated by the EDM and \(V_{data_{j}}\) is the experimental value. The experimental data used to calibrate the driver model is obtained by running DP, assuming that the vehicle stops at every traffic light along the route. This allows the calibration process to capture acceleration and deceleration to match the behavior of the DP solution. Table 2 shows the optimized parameter values.  
The EMS used for the baseline is A-ECMS, where the adaptation is done via PI control based on SOC feedback. The controller adjusts \(s\) to minimize the difference between the current SOC and the target SOC with the goal of maintaining charge sustainability. The formulation is as follows:  
\[s(t)=s_{0}+k_{p}(x_{ref}-x(t))+k_{I}\int_{0}^{t}(x_{ref}-x(\tau))d\tau, \tag{18}\]  
where \(s_{0}\) is the EF at \(t=0\), \(k_{p}\) and \(k_{I}\) are the proportional and integral gains, respectively, \(x(t)\) is the SOC at time \(t\), and \(x_{ref}\) is the reference SOC.