| Algorithm 1. The Proposed Clustering Algorithm for EEDCF |
| 1 Begin 2 N=Total number of nodes 3 i=ID of living sensor node in current round 4 node[i].statement=initial_state 5 for each node[i] 6 receives Node_MSG from Neighbor_Node 7 node[i].Info_table updates ▷Input parameters: Residual Energy (RE), Node Degree (ND), Neighbor nodes’ Residual Energy (NRE) 8 node[i].RE=residual energy of node[i] 9 node[i].ND=number of nodes within communication “R” 10 node[i].NRE=residual energy of neighbor nodes of node[i] ▷Analysis through fuzzy inference system (FIS) 11 probability=FIS(node[i].RE, node[i].ND, node[i].NRE) 12 Send Head_compete to all neighbor nodes 13 Neighbor_Node[j]=list of Head _compete from neighbor node ▷Comparing the result from FIS (Fuzzy Inference System) with neighbor nodes’ 14 If (node[i].probability> Neighbor_Node[j].probability) 15 node[i].statement=CH 16 advertise CH_Message 17 else 18 on receiving CH_Message 19 select the nearest CH 20 send Node_JOIN to the nearest CH 21 end 22 end 23 End |