Function  Topology Construction Algorithm at node (v) in G:
(1)  𝐺 𝑣 ( 𝑁 ( 𝑣 ) , 𝐿 ( 𝑣 ) ) ; where 𝐿 ( 𝑣 ) 𝐸
(2)   𝑃 ( 𝑣 )
(3)   𝐶 ( 𝑣 ) = { 𝑥 𝑥 𝑁 ( 𝑣 ) , 𝑃 ( 𝑥 ) 𝑣 , s i n k ( 𝑥 ) = t r u e }
(4)  If { 𝜀 r m ( 𝑢 ) | 𝑢 𝐶 ( 𝑣 ) } = =
(5)   𝑃 ( 𝑣 ) 𝑢
(6)   𝜀 t x ( 𝑣 ) = 𝜀 m i n ( 𝑃 ( 𝑣 ) , 𝑣 )
(7)   Break;
(8)  else
(9)   If 𝜀 r m ( 𝑣 ) ==
(10)    For 𝜀 p l ( 𝑣 ) in decrease order
(11)      𝑃 ( 𝑣 ) = M a x 𝑢 { 𝜀 r m ( 𝑢 ) | 𝑢 𝐶 ( 𝑣 ) , H C ( 𝑢 ) H C ( 𝑣 ) }
(12)      𝜀 t x ( 𝑣 ) = 𝜀 m i n ( 𝑃 ( 𝑣 ) , 𝑣 )
(13)    End for
(14)   else
(15)    For 𝜀 t x ( 𝑣 ) in increase order
(16)      𝑃 ( 𝑣 ) = a r g m a x { 𝜀 r m ( 𝑢 ) | 𝑢 𝐶 ( 𝑣 ) , H C ( 𝑢 ) H C ( 𝑣 ) }
(17)     𝜀 t x ( 𝑣 ) = 𝜀 m i n ( 𝑃 ( 𝑣 ) , 𝑣 )
(18)    End For
(19)   End If
(20) End if
(21) If 𝑃 ( 𝑣 ) = =
(22)    𝑃 ( 𝑣 ) = M a x 𝑢 { 𝜀 r m ( 𝑢 ) | 𝑢 𝐶 ( 𝑣 ) }
(23)  End If
(24)  Trigger topology maintenance  Algorithm
Algorithm 1: Topology contraction algorithm running on a node v in G.