## 4 Simulation Environment and Scenario Setup  
### Simulink-Based ACC Platform Architecture  
To evaluate the proposed DWMPC strategy, a complete adaptive cruise control (ACC) simulation platform was constructed in MATLAB/Simulink R2024a. The system integrates multiple modules, including the DWMPC-based controller, vehicle body dynamics, electric motor, and battery pack.  
As shown in Figure 4, the simulation framework is modularly organized into five components.  
\begin{table}
\begin{tabular}{c c c c c} \hline \hline
**Mode** & \(E\)**Range** & \(C_{2}\) & \(C_{3}\) & **Control Priority** \\ \hline
1 & \(E<0.25\) & 1 & 2000 & Comfort (smoothness dominant) \\
2 & \(0.25\leq E<0.5\) & 10 & 1000 & Economy (efficiency dominant) \\
3 & \(0.5\leq E<0.75\) & 50 & 800 & Normal (balanced control) \\
4 & \(E\geq 0.75\) & 100 & 500 & Emergency (fast response) \\ \hline \hline \end{tabular}
\end{table}
Table 1: Weight parameters corresponding to four driving modes based on an emergency coefficient.  
Figure 3: Framework of the emergency-aware dynamic weight assignment.  
* Adaptive cruise controller module: Computes optimal acceleration via the DWMPC algorithm.
* Controller module: Converts acceleration to motor torque and braking commands, accounting for battery SOC.
* Simulink vehicle body module: Simulates vehicle longitudinal dynamics under input torque and braking.
* Motor and battery pack module: Models energy conversion, SOC evolution, and drivetrain efficiency.
* Simulation results module: Collects outputs such as velocity, distance, SOC, and control commands.  
A comprehensive set of physical and drivetrain parameters was configured to represent a mid-size pure electric vehicle. These parameters govern the longitudinal dynamics, energy consumption, and regenerative behavior throughout the test scenarios.  
To ensure realism, the selected values reflect the typical specifications of commercially available EVs in the C-segment. The mass, rolling resistance, aerodynamic drag, and road grade directly influence longitudinal forces in the dynamic model. Meanwhile, drivetrain-related parameters, such as gear ratio, motor inertia, and wheel inertia, affect acceleration response and torque transmission. Battery specifications determine the available energy, while the initial state of charge (SOC) defines the baseline for evaluating energy consumption and regenerative braking effectiveness.  
These parameters are integrated into the vehicle's longitudinal force balance and drivetrain efficiency models, forming the basis for simulating acceleration, deceleration, and power consumption under different traffic scenarios. The main vehicle parameters used in the simulation model are summarized in Table 2.  
For baseline comparison, a classical PI controller is implemented with the control law:  
\[a_{\text{PI}}(t)=K_{p}\cdot e_{v}(t)+K_{i}\cdot\int_{0}^{t}e_{v}(\tau)\,d\tau, \tag{23}\]  
where \(e_{v}(t)=v_{\text{ref}}(t)-v_{f}(t)\) is the velocity tracking error. The gains were tuned using the Ziegler-Nichols method and fine-adjusted for stable tracking under the WLTC cycle. The final settings are \(K_{p}=0.6\) and \(K_{i}=0.4\).  
Figure 4: Integrated Simulink architecture for the ACC testing environment.