# Resource Assignment Algorithms for Autonomous Mobile Robots with Task Offloading
## 5 Simulation Results and Discussion
### Variable Scenarios  
Scenario _6/7/4_variable_ has the same complexity of _6/7/4_fixed_, but UL access rates are generated randomly with uniform distribution between 0 Mbit/s and 20 Mbit/s and wired link delays randomly with uniform distribution between 5 ms and 150 ms. The connection matrices are created in this way: UL access rates lower than 9 Mbit/s are considered to not provide connection, and link delays higher than 60 ms correspond to an unavailable link. As for the other parameters, \(\rho_{i}=5\) Mbit/s, \(\gamma_{m}=1/4\) CPU, \(l_{m}=33\) ms, and \(\ell_{i}=100\) ms. Differently from the fixed case, every simulation consists of 100 randomly generated configurations, for which the performance of all algorithms is averaged for comparison. For this scenario, on average, there are \(N_{\rm val}=2.1\times 10^{5}\) valid configurations, so we consider VEX as the optimum, reference solution. Figure 12a shows the percentage of times an algorithm achieves the best KPI among the four algorithms (ties are counted as wins), and its KPI equals that of the VEX solution. GA wins in 92% of cases, whereas SM does so in 73 % of cases and RSAM in 71% of cases. MLAT is the last, winning only in 28% of cases. However, while GA, SM, and RSAM do not guarantee to obtain the optimum value in all victory situations, MLAT does. Although there is a 19% difference between GA and SM, the loss in terms of average total latency is minimal (Figure 12b): GA achieves a value of 295.7 ms, SM obtains 299.1 ms, and RSAM is slightly better, at 296.7 ms, while MLAT underperforms at 366.3 ms. VEX provides the optimal value of 295.0 ms. The moderate KPI loss of SM with respect to GA, however, is compensated by a significant running time reduction, shown in Figure 13a. While SM runs in 2 ms, GA takes 20.9 s, and both RSAM and VEX employ 0.4 s. Figure 13b shows the number of calls, which is fixed for RSAM and MLAT, about 100 for SM, and more than \(2\times 10^{5}\) for VEX; GA instead peaks at about \(10^{6}\) calls. Another scenario, _10/25/5_variable_, has nearly the same dimensions of _10/25/13_fixed_, except for the DCs, which are decreased to \(N_{\rm DC}=5\) to simulate the effects of scarce computation resources; UL rates, link delays, connection matrixes, and AV bit rates are generated randomly as in scenario _6/7/4_variable_. Simulation results are averaged over 100 randomly generated configurations. Figure 11: Configurations found for the _10/25/13_fixed_ scenario: (**a**) RSAM solution. (**b**) MLAT solution. (**c**) GA solution. (**d**) SM solution. From Figure 14a, the percentage of winning is 71% and 41% for GA and SM, respectively, while RSAM and MLAT never win. Additionally, the difference in average total latency between GA and SM is small (410.4 ms for GA and 412.9 ms for SM), and RSAM average latency is sensibly the worst, while MLAT average latency is more than doubled with respect to GA (Figure 14b). As concerns the number of calls (Figure 15a) and the running times (Figure 15b), GA is still the slowest and most complex, with a 26.8 s run time, while RSAM takes 0.6 s, SM 5 ms, and MLAT less than 1 ms.  
Figure 14: Scenario _10/25/5_variable_: (**a**) Probability of win. (**b**) Average of the KPI. Figure 12: Scenario _67/4_variable_. (**a**) Percentage of winning and achieving optimum. (**b**) Average KPI. Figure 13: Scenario _67/4_variable_. (**a**) Average running time. (**b**) Average number of calls. Finally, we introduce another variable scenario to compare the convergence performance of the best algorithm, GA, with that of the proposed SM, which is faster and only slightly less optimal. For this comparison, we consider the scenario _40/60/20_variable_ with dimensions \(N_{\text{AV}}=40\), \(N_{\text{BS}}=60\), and \(N_{\text{DC}}=20\).