Trust-Aware and Fuzzy Logic-Based Reliable Layering Routing Protocol for Underwater Acoustic Networks

Routing protocols based on trust mechanisms have been widely investigated for wireless sensor networks, and the works have achieved good results, while there are few works on trusted routing for underwater acoustic networks (UANs). However, trust-aware routing is the key to improving the packet delivery rate and the energy efficiency of UANs. Therefore, inspired by the theory of trust evaluation, a trust-aware and fuzzy logic-based reliable layering routing protocol (TAFLRLR) is proposed. In the TAFLRLR protocol, to avoid the problem of the void area and improve the transmission reliability, the candidate nodes of the next-hop forwarding nodes are determined according to the layers of neighbor nodes. Moreover, a fuzzy logic-based trust evaluation mechanism (FLTEM) is provided, which employs the fuzzy comprehensive evaluation decision model to calculate the comprehensive trust value for underwater sensor nodes. Further, the node density of a candidate node and its comprehensive trust value are taken as the input of a fuzzy control system and the forwarding probability (FP) of the node is taken as the output, and the candidate node with the highest FP is selected as the best forwarding node. Simulation results illustrate the superiority and effectiveness of the TAFLRLR protocol in terms of energy efficiency, routing reliability, and transmission reliability.


Introduction
In recent years, underwater acoustic networks (UANs) have been widely used in marine pollution monitoring, aided navigation, resource exploration, and military fields [1].UANs are deployed underwater and composed of numerous sensor nodes, autonomous underwater vehicles, and unmanned underwater vehicles [2,3].UANs use sensors to collect the physical information of the water, such as temperature, depth, and salinity, and transmit the information to a sink node in a multi-hop manner.Then, the sink node sends the information to the server using the radio signal for data analysis.
Usually, research concerning UANs includes topology control, node localization, routing and MAC protocol, reliable transmission, etc.However, compared with terrestrial wireless sensor networks, the following characteristics of UANs bring significant challenges for node deployment, protocol design, and reliable transmission.
(1) The propagation speed of the acoustic waves in water is 1500 m/s, which leads to a long propagation delay.(2) The channel error rate is high due to the influence of the Doppler effect, path loss, ship noises, etc. (3) The acoustic signals can decay with increasing transmission distance when transmitted underwater; the exponential decay factor increases with increasing frequency; thus, low-frequency signals are more preferable for long-range communications, which results in a low bit rate.(4) The underwater node is powered by the battery, and it is difficult to recharge or replace the battery in harsh underwater environments, which results in the energy of the node being limited.However, underwater acoustic modems consume more energy in packet transmission than terrestrial radio frequency modems.(5) The nodes move autonomously or with the water flow or other activities, which leads to a dynamically changing network topology [4][5][6].
These characteristics have a significant effect on the protocol design as well as the performance of the designed protocol.In addition, the opening and sharing of underwater acoustic channels also bring about great challenges to the reliable transmission of UANs.Nodes of UANs are deployed underwater and are unguarded, and they are easily captured as malicious nodes (MNs), which expose the network to threats and attacks.For example, an MN may flood HELLO packets (HELLO packets are also called beacon messages, which are usually used for neighbor discovery and routing maintenance.In our proposed protocol, HELLO packets are also used for configuring the layer of nodes.The details are provided in Section 3) in the network.The malicious HELLO packets have the following negative impacts.(1) Many collisions occur in the network, which decreases the packet delivery rate.(2) Other nodes are subject to forward malicious HELLO packets, which results in low energy efficiency.(3) Data packets from sensor nodes are transmitted probably to the MNs instead of the sink node.The above-mentioned is a typical HELLO packet flooding attack.Beyond that, there are black hole attacks, selective forwarding attacks, etc.All of these can lead to severe network bandwidth consumption, energy consumption, and channel utilization reduction.Therefore, it is necessary to design trust-aware routing protocols to defend against MN attacks and threats to UANs.In this view, some defensive mechanisms and secure routing protocols, such as an energy-efficient key agreement mechanism [7], a secure and reliable multi-path transmission scheme [8], a secure routing scheme [9], and a secure routing protocol based on depth [10] have been investigated and developed.The existing defensive and security mechanisms can be divided roughly into intrusion protection, intrusion detection, and intrusion tolerance mechanisms.In intrusion tolerance mechanisms, trust evaluation is not only a powerful means to ensure the reliability of routing but also an effective supplement to encryption algorithms and authentication mechanisms in the view of security.Jiang et al. studied the problem of trust between nodes in UANs, analyzed the existing trust management mechanism, and proposed a trust cloud model according to the characteristics of UANs [11].The trust cloud model can improve the calculation accuracy of trust between nodes and the communication success rate.In [12], Krishnaswamy et al. proposed a scheme to select the trusted cluster heads and their member nodes based on fuzzy logic.The proposed scheme uses a lightweight XOR encryption algorithm to authenticate the nodes in the cluster and calculates the trust value based on the residual energy of the node, the distance, and relative mobility between nodes, and then uses fuzzy logic to select trusted nodes based on the trust value.In both [11,12], trust management is used to improve the reliability of transmission.
Inspired by [11,12], in this paper, we propose a fuzzy logic-based trust evaluation mechanism (FLTEM) for underwater sensor nodes.FLTEM uses the fuzzy comprehensive evaluation decision model to calculate the comprehensive trust value of nodes to identify MNs and improve the reliability of the network.Moreover, we designed a trust-aware and fuzzy logic-based reliable layering routing (TAFLRLR) protocol using FLTEM.We employ a fuzzy control system (FCS) to calculate the forwarding probability (FP) and select the best next-hop node.
The main contributions of this paper can be summarized as follows: (1) A layering algorithm is proposed to configure a layer for each node according to the minimum hop count, which improves the delivery rate of packets by avoiding the problem of void area.
(2) A fuzzy logic-based trust evaluation mechanism for underwater nodes, called FLTEM, is proposed.Considering the residual energy and different forwarding behaviors between HELLO packets and DATA packets, a fuzzy comprehensive evaluation decision model is introduced to calculate the direct trust value (DTV) of a neighbor node, and then the indirect trust value (ITV) is calculated according to the DTVs of the public neighbor nodes.Finally, the comprehensive trust value (CTV) can be obtained based on the DTV and ITV, and CTV can be used to effectively identify the MNs in the network.For instance, node n calculates the DTV n,a for its neighboring node a based on the communication behavior of node a, node a calculates the DTV a,k for its neighboring node k based on the communication behavior of node k; thus, the ITV of node k for node n is DTV n,a × DTV a,k .The CTV is the weighted sum of DTV and ITV.The calculation of DTV, ITV, and CTV is detailed in Section 4. (3) A trust-aware and fuzzy logic-based reliable layering routing protocol, called TAFLRLR, is proposed to achieve transmission reliability.TAFLRLR takes the CTV and node density (ND) of a candidate node as the input of FCS and the FP as the output.The candidate node with the maximum FP will be selected as the best next-hop node.(4) Simulation results in NS3 show that the TAFLRLR protocol has superior performance in terms of transmission reliability, routing reliability and energy efficiency.
The remainder of this paper is organized as follows.Section 2 presents several common threats and attacks faced by UANs.The network model and network initialization are introduced in Section 3. The proposed FLTEM and TAFLRLR are described in detail in Sections 4 and 5, respectively.In Section 6, we evaluate the performance of the TAFLRLR protocol via NS3 simulations.In Section 7, the paper is summarized, and future research is proposed.

Attacks in Underwater Acoustic Networks
As mentioned previously, the opening and sharing of the underwater acoustic channel make UANs vulnerable to various threats and attacks from MNs.Three common threats and attacks in UANs are as follows [13][14][15][16].
(1) A HELLO packet flooding attack occurs when an MN sends HELLO packets with higher power than that from a good node, which causes the nodes receiving the HELLO packet to consider the MN as their neighbor.In the subsequent data forwarding, the nodes that have received the HELLO packets from the MN may choose the MN as the best next-hop node and send the data packets to the MN.However, the transmission power of the normal nodes is less than that of the MN, which means that the data packets are unable to reach either the sink node or the MN.(2) Another HELLO packet flooding attack is considered in this paper.It occurs when an MN frequently floods HELLO packets in the network, which interferes heavily with the normal communication in UANs, intensifies the packet re-transmission, increases the network energy consumption, and reduces the packet delivery rate.(3) In a selective forwarding attack, the MN masquerades as a normal node in the network and drops packets with a certain probability, resulting in packet loss.So, selective forwarding attacks exacerbate packet re-transmissions, reduce the packet delivery rate, and consume much energy, which is unfavorable for energy-limited UANs.
The above attacks severely waste the resources of the network, such as bandwidth, energy, and channel utilization.Therefore, a fuzzy comprehensive evaluation decision model is introduced to establish a trust evaluation mechanism for underwater nodes and identify the MNs in the network to mitigate the threats caused by the above attacks and ensure reliable routing.

Network Model
The considered 3D network model is shown in Figure 1, where one source node is deployed underwater and it is responsible for periodically collecting and sending data.Numerous nodes (forwarding nodes) are randomly deployed underwater to receive a DATA packet and transmit it from the source node [17].A sink node deployed on the water surface collects DATA packets and delivers the packets to the server in a data center.For understanding, we made the following assumptions.
The considered 3D network model is shown in Figure 1, where one source deployed underwater and it is responsible for periodically collecting and sendin Numerous nodes (forwarding nodes) are randomly deployed underwater to re DATA packet and transmit it from the source node [17].A sink node deployed water surface collects DATA packets and delivers the packets to the server in a data For understanding, we made the following assumptions.

Network Initialization
In the initialization phase of the network, the sink node starts to broadcast p cally HELLO packets.A HELLO packet is identified by using the sequence (HELLO_seq_num) and involves some key information of the sending node, suc layer, and residual energy.The information of the sending node is updated hopand the node receiving the HELLO packet updates its layer and neighbor infor table according to the information from the received packets, which is described la structure of a HELLO packet is shown in Table 1 [17], in which SN represents the node and RN represents the receiving node.S_ID and R_ID are the IDs of the node and receiving node, respectively.When an underwater node hears a HELLO packet, it stores the ID, layer, and r energy of the sending node in the neighbor information table and reco HELLO_seq_num.The receiving node compares the layer of the sending node layer to determine whether to update its layer and forward the HELLO packet.O nodes with larger layers than the sending node are allowed to update and forw (1) Each node in the network has a unique ID.
(2) All the legal nodes in the network are isomorphic and have the same parameter settings, such as receiving power, transmitting power, idle power, sleeping power, and communication radius.(3) The source node generates packets periodically.(4) The CTV of each node in the network is initialized to 0.5 in the network initialization.

Network Initialization
In the initialization phase of the network, the sink node starts to broadcast periodically HELLO packets.A HELLO packet is identified by using the sequence number (HELLO_seq_num) and involves some key information of the sending node, such as ID, layer, and residual energy.The information of the sending node is updated hop-by-hop, and the node receiving the HELLO packet updates its layer and neighbor information table according to the information from the received packets, which is described later.The structure of a HELLO packet is shown in Table 1 [17], in which SN represents the sending node and RN represents the receiving node.S_ID and R_ID are the IDs of the sending node and receiving node, respectively.When an underwater node hears a HELLO packet, it stores the ID, layer, and residual energy of the sending node in the neighbor information table and records the HELLO_seq_num.The receiving node compares the layer of the sending node with its layer to determine whether to update its layer and forward the HELLO packet.Only the nodes with larger Sensors 2023, 23, 9323 5 of 21 layers than the sending node are allowed to update and forward the HELLO packet, which avoids packet collisions and saves energy.Significantly, the information in the HELLO packet is updated hop-by-hop.In this way, the nodes in the network can discover their neighbor nodes.The sink node periodically floods the HELLO packets, which allow the underwater nodes to update their neighbor information tables in time.Each node can only forward the HELLO packet once within a flooding cycle period.In this paper, the flooding cycle period T flood of the HELLO packets is defined according to the communication radius and the average movement speed of underwater nodes: where R is the communication radius of the node, V ave_mov denotes the average moving speed of nodes, and Rand () is the random function with a range of (0, 10].
As mentioned earlier, each node maintains a neighbor information table in which the ID, the layer L n , the residual energy E r , and RH_flag of the neighbors are recorded.The structure of the neighbor information table is shown in Table 2, in which the RH_Flag is used to indicate whether HELLO packets have been received from neighboring nodes and has been described in detail in Section 4. N n_c denotes the number of HELLO packets forwarded normally, N a_c denotes the number of HELLO packets forwarded abnormally, N n_d represents the number of DATA packets forwarded normally, and N a_d represents the number of the DATA packets forwarded abnormally.The definitions of HELLO/DATA packets normally/abnormally forwarded have been given in Section 4. All the information stored in the neighbor information table will be used to calculate DTV and select the best forwarding node.

Layering Algorithm
To avoid the void area routing problem and improve transmission reliability, a layer update algorithm is proposed, which is shown in Algorithm 1.
In the TAFLRLR protocol, each node maintains a layer that represents the hop count from the node to the sink.The layer (L sink ) of the sink node is set to 0, and the layer (L cur ) of other nodes is initialized to 0xFF [17][18][19].The layer is the only basis for determining whether a node is a candidate forwarding node.When a node receives a HELLO packet, it updates its layer according to the layer (L send ) of the sending node in the header of the packet.As shown in Algorithm 1, a layer aging timer (i.e., layer_aging_timer) is set for each node.The layer aging timer is initialized to the flooding period T flood .Received_HELLO_seq_num represents the sequence number of the HELLO packet received by the node.
After the layers of all the nodes are configured, the HELLO packets are transmitted only along the paths from nodes with lower layers to nodes with higher layers.On the contrary, DATA packets are transmitted along the paths from nodes with higher layers to nodes with lower layers until the sink node.

Trust Evaluation Mechanism
Trust evaluation is used to evaluate the reliability of nodes in networks based on their behavior and has been widely investigated in networks such as WSNs [20,21].In WSNs, the behavior of sensor nodes includes HELLO packet forwarding, DATA packet forwarding, etc. Evaluating the behavior of nodes to identify MNs in the network provides a strong guarantee for the secure and reliable communication of WSNs.
Compared with nodes in WSNs, underwater nodes are more likely to be captured, which makes UAN communication vulnerable to MN attacks.Therefore, it is essential to establish a trust evaluation mechanism for the nodes to identify MNs and ensure the reliable communication of the UANs.In this paper, a fuzzy logic-based trust evaluation mechanism (FLTEM) is presented.In FLTEM, nodes are evaluated according to their residual energy and forwarding behavior.The DTV of the nodes is calculated by using a fuzzy comprehensive evaluation decision model, and the average of the DTVs from multiple common neighbor nodes is taken as the ITV of the node [22].Furthermore, the reliability of a node is denoted by the CTV, which is determined according to the DTV and ITV.The framework of FLTEM is shown in Figure 2, where HPFBTF represents the trust factor of HELLO packet forwarding behavior, DPFBTF is the trust factor of DATA packet forwarding behavior, and RERTF is the trust factor of residual energy.DTV, ITV, and CTV will be described in detail later in this section.Node N updates the header and load information of the HELLO packet and for-10: else 11: If (layer_aging_timer > 0 and Lcur < Lsend +1) then 12: Node N discards the HELLO packet and does not update its layer; 13: else 14: Node N updates header and load information of the HELLO packet and for-16: end if 17: end if 18: else 19: Node N updates its neighbor information table; 20: end if

Trust Evaluation Mechanism
Trust evaluation is used to evaluate the reliability of nodes in networks based on their behavior and has been widely investigated in networks such as WSNs [20,21].In WSNs, the behavior of sensor nodes includes HELLO packet forwarding, DATA packet forwarding, etc. Evaluating the behavior of nodes to identify MNs in the network provides a strong guarantee for the secure and reliable communication of WSNs.
Compared with nodes in WSNs, underwater nodes are more likely to be captured, which makes UAN communication vulnerable to MN attacks.Therefore, it is essential to establish a trust evaluation mechanism for the nodes to identify MNs and ensure the reliable communication of the UANs.In this paper, a fuzzy logic-based trust evaluation mechanism (FLTEM) is presented.In FLTEM, nodes are evaluated according to their residual energy and forwarding behavior.The DTV of the nodes is calculated by using a fuzzy comprehensive evaluation decision model, and the average of the DTVs from multiple common neighbor nodes is taken as the ITV of the node [22].Furthermore, the reliability of a node is denoted by the CTV, which is determined according to the DTV and ITV.The framework of FLTEM is shown in Figure 2, where HPFBTF represents the trust factor of HELLO packet forwarding behavior, DPFBTF is the trust factor of DATA packet forwarding behavior, and RERTF is the trust factor of residual energy.DTV, ITV, and CTV will be described in detail later in this section.

Direct Trust Value of Nodes
Based on the membership theory of fuzzy mathematics, the fuzzy comprehensive evaluation decision converts the qualitative evaluation of the evaluation object into a quantitative evaluation and performs a comprehensive evaluation with multiple constraints on the evaluation object.In addition, the fuzzy comprehensive evaluation decision model has the characteristics of accurate results and strong systematization, which are suitable for solving uncertain problems, so the DTVs of nodes are calculated based on the fuzzy comprehensive evaluation decision model.The steps to calculate the DTV are given as follows.
HPFBTF is calculated according to the number of HELLO packets normally and abnormally forwarded by a node.For understanding, we provide the following definition.
Definition 1.The behavior of abnormally forwarding HELLO packets means that the node does not forward HELLO packets according to the rules.
In Beta reputation systems designed for sensor networks, Ganeriwal et al. fitted the reputation distribution and Beta distribution using the Bayesian formula and concluded that the reputation of sensor nodes obeys the Beta distribution [16,23].Therefore, the trust factor of the nodes can be obtained by calculating the expectation of Beta distribution [24].Assuming that the trust factor distribution of HELLO packet forwarding behavior of node k is denoted by h, then according to the expectation E of Beta distribution, the HPFBTF n,k of node k calculated using node n can be expressed as where N n_c and N a_c represent the number of HELLO packets forwarded normally and abnormally by node k, respectively.As mentioned earlier, a RH_Flag field is set in the neighbor table for each neighboring node to indicate whether the node has received a HELLO packet forwarded by the neighbor node.At the beginning of each HELLO cycle, the node sets the RH_Flag field for each neighbor node to "0".Specifically, when node R receives a HELLO packet from node S for the first time within the cycle, it sets the RH_Flag to "1".Afterwards, when node R receives one more HELLO packet forwarded by node S within the same cycle, node R determines whether the HELLO packet has been received from node S by determining the RH_Flag in the neighbor information table.If RH_Flag = 1, we think node S forwards the HELLO packet abnormally once.; in this case, N a_c = N a_c + 1; otherwise, N n_c = N n_c + 1.
DPFBTF is calculated by using the number of DATA packets forwarded normally and abnormally by a node.For understanding, we provide the following definition.Definition 2. The behavior of abnormally forwarding DATA packets means that an MN is selected as a forwarding node; however, the MN discards the received packets instead of forwarding them, or the MN does not forward the received DATA packets according to the specific routing rules.For example, a packet is forwarded to a node with a higher layer than that of the forwarder.
As mentioned earlier, the trust factor of a node can be obtained by calculating the expectation of the Beta distribution.Assuming that the trust factor distribution of the DATA packet forwarding behavior of node k is d, then according to the expectation E of Beta distribution, the DPFBTF n,k of node k calculated by node n can be expressed as where N n_d and N a_d represent the number of DATA packets forwarded normally and abnormally by node k, respectively.The detection of abnormal forwarding of data packets mainly includes two aspects.On the one hand, if a node in the network hears a data packet in which the layer of the receiver is greater than that of the sender, it implies that the sender may be an MN.In this case, N a_d = N a_d + 1.Otherwise, N n_d = N n_d + 1.On the other hand, after forwarding a data packet, the node switches to the listening mode to determine whether the selected next-hop node is an MN.If no data packet is heard from the next-hop node during RTT (Round-Trip Time), it implies that the selected next-hop node may be an MN.In this case, N a_d = N a_d + 1.Otherwise, N n_d = N n_d + 1.
RERTF: In UANs, the energy of nodes is limited.Unbalanced energy consumption has a great impact on network performance, such as the network lifetime.The reasonable and balanced use of node energy can effectively improve network performance.However, the energy consumption of the nodes is not taken into account in some of the existing trust mechanisms.Consequently, the residual energy of nodes is considered a trust factor (i.e., RERTF) to balance the energy consumption of UANs.Assuming that the initial energy of a node is E init , and the residual energy of node k is E resi , then the RERTF n, k of node k calculated by node n can be expressed as (1) Construct the evaluation set V = {v 1 , v 2 , v 3 } to indicate the degree of trust for each trust factor (i.e., u 1 , u 2 , u 3 ), where v 1 , v 2 , and v 3 represent untrusted, trusted, and very trusted, respectively.(2) Get the membership degree matrix R. Membership degree of trust factors u 1 , u 2 and u 3 is obtained via the triangle membership function, which is shown in Figure 3.
Membership degree matrix R is defined as In R, each element r ij is the membership degree of u i to the evaluation set element v j .
(1) Obtain the evaluation result.Given a fuzzy subset V = (w 1 , w 2 , w 3 ), By normalizing B, we obtain the evaluation result where δ = Then, the DTV of node k calculated by node n can be obtained as Equation ( 9) (2) Get the membership degree matrix R. Membership degree of trust factors u1, u2 and u3 is obtained via the triangle membership function, which is shown in Figure 3. Membership degree matrix R is defined as In R, each element rij is the membership degree of ui to the evaluation set element vj.

Indirect Trust Value of Nodes
The ITV of the node is calculated according to the DTVs of their common neighbors.However, if the common neighbor node is an MN, the MN may tamper with the DTV of node k.Therefore, to prevent the network from being attacked, the average value of the DTVs of common neighbor nodes is considered the ITV of the evaluated node.Take Figure 4 as an example for further explanation.It can be seen that node a and node b are the common neighbor nodes of node n and node k. [25], the evaluation result B can be obtained: where B is considered as a weight.Given Τ = (0.15,0.5,0.95) Then, the DTV of node k calculated by node n can be obtained as Equation ( 9)

Indirect Trust Value of Nodes
The ITV of the node is calculated according to the DTVs of their common neighbors.However, if the common neighbor node is an MN, the MN may tamper with the DTV of node k.Therefore, to prevent the network from being attacked, the average value of the DTVs of common neighbor nodes is considered the ITV of the evaluated node.Take Figure 4 as an example for further explanation.It can be seen that node a and node b are the common neighbor nodes of node n and node k.Let the DTVs of node a and node b calculated by node n be DTV n,a and DTV n,b , respectively.Let the DTVs of node k calculated by node a and b be DTV a,k and DTV b,k , respectively.The ITV of node k calculated by node n can be expressed as Moreover, let the set P = {p 1 , p 2 , p 3 , . . . ,p e } be the common neighbor nodes of node n and node k, where e is the number of common neighbor nodes, then the generalized form of the ITV of node k calculated by node n is

Comprehensive Trust Value of Nodes
To further improve the discrimination accuracy of MNs, the CTV is calculated according to the DTV and ITV of the nodes and can be expressed as where α and β are weight coefficients, and α + β = 1.

Overview of the TAFLRLR Protocol
Aiming at the characteristics and challenges of UANs mentioned in the previous section, a trust-aware and fuzzy logic-based reliable layering routing protocol is proposed to achieve routing reliability and energy efficiency.The framework of TAFLRLR is shown in Figure 5.The TAFLRLR protocol has the following features.
To further improve the discrimination accuracy of MNs, the CTV is calculated according to the DTV and ITV of the nodes and can be expressed as where α and β are weight coefficients, and α β + = 1 .

Overview of the TAFLRLR Protocol
Aiming at the characteristics and challenges of UANs mentioned in the previous section, a trust-aware and fuzzy logic-based reliable layering routing protocol is proposed to achieve routing reliability and energy efficiency.The framework of TAFLRLR is shown in Figure 5.The TAFLRLR protocol has the following features.(1) With the TAFLRLR protocol, a layer is configured for each node, and DATA packets are transmitted layer by layer from a node with a higher layer to the sink node with layer 0, so the reliability of the routing is guaranteed.(2) The TAFLRLR is essentially a single-path routing, in which one path is established between a source node and the sink node.In each hop, the forwarding node is determined by the sender of the previous hop.Compared with multi-path routing, TAFLRLR can decrease the probability of packet collision and effectively reduce energy consumption.(3) The FLTEM mechanism is proposed for the trust evaluation of nodes.Specifically, with the consideration of HELLO packet forwarding behavior, DATA packet forwarding behavior, and residual energy, a fuzzy comprehensive evaluation decision model is introduced to calculate DTV for each node.In addition, combined with the DTV and ITV, the CTV is calculated to identify the MNs in UANs as well as select the best forwarding node.(1) With the TAFLRLR protocol, a layer is configured for each node, and DATA packets are transmitted layer by layer from a node with a higher layer to the sink node with layer 0, so the reliability of the routing is guaranteed.(2) The TAFLRLR is essentially a single-path routing, in which one path is established between a source node and the sink node.In each hop, the forwarding node is determined by the sender of the previous hop.Compared with multi-path routing, TAFLRLR can decrease the probability of packet collision and effectively reduce energy consumption.(3) The FLTEM mechanism is proposed for the trust evaluation of nodes.Specifically, with the consideration of HELLO packet forwarding behavior, DATA packet forwarding behavior, and residual energy, a fuzzy comprehensive evaluation decision model is introduced to calculate DTV for each node.In addition, combined with the DTV and ITV, the CTV is calculated to identify the MNs in UANs as well as select the best forwarding node.(4) The best forwarding node in the TAFLRLR is decided by the forwarding probabilities (FPs) of candidate forwarding nodes; the candidate forwarding node with the maximum FP is chosen as the best forwarding node.To improve the performance of the routing for UANs, the FP is calculated through a fuzzy control system (FCS) since the FCS has many advantages, such as low computational complexity and excellent adaptability [17,26].In the FCS, the NDs and the CTVs of candidate nodes are taken as the input variables of the FCS, and the outputs of the FCS are the FPs of the input nodes.

Best Forwarding Node Selection and Data Forwarding
In this subsection, the calculation of ND and FP is presented in detail.
In the TAFLRLR protocol, the sending node selects all the nodes whose layer is 1 smaller than its layer in the neighbor information table as candidate forwarding nodes and utilizes an FCS to calculate the FPs of candidate nodes according to the ND and CTV of the candidate nodes [17].The calculation of the CTV is presented in detail in Section 4. The calculation of ND is given in Equation (13).
where N L−1 denotes the number of neighbor nodes whose layer is 1 lower than the layer of the candidate forwarding node, and N is the number of all nodes in the network.
Next, an example is given to explain the calculation of ND, which is shown in Figure 6.In Figure 6, there are 17 nodes in the network.Node a is the sending node, Nodes b and c are candidate forwarding nodes, and the set of candidate nodes is denoted by S a_u = {b, c}.S b_all = {a, x, y, z} is the set of all the neighbor nodes of the candidate forwarding node b and S c_all = {a, k, l, m, n, p} is the set of all neighbor nodes of the candidate forwarding node c. S b_u = {x, y} is the set of upper-layer neighbor nodes of b. S c_u = {k, l, m, n} is the set of upper-layer neighbor nodes of c.

Best Forwarding Node Selection and Data Forwarding
In this subsection, the calculation of ND and FP is presented in detail.In the TAFLRLR protocol, the sending node selects all the nodes whose layer is 1 smaller than its layer in the neighbor information table as candidate forwarding nodes and utilizes an FCS to calculate the FPs of candidate nodes according to the ND and CTV of the candidate nodes [17].The calculation of the CTV is presented in detail in Section 4 The calculation of ND is given in Equation (13).
where NL−1 denotes the number of neighbor nodes whose layer is 1 lower than the layer o the candidate forwarding node, and N is the number of all nodes in the network.
Next, an example is given to explain the calculation of ND, which is shown in Figure 6.In Figure 6 (1) The linguistic values (i.e., fuzzy sets) are set for ND, CTV, and FP, respectively, as shown in Table 3. (2) By using the triangular membership function and the trapezoidal membership func tion, membership functions of linguistic values of ND and CTV are fuzzified and expressed as shown in Equations ( 14)-( 16): (1) The linguistic values (i.e., fuzzy sets) are set for ND, CTV, and FP, respectively, as shown in Table 3. (2) By using the triangular membership function and the trapezoidal membership function, membership functions of linguistic values of ND and CTV are fuzzified and expressed as shown in Equations ( 14)-( 16): where a = 0.33, b = 0.6, e = 0.33, f = 0.5, g = 0.67, m = 0.5, n = 0.67 for ND; a = 0.4, b = 0.6, e = 0.4, f = 0.6, g = 0.8, m = 0.6, n = 0.8 for CTV.
The membership functions of the ND and CTV are plotted, respectively, in Figure 7a,b.
Sensors 2023, 23, 9323 (6) Select the best forwarding node.The sending node takes the candidate node with the largest FP in step (5) as the best forwarding node and sends the DATA packet to the best forwarding node.
Reviewing that the NDs of node b and node c are 0.13 and 0.27, respectively, assuming that the CTVs of node b and node c are 0.85 and 0.75, respectively, based on the above steps, it can be calculated that the FPs of node b and node c are 0.5 and 0.428, which are shown in Figures 7c and 9, respectively.In addition, the rule triggering and defuzzification of node b and node c are simulated through the use of MATLAB R2022a, and illustrated in Figure 10a,b.Obviously, the FP of node b is greater than that of node c.Therefore, the sending node will select node b as the best forwarding node.After the best forwarding node is determined, the ID of the best forwarding node is filled in the field of the sender's ID of the packet; then, the DATA packet is sent to the best forwarding node.The flow chart is shown in Figure 11, where the N_ID and Sink_ID represent the ID of the neighbor node and the ID of the sink node, respectively.From the flow chart, we can see the procedure includes the following five steps.
Step 1: When a sending node N has a DATA packet to send, it first searches its neighbor information table for the sink node.If it cannot find the sink node, Node N finds the nodes whose layers are 1 lower than its layer from its neighbor information table as can- After the best forwarding node is determined, the ID of the best forwarding node is filled in the field of the sender's ID of the packet; then, the DATA packet is sent to the best forwarding node.The flow chart is shown in Figure 11, where the N_ID and Sink_ID represent the ID of the neighbor node and the ID of the sink node, respectively.From the flow chart, we can see the procedure includes the following five steps.
Step 1: When a sending node N has a DATA packet to send, it first searches its neighbor information table for the sink node.If it cannot find the sink node, Node N finds the nodes whose layers are 1 lower than its layer from its neighbor information table as can- After the best forwarding node is determined, the ID of the best forwarding node is filled in the field of the sender's ID of the packet; then, the DATA packet is sent to the best forwarding node.The flow chart is shown in Figure 11, where the N_ID and Sink_ID represent the ID of the neighbor node and the ID of the sink node, respectively.From the flow chart, we can see the procedure includes the following five steps.

DATA Receiving
After Node N sends the DATA packet, the neighbor nodes within the transmission range of the sending node N can hear the DATA packet.The receiving flow of the DATA packet is shown in Figure 12, where Self ID represents the ID of the current receiving node and the Rece ID represents the ID of the destinated receiving node assigned by the head field of the packet.According to the Rece_ID, there are three cases of data receiving [17].
Case 1: If the node that hears the packet is a sink node, it updates the neighbor information table and receives the packet.
Case 2: If the ID of the receiving node is the same as the Rece_ID in the head of the packet, the receiving node updates the neighbor information table, receives the packet, and then finds the best next-hop forwarding node, updates the Rece_ID field of the packet with the ID of the best forwarding node and sends the packet to the best forwarding node.
Case 3: If the receiving node is neither the sink node nor the best forwarding node, it just updates the neighbor information table and discards the received packet.Step 1: When a sending node N has a DATA packet to send, it first searches its neighbor information table for the sink node.If it cannot find the sink node, Node N finds the nodes whose layers are 1 lower than its layer from its neighbor information table as candidate forwarding nodes.
Step 2: The sending node N calculates the CTV and ND for each candidate forwarding node.
Step 4: Determine the candidate forwarding node with the largest FP as the best forwarding node and return the ID of the best forwarding node.
Step 5: Node N updates the field of Rece ID in the packet with the ID of the best forwarding node and sends the DATA packet to the best forwarding node.

DATA Receiving
After Node N sends the DATA packet, the neighbor nodes within the transmission range of the sending node N can hear the DATA packet.The receiving flow of the DATA packet is shown in Figure 12, where Self ID represents the ID of the current receiving node and the Rece ID represents the ID of the destinated receiving node assigned by the head field of the packet.According to the Rece_ID, there are three cases of data receiving [17].

DATA Receiving
After Node N sends the DATA packet, the neighbor nodes within the transmission range of the sending node N can hear the DATA packet.The receiving flow of the DATA packet is shown in Figure 12, where Self ID represents the ID of the current receiving node and the Rece ID represents the ID of the destinated receiving node assigned by the head field of the packet.According to the Rece_ID, there are three cases of data receiving [17].
Case 1: If the node that hears the packet is a sink node, it updates the neighbor information table and receives the packet.
Case 2: If the ID of the receiving node is the same as the Rece_ID in the head of the packet, the receiving node updates the neighbor information table, receives the packet, and then finds the best next-hop forwarding node, updates the Rece_ID field of the packet with the ID of the best forwarding node and sends the packet to the best forwarding node.
Case 3: If the receiving node is neither the sink node nor the best forwarding node, it just updates the neighbor information table and discards the received packet.Case 1: If the node that hears the packet is a sink node, it updates the neighbor information table and receives the packet.
Case 2: If the ID of the receiving node is the same as the Rece_ID in the head of the packet, the receiving node updates the neighbor information table, receives the packet, and then finds the best next-hop forwarding node, updates the Rece_ID field of the packet with the ID of the best forwarding node and sends the packet to the best forwarding node.
Case 3: If the receiving node is neither the sink node nor the best forwarding node, it just updates the neighbor information table and discards the received packet.

Performance Evaluation
In this section, we evaluate the performance of the TAFLRLR protocol in terms of packet delivery rate (PDR) and total energy consumption (TEC) with the NS3 network simulation platform.The main simulation parameters are listed in Table 5.

Performance Metrics
Packet delivery rate: The ratio of the number of DATA packets delivered successfully to the sink node N sink_rece to the number of the DATA packets transmitted by the source nodes N source_send which is given by Equation ( 18) [17].
where N simu is the number of simulation experiments.Total energy consumption: The average of the total energy consumed by all nodes in the network in their operating states for N simu simulation experiments, which is given in Equation ( 19) [17].
where E send is the energy consumed by all nodes in the network in the sending state, E rece is the energy consumed by all nodes in the network in the receiving E idle is the energy consumed by all nodes in the network in the idle state, and E sleep is the energy consumed by all nodes in the network in the sleeping state.

Simulation Results Analysis
In this section, we analyze the performance of the TAFLRLR protocol under different simulation parameter settings.In the simulation experiments, the MNs employ mainly two attack methods: the HELLO packet flooding attack and the selective forwarding attack.
Assuming that an MN can only use one attack mode.The MN with a selective forwarding attack directly discards the received packet.The MN with the first HELLO packet flooding attack forwards HELLO packets with a larger communication range than a normal node.By contrast, the MN with the second HELLO packet flooding attack forwards the received HELLO packets repeatedly.

The Change of Trust Value of the Normal Node and MN
The network topology in the experiment is shown in Figure 13.In Figure 13, nine nodes are deployed the water.Most notably, node 10 is an MN with the selective forwarding attack mode.The trust values of the MN and a normal node, node 7, during 20 transmission rounds are recorded and they are shown in Figure 14.The network topology in the experiment is shown in Figure 13.In Figure 13, nine nodes are deployed in the water.Most notably, node 10 is an MN with the selective forwarding attack mode.The trust values of the MN and a normal node, node 7, during 20 transmission rounds are recorded and they are shown in Figure 14.From Figure 14, it is seen that as the number of transmission rounds increases, the trust value of the normal node gradually increases.When the number of transmission rounds exceeds six, the trust value of the normal node reaches 0.7 and then remains constant.In contrast, when the number of transmission rounds exceeds two, the trust value of the MN decreases to 0.52 and then remains constant.As mentioned earlier, the trust value is related to the residual energy of the node as well as the data packet forwarding behavior and the HELLO packet forwarding behavior.The trust value of the MN increases in the second transmission round because the MN forwards HELLO packets normally.However, after the second round, the trust value of the MN begins to decrease because the MN does not forward the received DATA packets.Since the nodes with low trust values have a small probability of being selected as the best next-hop forwarding node, the trust value of the MN tends to remain constant as the number of transmission rounds increases.Based on the topology shown in Figure 13, we increase the number of MNs and compare the PDRs of the routing protocols with FLTEM and without FLTEM.Especially, the MNs can adopt an arbitrary attack method, as listed in Section 2. The experiment results The network topology in the experiment is shown in Figure 13.In Figure 13, nine nodes are deployed in the water.Most notably, node 10 is an MN with the selective forwarding attack mode.The trust values of the MN and a normal node, node 7, during 20 transmission rounds are recorded and they are shown in Figure 14.From Figure 14, it is seen that as the number of transmission rounds increases, the trust value of the normal node gradually increases.When the number of transmission rounds exceeds six, the trust value of the normal node reaches 0.7 and then remains constant.In contrast, when the number of transmission rounds exceeds two, the trust value of the MN decreases to 0.52 and then remains constant.As mentioned earlier, the trust value is related to the residual energy of the node as well as the data packet forwarding behavior and the HELLO packet forwarding behavior.The trust value of the MN increases in the second transmission round because the MN forwards HELLO packets normally.However, after the second round, the trust value of the MN begins to decrease because the MN does not forward the received DATA packets.Since the nodes with low trust values have a small probability of being selected as the best next-hop forwarding node, the trust value of the MN tends to remain constant as the number of transmission rounds increases.

PDR with FLTEM and without FLTEM of the Network with Stationary Topology
Based on the topology shown in Figure 13, we increase the number of MNs and compare the PDRs of the routing protocols with FLTEM and without FLTEM.Especially, the MNs can adopt an arbitrary attack method, as listed in Section 2. The experiment results are shown in Figure 15.From Figure 14, it is seen that as the number of transmission rounds increases, the trust value of the normal node gradually increases.When the number of transmission rounds exceeds six, the trust value of the normal node reaches 0.7 and then remains constant.In contrast, when the number of transmission rounds exceeds two, the trust value of the MN decreases to 0.52 and then remains constant.As mentioned earlier, the trust value is related to the residual energy of the node as well as the data packet forwarding behavior and the HELLO packet forwarding behavior.The trust value of the MN increases in the second transmission round because the MN forwards HELLO packets normally.However, after the second round, the trust value of the MN begins to decrease because the MN does not forward the received DATA packets.Since the nodes with low trust values have a small probability of being selected as the best next-hop forwarding node, the trust value of the MN tends to remain constant as the number of transmission rounds increases.

PDR with FLTEM and without FLTEM of the Network with Stationary Topology
Based on the topology shown in Figure 13, we increase the number of MNs and compare the PDRs of the routing protocols with FLTEM and without FLTEM.Especially, the MNs can adopt an arbitrary attack method, as listed in Section 2. The experiment results are shown in Figure 15.From Figure 15, it can be seen that when there are no MNs in the network, the PDR 0.98.As the number of MNs increases, the PDR of the network, either with o without FLTEM, decreases.However, the PDR with FLTEM is generally greater than tha without FLTEM.In addition, the PDR without FLTEM decreases sharply with the increas ing number of MNs, while the PDR with FLTEM decreases slowly.The experimental re sults show that the FLTEM greatly improves the packet delivery rate and transmission reliability of the network with stationary topology.From Figure 15, it can be seen that when there are no MNs in the network, the PDR reaches 0.98.As the number of MNs increases, the PDR of the network, either with or without FLTEM, decreases.However, the PDR with FLTEM is generally greater than that without FLTEM.In addition, the PDR without FLTEM decreases sharply with the increasing number of MNs, while the PDR with FLTEM decreases slowly.The experimental results show that the FLTEM greatly improves the packet delivery rate and transmission reliability of the network with stationary topology.

PDR with FLTEM and without FLTEM of the Network with Dynamic Topology
With the topology shown in Figure 1, we deploy 40-300 nodes in a 3D area of 500 m × 500 m × 500 m.We analyze the effect of FLTEM and the number of MNs on PDR and TEC.The proportion of MNs in the network is 0-0.3.Each MN has an arbitrary attack method listed in Section 2. The experimental results are shown in Figures 16-19.
Figure 16a-e show the effect of the number of MNs on the PDR of the network with or without the FLTEM mechanism when the number of nodes is 40, 100, 160, 220, and 300, respectively.Specifically, the PDRs reach the maximum values when there is no MN in the network.When there are some MNs in the network, the PDRs decrease significantly.Meanwhile, the PDRs decrease with the increasing number of MNs.The more the number of MNs, the smaller the PDR is.It can be seen from Figure 16a-e that when there are MNs in the network, the PDRs with FLTEM are significantly improved and generally greater than those without FLTEM.The experimental results show that the FLTEM greatly improves the packet delivery rate and transmission reliability of the network with dynamic topology.
Figure 17a-e show the effect of the number of MNs on TEC with or without FLTEM when the number of nodes is 40, 100, 160, 220, and 300, respectively.From Figure 17a-e, it can be seen that TEC reaches the minimum value when there is no MN in the network.As the number of MNs increases, the TEC increases significantly.Moreover, it is also seen from Figure 17a-e that when there are some MNs in the network, the TEC without FLTEM is significantly greater than that with FLTEM.The experimental results show that the FLTEM mechanism can improve energy efficiency.
Figures 18 and 19 show the effect of the number of nodes on PDR and TEC with FLTEM under the different proportions of MNs.
From Figure 18, we can see that no matter whether there are MNs in the network, the PDR increases with the number of nodes.Generally speaking, the PDR of the network without MNs is greater than the PDR of the network with MNs.The PDR increases as the number of MNs increases, and the PDR of the network with a large proportion of MNs is greater than that of the network with a small proportion of MNs.  Figure 16a-e show the effect of the number of MNs on the PDR of the network with or without the FLTEM mechanism when the number of nodes is 40, 100, 160, 220, and 300, respectively.Specifically, the PDRs reach the maximum values when there is no MN in the network.When there are some MNs in the network, the PDRs decrease significantly.Meanwhile, the PDRs decrease with the increasing number of MNs.The more the number of MNs, the smaller the PDR is.It can be seen from Figure 16a-e that when there are MNs in the network, the PDRs with FLTEM are significantly improved and generally greater than those without FLTEM.The experimental results show that the FLTEM greatly improves the packet delivery rate and transmission reliability of the network with dynamic topology.Figure 17a-e show the effect of the number of MNs on TEC with or without FLTEM when the number of nodes is 40, 100, 160, 220, and 300, respectively.From Figure 17a-e, it can be seen that TEC reaches the minimum value when there is no MN in the network.As the number of MNs increases, the TEC increases significantly.Moreover, it is also seen   From Figure 18, we can see that no matter whether there are MNs in the network, the PDR increases with the number of nodes.Generally speaking, the PDR of the network without MNs is greater than the PDR of the network with MNs.The PDR increases as the number of MNs increases, and the PDR of the network with a large proportion of MNs is greater than that of the network with a small proportion of MNs.
From Figure 19, we can see that no matter whether there are MNs in the network, the TEC increases with the number of nodes.The TEC of the network with MNs is always greater than that of the network without MNs.Moreover, the TEC increases with the proportion of MNs in the network.This is because the number of HELLO packets flooded in the network increases with the number of nodes executing the HELLO packet flooding attack in Section 2, so the TEC of the network increases.
As shown in Figures 16-19, the performance of the network in terms of PDR and energy efficiency significantly drops when there are some MNs in the network, which is unfavorable for UANs.Fortunately, the experimental results show that the performance of the network in terms of the PDR and energy efficiency is significantly improved after the FLTEM mechanism is introduced.
The above results show that both the trust mechanism FLTEM and the routing protocol TAFLRLR proposed in this paper can improve the PDR and reduce the TEC of the network.

Conclusions
In this paper, a trust mechanism FLTEM and reliable routing protocol TAFLRLR are proposed for UANs.Extensive simulation experiments are performed to evaluate the performance of the FLTEM and TAFLRLR protocols.We compare the performance of the network with and without FLTEM.The experimental results show that (1) The network without MN achieves the largest PDR and the lowest TEC.(2) The performance in terms of  From Figure 18, we can see that no matter whether there are MNs in the network, the PDR increases with the number of nodes.Generally speaking, the PDR of the network without MNs is greater than the PDR of the network with MNs.The PDR increases as the number of MNs increases, and the PDR of the network with a large proportion of MNs is greater than that of the network with a small proportion of MNs.
From Figure 19, we can see that no matter whether there are MNs in the network, the TEC increases with the number of nodes.The TEC of the network with MNs is always greater than that of the network without MNs.Moreover, the TEC increases with the proportion of MNs in the network.This is because the number of HELLO packets flooded in the network increases with the number of nodes executing the HELLO packet flooding attack in Section 2, so the TEC of the network increases.
As shown in Figures 16-19, the performance of the network in terms of PDR and energy efficiency significantly drops when there are some MNs in the network, which is unfavorable for UANs.Fortunately, the experimental results show that the performance of the network in terms of the PDR and energy efficiency is significantly improved after the FLTEM mechanism is introduced.
The above results show that both the trust mechanism FLTEM and the routing protocol TAFLRLR proposed in this paper can improve the PDR and reduce the TEC of the network.

Conclusions
In this paper, a trust mechanism FLTEM and reliable routing protocol TAFLRLR are proposed for UANs.Extensive simulation experiments are performed to evaluate the performance of the FLTEM and TAFLRLR protocols.We compare the performance of the network with and without FLTEM.The experimental results show that (1) The network without MN achieves the largest PDR and the lowest TEC.(2) The performance in terms of From Figure 19, we can see that no matter whether there are MNs in the network, the TEC increases with the number of nodes.The TEC of the network with MNs is always greater than that of the network without MNs.Moreover, the TEC increases with the proportion of MNs in the network.This is because the number of HELLO packets flooded in the network increases with the number of nodes executing the HELLO packet flooding attack in Section 2, so the TEC of the network increases.
As shown in Figures 16-19, the performance of the network in terms of PDR and energy efficiency significantly drops when there are some MNs in the network, which is unfavorable for UANs.Fortunately, the experimental results show that the performance of the network in terms of the PDR and energy efficiency is significantly improved after the FLTEM mechanism is introduced.
The above results show that both the trust mechanism FLTEM and the routing protocol TAFLRLR proposed in this paper can improve the PDR and reduce the TEC of the network.

Conclusions
In this paper, a trust mechanism FLTEM and reliable routing protocol TAFLRLR are proposed for UANs.Extensive simulation experiments are performed to evaluate the performance of the FLTEM and TAFLRLR protocols.We compare the performance of the network with and without FLTEM.The experimental results show that (1) The network without MN achieves the largest PDR and the lowest TEC.(2) The performance in terms of PDR and energy efficiency significantly drops when there are some MNs in the network.
(3) The performance of the network with FLTEM is significantly improved compared with that without FLTEM.Therefore, the trust mechanism FLTEM and the routing protocol TAFLRLR proposed in this paper can improve the PDR and reduce the TEC of the network.
In future research, we will further optimize the FLTEM mechanism and the TAFLRLR protocol by using deep reinforcement learning, swarm intelligence algorithms, and clustering algorithms to further improve the PDR, energy efficiency, and reliability of the network.

3 ∑
i=1 w i = 1, where w i represents the weight of the ith trust factor, and the weight is adjustable.Then, by utilizing the weighted average model M(•, +)[25], the evaluation result B can be obtained:

Figure 3 .
Figure 3.The membership function of the elements of the evaluation set.

Figure 3 .
Figure 3.The membership function of the elements of the evaluation set.
represents the weight of the ith trust factor, and the weight is adjustable.Then, by utilizing the weighted average model ⋅ + ( , ) M normalizing B, we obtain the evaluation result ' B

Figure 4 .
Figure 4. Schematic diagram of the ITV.Let the DTVs of node a and node b calculated by node n be DTVn,a and DTVn,b, respectively.Let the DTVs of node k calculated by node a and b be DTVa,k and DTVb,k, respectively.The ITV of node k calculated by node n can be expressed as + = , , , ,

Figure 4 .
Figure 4. Schematic diagram of the ITV.

Figure 5 .
Figure 5.The overall framework of the TAFLRLR protocol.

Figure 5 .
Figure 5.The overall framework of the TAFLRLR protocol.

Figure 9 .Figure 10 .
Figure 9. Membership degree functions and FP of the candidate node c.

Figure 9 . 15 Figure 9 .Figure 10 .
Figure 9. Membership degree functions and FP of the candidate node c.

Figure 10 .
Figure 10.The rule triggering and defuzzification process.(a) The values of input variables are 0.85 and 0.13.(b) The values of input variables are 0.75 and 0.27.

Figure 11 .
Figure 11.The forwarding flow of the TAFLRLR protocol.

Figure 12 .
Figure 12.The receiving flow of the TAFLRLR protocol.

Figure 11 .
Figure 11.The forwarding flow of the TAFLRLR protocol.

Figure 11 .
Figure 11.The forwarding flow of the TAFLRLR protocol.

Figure 12 .
Figure 12.The receiving flow of the TAFLRLR protocol.

Figure 12 .
Figure 12.The receiving flow of the TAFLRLR protocol.

Sensors 2023 , 18 6. 2 . 1 .
23, x FOR PEER REVIEW 17 of The Change of Trust Value of the Normal Node and MN

Figure 14 .
Figure 14.Trust values of a normal node and the MN.6.2.2.PDR with FLTEM and without FLTEM of the Network with Stationary Topology

Figure 14 .
Figure 14.Trust values of a normal node and the MN.

Figure 14 .
Figure 14.Trust values of a normal node and the MN.

Figure 15 .
Figure 15.Effect of the number of MNs on PDR when the number of nodes is 9 and topology i fixed. .

Figure 16 .
Figure 16.The effect of the number of MNs on PDR with or without FLTEM.(a) The total numbe of nodes is 40.(b) The total number of nodes is 100.(c) The total number of nodes is 160.(d) Th total number of nodes is 220.(e) The total number of nodes is 300.

Figure 15 .
Figure 15.Effect of the number of MNs on PDR when the number of nodes is 9 and topology is fixed.

Figure 15 .
Figure15.Effect of the number of MNs on PDR when the number of nodes is 9 and topology is fixed.6.2.3.PDR with FLTEM and without FLTEM of the Network with Dynamic TopologyWith the topology shown in Figure1, we deploy 40-300 nodes in a 3D area of 500 m × 500 m × 500 m.We analyze the effect of FLTEM and the number of MNs on PDR and TEC.The proportion of MNs in the network is 0-0.3.Each MN has an arbitrary attack method listed in Section 2. The experimental results are shown in Figures16-19.

Figure 16 .Figure 16 .
Figure 16.The effect of the number of MNs on PDR with or without FLTEM.(a) The total number of nodes is 40.(b) The total number of nodes is 100.(c) The total number of nodes is 160.(d) The total number of nodes is 220.(e) The total number of nodes is 300.

Figure 17 .
Figure 17.The effect of the number of MNs on TEC with or without FLTEM.(a) The total number of nodes is 40.(b) The total number of nodes is 100.(c) The total number of nodes is 160.(d) The total number of nodes is 220.(e) The total number of nodes is 300.

Figure 17 .
Figure 17.The effect of the number of MNs on TEC with or without FLTEM.(a) The total number of nodes is 40.(b) The total number of nodes is 100.(c) The total number of nodes is 160.(d) The total number of nodes is 220.(e) The total number of nodes is 300.

Figure 18 .
Figure 18.The effect of the number of nodes on PDR.

Figure 19 .
Figure 19.The effect of the number of nodes on TEC.

Figure 18 . 21 Figure 18 .
Figure 18.The effect of the number of nodes on PDR.

Figure 19 .
Figure 19.The effect of the number of nodes on TEC.

Figure 19 .
Figure 19.The effect of the number of nodes on TEC.

Table 1 .
The format of the HELLO packet.

Table 1 .
The format of the HELLO packet.

Table 2 .
The structure of the neighbor information table.

Table 4 .
Fuzzy rule table in TAFLRLR protocol.