Research Article

Improving Topic-Based Data Exchanges among IoT Devices

Algorithm 2

TBRG.
(1)Procedure TBRG
(2)ultimate consumer node R;
(3);
(4);
(5)whiledo
(6)  ;
(7)  for alldo
(8)   ;
(9)   ifthen
(10)    ;
(11)    ;
(12)    ;
(13)    ;
(14)    ;
(15)    ifthen
(16)     ;
(17)     ;
(18)    else ifthen
(19)     ;
(20)  ;
(21)  ;