## 5 Results
### Scalability Simulation Analysis
Compared to the Cloud-only simulation, the Fog-only simulation shows significantly less latency by 85.28% at 100.78 ms for 20 devices and 87.33% less latency at 117.38 ms  
Figure 5: Cloud/Fog scenario latency comparison. for 200 devices, a latency difference of 16.60 ms. There is a significantly lower latency between Cloud and Fog-only data management and computation processing resources, clearly highlighting the benefits of Fog computing in the smart building architecture. Data processing and computations are performed at the network's edge, allowing the Fog nodes to act as resources closer to the smart IoT devices in the smart building. Hence, the data travels a shorter distance than the transfer and management of data at the Cloud (data centre) layer, which will include more network hops at a greater distance. In continuation, Figure 6 below graphically illustrates the simulation results for network bandwidth usage, focusing on the data management of CCTV IoT device data, CO2 IoT device data, and light sensor IoT device data processed with computing and storage resources at both the data centre (Cloud) and the network's edge (Fog) in the smart building. Similarly, Table 9 shows a similarity in the trends from earlier simulation results for energy consumption with a direct correlation between an increase in the number of devices and an increase in network bandwidth usage for both Cloud and Fog-only simulations. The network bandwidth usage simulation results for Cloud-only CCTV data management were 12.67 Gbps for 20 devices, which increased to 110.75 Gbps for 200 devices, a difference of 98.08 Gbps. In contrast, the Fog-only simulation, in comparison to Cloud-only simulation, shows a significantly lower network bandwidth usage by 31.02% at 8.74 Gbps for 20 devices and 23.72% less network bandwidth usage at 84.48 Gbps for 200 devices, a network bandwidth usage difference of 75.74 Gbps. Note that the percentage difference between the Cloud and Fog scenarios ranges from 31.02% at 20 devices, decreasing to 21.67% at 80 devices, then increasing steadily to 23.72% at 200 devices. The trend continued, showing the network bandwidth usage simulation results for Cloud-only CO2 data management at 15.05 Gbps for 20 devices and increasing to 111.27 Gbps for 200 devices, a difference of 96.23 Gbps. The Fog-only simulation, in comparison to the Cloud-only simulation, shows significantly lower network bandwidth usage by 35.97% at 9.63 Gbps for 20 devices and 31.04% less network bandwidth usage at 84.48 Gbps for 200 devices, a network bandwidth usage difference of 67.10 Gbps. Note that the percentage difference between the Cloud and Fog scenarios ranges from 35.97% at 20 devices, decreasing steadily to 31.04% at 200 devices. Table 9 shows a direct correlation between the number of devices and the increase in the Cloud and Fog network bandwidth  
Figure 6: Cloud/Fog scenario network bandwidth usage comparison. usage simulation results. The decentralised Fog computing results clearly show more than a 35% reduction in network bandwidth usage compared to the centralised Cloud computing results. The simulation results for the light sensors maintained the same trends, with the Cloud-only data at 14.78 Gbps for 20 devices and increasing to 110.76 Gbps for 200 devices, a difference of 95.98 Gbps. At the same time, the Fog-only simulation, in comparison to Cloud-only simulation, shows significantly lower network bandwidth usage by 34.78% at 9.64 Gbps for 20 devices and 31.22% less network bandwidth usage at 76.18 Gbps for 200 devices, a network bandwidth usage difference of 66.54 Gbps. Note that the percentage difference between the Cloud and Fog scenarios ranges from 34.78% at 20 devices, decreasing steadily to 31.22% at 200 devices, showing a direct correlation between the increase in the number of devices and the increase in both Cloud and Fog network bandwidth usage simulation results.