Skip to main content
. 2020 Dec 31;21(1):218. doi: 10.3390/s21010218
Algorithm 3 Failure recovery algorithm.
  • Input: physical WSN GS; VSNR GTV; node mapping results set NODE={njs,,nks};

  • Fault physical sensor node nxs

  • Output: Failure recovery result RM={n1s,nms}

  • Initialization: Failure recovery result RM=

  • ifnxs fault then

  •       Rank invalid m VSNs in descending order by penalty

  • end if

  • fori=1,,mdo

  •           GSGS/{nxs,lxis,lixs}

  •           for niv in VSNi do

  •              if niv is critical virtual sensor node then

  •                Remap njv to nis through formula (24)

  •                Add nis to RM

  •           else

  •             find feasible nodes nms in the remaining WSN network

  •             Add nms to RM

  •           end if

  •        end for

  • end for

  • return the physical node failure recovery successfully