## 4 Evaluation of the Task Assignment Algorithm
### Performance Evaluation  
The effectiveness of the proposed RNN-based task assignment algorithm is evaluated in terms of three performance metrics: (1) the percentage of evacuees who are saved by rescuers under diverse population densities (30, 60 and 90 evacuees in the building); (2) the number of victims saved by rescuers with the sizes of the set of rescuers and the set of victims given; and (3) the average remaining health of the rescued evacuees. Metrics (1) and (2) denote straightforwardly the efficiency of the RNN-based algorithm; and (3) indicates if the algorithm is fast enough to save people in a timely manner. The results of our experiments are obtained by comparing two different scenarios, without the task assignment algorithm and with the RNN-based algorithm. The \"without algorithm\" scenario is run with the random assignment, where the rescuers will save the victims in a random way. In the \"with the algorithm\" scenario, each rescuer holds an RNN and executes the task, relying on the solutions of the RNN computation. Each result is obtained by executing 10 simulation runs, and for each simulation run, the locations of injured civilians are randomized around the hazards in the building. The purpose of the simulations is to check if the RNN-based algorithm can avoid the waste of resources and reduce the inefficiency of resource allocations. Thus, to keep things as simple as possible, the cost of each assignment, \(C(r,v)\), and the failed rescue probability, \(L(r,v)\), are taken to be independent from the assigned victim, \(v\)[27], and generated randomly. Specifically, \(K(v)\), \(C(r)\) and \(L(r)\) are generated from the uniform distribution in the interval \([0,50]\), \([0,10]\) and \([0.05,0.15]\), respectively, and \(q(r,v)\) is initialized to zero for all assignments. All RNN parameters are updated 20 times for each allocation to reach convergence, and the assignment with the highest probability of being active (i.e., \(q(r,v)\)) will be selected. The simulation results are shown below with a 95% confidence interval. In Figure 3, it is clear that the percentage of rescued civilians decreases with the increasing number of evacuees in the building. This is due to the fact that it takes a relatively long time to evacuate in high population density environments, because of congestion problems, which then increases the time of exposure to the hazards and reduces the number of survivors. Without the task assignment algorithm, the system with seven rescuers reduces the percentage of rescued civilians compared with the system with five rescuers for each case (30, 60 and 90 evacuees), which is more obvious in high population densities (60 and 90 evacuees). The reason is that when there are people who need help, the rescuers enter the building and move towards the hazardous areas, so that some of them may increase congestion along the road [26]. Hence, the rescuers and the remaining evacuees will probably spend a long time waiting or be obstructed by congestion. Moreover, it is possible that: (1) different rescuers are allocated to the same victim; (2) different victims are assigned to the same rescuer; and (3) a rescuer may be injured during rescue and, then, cannot finish the task. The reason for phenomena (1) and (2) is that there is no relationship and effect between each assignment, that is, the allocation of a rescuer to a victim does not consider the assignments that have already been done. In high population density environments, more evacuees may be at stake at bottleneck points [49], such as stairs and exits, due to pedestrian congestion, and then, more people need to be assigned a rescuer simultaneously. Therefore, it is more likely that the rescuers receive more than one rescue message from the sensor network, and/or the same rescue message is sent to more than one rescuer. In this case, the rescuers select their target randomly, which leads to problems (1) and (2).