NLFFT: A Novel Fault Tolerance Model Using Artificial Intelligence to Improve Performance in Wireless Sensor Networks

A wireless sensor network (WSN) is a collection of various tiny devices known as sensor nodes, which are also called motes. Due to high-energy consumption, the possibility of hardware, link or node failure, and some malicious attacks, sensor networks are considered error-prone networks. Hence, fault tolerance (FT) in WSN is one of the prominent issues. This article presents a novel FT approach named node-link failure fault tolerance model (NLFFT Model) in WSN, to handle the faults that occur either by link or node failure during data transmission from the sensor to the sink or base station. The NLFFT model consists of an improved quadratic minimum spanning tree (Imp-QMST) approach. This approach helps in finding the alternate link whenever it fails due to various situations and also an improved-handoff (Imp-Handoff) algorithm to support the node failure to the fault tolerance. Improved QMST presents a novel mechanism to find an alternate edge in place of the broken or failed edge in the spanning tree, to improve the fault tolerance in WSN. Imp-Handoff suggests a novel way to find the faulty node owing to less battery power and replaces a defective node by an appropriate neighbor to shift the tasks performed by a faulty node in WSN. Simulation results clearly state that as compared to the basic techniques i.e. Q-MST and Handoff algorithm, the proposed NLFFT model improvises the performance of WSN around by 7%. The results prove that the Imp-QMST gives about 6% improved throughput, 5% less end-to-end delay, and 6% less power consumption than the QMST algorithm. Similarly, Imp-Handoff improves about 4% throughput, 6% less end-to-end delay, and utilizes 7% less power consumption.

shows an example of WSN with sensor nodes, CH, and BS. In the considered WSN, mainly four kinds of links exist namely sensor to sensor, sensor to CH, CH to CH, and CH to BS. The link existence between n i to n j is based on the available bandwidth B(n i , n j ) and active status of both nodes. Here, a node may be considered as sensor node, CH, BS. The link existence will exist based on the predefined threshold for various kinds of links. The proposed work applies to all kind of links mentioned in Fig. 1.
Based on the environment, sensor networks can be classified into various categories such as terrestrial WSN, underwater WSN, underground WSN, and mobile WSN. In some critical applications, such as critical-medical care [1], the sensor networks need to provide interminable services. Hence, enabling endless services in critical systems is only possible by fault tolerance. The efficient fault diagnosis method is required to find the faults to support fault tolerance. The fault tolerance is a combination of fault detection, fault diagnosis, and fault removal [2] processes.
WSNs are vulnerable to faults mainly because of two reasons-one is the failure of nodes, and the other is a link failure. Tiny and less battery power sensor nodes are deployed in a disastrous and harsh environment; hence, there may be higher chances of hardware failures in WSN. Due to faults in WSN, there may also be a loss in huge data transfer, long data transmission delay, and less throughput. So, there is a need for novel protocol architecture for WSN. Consequently, the identification of faulty nodes and links is a must to improve the capacity of WSN in terms of efficient data delivery.
Hence, a novel mechanism is needed to identify the faults and create a recovery mechanism to improve the reliability and quality of service during data transmission. The major contributions of the proposed research are as follows: 1. A novel fault-tolerance model is proposed to handle both kinds of faults i.e. link failure and node failure. 2. The Imp-QMST algorithm is introduced to find the alternate link in case of link failure. 3. The Imp-Handoff algorithm is presented to identify the faulty node and selection of appropriate new nodes in case of node failure.
4. Imp-QMST and Imp-Handoff need MST. Thus, four swarm intelligence-based algorithms have been used to generate spanning trees in WSN and the performance for different characteristics, i.e., throughput, end-to-end delay, and power dissipation of proposed methods to existing methods Q-MST [3][4][5] and Handoff [10] has been evaluated.
The rest of the paper is organized thus: Related work is explained in section II. Section III describes the proposed helping algorithms to find active links and nodes in the NLFFT model. Section IV narrates various system models and the newly proposed NLFFT model in detail. Section V elaborates on the proposed work along with examples and describes the various algorithms used in constructing MST to support the suggested fault tolerance model (given in section IV). Section VI explains the experimental setup. In section VII, the result analysis part highlights the experiments and performance comparison with other mechanisms namely PRIMS, Ant Colony Optimization (ACO), Particle Swarm Optimization (PSO), Imperialistic Competitive Algorithm (ICA) and Firefly (FF) algorithm concerning various network parameters viz. throughput, end-to-end delay, and power consumption. Finally, Section VIII concludes the paper highlighting the future scope.

II. RELATED WORK
This section presents a comprehensive literature survey of various routing protocols, data aggregation, and Fault Tolerance. Fault tolerance in WSN can be achieved broadly in two ways, one is to find the link failure, and the other one is to detect node failure. In the literature, there are several techniques available to find links and node failures individually. However, very few research techniques are available to find both node and link failures simultaneously. There are several techniques available in the literature to improve the reliability and quality of service (QoS) in WSN. The multipath [6] finding is the one to improve the reliability, timeliness, and load balancing in WSN. Faulty node detection and interference model caused by neighbor nodes are also equally popular in identifying the faults in WSN.
The work proposed in Lee and Choi [7] is a distributed algorithm to find the faults in WSN. The faulty nodes are identified based on the comparison of neighbor nodes and dissemination decisions made by each node. The proposed research identifies the transient faults in communication and sensing in WSN. A sliding window is utilized to eliminate the time redundancy.
Qu et al. [8] proposed a fault tolerance model with mobile agents to attain consistent and efficient performance, with required functions within a given period. The faults are detected and identified as the kind of failures owing to the behavior of the mobile agent. The behavior of the mobile agents can be analyzed statistically by various parameters viz. migration time from one sensor node to another sensor node, the lifetime of the mobile agents, and distribution of mobile agent population. This mechanism overhead controls the behavior of mobile agents to adopt the changes in the environment.
Guo et al. [9] introduced the hybrid on-demand distance vector multi-path (HODVM) routing protocol for spatial wireless ad-hoc networks (SWAHN). The proposed protocol HODVM divides the SWAHN into two parts. The first part is with the backbone, and the second one is without a backbone. HODVM finds adaptive multipath to balance the workload and improve the fault tolerance in SWAHN. In WSN, maintaining multipath is a very complicated task due to the size and capacity of the links among various kinds of nodes.
Geeta et al. [10] described an active node based fault tolerance and interference (AFBTI) in sensor networks to pick out faulty nodes using two models, one being the battery power model, and another being interference model. They presented the handoff mechanism as a fault tolerance mechanism to face low battery power. However, the proposed work considers only battery power as criteria to decide the faulty node. It may not be appropriate in WSN.
Abba and Lee [11] proposed an autonomous self-aware and adaptive fault-tolerant routing technique (ASAART) for WSNs and compared the simulation results with self-selective routing and self-healing routing protocols in different simulation scenarios and found better in throughput, delay (end-to-end), packets error rate and power conservation in faulty and congested WSN. Yucai Zhou et al. [12] pointed out in their paper that due to faults or node failures occurring by abrupt environmental changes, sensor network performance gets deteriorated. Hence, to solve the problem mentioned above, a protocol supporting high fault tolerance and power efficiency based on a multi-way routing mechanism has been proposed. It is an enhancement in hybrid, energyefficient distributed clustering mechanism (HEED) protocol, called HEED-FT. The HEED-FT mechanism consumes less energy and provides high reliability and increases network lifetime.
Sutagundar et al. [13] proposed a fault-tolerance approach based on multiple (both fixed and mobile) agents. This proposed multi-agent-based scheme provides fault tolerance at the node, cluster, and sinks level. In node-level fault tolerance, a node accepts only correct samples i.e., the samples in the reference range and rejects the false samples. Thus, the node calculates the average of all samples which were found correct. At cluster level fault tolerance, after receiving the data from all the nodes, the difference in data is computed by comparing the data of each node to all other nodes. Finally, fault tolerance at the sink level, the sink node broadcasts alive packets to every node and replicates the sink node periodically. If nodes and replicated sink nodes get alive packets from the sink node, then it transmits the data to the sink otherwise replicated sink node broadcasts its ID to every node.
Tien et al. [14] proposed dual separate paths (DSP) algorithm to support fault-tolerance by improving network traffic in WSNs. The DSP algorithm constructs two different paths between the source and target (destination) nodes, depending on the topology of the network. This algorithm supports both wired and wireless networks and provides non-interminable fault tolerance. Elsayed et al. [2] presented an approach called distributed self-healing approach abbreviated as DSHA, wherein fault identification, diagnosis, and repairs are performed. These are skilled at both the cluster head and node level. DSHA mechanism was found effective in identifying hardware failures and diagnoses to make sensor networks resilient and reliable. The results showed that the DSHA approach can handle up to 67.3% hardware malfunctioning and hence improve 62.6% network lifetime.
Mitra and Das [15] observed that network reliability and dependability can be measured by its fault identification, fault diagnosis, and overcome techniques. The proposed architecture supported distributed fault tolerance and algorithms for fault recovery by using checkpoints of data and state of nodes in a distributed environment. Ma et al. [16] developed a novel algorithm for fault tolerance by generating a multirouting tree abbreviated as FTMRT. In it, a multi-routing tree is constructed to ensure k-disjoints routes from every sensor node to a collection of super-nodes. Thus, to build a fault-tolerant topology, each data transmitting node redefines the transmission power in compliance with the multi-routing tree.
Begum and Nandury [17], proposed a fault-tolerant mechanism called component-based self-healing mechanism which builds an alternate path to reach the root node in a hierarchical aggregation tree when any node or link fails. The said mechanism is based on two algorithms, the first is Self-healing Component-based Reconfiguration (SCR) for preserving precedence relations and another one is SCR-Dynamic Transmission Range Adjustment (SCR-DTRA). These two approaches are compared with existing approaches i.e. Tree Reconstruction, WKLP, and FTS. Simulation results prove that the SCR-DTRA approach is effective in terms of the Affected Ratio (AR) and Recovery Ratio (RR).
In [18], Kim et al. introduced a Maximum fault tolerance barrier coverage problem related to hybrid sensor networks (MFBP-HSN), containing both static and fully-controllable dynamic (mobile) sensors. It tried to migrate the mobile nodes in such a manner that fault tolerance of barrier-coverage of hybrid sensor networks mentioned above, was maximized. A polynomial-time exact algorithm was proposed for the above-said problem.
Shagufta Henna [19] presented an algorithm for approximation known as energy-efficient maximum disjoint coverage (EMDC) with a resemblance estimation ratio. In the proposed work, EMDC performance analyses showed up in favor of power efficiency and fault tolerance. The EMDC algorithm increased the lifespan of the network by choosing two disarticulated set covers minimizing relay power. The EMDC mechanism was found better in terms of network lifetime in comparison of DSC-MDC for a different count of nodes and ranges. VOLUME 8, 2020 Moussa and Elalaoui [20] proposed a mechanism related to fault tolerance of cluster heads. The simulation was performed and found better as compared to low energy adaptive clustering protocol (LEACH), and informer homed routing mechanism.
To overcome the challenges of WSN, Jassbi and Moridi [21] presented an algorithm called the HEED algorithm for clustering. Further, for improving power consumption, they proposed a sleep/wake-up method for the cluster members. The main focus of work [21] was to identify and repair faults of cluster heads as well as cluster member sensor nodes. Hence, to perform this task, a node is chosen as a backup node of the cluster head. The failed node is separated, and its place is taken by its neighbor node, which goes to wake-up mode from the sleep mode.
Hence, by anatomizing the literature it has been found that a unique mechanism is needed to diagnose the faults and novel methods must be discovered to ameliorate the reliability and quality of service during the transmission of data. Further, the existing literature on spanning trees to achieve data aggregation is devoid of any fault tolerance procedure and thus, it influences the various important parameters of WSN viz., throughput, end-to-end delay, and power consumption.

III. PROCEDURES TO FIND ACTIVE NODES AND ACTIVE LINKS
In WSN, fault tolerance is a crucial issue, and it can be achieved by finding the active node and active link. The number of active nodes and links, define the fault tolerance factor of WSN. In this proposed model, we derived a procedure to find the active node and link. The proposed dynamic node model makes use of the neighbor node, average battery power, and distance. The dynamic connection can be identified based on the available bandwidth over the link. The following sections illustrate the mechanism to find the active node and link separately.

A. ACTIVE NODE IN WSN USING BATTERY POWER AND DISTANCE
The active state of the node is represented by n active = [n bp , d], where n bp is the battery power of node, and d is the distance between the intermediate node and its neighbor node. In the proposed model, the active node is decided based on the heuristic method, in which existing neighbor node battery power and distance are compared with predefined threshold values. The threshold values are node's average battery power denoted by n avg−bp and average distance indicated by d avg . These values are evaluated based on the existing neighbor node's average battery power and average distance. The following is the procedure to find the active node in the improved handoff algorithm (refer algorithm 1).

B. ACTIVE LINK IN WSN USING AVAILABLE BANDWIDTH
In the given WSN, all sensor nodes are connected with the base station, cluster head (CH), and with other sensor nodes with specific bandwidth (i.e. frequency range). In the proposed model, certain bandwidth thresholds are defined between sensor to sensor (B s−s ), a sensor to CH (B s−ch ), CH to CH (B ch−ch ), and CH to Base Station (B ch−bs ). If any link (edge) weight is less than the threshold, then it is considered as a broken link. The thresholds among the various kinds of links and bandwidth thresholds are given in Table 1.
The following procedure is used to find the active link in the improved Q-MST algorithm (refer algorithm 2).

IV. PROPOSED SYSTEM MODELS
Various system models used in this article are discussed in the subsequent section:

A. PATH LOSS MODEL
In wireless communication literature, various path loss models and their analysis exist. The followings are well-known path loss models in wireless communication.
• Free-space model • Two-ray model • The simplified path loss model • Empirical models. Path loss is defined as P L = (P t P r ) > 1 where, P L is the path loss, P t is power transmission, and P r is received power.
The radio signals, as propagates away from the transmitters, the power of the radio signals is reduced according to distance traveled from the transmitters. In most of the wireless communication systems, often, the default path loss model is the free space path loss model, which computes attenuations according to the inverse square law along a single line-ofsight propagation path.
In all of the above-said models, the path loss is proportional to distance with some exponent, and exponent depends on the path model. Further, in all of the path loss models, the distance from the receiver and transmitter is the key factor. Hence, in our proposed model, we have considered the average distance, which is the threshold to decide the active node.

Algorithm 2 Procedure for Finding Active Link
Procedure (Type of the Link, Bandwidth) Begin: Return Inactive END: END: Figure 2 shows the path loss in the first order radio model and its relation with distance. In WSN currently, there is a great deal of low radio energy consumption models. In the proposed model, we have adopted first order radio model for simplicity and the radio dissipates E elec = 50 nJ/bit to run the transmitter or receiver circuitry and E amp = 0.1 nJ/bit/m 2 for the transmit amplifier. These parameters also are shown in Table 5.
The eq. (2) indicates the path loss model, which depends on the radio transmission and receiving power, which is proportional to some of the power of the distance in all the well-known path loss models [22]. The distance between two nodes (x i , y i ) and (x j , y j ) will be evaluated using the formula . P L is path loss from each neighbor at node n from each neighbor node 1, 2, 3, 4, and 5.
In the proposed model, using the average distance (d avg ) among n nodes, consider nodes 1, 3, and 5 are active and thus deemed to intended. Similarly, nodes 2 and 4 are inactive; hence, these are not considered to intend. In nodes 2 and 4, the interference problem arises, and it is handled  by the interference model given in [10], but according to suggested work in this article, it is essential not to consider the interference model as already selecting the node of a higher average distance. Further, due to interference, there is a kind of node or link failure that has been previously handled by the proposed fault tolerance model; hence, the interference model is not required in the proposed approach.

B. THE FLOW CHART OF THE PROPOSED NLF FAULT TOLERANCE MODEL
A model for fault tolerance is proposed to support both node and link failure; its functioning has been presented here in Fig. 4. For a link or edge failure, the Imp-QMST algorithm and, for node failure, the Imp-Handoff algorithm have been proposed, which are improved forms of QMST and Handoff algorithm, respectively. A WSN comprises of several sensor nodes. Let an undirected fully connected graph G = (V, E) represent the topology of the network where The proposed NLFFT model control flow illustrated in Fig. 4.

C. ENERGY CONSUMPTION MODEL OF WSN
A variety of power consumption models [23] are available, but this article uses Heinzelman et al. [24] model for power dissipation and the meaning of symbols has been illustrated in Table 5. The proposed work uses, to transmit and receive an n-bit message to a distance (d) by using radio model: Energy Consumption at Transmitter (refer Eq. 3) Energy Consumption at Receiver (refer Eq. 4) In the simulation, it summarizes that the size of every incoming and outgoing message is one bit. Hence, the Eq. (2) and Eq. (3) are converted into (4) and (5) respectively.

D. END TO END DELAY MODEL
To calculate the end-to-end delay, the following formulae have been used: The Time required to send a packet at k-links Here, H is the header size (in bits), D is bit size of data, P is some packets and C is the link capacity, also known as buffer size. It has been assumed that the header size (H) of each packet is 2 bits and the data size is (D) 1 bit. All the links are considered as homogeneous and having a capacity to store 50 packets (identical to the link capacity).
Thus, it can be seen that the number of packets is identical to the sum of the size of all the data packets. Thus, by putting D/P = 1, H = 2, and C = 5 the above-given formula (refer Eq. 7) is converted to Eq. (8).

V. NLFFT MODEL: A NOVEL FAULT TOLERANCE MODEL TO SUPPORT FAILURE AT BOTH LINK AND NODE LEVEL
Though the flow chart of the NLLFT model has been presented in the previous section, this section highlights the implementation of the techniques used in the proposed NLFFT model. Firstly, MST is generated by using swarm-based approaches (ACO, PSO, FF, and ICA algorithm) and traditional PRIMS algorithm to implement the proposed NLFFT model for fault tolerance. Every node as a part of MST acts as a data aggregator node. The Prims algorithm is known as Jarnik's algorithm, which is a greedy algorithm to find MST by calculating the subset of edges that construct a tree, including all vertices, at least once.
Marco Dorigo gave the ant colony optimization (ACO) [25] in 2006. In ACO, artificial ants are deployed to perform a heuristic search. The ACO [26]- [28] algorithm uses a probabilistic approach to get MST, which acts as a data aggregation tree. After obtaining the desired solution, the pheromone and evaporation parameters get updated.
The PSO algorithm is a meta-heuristic and populationbased algorithm. It was developed by Eberhart and Kennedy in the year 1995 [29]. It is a nature-inspired and swarm-intelligence based heuristics method, provided by recognizing the movement and behavior of birds and fish flocks. The minimum spanning tree using the PSO algorithm and various parameters related to it have been explained by Goldbarg et al. [30] and improved by various researchers for performance improvement [31].
The Firefly algorithm was developed by Xin-She Yang at the end of the year 2007 and the beginning of 2008 [32], [33], similar to PSO, it is also a meta-heuristic algorithm inspired by the flashing behavior of fireflies and their bioluminescent communication [34]. A discrete Firefly algorithm for improved data collection and data aggregation in WSN was elaborated in [35], [36]. The ICA [37] algorithm was given by Atashpaz-Gargari and Lucas in 2007 [38]. ICA can be considered as a human counterpart of the Genetic Algorithm [39]. It performs human social evolution while the Genetic Algorithm performs biological evolution of species. Sayadnavard et al. explained sensor network localization using the ICA algorithm [40].
The ABC algorithm was presented by Devis Karaboga [41] in the year 2005. It is a meta-heuristic algorithm based on the swarm. It was designed to optimize and solve multivariable and numerical problems [42], and it was influenced by the honey bees and their genius foraging behavior. The ABC algorithm contains three components, mainly, i.e., working bees, unemployed bees, and the food source. The detailed algorithm related to this article, to solve Q-MST using ABC, is explained in [4]. In the NLFFT model, an improved version of QMST [3]- [5] and Improved Handoff algorithm were proposed and named as Imp-QMST and Imp-Handoff algorithms respectively. Tools generally used for WSN are discussed in [43] and energy-efficient protocols are developed in [44]. A detailed study of the swarm and evolutionary algorithm available in [45]- [49].

A. IMP-QMST MECHANISM
In the Q-MST approach, at the place of edge cost (weight), the cost of enjoined pair of edges is also considered, and the target is to find out the side with the lowest side cost, to be replaced at the place of broken link or edge. The Q-MST is an NP-Hard problem, which was suggested by Asad and Xu [42]. Further, it was extended by Sundar and Singh [4] by implementing an ABC algorithm to find MST. The concept of applying fault tolerance in WSN using the Q-MST approach, along with an example, has been implemented by Menaria et al. [3].
Going a step ahead of the above-mentioned Q-MST approach, this article proposes an improved-QMST (Imp-QMST) mechanism. The flowchart of Imp-QMST has been shown in section 4.A.2 and can be explained thus: 1. When a node or link breaks down, or failure occurs due to battery power or any other reason, the sensor network is separated into two components. (one remains to the left side of the broken link and another to the right side) 2. Find the edges which connect the two parts mentioned above (sets).
where b i is the battery power of i th node on the edge e i . 6. Similarly, calculate the cumulative average battery power (B cum−avg ) for all the edges using Eq. 10, which are included in the connecting sets, i.e. edges which connect both components.
7. Edge Selection (Select the edge which has its cost lower than or equals to average cost d avg , and its average battery power b average is higher than or equal to cumulative average battery power i.e. B cum−avg . 8. If no edge is found in step 6, then follow a simple Q-MST mechanism, i.e., select the edge with minimum cost as calculated by step 3. 9. Replace the selected edge at the broken edge or link in the network and continue transmissions. 10. End Let's consider the steps mentioned above with a sensor network taken as an example in Fig. 5. Figure 5(a) shows a complete undirected graph with 5 sensor nodes, and these nodes are connected through 10 numbers of sides (edges), called links in the WSN ranging from e1 to e10. The inter-cost matrix (edge-to-edge cost matrix) of the said network has been shown in Table 2. Table 3 depicts the battery power at the given moment, for all the five nodes participating in the network.  In the mentioned inter-cost matrix in Table 2, each diagonal element presents the edge weights (cost or distance), and the remaining elements are edge-to-edge costs, which can be considered as a parameter related to WSN, i.e., channel strength. Figure 5(b) is a minimum spanning tree with a total weight of 223. Now suppose, due to any valid reason, the link e9 becomes weak or broken down (refer Fig. 5(c)), then the whole graph is separated into two sets, one is {1, 2, 5}, and another set is {3, 4}. Now, it is required to select the alternate edge or side connecting the said two sets. Fig. 5(d) depicts that there are 3 possible edges connecting the two sets namely {e 5 , e6, e8). Now, the total weight (cost) is to be calculated for all three edges. First, an edge-to-edge cost is calculated by considering every possible alternate edge using following steps: As the total weight (cost) of edge e6 is low i.e., 140 than other replaceable edges hence, in QMST approach the broken edge, i.e. e9 will be replaced by e 6  4. Now, the selection process starts by using the information provided in steps 1 to 3 and can be concluded by making a decision table, i.e. Table 4.
Thus, it can be seen clearly in the decision table that the edge e 5 , having the link cost lower than average cost,  i.e.145<=145.66 and its average battery power is higher than the cumulative battery power, i.e., 475.42>=437.91). Hence, the edge e 5 will get selected as an alternative edge at the place of broken edge e9, as shown in Fig. 5(f).
The side e6 and e8 do not fulfill both the conditions, so these sides will not be considered. Now the question arises that by following the above Imp-QMST procedure, what to do when more than one edge found suitable. In this case, among all suitable edges, the edge with minimum cost gets selected as a replaceable edge.

B. IMP-HANDOFF MECHANISM
Similar to the QMST mechanism, the Handoff algorithm is used in fault tolerance to handle node failure in WSN. The only difference is that Q-MST or proposed Imp-QMST algorithm works on a link or edge failure while the Handoff or Imp-Handoff mechanism works on node failure. The flowchart of the Imp-Handoff mechanism is shown in section 4.A.2 in the proposed NLF Fault Tolerance Model. The algorithm is shown in this section.
The handoff mechanism [10] is used to replace the faulty node with an alternate sensor node. In the handoff mechanism, whenever a fault occurs at any node due to low battery power or power failure, the neighboring node with the highest battery power replaces the faulty node, and all services running on the defective node get transferred to the new neighbor node. Thus, the data transmission process does not get interrupted.
The Imp-Handoff algorithm is applied as the fault tolerance technique because of the battery power drain mentioned in Fig. 6.
Whenever a node, either a malicious or non-faulty, recognizes that its battery energy level is reduced to a degree up to b th , i.e., if b k ≤ b th (b k indicate to the k th time window), a handoff connection to its neighbor node needs to be initiated. In the Handoff mechanism, the malicious node gathers the status of the energy level of all its neighbor nodes and transmits the handoff parameters to the neighbor node, containing the superior battery power. The battery power gathering process has two phases: (1) sending a request of VOLUME 8, 2020 battery power to all neighbor nodes (2) all the neighbors, send reply packets having their latest battery power.
In the Imp-handoff mechanism, besides including the process mentioned in the above paragraph (related to the battery power), two more parameters are also considered-namely the distance (weight) of all neighbor nodes to faulty node and fault index of every node. The term fault index (FI ) is defined as: FI = n missed n total (11) where n missed = total number of missed packets and n total is the total number of packets. Initially, the fault index of every node is considered zero, but as soon as transmission starts, its value gets updated. After receiving all the parameters, the average battery power and average distance for all the neighbor nodes are calculated.
At first, the neighbor node with battery power higher than or equals to average battery power and with distance higher than or equal to the average distance will get selected. While in some cases, if the above condition does not get satisfied, then the neighbor node with the least fault index will get selected. The notations used and the Imp-Handoff algorithm are presented below: Algorithm 3 Improved Handoff Algorithm (Imp-Handoff Algorithm) 1. Initially assign a battery power (b i ) to every sensor node arbitrarily. 2. Define Source, Sink, and Threshold value (b th ) of the Battery Power. 3. Start data transmission from defined source to destination repeatedly. 4. Update the battery power for every transmission defined in step 3. 5. IF any fault occurs in step 3 (b k < b th ) then 6. Send REQUEST packets to all neighbor nodes for both distance and updated battery power excluding nexthop. 7. Receive the REPLY packets in the response of request given in step 6, from each n-1 neighbor node. 8. Arrange all the neighbor nodes of a failed node in ascending order of distance. 9. Calculate the parameters b average and d avg . 10. For each node from the list of (n-1) nodes 11. Check whether it's the last updated battery power ≥ b average and distance ≥ d avg . 12. If any suitable node found in step 10 then replace the faulty node from this node by sending all parameters related to connection to the identified node i. 13. Else select the node which has the lowest fault index (FI i ). 14. Replace the faulty node with the identified node in steps 8 to 12.

End
Notations: b k is the battery power of the faulty node in a k th time frame, b th is the threshold power which is a predefined constant, n is the count of neighbor nodes, d k is the distance (weight) of a neighbor node from the faulty node, b average is the average battery power, d avg is the average distance (weight) of neighbors from faulty nodes, and FI i is the fault index of node i.
The above proposed Imp-Handoff algorithm is compared with the existing handoff algorithm. The results have been analyzed in section 7, with the experimental setup discussed in section 6.

VI. EXPERIMENTAL SETUP A. ASSUMPTIONS
While examining the performance of the proposed NLFFT model, the following assumptions are considered: • It is assumed that every node in the sensor network setup is homogeneous and is deployed statically.
• Every sensor node has an equal capability to sense the surrounding data.
• The probabilistic approach is taken into consideration from the Prowler Simulator for networks, in the context of packet transmission from source to sink node. In this approach, every packet has a probability between 0 and 1 and those packets that have a probability greater than 0.5, will only be transmitted to the next hop.
• After constructing the MST using various swarm intelligence techniques, this MST is considered as a data aggregation tree where all the leaf nodes are considered as data aggregator nodes.

B. SIMULATIONS AND SIMULATION PARAMETERS
The simulation was performed in the MATLAB environment. The sensor nodes were set out randomly in a 200 * 200 square unit area. The source and destination (sink) nodes were also declared arbitrary. The Euclidean distance of all the pairs of connected nodes was calculated and if it was found less than 150 meters, then those nodes could be considered as disconnected. Finally, the depth-first search (DFS) was imposed on examining whether the network was connected or disconnected. If the network was found as disconnected, then the whole procedure was repeated to get the connected graph to carry out the further simulation. After getting a connected graph, MST is originated with various algorithms, as mentioned in section V, and then performs packet transmission. While carrying out packet transmission, if any node or link fails due to less battery power or power failure, Handoff and Imp-Handoff algorithms, Q-MST, and Imp-QMST algorithms are applied to support fault tolerance, as elaborated in section V.
As the packet transmission process is completed, various parameters like the total number of packets transferred, total packets received, total packets lost, the power consumed, and the end-to-end delay are calculated. The various comparative graphs are plotted in the result analysis in section VII.  Table 5 enlists various simulations parameters that are considered as an experimental setup to measure the performance of the proposed NLFFT model.

VII. RESULT ANALYSIS
Competitive analysis between QMST versus Imp-QMST and Handoff versus Imp-Handoff has been performed through various swarm intelligence techniques viz. ACO, PSO, FF, ICA, and traditional PRIMS algorithms.
Initially, MST is constructed through techniques as mentioned above. Whenever there are link or node failure, the said fault tolerance techniques, i.e. Q-MST, Imp-QMST, Handoff, and Imp-Handoff are applied. Results are calculated in terms of throughput, end-to-end delay, and energy consumed during the whole data transmission process. After performing several simulations, for each of the transmission, the average results are computed, as shown in Table 5. Results for QMST and Imp-QMST have been discussed in section VIII part A.

A. QMST VS IMP-QMST ALGORITHM
In this section, MST is generated by using the abovementioned swarm intelligence algorithms and the PRIMs algorithm. Further, QMST and Imp-QMST are applied for the fault-tolerance purpose. The QMST and Imp-QMST algorithms deploy the ABC algorithm to find an alternate edge or link at the place of the broken link. The comparison of results has been depicted in subsequent sections. Table 6 and Fig. 7 shows the throughput comparison between QMST and the Imp-QMST approach. The graphical presentation of throughput comparison is shown in Fig. 7. It is clear by analyzing Table 6 and Fig. 7 that the throughput received through Imp-QMST is almost 2% better than the Q-MST approach. If it is analyzed algorithm wise, then it is found that Imp-QMST is 7% better than QMST for the PRIMS algorithm, 3% for ACO algorithm, 7% better for PSO algorithm, 6% better for FF algorithm and finally it is (Imp-QMST).50% better than ICA algorithm.

1) THROUGHPUT COMPARISON
Further, it can be seen that among all the swarm-based techniques, the ACO algorithm gives the highest throughput (203%, 177%, 203%, and 146% more as compared to PRIMS, PSO, FF and ICA algorithm for Imp-QMST) and it remains almost the same along with a varying number of nodes.

2) END-TO-END DELAY COMPARISON
The end-to-end delay between Q-MST and proposed Imp-QMST has been analyzed in Figure8. The calculation of endto-end delay is performed using Eq. 7, which is mentioned in section III. The explicit values are shown in Table 7. Figure 8 depicts that the end-to-end delay achieved by Imp-QMST is lower than the QMST approach. By analyzing the simulation results, shown in Table 7, it becomes clear that Imp-QMST is almost 9% better than the QMST approach. Regarding Imp-QMST, the ACO algorithm is almost 80% better than other algorithms viz. ACO, PSO, FF, and ICA algorithms.
Hence, it's clear by Fig. 8 that the ACO algorithm has a lower end-to-end delay as compared to other swarm intelligence approaches, depicted in the above-said figure.

3) POWER DISSIPATION COMPARISON
On the lines of the comparison performed in sub-section 1 and 2, a similar comparison related to power dissipation is shown here in Table 8 and Fig. 9.
It is clear from the tabular analysis that the average power dissipation while considering all the swarm intelligence algorithms, the Imp-QMST is 10% better than the QMST approach. Further, it is also apparent in Fig. 9 that power dissipated in the Imp-QMST is less than QMST. By the Imp-QMST approach with the ACO algorithm, it is 25% better than the PRIMS algorithm, 34% better than the PSO algorithm, 26% better than the FF algorithm, and 37% better than the ICA algorithm. Hence, it is concluded that among all the MST construction algorithms, the ACO algorithm has less power dissipation as compared to others and Imp-QMST performs better than the QMST approach.
The graphical representation of power dissipation is shown in Fig. 9. Here, the above-mentioned comparisons have been elaborated again by setting the count of nodes fixed to 35 and varying the call of data transmissions from 100 to 1000. The throughput, delay, and power dissipation comparisons are given in this section and subsections:

a: THROUGHPUT COMPARISON
A tabular comparison of throughput is shown in Table 9. Figure 10 narrates the throughput comparison between VOLUME 8, 2020      QMST and Imp-QMST algorithms by using various artificial intelligence techniques as an MST generation algorithm (data aggregation).
The tabular analysis in (Table 9), shows that the cumulative throughput of proposed Imp-QMST applied to all the said algorithms is almost 11% better than the QMST approach. The individual analysis of each algorithm between Imp-QMST v/s QMST shows that the PRIMS algorithm with Imp-QMST is 48% better than with QMST. Similarly, ACO algorithms with Imp-QMST are 2% better than QMST, PSO algorithm with Imp-QMST is 24% better than QMST, FF algorithm with Imp-QMST is 21% efficient than QMST and finally, ICA algorithm with Imp-QMST is about 7% more, efficient than QMST approach. Further, regarding the Imp-QMST approach it has been found that the ACO algorithm performs 363% better than PRIMS, 295% better than the PSO algorithm, 264% better than the FF algorithm, and 230% better than ICA algorithm.
Hence, it is comprehensive that the throughput from the Imp-QMST procedure is higher than QMST while numbers  of nodes are kept fixed and the ACO algorithm performs better than all the other said algorithms.

b: END-TO-END DELAY COMPARISON
The comparison regarding the delay between QMST and Imp-QMST by fixing the count of nodes is delineated in Table 10 and the graphical representation is shown in Fig. 11.
The analysis of Table 10 shows that the cumulative endto-end delay of all the algorithms with Imp-QMST performs better. If we compare it individually on the ACO algorithm then it is found that the ACO algorithm with Imp-QMST performs almost 2% better than ACO with the QMST approach.
Further, it is clear from Fig. 11 that the Imp-QMST algorithm causes lesser delay than the QMST approach.  Table 11 and Fig. 12 show that the energy consumed (nJ) by QMST is greater than Imp-QMST.  Similar to previous analyses, here also the ACO algorithm performs better than to other algorithms i.e. in Imp-QMST, the ACO algorithm is about 32% better than PRIMS and PSO algorithm, 29% better than FF algorithm and 39% better than ICA algorithm.

B. HANDOFF VS IMP-HANDOFF ALGORITHM
Along the lines of the previous sub-section i.e. subsection A, the performance comparison between Handoff and proposed Imp-Handoff algorithm is measured on various artificial intelligence (AI) algorithms for three network parameters.   Table 12 and Fig. 13 enlist the throughput comparison between Handoff v/s IMP-Handoff algorithms on the data aggregation tree generated by various swarm intelligence techniques.

1) THROUGHPUT COMPARISON
The tabular analysis makes it clear that the Imp-Handoff algorithm is better than handoff algorithm, tested on various AI algorithms i.e. Imp-Handoff algorithm is about 3% better than handoff algorithm for PRIMS algorithm, 1.5% better for ACO algorithm, 3% better for FF algorithm and 2% better for ICA algorithm.
To find a better-suited algorithm, the performance of all the said AI algorithms are compared and it is found that the performance of the ACO algorithm for generating MST along with Imp-Handoff algorithm for fault tolerance is best suited. The ACO algorithm with Imp-Handoff FT gives about 214% better throughput than PRIMS with the Imp-Handoff algorithm for FT. Similarly, ACO performs 198%, 229%, and 184% better than to PSO, FF, and ICA algorithms.
Hence, it is clear and it can also be seen from Fig. 13 that the throughput produced through the Imp-Handoff algorithm is way better than the Handoff algorithm.

2) END-TO-END DELAY COMPARISON
The tabular comparison between the handoff and the Imp-Handoff algorithm on various algorithms shown in Table 13.
Considering the end-to-end delay in Table 13, it is clear that on an average Imp-Handoff algorithm is about 9% better than the Handoff algorithm. If the PRIMS algorithm is considered then applying handoff and Imp-Handoff algorithms on it as FT techniques, the Imp-Handoff technique is around 7% better than the handoff algorithm. Similarly, Imp-handoff on ACO, FF, and ICA algorithm is found to be 11% better than handoff and on PSO it is found 7% better than the handoff algorithm.
Further, concerning Imp-Handoff, while comparing the performance of various algorithms, the ACO algorithm is found 80% efficient than PRIMS, PSO, FF, and ICA algorithm. Apart from the tabular comparison, the graphical representation of the end-to-end delay comparison of aforesaid is shown in Fig.14.
By observing Fig. 14, it is clear that the end-to-end delay using the Imp-Handoff algorithm is less than the Handoff algorithm. Further, it is also clear that as the number of nodes increases, the end-to-end delay also increases.

3) POWER DISSIPATION COMPARISON
The comparison of power dissipated in the fault tolerance process by using both the Handoff and the proposed Imp-Handoff algorithms on various AI algorithms is visualized in Table 14. Further, graphical analysis of shown comparison is shown in Fig. 15. Table 14 shows that cumulatively considering all the AI algorithms shown in this table, the proposed Imp-Handoff algorithm is 7% more efficient in energy consumption as compared to the existing Handoff algorithm. If we compare the Handoff and Imp-Handoff algorithm on an individual algorithm, then it is found that, for the PRIMS algorithm, the Imp-Handoff algorithm is 10% better than the Handoff algorithm. Similarly, for ACO, PSO, FF, and ICA algorithm, the Imp-Handoff is 2%, 5%, 9%, and 4% better than the Handoff mechanism.
Further, to find out the best-suited algorithm to construct MST respective to the Imp-Handoff mechanism, it is found that the ACO algorithm (Table 14) is about 56% efficient than PRIMS, PSO, FF, and ICA algorithm. Figure 15 also makes it clear that during transmission, the power dissipated by the traditional Handoff algorithm is higher than the Imp-Handoff algorithm. Power consumption is a crucial parameter in any network as it directly affects network lifetime.    Table 15 and Fig. 16 in this section enlist the throughput comparison between the Handoff and Imp-Handoff algorithm by keeping the fixed number of nodes and increasing the number of transmissions.
The tabular comparison makes it clear that the cumulative throughput of the Imp-Handoff mechanism is about 3-4% more than the Handoff mechanism. The individual comparison of various algorithms by the Imp-Handoff mechanism shows that the Imp-Handoff applied to the PRIMS algorithm is about 28% efficient than the Handoff algorithm. Similarly, the Imp-Handoff applied on ACO, PSO, FF, and PSO algorithms are about 1%, 19%, 14%, and 9% efficient than the Handoff algorithm.  Further, it can also be concluded from Table 15 that for Imp-Handoff, the ACO algorithm is around 355% efficient than the PRIMS algorithm, 350% efficient than PSO, 261% than FF, and 215% efficient than ICA algorithm.
Hence, it can be concluded that by keeping the fixed number of nodes and changing the transmissions in ascending order, the throughput by the Imp-Handoff algorithm becomes better than the Handoff algorithm.

b: END-TO-END DELAY COMPARISON
The end-to-end delay comparison of the Handoff algorithm and the Imp-Handoff algorithm with said data aggregation algorithms by setting the count of nodes to 35, has been given in Table 16. The pictorial analysis of the end-to-end delay comparison of Handoff and Imp-handoff algorithms is shown in Fig. 17.
The analysis of Table 16 shows that the Imp-Handoff algorithm performs better and, on average, it is about 2% better as compared to the Handoff algorithm. By comparing individual algorithms with Imp-Handoff and Handoff, it is found that Imp-Handoff applied on the PRIMS algorithm gives about 2% better performance, ICA gives 8% better performance and rest of the algorithms mentioned in Table 16 give a slightly better or equal performance as compared to  Handoff approach. Further, by analyzing Table 16, it becomes clear that by Imp-Handoff, the ACO algorithm is an average 82% efficient as compared to PRIMS, PSO, FF, and ICA algorithms.
Hence, Fig. 17 concludes that the end-to-end delay of the Imp-Handoff algorithm is way lesser than the Handoff algorithm and stays almost the same for all the number of transmissions, for all MST generation algorithms.

c: POWER DISSIPATION COMPARISON
The power dissipation comparison is also specified in Table 17. Table 17 depicts that, on an average, Imp-Handoff algorithm is 8% efficient in saving energy as compared to the Handoff algorithm. The Imp-Handoff on PRIMS algorithm saves 5% energy as compared to the Handoff algorithm. Similarly, the Imp-Handoff algorithm, as a fault tolerance algorithm applied on ACO, PSO, FF, and ICA;  saves about 11%, 2%, 5%, and 12% less energy as compared to the Handoff mechanism. Similar to previous result analysis sections, Fig. 18 depicts the graphical analysis of power dissipation between handoff and Imp-Handoff techniques on MST constructed by various artificial intelligence techniques.
Further, the Imp-Handoff mechanism applied to the ACO algorithm is around 68% energy efficient as compared to other algorithms viz. PRIMS, PSO, FF, and ICA algorithm.
Hence, by viewing Fig. 18 and Table 17, it is concluded that the power dissipation by the Imp-Handoff mechanism is low as compared to the existing handoff mechanism.

VIII. CONCLUSION AND FUTURE SCOPE
The result analysis of section VII makes it clear that the proposed NLFFT model for fault tolerance (shown in section IV) is successful when any node or link failure occurs in the sensor networks. The supportive Imp-QMST and Imp-Handoff algorithms are found to be way better than QMST and Hand-off algorithm in terms of throughput, end-to-end delay, and power dissipation. In the mentioned result analysis section, four swarm intelligence techniques (ACO, PSO, FF, and ICA) and one traditional PRIMS algorithm have been applied to generate MST to support data aggregation, and then fault tolerance mechanism is imposed according to the proposed NLF fault-tolerance model.
Simulation results depict that as compared to basic techniques, i.e. Q-MST and Handoff algorithm, the proposed NLFFT model improvises the performance of WSN around 7%. The comparison of the individual algorithm shows that the Imp-QMST gives about 6% improved throughput, 5% lesser end-to-end delay, and 6% less power consumption as compared to the QMST algorithm. Similarly, Imp-Handoff improves about 4% throughput, 6% lesser end-to-end delay, and 7% less power consumption as compared to the Handoff algorithm. Hence, the proposed NLFFT model proves the improved performance in terms of throughput, end-to-end delay, and power consumption.
Though the complexity of the proposed algorithms in the NLFFT model is increased by involving more than one parameter, i.e. battery power, cost of edges but the competent results go on to prove the efficacy of the proposed NLFFT model and shows that it can be applied to handle node or link failures.
Further, as the proposed NLFFT fault tolerance model is applied to the statically deployed sensor nodes only, it can be extended and applied to the dynamically deployed sensor networks also. This work can also be extended in Internet-based applications by adding some security protocols and regulations.