Skip to main content
. 2021 Dec 17;21(24):8445. doi: 10.3390/s21248445
Algorithm 4: Modeling of Data Communication between CH and UAV
Input:
X = consists of a total n number of data items.
{CH1, CH2, CH3,, CHCopt} = A set of optimum Clusters, Copt
lthreshold = distance threshold range = δfsδmp=87.7 m
Steps:
1: CHs gets data packets from neighboring SNs.
2: Compute the distance between each elected CH and UAV (lUAV)
3: If (lUAV < lthreshold)
4:   then
5:     CH directly communicate to the UAV
6: else
7:     It selects the nearest neighbor CH whose l UAV is less than lthreshold to communicate to the UAV.
8: End if