3.1. Area Decomposition
In this work, we assume that the UAVs will fly over the area to be covered executing a back and forth motion in rows perpendicular to a given sweep direction, as shown in
Figure 1. While following the rows, the UAV is leveled (which means that its camera is pointing down), but at the end of the row, it makes a curve outside the area to return to the next row. During such a curve, the camera is generally not pointing to the ground. Furthermore, as pointed out by Huang [
9], the number of turns is directly related to the time of coverage of a given region. Therefore, as suggested in [
9], the first step of our method is to find the optimal direction of coverage, which is perpendicular to the smallest height of the polygonal area. In this direction, the area can be covered with the smallest number of rows, thus with the smallest number of curves. This can be observed in
Figure 1. As pointed out by [
10], a path with less turns is more efficient in terms of route length, duration and energy. However, notice that the sweep direction may be chosen in different ways. It is possible, for example, to choose the direction of the coverage rows as a function of the wind, since flying against the wind may destabilize the vehicle [
12].
Figure 1.
Coverage strategy used in this work. A rectangular area is covered using a back and forth motion along lines perpendicular to the sweep direction. Notice that the sweep direction highly influences the number of turns outside the area to be covered, thus affecting the coverage time. The optimal sweep direction is parallel to the smallest linear dimension of the area [
9].
Figure 1.
Coverage strategy used in this work. A rectangular area is covered using a back and forth motion along lines perpendicular to the sweep direction. Notice that the sweep direction highly influences the number of turns outside the area to be covered, thus affecting the coverage time. The optimal sweep direction is parallel to the smallest linear dimension of the area [
9].
To find the optimal direction of coverage of a given polygon, a simple search procedure may be used. As shown in
Figure 2, the polygon is rotated over a surface, and its height is measured. The best orientation is the one that yields the smallest height,
.
Figure 2.
Procedure to search the optimal direction of coverage. The area is rotated until the smallest height is found.
Figure 2.
Procedure to search the optimal direction of coverage. The area is rotated until the smallest height is found.
Once the optimal sweep direction is found, it is then possible to distribute the rows over the area. In our approach, the distance between two rows is chosen as a function of the footprint of the on-board cameras on the ground. As shown in
Figure 3, assuming that the image sensor is parallel to the ground plane (
i.e., the UAV is leveled), by knowing the width of the image sensor,
l, the focal distance of the camera’s lens,
f, both in millimeters, and the distance between the camera and the ground,
H (the flying height), in meters, it is possible to compute the width
L of the camera’s footprint, in meters, as:
Figure 3.
Relation between the size of the camera sensor, the height of flight and the camera footprint on the ground.
Figure 3.
Relation between the size of the camera sensor, the height of flight and the camera footprint on the ground.
The number of coverage rows is then computed as:
while the distance, in meters, between two rows is:
where
represents the fraction of overlap between two images. This overlap is generally necessary to concatenate the images to compose an aerial map.
Assuming that the polygon that represents the region is rotated in a way that the optimal direction of coverage is parallel to the
x axis of the global reference frame, the coverage rows can be defined by two planar points
with identical
y coordinates given by:
and
x coordinates defined by the points where the horizontal straight line with coordinate
intercepts the borders of the area to be covered. Once the points are computed, they are rotated back to the original orientation.
The extreme points of the coverage rows, along with the coordinates of the UAV launch position, called the base or depot, are considered to be the set of nodes
V of a graph
. Each node of the graph is numbered so that the base receives Number 1, the nodes related to the first coverage row receives Numbers 2 and 3, the ones associated with the second row are labeled 4 and 5, and so on. At the end, each coverage row is associated with subsequent even and odd nodes. The edge set,
E, is composed of all lines connecting the
N nodes of the graph, thus forming a complete graph, as shown in
Figure 4.
Figure 4.
Graph representing the coverage problem. On the left, a rectangular region to be covered, the launch position and the covered rows. The nodes of the graph on the right are composed of the launch position and the intersection points between the coverage rows and the borders of the region. All nodes are connected by edges, forming a complete graph.
Figure 4.
Graph representing the coverage problem. On the left, a rectangular region to be covered, the launch position and the covered rows. The nodes of the graph on the right are composed of the launch position and the intersection points between the coverage rows and the borders of the region. All nodes are connected by edges, forming a complete graph.
Mathematically, graph G may be represented by an cost matrix C whose elements, , are given by the Euclidean distance between the spatial coordinates of nodes i and j. It is important to notice that C is time invariant, symmetric, i.e., , and its elements satisfy the triangular inequality, i.e., . The next subsection will describe how the graph represented by C will be used in an optimization problem to allow the coverage of an area in minimum time using multiple UAVs.
3.2. Routing Strategy
Once a graph associated with the region to be covered is created, the coverage problem can be posed as a vehicle routing problem (VRP) [
13]. In this class of problems, a set of customers must be visited by a set of vehicles. To transform the problem proposed in
Section 2 into a VRP, each UAV will be modeled as a vehicle and each extreme point of the coverage rows as a customer. Furthermore, by proposing new constraints, it is possible to enforce the vehicles to use some pre-specified edges of the graph in their routes, so that the coverage rows will be certainly followed by one of the launched UAVs. Finally, by solving the VRP, one can obtain the set of routes that each UAV will have to perform.
Before presenting the mathematical formulation of the routing problem, we will define the constants and variables necessary for this formulation. As defined in the previous section, constant represents the traversing cost of the edge between nodes i and j. To indicate whether or not the UAV is going to fly from vertex i to vertex j, the binary variable is used. Furthermore, let constant represent the flight speed of the UAV while flying from vertex i to vertex j, constant be the individual setup time and be the battery duration of UAV number k. Let also be the variable that represents the number of UAVs designed for a mission, be the total number of UAVs available, be the constant number of UAV operators and be the number of nodes of the graph. Finally, the variable represents the extra time necessary to launch UAV k.
Based on the variables previously defined, the time spent by UAV
k to fly its route is mathematically given by:
Our main objective is to minimize the mission time. This can be accomplished by minimizing the time of the longest route among the routes of all UAVs. Therefore, our problem is in fact a min-max problem in which we want to minimize the maximum
. To transform the min-max problem into a linear problem, we introduce an extra variable
, which represents the longest UAV route. The basic optimization problem is then written as:
subject to
As previously shown, constraint in Equation (
6) accounts for the individual cost (time) of UAV
k. This corresponds to
. By defining this constraint along with the objective function in Equation (
5) using variable
, we are posing a linear version of the min-max problem, where the maximum cost among the ones of all UAVs must be minimum. By doing this, we are, in practice, minimizing the time taken to cover the complete area.
In Equation (
6), the term
, detailed in Equation (
7), accounts for the setup time,
, which is an extra cost that corresponds to the time spent by a human operator to prepare and launch the UAV for the mission. In a mission where only one person is operating the whole team of UAVs, each UAV will have the extra time
, which will be cumulative. In a system with two UAVs, for example, while UAV 1 is prepared, nothing is happening with UAV 2. After the launch of UAV 1, UAV 2 is prepared to be launched. Notice in Equation (
7) that
is null when the UAV is not used, once
is zero, indicating that UAV
k did not leave Node 1, which represents the launching position.
Since the setup time is one of the main contributions of this work, before proceeding with the additional constraints necessary to guarantee a coverage solution, we will explore the effect of constraint in Equation (
7) with three examples. For the first example, assume a team of
UAVs with individual setup time
min and a single operator (
). The team is supposed to cover a rectangular area with 8 coverage rows. Each row can be covered in
min, and the time to reach the region and to change between rows is considered to be negligible. Given this, the cumulative setup time of each UAV, as computed by Equation (
7), is given by:
Notice that the cumulative setup time for UAV 3, min, is equal to the time a single UAV would expend to cover the region (min). This indicates that the use of 3 UAVs for this mission is not worth it. In this way, the best solution would make , indicating that UAV 3 would not be used in this mission. Two UAVs would be launched, and the best coverage time would be min. For this solution, UAV 1 would cover six coverage rows and UAV 2 only two rows. As a remark, if three UAVs were considered, the best coverage time would be min.
The second example explores the case when the number of operators is larger than one, but is smaller than the number of UAVs available. Suppose a team of
UAVs with individual setup time
min and a number of
operators. Using Equation (
7), we have:
As can be seen, UAVs 1 and 2 have the same setup time, because the two operators will prepare them simultaneously. After the takeoff of these UAVs, UAVs 3 and 4 will be prepared. Their setup time is min, composed of min of waiting for UAV 1 and 2 to be prepared and min of their own preparation. For UAV 5, the same reasoning can be applied.
In a third example, consider the case where the number of operators is equal to the number of UAVs. In this case, since
in Equation (
7) will be equal to one for all UAVs, the setup time for each UAV would be
.
To complete the optimization problem and to guarantee its solution, a solution to the problem posed in
Section 2 is indeed, and other constraints need to be incorporated into the the basic problem. The first of these constraints is given by:
which limits the maximum time of flight of UAV
k by its battery duration,
. We consider that the charge of the battery does not decrease during the setup time or that charge decreasing is negligible. In this way, the time of flight of each UAV is simply the total time in Equation (
6) subtracted by the setup time
. It is important to mention that constraint in Equation (
8) can make the problem infeasible. This is expected if, for example, a large area is to be covered by a very small team of UAVs. The only solution in this case would be to increase the number of agents. In another situation, if the time to cover a single row is larger than the battery duration of a single UAV, the problem would also have no solution. In this case, one could go back to the first step of the methodology and try to reduce the length of the rows by changing the sweep direction (which would increase the number of turns). A more complex alternative for both situations would be to change the optimization problem to consider battery recharging. These solutions are left as suggestions for future research.
To guarantee that each node of the graph is visited only once by a single UAV, two other constraints are necessary:
Notice that constraint in Equation (
9) enforces that each node, except the base (represented by Node 1) is visited by only one UAV. On the other hand, constraint in Equation (
10) guarantees that the UAV that arrives at a given node is the same one that leaves this node.
To enforce that each UAV path starts and finishes at the base (Node 1) and to guarantee that the path has no internal cycles, a standard sub-tour elimination constraint [
19] is used:
where
.
To make sure the VRP solution will make the UAVs cover the area modeled by graph
G, the following constraint is also necessary:
This constraint enforces that each UAV, having visited one of the nodes of a coverage row, must visit the other node of that row. This is possible given the way the nodes were numbered (see
Figure 4). Constraint in Equation (
12) guarantees that each UAV that visits an even node also visits the next odd node. Furthermore, a UAV that visits an odd node must visit the previous even node. Therefore, this constraint is essential to make the problem solution an actual coverage solution.
To avoid the UAVs crossing the coverage area following an edge that is not parallel to the coverage rows, two optional constraints can be added to the optimization problem:
In practice, constraints in Equations (
13) and (
14) can avoid the UAVs executing sharp turns and also photos being taken in different directions. If these issues are not important for a given task, these two constraints can be simply ignored without compromising the execution of the task.
Finally, to allow the number of UAVs used in the mission,
m, to be smaller than the maximum number of UAVs available,
M, we introduce the following constraints:
It is important to mention that constraints in Equations (
15) and (
16) represent an important contribution of this work in relation to others that were previously published, such as [
19], where the number of UAVs is kept constant. In this work, the number of UAVs will be chosen as a function of the minimization of
.
By solving the problem represented by the objective function in Equation (
5) and constraints in Equations (6)–(16), one would expect to obtain a solution in which the minimum number of UAVs would follow the shortest possible paths, covering in minimum time the area modeled by graph
G. However, although the mission time will indeed be minimum, the objective function does not explicitly take into account the number of UAVs, which may cause the computed solution to consider a number of UAVs that is not optimal. Moreover, since our problem minimizes the longest path in terms of mission time, once the best longest path is found, there is no guarantee that the paths for the other UAVs are minimized. To make sure that the optimal number of UAVs,
m, is chosen and that the paths for all UAVs are minimum, two strategies were devised.
The first one is a heuristic and depends on the adjustment of some constants. The idea is to change the utility cost function, so that it explicitly takes into account the number of UAVs and/or a combination of all UAV path costs. For example, the cost function explicitly considers the number of UAVs. A correct choice of constant ρ will make the optimizer find the best m. In the same way, if is the individual coverage time for UAV k, the cost function would minimize the paths of all UAVs if ρ is chosen properly.
The second strategy, which will generate the optimal solution in terms of the number of UAVs and individual paths independently of parameter choices, is an iterative solution that consists of solving the optimization problem more than once. In the first iteration, the original graph is used, and the optimization problem to be solved is exactly the one previously presented. In the second iteration, the problem is reduced by removing the UAV assigned to the longest path in the first iteration, which is already optimal, and all nodes (except for the base) and associated edges that belong to its path. This procedure is repeated until all nodes, but the base, are removed from the graph. With this procedure, we have a better use of the available resources. It is then guaranteed that the optimal number of UAVs is found and that the paths for all UAVs are optimal without compromising the primary objective, which is to minimize the cost of the route with the highest cost.
In the next section, we present simulations that illustrate our methodology and the role of the constraints in the optimization problem.