Research Article

Matching Learning-Based Relay Selection for Substation Power Internet of Things

Algorithm 1

MLRS.
(1)Input: , , , .
(2)Output: .
(3)In the first time slots, traverse to select once to observe the transmission performance.
(4)whiledo
(5)All source nodes construct a preference list as (16).
(6) Step 1: Initialization
(7)Set , , , , .
(8) Step 2: Iterative Matching
(9) whiledo
(10)  fordo
(11)    makes a request to its most preferred according to .
(12)  end for
(13)  Add the relay nodes selected by more than one source node into
(14)  ifthen
(15)   fordo
(16)     raises its price as (17).
(17)     selecting , update and renew its request.
(18)    Repeat price rising process until is not requested by more than one source node. Remove from .
(19)   end for
(20)  end if
(21) end while
(22)The gateway sends the result to source nodes. selects and transmits data.
(23) Step 3: Learning
(24)Observe transmission performance and get energy consumption .
(25)Update and as (18) and (19).
(26)end while