## 4 The Cloud-Enabled Emergency Navigation System
### Power-Aware Protocol  
As the front-end component of the framework, smart phones, which can offer diverse services, high data rate connectivity and sensing capabilities, play a vital role in the cloud-enabled system. However, due to the limitation on battery size and the efficiency of chemical reactions of the widely-used lithium-ion batteries [52], the capacity of batteries becomes a bottleneck in the operational time of the cloud-based system. In fact, the development of battery capacity does not keep pace with the computational complexity: the computational complexity is roughly doubled every two year with respect to [PERSON]'s law, while the battery capacity is doubled every decade [53]. Emergency evacuation is an energy-hungry process due to the large amount of information exchange involved. Experiments in [54] show that the energy consumption of air interfaces, such as Wi-Fi and GPRS, far exceed the power utilization of the RAM and CPU. Furthermore, the energy consumption for different communication modes varies. For instance, Bluetooth consumes much less energy than 3G mode during data sending and receiving [53]. Because the remaining battery power of portable devices is different when an emergency event occurs and the power utilisation rate of different handsets varies, it is not an optimal strategy for each smart phone to exchange information with the cloud through 3G directly. In this section, we make use of the cluster behaviours proposed in the aforementioned section to employ short-range communications to relay sensory information and, ultimately, upload the data from a certain number of mobile devices through 3G. Similarly, decisions from the cloud are not conveyed to each evacuee directly, but are transmitted to a certain evacuee and then distributed within the group using short-range communication technologies. To realise energy efficiency and to maximise the overall average battery lifetime of smart phones, we employ an AHCPN-based algorithm to optimise the routes for the information flows. The AHCPN-based algorithm is deployed on the smart phones to search power-saving paths for conveying sensory data to the cloud. The QoS criterion we used is inspired by the energy-aware metric in [8]. It is a compound metric, which involves battery power and latency. Here, we also employ the \"path availability\" notion and construct a similar metric. \[G_{ed}=\alpha\prod_{i=0}^{n-1}P_{a}(\pi(i),\pi(i+1))\left\{\sum_{i=0}^{n-1}D( \pi(i),\pi(i+1))\right\} \tag{2}\]  
where \(\pi\) represents a particular path, \(n\) is the number of nodes on the path \(\pi\) and \(\pi(i)\) is the i-th node on the path \(\pi\). Hence, \(\pi(0)\) is the source node, while \(\pi(n)\) is the destination node (the cloud access point). Term \(P_{a}(\pi(i),\pi(i+1))\) is the availability of the edge between \(\pi(i)\) and \(\pi(i+1)\). \(D(\pi(i),\pi(i+1))\) is the delay cost for a packet to transmit from \(\pi(i)\) to \(\pi(i+1)\). Term \(\alpha\) is a constant that coordinates the relation between the path availability and delay. Because the average latency for uploading a photo is less than 0.1 s and the path availability is normally slightly larger than one (due to the fact that the remaining battery power is usually much larger than the energy consumption of uploading a snapshot), term \(\alpha\) is set to 100 to amplify the result of the goal function and to ensure the effective training process of random neural networks. The path availability is affected by the remaining battery power of a smart phone and the estimated power consumption of transmitting a piece of information:  
\[P_{a}(\pi(i),\pi(i+1))=\frac{B_{i}^{C}}{B_{i}^{C}-B_{i}^{U}} \tag{3}\]  
where \(B_{i}^{C}\) represents the current remaining battery power of a node (smart phone) \(\pi(i)\) and \(B_{i}^{U}\) depicts the power utilisation at node \(\pi(i)\) to convey a certain piece of information. It is estimated by the number of packets that will be transmitted. If the potential power utilisation is larger than the remaining battery, then this node is excluded.