Function  Topology Maintenance Algorithm at node (v):
(1) Broadcast beacon message to neighbor 𝑁 ( 𝑣 )
(2) Receive beacon message from each neighbor 𝑁 ( 𝑣 )
(3)  𝐶 ( 𝑣 ) = { 𝑥 𝑥 𝑁 ( 𝑣 ) , 𝑃 ( 𝑥 ) 𝑣 , s i n k ( 𝑥 ) = t r u e }
(4) If 𝑃 ( 𝑣 ) is miss
(5)   Trigger Topology Construction Algorithm
(6) End If
(7) If 𝜀 r m ( 𝐶 ( 𝑣 ) ) = =
(8)   Trigger Topology Construction Algorithm
(9) End If
(10) If 𝜀 r m ( 𝑃 ( 𝑣 ) ) < 𝜀 r m ( 𝐶 ( 𝑣 ) )
(11)  Trigger Topology Construction Algorithm
(12) End If
Algorithm 2: Topology maintenance algorithm running on a node 𝑣 in G.