# A Helping Hand to the Elderly: Securing Their Freedom through the HAIE Framework
## 6 Results and Discussion  
The proposed HAIE model has been validated by considering two factors: latency and accuracy. Latency involves the timely transmission of data so that the appropriate actions can be executed. In the proposed model, the data are transmitted from smart gadgets to the local server at home and then to the cloud environment. Thus, the total latency (\(T_{I}\)) can be calculated by using Equation (1). \[T_{I}=N_{I}+C_{I} \tag{1}\]  
where \(N_{I}\) represents latency in the network and \(C_{I}\) represents latency with the cloud. The total latency of the HAIE model-based case studies can be calculated through the following equations. The network delay \(N_{I}\) can be calculated by using Equation (2), where \(P_{d}\) is processing delay, \(Q_{d}\) is queuing delay, \(T_{d}\) is transmission delay, and \(PR_{d}\) is propagation delay. \(C_{l}\) represents the delay, which is the time difference between sending a data packet from the client's side and receiving a response from the server end. For the proposed work, we considered \(P_{d}\) and \(Q_{d}\) as 0. \(T_{d}\) is calculated by dividing the number of bits by the transmission rate. Moreover, \(PR_{d}\) is calculated by dividing the distance by the speed of the packets. \[N_{l}=T_{d}+PR_{d}+P_{d}+Q_{d} \tag{2}\]  
For the given case studies, we have considered a transmission rate of 1 Mbps and a propagation delay of 54 ms. Hence, the time required to transmit 1 kbps of data can be calculated by using Equation (2). \[N_{l}=\frac{1000}{1000000}+\frac{80}{1000}+0+0=0.054\;\mathrm{s}=54\;\mathrm{ ms} \tag{3}\]  
The total end-to-end latency (\(n_{lt}\)) for the cloud can be calculated by adding the bootstrap time (\(n_{bt}\)), connection time (\(n_{ct}\)), and transmission time (\(n_{tt}\)). \(n_{tt}\) is the combination of three other components, i.e., the sending time \(n_{st}\), uploading time \(n_{ut}\), and response time \(n_{rt}\), as defined in Equation (4). We assume an idle latency of 30.35 ms over the cloud as it uses 4G networking with no congestion environment to communicate with the cloud storage. \[n_{tt}=n_{st}+n_{ut}+n_{rt} \tag{4}\]  
Hence, the total latency (\(N_{l}\)), i.e., from smart gadgets to the cloud environment, can be calculated by using Equation (1). \[N_{l}=54\;\mathrm{ms}+30.35\;\mathrm{ms}=84.35\;\mathrm{ms} \tag{5}\]  
In Figure 17, latency plots are presented for IoT devices with the required rates of 200 Kbps, 500 Kbps, and 1 Mbps. The results show that for a required rate of 200 Kbps, increasing the number of IoT devices results in higher latency compared to 500 Kbps and 1 Mbps. This finding confirms the notion that latency increases as the required data rate increases. As a result, reducing end-to-end latency can lead to lower energy consumption at every step, as IoT devices can be served more quickly. In the proposed study, the consideration of only two devices resulted in lower latency. Another factor is accuracy; under this, we collected the alarms that were generated by the proposed model. Here, from the set of observed alarms (\(n_{o}\)), the number of accurate alarms (\(n_{a}\)) and false alarms (\(n_{f}\)) can be calculated by using Equation (6). \[n_{o}\%=\frac{n_{a}-n_{o}}{n_{a}\times 100} \tag{6}\]  
The accuracy of smart devices can be particularly important for older individuals who may have more difficulty with manual tasks or may require additional assistance with daily activities. For example, an automatic sliding door that fails to properly acknowledge a person's presence could become a safety hazard for an elderly individual with limited mobility. On the other hand, a voice assistant with a high accuracy rate, combined with a light feature, can provide a convenient and reliable way for elderly individuals to control their home environments without the need to manually operate switches or knobs.