Abstract

In sensor networks, UAVs are often introduced to assist data collection tasks. UAVs can operate as data ferry nodes, connecting distributed areas that are separated from each other. This paper proposes a data collection method for distributed wireless sensor networks based on UAV and introduces the idea of edge computing in it. In the single-hop transmission scenario, the -means++ clustering method is used for sensor node clustering and cluster head election in the initial state. In the next rounds of data collection, UAV is used to assist in the election of new cluster heads and data collection tasks, taking into account the relative distance and the relative remaining energy relationship of the sensor nodes in their clusters. In addition, reasonable priorities are set for some nodes that have never been elected in the previous rounds and for the dead nodes. In the multihop transmission scenarios, for nodes that cannot deliver directly, the optimal relay node is selected for routing by comprehensively considering factors such as transmission angle, transmission distance, and remaining energy of the node in each cluster. The method proposed in this paper coordinates the overall energy consumption of sensor nodes in the environmental monitoring area, delays the death time of key sensor nodes, and extends the network lifetime. At the same time, an improved ACO is used to reasonably plan the data collection path of the UAV. Compared with the comparison scheme, the improved ACO can obtain a better shortest path length and has the fastest convergence speed when reaching the shortest path.

1. Introduction

In recent years, with the rapid development of wireless networks and the technical advantages of wireless sensor networks, such as self-organization, rapid deployment, high error tolerance, and low cost, sensor networks are often used to monitor and collect ecological environment data, collect information in the process of geological monitoring, and sense some areas that are not suitable for human beings to stay and live for a long time. However, due to the influence of the volume of sensor nodes and the difficulty of replacing batteries of a large number of sensor nodes, how to reduce energy consumption when collecting data is an important problem. After a large number of sensor nodes are deployed, how to effectively collect sensor network data and how to effectively prolong the service life of sensor nodes in the process of sensor network data collection have become hot issues in academic and industrial circles in recent years.

For sensor data monitoring and collection tasks in special environments, multiple sensor data collection areas may be separated from each other due to geographical environmental factors such as rivers, mountains, and swamps. Deploying relay nodes in these areas will consume a lot of manpower and material resources and is very inconvenient to implement. The use of UAVs can effectively solve the impact of ground environmental factors on data collection tasks. With the increasing maturity of UAV technology, UAVs have been widely used in vehicle networking, agriculture, military reconnaissance, and other fields, and civil UAVs are also gradually popularized.

By introducing UAVs into wireless sensor networks, it can form a delay-tolerant network with traditional sensor networks, and effectively assist sensor networks in data collection tasks by using the “store-carry-forward” method. The UAV serves as a relay to collect data from sensor networks in remote areas and transmit it to the data center for processing, thus avoiding manual data collection and effectively addressing the impact of environmental factors on data collection on the ground.

UAVs assist wireless sensor networks where the UAV can move over the network, retrieve and collect data from sensor nodes. Using effective routing protocols can reduce energy consumption, avoid long-distance transmission and redundant transmission, and prolong the service life of sensors.

We have previously studied data collection by UAV-assisted wireless sensor networks. In reference [1], we mainly proposed a data collection strategy based on drone technology in wireless sensor networks, using -means++ method to conduct clustering and cluster head election in the initial state. Then, on the basis of comprehensive consideration of relative distance and relative residual energy of each sensor node, UAV is used to assist cluster head election and data collection. In addition, for some unelected nodes, a reasonable priority is set to make the energy consumption of sensor nodes more balanced. Experiments show that this strategy reduces the energy consumption and improves the performance of sensor networks. On the basis of the previous work, this paper further expands and utilizes UAV-related technology to assist data collection from multiple distributed sensor network areas separated from each other due to geographical environmental factors, so as to make the energy consumption of sensor nodes in the monitoring area more balanced. The main contributions of this paper are as follows.

Introducing the idea of edge computing into the data collection process of distributed sensor network can greatly improve the efficiency of data collection. We discuss the case that the sensor node transmits the environmental data to the cluster head node through single-hop or multihop transmission mode. This method is not only flexible but also has low cost, which solves the problem that the data collection task of sensor network cannot be carried out uniformly in the environment monitoring area under complex geographical conditions.

Due to the limited battery capacity and high energy consumption of UAV, an efficient and energy-saving routing protocol is needed in both military and commercial applications. In addition, the deployment and trajectory planning of UAVs have a significant impact on the performance of routing protocols. Therefore, an improved ACO is used in this paper to plan the UAV’s path, and the “store-carry-forward” method is adopted to collect sensor data from each cluster head node. In this way, the data is transmitted to the data center with a small path cost and time cost.

The remaining chapters of this paper are organized as follows. The second chapter mainly introduces the related work, including the data collection method of the sensor network and the typical UAV path planning method. The third chapter mainly introduces the system model. The fourth chapter mainly introduces the data collection of UAV-based sensor network. The fifth chapter mainly introduces the UAV path planning based on improved ACO. The sixth chapter mainly introduces the simulation experiment and result analysis. The seventh chapter mainly introduces the conclusion and outlook.

2.1. Data Collection Method of Sensor Network

For the data collection scheme of traditional sensor network, the data collection performance of the sensor network can be greatly improved by introducing mobile nodes as assistance, which has been paid attention to by most researchers [24]. In recent years, due to the reduction of UAV cost and the rapid development of UAV technology, using UAV as an auxiliary node to assist sensor network in data collection has become a research hotspot [58]. Traditional mobile nodes are susceptible to ground path restrictions and often cannot fully utilize the performance of sensor networks. However, the UAV has broken through the node’s movement path restriction and has better flexibility in data collection tasks.

Chen et al. [9] proposed a universal NOMA-enabled UAV-assisted data collection protocol to maximize the total rate of wireless sensor networks during the data collection process. Xu et al. [10] introduced blockchain into the UAV-assisted IoT scenario and proposed a data collection system that takes into account both safety and energy efficiency, which can effectively improve the safety and efficiency of data collection. In order to ensure the timeliness of the collected data, Zhu et al. [11] optimized the trajectory and wake-up time allocation of the UAV as well as the transmission power of the sensor nodes to minimize the task completion time. Ma et al. [12] modelled the convergence node, UAV deployment, and resource allocation as a mixed-integer nonconvex optimization problem. They used heuristic methods to effectively solve the problem, thereby prolonging the life of the network. Ebrahimi et al. [13] used UAVs in dense wireless sensor networks to use projection-based compressed data collection (CDG) as a novel solution to collect data. Du et al. [14] used UAVs to vehicle tolerance delay network (VDTN) for message storage and forwarding and proposed a VDTN routing protocol based on UAV, which considered both the probability of each encounter and the duration of connection between mobile nodes. This method not only reduced network overhead and end-to-end delay but also improved the reliability of message forwarding.

In summary, the existing data collection methods of sensor network rarely consider the problem of distributed wireless sensor networks composed of multiple isolated monitoring areas. In this network environment, how to collect data from the sensor network to reduce the overall energy consumption of the network and how to plan the UAV to optimize the data collection path of the separated monitoring area are problems worthy of study. These are also the focus of this paper.

2.2. Typical UAV Path Planning Method

Typical UAV path planning methods are mainly divided into two categories: classic UAV path planning methods and UAV path planning methods based on intelligent algorithms. The classic UAV path planning methods mainly include A-star algorithm, cell decomposition method, and artificial potential field method. UAV path planning methods based on intelligent algorithms mainly include genetic algorithm, particle swam optimization, and wolf colony algorithm.

The A-star algorithm is a direct search algorithm for planning the shortest flight path of UAVs in static state. At the same time, the A-star algorithm is one of the heuristic algorithms [15]. Its basic algorithm idea is to use the heuristic function to evaluate some candidate nodes and select the node with the best condition as the next node on the path. This is a purposeful search method that effectively avoids blind searches. The A-star algorithm can achieve faster calculation speed when the path matrix is small and efficiently obtain the UAV path information that needs path planning. However, when the number of paths increases sharply, its running time also increases accordingly, which is not suitable for path planning problems in dynamic states.

The artificial potential field path planning is a method that uses virtual forces in the environment to assist path planning. The basic idea of this algorithm is to abstract the movement process of the UAV in the environment as a movement process of the UAV under the virtual artificial potential field. The target point to be reached by the UAV is a gravitational field for it, and the obstacles in the path are a repulsive field for it. Under the combined action of the gravitational field and the repulsive field, the UAV starts from the starting point, avoids obstacles, and finally reaches the destination node. Generally speaking, the path generated by using the artificial potential field to plan the UAV’s path is smooth and safe, but this method has the problem of generating local optimal solutions, and there are certain human factors in the design of the repulsion field and the gravitational field. When there are obstacles near the target node, the UAV may not be able to reach the target node, which also limits the development of artificial potential field.

Particle swarm optimization is a kind of evolutionary algorithm. It simulates a predation behaviour of a flock of birds randomly searching for food, without requiring any leader. In Particle swarm optimization, the potential solution of each UAV optimization problem can be abstracted as a “particle” in the search space, that is, a bird. “Particles” follow the current optimal “particles” to search in the solution space. These “particles” are initially some random solutions, and the optimal solution is found after many iterations of optimization. Particle swarm optimization is widely used in the field of UAV path planning. It has good convergence and path optimization capabilities and is suitable for the optimization of continuous problems. However, the algorithm may get trapped in local optimal solutions and cannot handle optimization problems in discrete cases well.

Wolf colony algorithm is an algorithm based on the swarm intelligence of wolves. The algorithm simulates the predation behaviour of wolves and how wolves distribute their prey. The main body of the wolf colony algorithm is composed of three intelligent behaviours: wandering, calling, and besieging. The algorithm’s method of generating the head wolf uses the “winner is king” rule, while the algorithm’s method of updating the wolf colony uses the “stronger survival” mechanism. In solving the problem of UAV path planning, the wolf colony algorithm improves the probability of obtaining the optimal solution of UAV path planning in a limited time to a certain extent and reduces the understanding space. Although it can deal with simple UAV path planning problems and realize UAV path planning in a continuous environment, it cannot realize path planning in a discrete environment, and the iteration convergence speed is slow.

Reinforcement learning is a new algorithm based on learning. In recent years, reinforcement learning has been widely used. Chen et al. [16] applied reinforcement learning to the Internet of Vehicles and proposed an online deep reinforcement learning scheme. Each mobile user only made use of local information to make decisions such as channel auction, computational task unloading, and input packet scheduling, so as to optimize task unloading of the air-ground integrated multiaccess edge computing (MEC) system. Reinforcement learning has also been applied in path planning. In order to reduce communication delay between vehicles, Wu et al. [17] proposed a multichannel vehicle edge computing routing scheme based on cooperative learning to solve the communication path selection problem in multichannel vehicle environment. Tong et al. [18] modelled the UAV-assisted data collection problem as a limited range Markov decision process with limited state and action space and developed a deep reinforcement learning algorithm to find the asymptotically optimal strategy. The introduction of reinforcement learning breaks the previous idea of using intelligent algorithm to optimize the path and provides a new method for path planning. Therefore, we can consider future work and design reinforcement learning algorithm for our own application scenarios to optimize the flight path of UAV.

3. System Model

Edge computing refers to an open platform that integrates network, computing, storage, and application core capabilities to provide the nearest end service on one side of the object or data source. Edge computing provides faster services and is used to enforce business, security, and privacy. Introducing the idea of edge computing in the data collection process of distributed sensor networks can greatly improve the efficiency of data collection.

In a distributed sensor network environmental data monitoring and collection task which has multiple partitioned monitoring areas, multiple sensor nodes in each monitoring area are responsible for environmental data sensing. The sensor node transmits the environmental data to the cluster head node through single-hop transmission or multihop transmission. After that, the cluster head node aggregates and fuses the data of each sensor node. Starting from the data center, the UAV uses a “store-carry-forward” method according to a certain path planning method to collect data from the cluster head nodes in each partitioned area. The UAV returns the collected data to the data center for transmission and processing. The application scenario of sensor network data collection system is shown in Figure 1. The entities in the system and their functions are described as follows: Sensor Node (SN). The sensor node is used to collect the sensing data in the environmental monitoring area, such as temperature, humidity, light intensity, and the acid, alkali, and salt concentration in the soil, etc. The sensor node periodically sends the sensed environmental data to the cluster head node and at the same time transmits its own remaining energy information to the cluster head node.Relay Node (RN). Due to the limited communication distance of the sensor node, when the Euclidean distance between the sensor node and the cluster head node is greater than the communication distance, the relay node is responsible for relaying the transmitted data. The relay node can replace an unreachable link with multiple links of better quality to obtain better network coverage.Cluster Head Node (Cluster Head, CH). The cluster head node converges and fuses the data information collected by the sensors in the cluster. At the same time, the cluster head node is responsible for interacting with the UAV, transmitting the collected sensing data to the UAV, and receiving control information from the UAV.Data Center. The data center gathers the environmental monitoring data collected by UAV from each partitioned monitoring area and performs data processing.

By delegating computing and processing tasks to sensor nodes and UAV nodes, many controls will be achieved through local equipment without having to hand over to the data center in the cloud. The processing process is completed at the local edge layer, which greatly improves processing efficiency. This way, because it is closer to the terminal, the demand can be solved at the edge.

The whole system model can be divided into two parts: data collection of sensor network based on UAV and UAV path planning based on improved ACO. Between them, the data collection of UAV-based sensor network is divided into two cases: single-hop transmission and multihop transmission, according to the relationship between communication distance and transmission distance.

The system model is based on the following premise assumptions. (1) The position coordinates of each sensor node are fixed and the initial energy is known. (2) The UAV stores the mapping relationship information between the identity document (ID) of the sensor node and its location coordinates. (3) The sensor nodes can adjust the signal transmission power adaptively according to the distance of the nodes. (4) The communication channel is a symmetric propagation channel. (5) Issues such as communication security and encryption will not be considered for the time being.

4. Data Collection of UAV-Based Sensor Network

4.1. Sensor Clustering and Cluster Head Election in the Initial State

Abstract each area in the partitioned environmental monitoring area. Assume that each monitoring area is a rectangle with length and width . sensor nodes are randomly distributed, as shown in Figure 2. The communication distance of each sensor node is . The sensor node transmits the sensed data to the cluster head node of its own cluster. The cluster head node performs data fusion on the collected sensed data, waits for the arrival of the UAV, and interacts with the UAV. Then, the data is transferred to the data center.

For each separated environmental monitoring area, when the coverage of the monitoring area exceeds the communication range of the sensor node, two ways can be used to realize the communication between sensor nodes. (1) Divide a large area so that the range of each divided area will not exceed the communication range of sensor nodes, thereby ensuring single-hop transmission between sensor nodes. (2) Sensor nodes use multihop transmission to transmit data to other nodes through relay nodes.

First discuss the first case, that is, clustering a larger network, so that each sensor node can communicate with all other nodes in the cluster. The cluster number of sensor nodes is calculated according to Equations (1) and (2). takes an integer value in the interval . where is the smallest value of the number of sensor node clusters in the environmental monitoring area, is the largest value of the number of sensor node clusters in the environmental monitoring area, is the area of the environmental monitoring area, and is the communication distance of the sensor nodes. The environmental monitoring area can be of any shape. In order to simplify the description, a regular shape is selected for illustration. The basic idea of calculating the number of clusters of sensor nodes in a regular shape area or an irregular shape area is the same.

Because the main factor affecting the energy consumption of sensor nodes is transmission distance, the distance is evaluated as a similarity. Compared to the -means algorithm, the -means++ algorithm significantly reduces the error of classification results. So, we use the -means++ algorithm to cluster the nodes in the sensor network.

In the initial state, by using the -means++ algorithm, the clustering of randomly distributed sensor nodes in the environmental monitoring area is completed, and the initial cluster head nodes are elected. The initial cluster head node broadcasts its own node information in the cluster and uses time division multiple access (TDMA) [19] to allocate transmission time slots for the data collection of other sensor nodes in the cluster. During each round of data collection, the normal sensor nodes in each cluster use allocated time slots to transmit the sensing environmental data to the cluster head node and declare their remaining energy information. The data packet contains the remaining energy information of the node and the environmental monitoring data collected by the node in this round. The data packet format is shown in Figure 3. After the cluster head node obtains the remaining energy information of all nodes in the cluster, it forms the remaining energy matrix for the current round of transmission.

4.2. UAV-Assisted Cluster Head Election and Data Collection in a Single-Hop Scenario

In the process of UAV-assisted sensor network data collection, each sensor node is fixed in the environmental monitoring area. Therefore, the relative distance value of each sensor node in the cluster is calculated using where represents the intracluster distance relationship of the -th node in each cluster, and represent the -th node and the -th node, represents the -th cluster, represents the Euclidean distance between the current node and all nodes in the cluster, represents the total number of the nodes in the -th cluster, and represents the maximum Euclidean distance between the current node and other nodes in the cluster. is calculated according to where the coordinate of node is and the coordinate of node is .

In an environmental monitoring region, the position of each sensor node is fixed. Then after clustering in an initial state, the cluster of the node is fixed. Therefore, UAV only needs to calculate the relative distance of each sensor node once, which greatly reduces the calculation burden of the UAV.

During each round of data collection, the cluster head node collects and fuses the collection data of each node in the cluster and transmits the remaining energy information of each node in the cluster to the UAV. The UAV calculates the relative residual energy value of each node in each cluster according to where represents the remaining energy of the -th node in the -th cluster during the -th round of data transmission, represents the maximum remaining energy of the node in the -th cluster during the -th round of data transmission, is an integer value in the interval , and is the total number of nodes in the current cluster.

Since the goal is to select the node with the smallest relative distance from other nodes in the cluster and the largest relative residual energy as possible as the new cluster head node in the next round, therefore, the UAV is used to calculate the priority of each node to be elected as the cluster head in each cluster according to the Equation (6) and save it in . where is an integer value in the interval and is the total number of nodes in the current cluster.

If there is a node in the cluster that has never been elected as a cluster head in the previous ( is the proportion of cluster heads to all sensor nodes), its priority is added to the original basis by (, and is an integer). That is to say, in the next round, a node that has not been elected as a cluster head for a long time and has a relatively small relative distance from other nodes and a relatively large residual energy has a greater probability of becoming a new cluster head node. The equation is described in

When there is a node with a remaining energy value of 0 in the cluster, the priority value of the node is permanently set to (, and is an integer), as shown in

Through the above method, the UAV calculates the priority of each node in the sensor network to be elected as the cluster head in the next round and forms a priority matrix. The node corresponding to the item with the largest element value in the priority matrix becomes the cluster head node elected in the next round. The priority matrix formed by all clusters in the UAV is shown in

Among them, each column in the matrix represents the priority of each node in each cluster to be elected as the cluster head in the next round. There are columns in total, representing clusters. For clusters with fewer nodes, add several zeros at the end of the column.

UAV will use the identification number of the cluster head node in the next round as the control information to transmit to the current cluster head node. The current cluster head node broadcasts the information of the cluster head node in the next round in the cluster. The new cluster head node uses TDMA to allocate data transmission time slots for each node in the cluster. During the next round of data collection, the normal node will transmit the remaining energy information and data information to the new cluster head by the allocated time slot.

In this way, the UAV flies to each cluster head node to perform the task of collecting environmental monitoring data information, and the data information collected from each cluster head node is transmitted to the data center through the “store-carry-forward” DTN data transmission mode. The data center analyses, processes, and predicts the collected environmental monitoring data to complete a round of sensor network data collection tasks.

4.3. UAV-Assisted Data Collection in a Multihop Scenario

When the clustering range of each environmental monitoring area is greater than the communication range of the sensor node, that is, for the second case, the nodes outside the communication range need to use multihop transmission, and the communication with the cluster head node is completed by selecting the relay node.

First, use the same method as the previous method to perform the clustering of sensor nodes and the election of cluster heads under the initial conditions. After that, the same UAV-assisted cluster head election method is used to elect the cluster head nodes of each environmental monitoring area in the next round. The UAV uses a “store-carry-forward” approach to collect data from each cluster head node and passes it to the data center for processing. Next, the selection method of the relay node and the corresponding routing process are mainly explained. The model of data transmission using relay nodes is shown in Figure 4.

In the illustrated transmission model, during a round of data collection, nodes are mainly divided into three categories: cluster head nodes, relay nodes, and ordinary sensor nodes. Among them, the cluster head node is responsible for collecting the data sensed by noncluster head nodes in the cluster, performing data fusion, and then interacts with the UAV node. The relay node is selected from the set of candidate relay nodes and is responsible for relaying the data of sensor nodes that cannot directly reach the cluster head node. The relay node also completing its own data sensing task. The ordinary sensor node mainly completes the basic environmental data sensing task. In the above figure, is the angle in the middle of the connection between the candidate relay node and the ordinary sensor node and the connection between the ordinary sensor node and the cluster head node.

In the entire sensor network, the positions of all nodes are fixed. Therefore, it is assumed that after the initial state clustering is completed, each sensor node forms a mapping table of the distance between each node in the cluster and other nodes in the cluster.

Since ID and coordinates of each node in each cluster are known and they have a one-to-one correspondence, after the cluster head node broadcasts the next round of cluster head messages, the ordinary sensor node that needs to transmit data first obtains the distance between it and the cluster head node by querying the node distance mapping table. When the distance is less than the communication distance of an ordinary sensor node, the ordinary sensor node transfers the collected data to the cluster head node by direct delivery. When the distance is greater than the communication distance of an ordinary sensor node, the ordinary sensor node selects a relay node according to the method described below.

Assume that the position distribution relationship of cluster head node, candidate relay node, and ordinary sensor node is shown in Figure 5.

According to geometric knowledge, the calculation method of the included angle is shown in where is the distance between the cluster head node and the candidate relay node, is the distance between the candidate relay node and the ordinary sensor node, and is the distance between the ordinary sensor node and the cluster head node.

If the ordinary sensor node cannot directly transmit the data to the cluster head node, the nodes within the one-hop communication range of the ordinary sensor node are classified and stored in different sets. The classification method is based on the above-mentioned included angle , and nodes meeting different conditions will be divided into different sets.

Since the goal is to transfer data in the direction closer to the cluster head node, for nodes within the communication range of ordinary sensor nodes, nodes within the range of are stored in the invalid set. The nodes in this set will never be selected. Next, divide the nodes in the range of into three sets. The set stores the nodes in the range of . The set stores the nodes in the range of . The set stores the nodes in the range of . The priority relationship of the nodes is . Then, calculate the priority of each candidate relay node in the , , and , as shown in where represents the priority function for the -th ordinary sensor node in the cluster to select the -th candidate relay node in the range of the set for relaying. The set is one of , , and . is the weight coefficient, and . is the angle in the middle of the connection between the candidate relay node and the ordinary sensor node, and the connection between the ordinary sensor node and the cluster head node. The larger the value of , the closer the position of the candidate relay node is to the direction of the cluster head node within the range of the candidate set. is the Euclidean distance between node and node . In order to reduce the number of hops from the ordinary sensor node to the cluster head node as much as possible, data should be transmitted to the candidate relay node closest to the cluster head node and farthest within the communication distance of the node. That is, a candidate relay node with a larger priority function value is more likely to become the final relay node.

Next, perform energy discrimination on the candidate relay node with the largest priority function value . When the remaining energy of node is greater than the average remaining energy of all nodes in the set , , and , the candidate relay node becomes the final relay node. Otherwise, the node with the second priority function value is judged. By analogy, the energy discrimination method of nodes is shown in where is the flag bit for whether node is elected. If its value is greater than 1, node is elected as the final relay node. is the remaining energy value of the current candidate relay node , and is the average remaining energy of all nodes in the set , , and . If there is no node in the set that meets the requirements, the nodes in the set are judged. If there is no node in the set that meets the requirements, the nodes in the set are judged until a suitable relay node is selected. If there is no suitable relay node for relaying, the ordinary sensor node is marked as unreachable.

If the data transmission range of the optimal relay node still cannot transmit data to the cluster head node, continue to select the next hop relay node for relay transmission according to the above method. If within the specified number of hops, the data still cannot be transmitted to the cluster head node, the ordinary sensor node is marked as unreachable.

4.4. Energy Consumption Model of Wireless Sensor Networks

Since the energy consumption of nodes in a wireless sensor networks is mainly composed of transmission energy consumption and receiving energy consumption, in the process of data transmission and data reception of sensor nodes, for short-distance transmission, the free space model is adopted, and for long-distance transmission, the multipath fading model is adopted [20]. The wireless transmission model is shown in Figure 6.

For the symmetric propagation channel, the energy consumption when the sensor node transmits bits data in the data packet to meters away is shown in [21]

The energy consumption of sensor nodes receiving bits data is calculated according to where is the data sending energy consumption, is the data reception energy consumption, is the energy consumption per bit of the transmitter or receiver, is the free space model parameter, and is the multipath fading model parameter.

The data fusion energy consumption of sensor nodes for bits data is shown in where is the energy consumption of data fusion and is the energy consumption parameter of data fusion.

5. UAV Path Planning Based on Improved ACO

When there are multiple separated environmental monitoring areas, these different monitoring areas have different area and different number of sensor nodes, as shown in Figure 1 in Chapter 3. How to make the UAV start from the data center, use the new cluster head node information obtained in the previous round, use appropriate algorithms, follow the preplanned path to collect data from the cluster head nodes in each monitoring area, and transfer the collected environmental data to the data center is an important issue.

This problem can be simplified to a traveling salesman problem (TSP) with a fixed starting point and ending point [22]. The TSP problem is one of the most well-known problems in the field of mathematics. It can be described as follows: suppose a UAV starts from the data center and needs to fly to sensor cluster head nodes for data collection. It must plan the flight path. The restriction is that each cluster head node can only be passed once and finally needs to return to the data center to submit sensing data. The goal of selecting the flight path is to require the resulting flight path to be the minimum of all paths. The TSP problem is an NP-hard problem with the computational complexity of NPC. Next, the research focus of this chapter will be put forward: UAV path planning method based on improved ant colony optimization.

For solving the task of UAV starting from a fixed data center, collecting sensing data from the cluster head nodes that in the separated environmental monitoring area in turn, and returning the collected data to the data center, this section uses an improved ACO to obtain a better approximate optimal solution. Introducing the simulated annealing algorithm with dynamic simulated annealing probability coefficient and tempering algorithm to further optimize the UAV’s data collection path.

The algorithm process of the improved ACO is as follows.

Step 1. Initialize ant pheromone and heuristic value. Initialize the pheromone value of each edge in the UAV data collection path and the taboo table of each ant. The pheromone value on each edge is initialized to a smaller value . The taboo table of each ant is used to record the sensor cluster head nodes that the ant has walked so far. Initialize the taboo table of each ant as the sensor cluster head node where the ant is currently located, and set the length of the taboo table to . In the initial state, the pheromone value released by the ant on each edge is 0.

Step 2. Introduce the simulated annealing to iterate to construct the flight path of UAV. At the temperature of the simulated annealing algorithm, perform an ant search. Ant determines the sensor cluster head node to be reached in the next step according to the probability , until it finally forms a legal UAV data collection path. Among them, the cluster head nodes that have passed are recorded in the taboo table. These nodes recorded in the taboo table cannot be included in the cluster head nodes that the ant will reach in the future. The calculation method of probability is shown in where is the selection probability of ant moving from cluster head node to cluster head node in the -th iteration and is the pheromone factor. The larger the value of , the greater the influence factor of the pheromone in the selection probability of the cluster head node. is the heuristic value factor. The larger the value of , the greater the influence factor of the heuristic value in the selection probability of the cluster head node. represents the cluster head node set that is not restricted by the taboo table. represents the pheromone on the edge of the ant in the -th iteration, and represents the heuristic value for the ant to move from the cluster head node to the cluster head node in the -th iteration. This value is usually the reciprocal of the distance between cluster head node and cluster head node . are the cluster head nodes that are not restricted by the taboo table. With the constraint of Equation (18), the ant will not pass through the cluster head node again, thus ensuring that the UAV will not repeatedly pass the same cluster head node during the data collection process.

Step 3. Obtain the shortest flight path of the UAV in the -th iteration. After the -th iteration, each ant has completed a tour through each cluster head node. Calculate the length of the path travelled by each ant, and save the shortest path travelled, thereby obtaining the objective function value. Compare the newly obtained shortest path value with the original shortest path value (the shortest path value generated by the first iteration process is not compared, and the result of the next iteration is waited for). If the newly obtained shortest path value is better than the shortest path value at the last temperature, then directly update the UAV flight path and shortest path value. Then, follow Step 4 to update the pheromone on each edge. If the newly obtained UAV flight shortest path value is not better than the shortest path value at the last temperature, update the dynamic simulated annealing probability coefficient according to where is the dynamic simulated annealing probability coefficient of the current iteration number, is the maximum dynamic simulated annealing probability coefficient, is the minimum dynamic simulated annealing probability coefficient, is the current iteration number, and is the maximum iteration number.
Then, the Metropolis acceptance criterion [23] is used to calculate the probability of introducing the dynamic simulated annealing probability coefficient at the current temperature to decide whether to accept the new path. The probability at temperature is calculated according to where is the difference between the shortest path objective function value of this iteration and the shortest path objective function value of the previous iteration, is the coefficient, and is the current temperature value.
Randomly generate a random number in the interval. If , accept this solution, update the UAV flight path, and update the shortest path value. Otherwise, discard the solution generated in this iteration. From the Equation (20), it can be concluded that as the iteration progresses, the temperature is continuously reduced due to the effect of the cooling coefficient, and the value of continues to decrease with the increase of the number of iterations. Therefore, the value of the probability is continuously reduced. That is, the probability of accepting a poor solution is constantly decreasing, similar to the annealing crystallization process of crystals in nature.

Step 4. Update the pheromone value. The update of the pheromone on each edge of the path includes the volatilization of the pheromone due to the passage of time and the newly produced pheromone released by the ants when they passed by. Pheromone is updated according to the rules shown in where is the pheromone on the edge at the -th iteration and is the pheromone on the edge at the -th iteration. is the pheromone volatilization factor, and . is the pheromone maintenance factor. is the -th ant. is the total number of ants. is the pheromone released by the -th ant on the edge when it passes during the -th iteration. is calculated according to the method shown in where is the pheromone enhancement factor, is the length of the path constructed by the -th ant, and is the coefficient. The smaller the path length , the Equation (22) shows that the higher the pheromone content on each edge of the path, and the greater the probability of being selected by other ants.
After all ants complete the pheromone update operation, save and record the shortest path of current UAV data collection. Then, initialize the taboo table and pheromone increment.

Step 5. Judgement of tempering conditions. After the pheromone released by the ants on each edge is updated, it is checked whether the tempering conditions are met, so as to decide whether to perform the tempering operation. Whenever the temperature during the simulated annealing operation is less than or equal to the minimum value of the tempering temperature , and the current tempering times has not reached the set maximum upper limit of the tempering times , use Equation (23) for tempering operation. where is the current temperature value and is the highest temperature value of the tempering temperature. According to the above operation, at most tempering operations are performed, the objective function value is more optimized.
Finally, use the cooling coefficient to update the temperature value, and the update method is shown in where is the temperature after the update, is the temperature before the update, and is the cooling coefficient.
Repeat the execution from Step 2 and loop in turn until the termination condition of the improved ACO is met. The final optimal path and shortest path value are output. The execution process of the improved ACO is shown in Figure 7 and Algorithm 1.

The improved ACO is implemented in the UAV node to realize edge computing. Before the next round of data collection tasks arrive, the UAV plans the data collection path through the new cluster head node ID and coordinate value calculated by itself in the previous round. The UAV collects sensor network data according to the data collection path planned in advance. Among them, when the UAV performs the first data collection task, it uses the cluster head node ID and coordinate values obtained by the initial clustering to plan the path, and can ignore the influence of other factors.

1. Initialize pheromone and heuristic value;
2. Initialize the taboo table of ants;
3. Introduce Simulated Annealing iteration;
4. Execute ant search algorithm;
5. Set the starting node of the ant search algorithm;
6. Calculate the cluster head node to be reached next;
7. If Path update is not complete then
8.     Return to step 5 and continue to execute;
9. Else
10.  If Ant search is not complete then
11.    Return to step 4 and continue to execute;
12.  Else
13.    Calculate the shortest path objective function value;
14.    If Better than the value at the previous temperature then
15.      Update path and shortest path value;
16.      Update pheromone;
17.      If the tempering conditions are met then
18.        Execute tempering algorithm;
19.        Update temperature;
20.        If the Simulated Annealing iteration is completed then
21.          Obtain the optimal path and shortest path value;
22.        Else
23.          Return to step 3 and continue to execute;
24.        End if
25.      Else
26.        Go to step 19;
27.      End if
28.    Else
29.      Update dynamic SA probability coefficient;
30.      If the new path acceptance probability condition is satisfied then
31.        Go to step 15;
32.      Else
33.        Go to step 16;
34.      End if
35.    End if
36. End if

6. Simulation Experiment and Result Analysis

This chapter uses MATLAB R2019a to perform simulation experiments to analyse the performance of the solutions proposed and discussed above.

Dead nodes refer to the nodes whose remaining energy is not enough to continue to complete the data collection task of the sensor network. Figures 811 show the first rounds of 10% of the nodes die, 30% of the nodes die, half of the nodes die, and all of the nodes die in the sensor network under LEACH [24], Fuzzy [25], KM-CF [26], and DCSD-single scheme proposed in this paper which is suitable for single-hop scenarios. In a sensor network, the number of rounds in which 10% of the nodes die, 30% of the nodes die, half of the nodes die, and all of the nodes die for the first time is an important performance evaluation index for the life cycle of the sensor network. As can be seen from the figure, compared with the other three schemes, the scheme proposed in this paper delays the first occurrence of the death of 10% nodes, the death of 30% nodes, the death of half nodes, and the death of all nodes and has better performance.

As mentioned earlier, for scenarios with a large network range, the UAV-assisted sensor data collection method proposed in this paper for single-hop scenarios can be used to divide an appropriate number of clusters. This method makes the distance between the sensor node and the cluster head node less than or equal to the communication distance of the node to complete the single-hop transmission between the sensor node and the cluster head node, which is the DCSD-single scheme. Or use the UAV-assisted sensor network data collection method proposed in this paper for multihop scenarios. Select a suitable relay node as a transmission relay, and solve the unreachable problem caused by the distance between the sensor node and the cluster head node being larger than the node communication distance. It is the DCSD-multi scheme.

The experimental scene is expanded. The DCSD-single scheme in the single-hop scenario and the DCSD-multi scheme in the multihop scenario are compared and tested in a monitoring area with 200 sensor nodes randomly distributed. Among them, in order to make multihop transmission occur, appropriately expand the range of each cluster in the DCSD-multi scheme in the multihop transmission scenario, that is, reduce the number of cluster head nodes in the network.

Because the flying height of the UAV will affect the distance between nodes, it will affect the energy consumption of information transmission. Therefore, the following comparative experiment considered the influence of the UAV’s flight height on the experimental results.

Figures 12 and 13 show that when the number of cluster head nodes in the DCSD-single scheme is 16 and the number of cluster head nodes in the DCSD-multi scheme are 12 and 8, the comparison graph of 10% of the nodes die, 30% of the nodes die, half of the nodes die, and all of the nodes die for the first time and the comparison graph of the network life cycle with the UAV flight altitude change.

Figure 13 shows the impact of UAV flight height on the performance of various schemes. As the flying height of the UAV increases, the cluster head node needs more transmission power to transmit data to the UAV node, which leads to an increase in the energy consumption of the cluster head node and reduces the life cycle of the network. Therefore, when the UAV is actually used to assist the sensor network for data collection, under the premise of ensuring safety, reducing the flying height of the UAV to a certain extent can delay the death time of the sensor nodes in the environmental monitoring area.

This chapter uses MATLAB R2019a to plan the UAV data collection path. Assume that there are five environmental monitoring areas separated from each other due to geographical environmental factors, which form a distributed wireless sensor networks through the flight transmission of UAV. According to the method of “store-carry-forward,” starting from the data center, the UAV collects data from the cluster head nodes in each separated environmental monitoring area through the designated algorithm, and then according to the planned optimal path, the UAV finally transmits the data to the data center. In most ecological environmental monitoring scenarios, sensor nodes are deployed on the ground, so the height of each sensor node is ignored, and the network scenario is simplified to a two-dimensional coordinate plane. This scene has a data center and five separated sensor network environmental monitoring areas.

The algorithm evaluation indicators in this chapter mainly include the total path length of UAV data collection, the minimum number of iterations required for each algorithm to reach the shortest path, and the convergence speed of each algorithm. Suppose the data center coordinates are (500, 1000), the range of sensor network 1 is , and the number of nodes is 100. The range of sensor network 2 and sensor network 3 is , respectively, and the number of nodes is 70, respectively. The range of sensor network 4 and sensor network 5 is , respectively, and the number of nodes is 50, respectively. According to the cluster head election method described in Chapter 4, the coordinates of the sensor cluster head nodes in each monitoring area can be obtained during a certain round of data collection. The simulation experiment parameter settings of the improved ACO are shown in Table 1.

This chapter conducts simulation experiments on four intelligent algorithms. The node numbered 1 shown by the five-pointed star logo represents the data center. The cluster head nodes elected in each partitioned environmental monitoring area are represented by number 2-31, respectively. The coordinate of the data center and the coordinate information of the cluster head nodes elected in each partitioned sensor network are shown in Table 2.

Figures 1417 show the results of using four algorithms for UAV data collection path planning, respectively. Figures 1417 show the optimal flight path for UAV path planning using four algorithms, respectively. Among them, 1 is the data center, which is the starting point and end point of the UAV data collection process. Nodes 2-31 are cluster head nodes distributed in each partition monitoring area.

The comparison of the number of iterations and the shortest path length of the ant colony optimization, simulated annealing, genetic algorithm, and improved ACO to achieve convergence is shown in Table 3.

The comparison of the iterative curves of the four algorithms to reach the shortest path of UAV data collection is shown in Figure 18. It can be seen from the figure that in the experimental scenario proposed in this chapter, the quality of the solution is poor in the initial search execution stage of the simulated annealing and the convergence speed of the algorithm is slow when it reaches the shortest path. The genetic algorithm also has the problem of low solution quality in the initial search execution stage, and the convergence speed is slow when it reaches the shortest path. However, compared with simulated annealing, genetic algorithm greatly reduces the shortest path length. In comparison, the ant colony optimization and the improved ACO can obtain higher-quality solutions in a limited number of iterations; that is, they can converge to the shortest flight path of the UAV faster. Using the improved ACO to plan the UAV data collection path can get a better shortest path length and can get the convergent shortest path result at the fastest speed.

7. Conclusion and Outlook

This paper studies the data collection method of sensor network based on UAV and introduces the idea of edge computing into it. Distributed wireless sensor networks separated from each other are assisted by UAV technology for clustering and cluster head elections, which reduces the overall energy consumption of the distributed sensor network. Then, the improved ant colony optimization is used to plan the UAV data collection path. Through the “store-carry-forward” method, the UAV takes the shortest path to carry the sensed data and transmits it to the data center.

In future work, we will consider the use of UAVs to charge and collect data in the sensor network, consider the impact of different sensor node distribution patterns on the performance of the sensor network, and consider multi-UAVs to coordinate the data collection of the sensor network to further improve the efficiency of data collection to serve a wider monitoring area and complete the corresponding environmental monitoring tasks.

In addition, it is considered that the intelligent algorithm (improved ACO) can be changed into a reinforcement learning algorithm, and a reinforcement learning algorithm that conforms to its own scene can be set, so that the UAV can plan the optimal path by itself, thus improving the data collection efficiency of the sensor network.

Data Availability

The experimental data used to support the findings of this study are available from the corresponding author upon request.

Conflicts of Interest

The authors declare that there is no conflict of interest regarding the publication of this paper.

Acknowledgments

This work was supported by the National Natural Science Foundation of China (62077032), the Inner Mongolia Natural Science Foundation (2020MS06023), and the Inner Mongolia Science and Technology Plan Project (2021GG0159).