# Context-Aware Beam Selection for IRS-Assisted mmWave V2I Communications
## 5 Results and Discussion
### Effectiveness of C-MAB on Connection Time  
We conducted a comparative analysis of the C-MAB algorithm against classical MAB, Best-SNR, and random beam selection schemes, focusing on the average beam sojourn time. In the Best-SNR approach, the base station opts for a vehicle reporting the strongest received signal strength in a greedy manner. In our C-MAB, we leverage our contextual framework stated in Section 4. The beam sojourn time performance among the considered schemes is compared in Figure 3. After the exploration phase, C-MAB exhibits a notable increase, while MAB demonstrates only a slight uptick in mean beam sojourn time. This disparity is attributed to C-MAB's proficiency in leveraging contextual information for decision-making, enabling it to outperform MAB by a factor of two, and significantly more when contrasted with Best-SNR and random selection schemes. In Figure 4, the beam sojourn time performance of the proposed C-MAB is illustrated for all beams. Following the exploration phase, there is a notable increase in the mean beam sojourn time for most beams as the algorithm transitions into exploration. This phenomenon is attributed to the increased utilization of certain beams in specific contexts, leading to longer beam sojourn times during the learning phase. Notably, Beam-8, Beam-5, and Beam-3, along with Beam-10 and Beam-6, exhibit enhanced mean beam sojourn times. The scenario portrayed in Figure 1 is in line with this observation, where the shaded areas \begin{table}
\begin{tabular}{l l} \hline
**Parameter** & **Value** \\ \hline Number of beams per mmBS (\(N_{b}\)) & 12 \\ Carrier Frequency (\(f_{c}\)) & 28 GHz \\ Transmit power & 30 dBm for BS/23 dBm for vehicles \\ Path loss exponent (LOS/NLOS) & 1.9/3.8 \\ Noise power & \(-90\)dBm \\ Vehicle Speed & 30–50 km/h \\ Traffic light duration (Light1/Light2) & 22/18 s \\ Simulation time & 3 h \\ Sampling time slot & 0.1 s \\ Simulation area & 800 m \(\times\) 450 m \\ \hline \end{tabular}
\end{table} 
Table 1: Simulation parameters. Figure 3: Average beam sojourn time performance of different beam selection schemes. for these beams predominantly represent extended road coverages due to IRSs and higher line-of-sight (LOS) instances owing to fewer obstructions. Similar observations can be deduced from Figure 5, which illustrates the total utilization ratio of each beam throughout the exploration and exploitation phases. During the exploration phase, initial beam-sector selections are randomized across sectors. Sectors 2, 12, 11, and 1 exhibit an extremely low selection frequency due to inherently minimal vehicle traffic and shorter connection range due to weak received signal strength. Sector 4 similarly experiences limited selection since it lacks IRS deployment, compelling vehicles traveling north to primarily rely on extended coverage from neighboring Sector 3, which benefits significantly from IRS support. Sectors 7 and 9 display higher selection rates during exploration due to heavy traffic on the main road; however, their selections drastically shrink during exploitation due to short sojourn times. In contrast, Sector 3 experiences a substantial increase in connection frequency during the exploitation phase, driven by the synergistic effect of extended signal coverage from IRS deployment and prolonged connectivity opportunities resulting from vehicles frequently stopping and waiting at adjacent traffic lights. The C-MAB algorithm dynamically adjusts beam-sector selection by prioritizing sectors that offer longer and more stable connection times during the exploitation phase, hence responding effectively to contextual conditions. It intelligently considers IRS presence and infrastructure placement, consistently selecting sectors with durable, high-quality connections while systematically deprioritizing sectors characterized by transient, unstable connections. Consequently, the proposed C-MAB adeptly deal with environmental and mobility dynamics by aligning specific contexts with available beams to maximize rewards.