# An Energy-Distance-Balanced Cluster Routing Protocol for Smart Microgrid IoT Sensing Networks
## 1 Introduction
\begin{table}
\begin{tabular}{l c c c c} \hline \hline \multirow{2}{*}{**Protocol**} & **Static** & **Distance** & **Energy** & **Microgrid** \\  & **Deployment** & **Awareness** & **Adaptation** & **Suitability** \\ \hline LEACH & ✗ & ✗ & \multicolumn{1}{c}{Low} & Poor \\ EDSHEED [20] & ✗ & \multicolumn{1}{c}{X} & Medium & Limited \\ DD-TL-LEACH & ✗ & \multicolumn{1}{c}{**✗**} & Medium & Moderate \\ LEAD-RP & ✓ & ✓ & \multicolumn{1}{c}{High} & Optimal \\ \hline \hline \end{tabular}
\end{table} 
Table 1: Protocol comparison. \begin{table}
\begin{tabular}{l c c c c c} \hline \hline
**Feature** & **LEAD-RP** & **CCIC-WSN [15]** & **EDsHEED [20]** & **SEP [21]** & **DEEC** & **RL-NOMA [16]** \\ \hline Dynamic Cluster Radius & ✓ & ✓ & \(\times\) & \(\times\) & \(\times\) & ✓ \\ Energy–Distance Balance & ✓ & \(\times\) & \(\times\) & ✓ & ✓ & ✓ \\ Security (RBAC-IoT) & ✓ & \(\times\) & \(\times\) & \(\times\) & \(\times\) & \(\times\) \\ Computational Overhead & \(\mathcal{O}(N)\) & \(\mathcal{O}(N\log N)\) & \(\mathcal{O}(N)\) & \(\mathcal{O}(N)\) & \(\mathcal{O}(N^{2})\) \\ Control Packet Reduction & 23\% & \(-\)40\% & 12\% & 8\% & 15\% & 18\% \\ Energy Imbalance Index & 0.89 & 0.72 & 0.78 & 0.75 & 0.81 & 0.83 \\ ML/AI Dependency & \(\times\) & \(\times\) & \(\times\) & \(\times\) & ✓ \\ Field Deployment & ✓ & \(\times\) & ✓ & ✓ & \(\times\) \\ \hline \hline \end{tabular}
\end{table} 
Table 2: Comprehensive feature comparison with contemporary protocols. \begin{table}
\begin{tabular}{l c c c c c} \hline \hline
**Protocol** & **Topology** & **Energy** & **Distance** & **Control** & **MG** \\  & **Adapt** & **Aware** & **Opt.** & **Overhead** & **Suitability** \\ \hline LEACH & \(\times\) & Low & \(\times\) & Low & Poor \\ M-LEACH & \(\triangleright\) & Medium & \(\times\) & High & Limited \\ EDsHEED & ✓ & High & \(\times\) & Medium & Moderate \\ DD-TL-LEACH & ✓ & Medium & \(\triangleright\) & High & Moderate \\ LEAD-RP & ✓ & High & ✓ & Low & Optimal \\ \hline \hline \end{tabular}
\end{table} 
Table 3: Limitations of LEACH variants in microgrids. According to quantitative metrics derived from simulation results (Algorithm 1) and literature analysis [15; 16; 20; 21] LEAD-RP achieves 35% higher energy-distance balance than EDsHEED while maintaining 60% lower computational overhead than RL-NOMA. ```
1 Initialization: Position nodes and the base station. Set initial parameters. 2 for each node \(i\)do
3 Compute cluster radius \(R_{i}\) using Equation (16). 4 Compute ideal cluster head proportion \(p\) using Equation (18). 5 endfor
6 Cluster Head Selection:
7 for each node \(i\)do
8 Calculate threshold \(T(S_{i})\) considering the following:
9 Distance factor \(D_{f}\);
10 Energy factor \(E_{f}\). 11 Generate a random number \(rand\). 12 if\(rand<T(S_{i})\)then
13 Node \(i\) becomes a cluster head. 14 endif
15 Refresh the set \(G\) of potential cluster heads. 16 endfor
17 Cluster Formation:
18 for each cluster head \(i\)do
19 Broadcast status as the cluster head. 20 endfor
21 for each non-cluster head node \(i\)do
22 Select the cluster head based on the highest residual energy and shortest distance within radius \(R_{i}\). 23 Join the selected cluster head. 24 endfor
```  
**Algorithm 1**Cluster Head Selection Method  
Figure 1: IoT-based microgrids.