Planning model of a group UAV flight in three-dimensional space

The paper describes the algorithm and model for planning group actions of unmanned aerial vehicles (UAVs) to monitor a given set of objects. A distinctive feature of the task is the shooting of objects from a predetermined height. This makes it necessary to move from considering a “flat” model to planning a flight in three-dimensional space. In addition, the authors take into account the possibility of destroying individual UAVs and the need to reschedule the flight route for the remaining UAVs in order to accomplish the assigned task.


1.
Introduction Nowadays, the use of unmanned aerial vehicles for the solution of observation problems is very important [1]. More and more often there are situations when there is a need for prompt receipt of information, while the information about situation necessary to obtain can be located both in hard-toreach and crowded places.
There is a wide range of available unmanned aerial vehicles on the Russian market and modern experience of their practical use has shown that already now they have sufficient technical characteristics not only to record the information received, but also to process it.
The issues of targeted flight (mission) planning, taking into account the air situation and possible enemy countermeasures have been resolved for a single UAV [2,3]. However, there is a need to resolve these issues for the group of UAVs. The method of sequential flight planning of a group of several UAVs in the general case is not able to ensure the optimal use of the existing group. Therefore, it becomes necessary to develop algorithms that allow simultaneous control of several UAVs.

2.
Problem statement The purpose of this paper is to solve the problem of planning a fly-by of many objects by a group of unmanned aerial vehicles and building its three-dimensional model.
The following is given: -the characteristics of each UAV model, which can be taken from the flight manual or from other documents of the chief designer of UAV; -the coordinates of the target and the specified height of their shooting;

3.
Development of a model for automated routing. Algorithm for the distribution of routing points for UAVs The problem of the distribution of routing points for UAVs is reduced to the solution of the classical problem of transport routing. The solution of the problem makes it possible to find the routes for several vehicles starting their route from one point (depot) [6]. In order to solve the problem, the authors propose to use a modified "greedy" algorithm [7]. Among the main factors that influenced this choice, in addition to the general restrictions imposed on the possibility of using UAVs, the authors used the following: when planning to fly over a certain area, a significant number of unmanned aerial vehicles can be used, as a result, the number of points required to create a route can be huge; -each considered UAV has unique technical characteristics that can change over time directly in the process of movement; -when using UAVs, there is a possibility of their failure, one of the reasons for such a situation may be a sharp change in weather conditions, as a result of which there is the increase in the consumption of energy resources required to reach the routing point.
Taking into account the above mentioned aspects, we can conclude that any pre-created route may turn out to be incorrect even with a slight error in the calculations, and making amendments to the already formed route leads to its complete recalculation.
Let us consider the UAV group flight algorithm ( Figure 1): 1) At the initial stage, a search is performed for available route points that are at the greatest distance from the starting point and from each other. The criterion of proximity in this case is the technical characteristics of the UAV (the availability of the necessary energy resources to reach the found route point and return movement, as well as the ability to climb to the height specified by the route point).
2) After the drone reaches the first route point, it is necessary to search for the nearest reachable route points. One of which is defined as a new route point for the UAV. 1) In the case that the search gave negative results and there are no more reachable waypoints, the UAV returns to the starting point.
Let us introduce some clarifications into the operation of the algorithm:  each UAV has information on the location of all points requiring a visit, when a point is included in the visiting route by one of the UAVs, others no longer visit this point, it becomes inaccessible to them;  in the case of emergency, functional loss of UAV, its unvisited points are opened for access to other unmanned aerial vehicles;  before the departure, the analysis of the flown territory is carried out for the presence of "restricted" zones, which are marked on the map and this terrain becomes inaccessible to the UAV. Such zones can be zones closed for UAV flights or those where there are threats of UAV functional loss. Terrain analysis is also carried out to determine possible obstacles to the movement of UAV. The UAV route should be built taking into account the bypass of the marked obstacle in order to avoid collision  the flight range of unmanned aerial vehicles is significantly influenced by weather conditions (mainly wind).
In order to solve the problem, we will take into account the following characteristics of UAV: -possible speed of movement;

4.
Development of software for modeling automated routing Software development was carried out using Qt Framework in the high-level C ++ language using the Qt classes. The mingw32 compiler was used to build the project on the Windows platform and linuxg ++ for Ubuntu.

5.
UAV movement In order to calculate the motion of UAV in the simulation, a discrete constant step (h=19729 m/sec) was used. Before the next shift of the unmanned aerial vehicle, the speed and direction of its movement are calculated, taking into account the influence of the environment.
The UAV can change the direction of movement as needed. The direction of turn depends on the current position of a drone, angular speed and distance to the route point.
The angle of rotation to which UAV must be deployed can be calculated as follows:  where xdrone and ydrone -UAV coordinates, xpoint, ypoint -route point coordinates.
To make a decision on the need to UAV rotation, the current angle of the direction of flight and the required (calculated) angle are compared.
The rotation of UAV does not occur instantly, for its implementation, a certain spatial volume is required, in order to calculate the required distance to complete the rotation, we use the following formula: wherechord length; Vrotaterotation speed; Vsum -UAV speed with wind influence.
Depending on the obtained result, the radius of the rotation is determined, if the rotation requires a distance greater than to the road point, then the rotation will be carried out along a large radius, if less -along a small one. The example of the choice of the direction of rotation is shown in Figure 2. Height gain One of the characteristics of a route point is its height. This characteristic was introduced in order to be able to set the height from which to shoot the object located in it. This is explained by the rugged (mountainous) terrain over which UAV flies, or urban or industrial buildings, the height of which can reach several hundred meters. If the distance to the nearest route point is less than the distance necessary to lift UAV (taking into account its maximum vertical speed), an UAV will move around the route point until it reaches the required height. The example of such a movement is shown in Figure 3.

7.
Obstacle avoidance One of the problems that an unmanned aerial vehicle may face is an obstacle, such as a mountain, a high building, etc. When it faces an obstacle, an UAV can either change its direction of movement, or gain height and fly around it vertically. Bypassing an obstacle in the horizontal plane is almost always possible, however flying vertically is possible only if the technical characteristics of UAV allow it (it is necessary to take into account the maximum height of UAV and the height of an obstacle).
There are several algorithms to find the ways to avoid obstacles during the movement from one point to another [8,9]. The most famous ones are the wave tracing algorithm and the А* algorithm. In most cases, these algorithms accurately find a route among several obstacles of a complex form. However, they are not quite suitable for our task. The main reason for this is resource consumption. When using these algorithms, the terrain map is divided into cells and taking into account the speed with which the UAV moves and the model of its movement, it will be necessary to consider areas that are large in size in order to solve the problem the use of these algorithms. Another reason is the virtually complete absence of complex obstacles on the flight route as almost all industrial facilities are located on flat terrain. Therefore, most of the objects that can be met on the path of UAVs have an extremely simple form and can be represented in the form of circles described around the object. In the same way it is possible to imagine the areas initially prohibited for UAVs.
First, the stage of checking the route for the presence of obstacles includes the search for the first obstacle on the way of UAV and evaluation of its length. If the analysis shows the presence of an obstacle, then the distance from UAV to the obstacle is calculated, as well as the distance required for height gain. In the case when there is no opportunity to gain height (there is not enough available distance, technical characteristics of UAV are insufficient), the search is carried out for the nearest point to bypass an obstacle, which will become the route point.
The operation to find obstacles is repeated at each new route point, until all obstacles are overcome.

8.
Wind generation algorithm As we have already mentioned above, weather conditions and wind in particular, have a significant effect on the duration of UAV's stay in the air, its speed and fuel consumption. To assess this influence, we have proposed the algorithm that simulates the behavior of wind. At the initial stage of modeling, the wind direction and speed were set randomly and its further behavior was subject to several conditions: -the calculation of changes in wind characteristics occurs at each step of the simulation; -there was the assumption that there was a direct relationship between the wind speed and the probability of its change (the increase in wind speed leads to the increase in the probability of its decrease and vice versa); -every change in wind characteristics can be cut off randomly; there is a possibility that the wind strength and speed will remain unchanged in the next step of the simulation; -the direction and speed of wind change randomly without sharp jumps.

9.
Interface description During the development of the interface, the main task was to provide a user with only the information he needed at the moment. In this regard, all settings were moved to separate windows.
The main window of the program can be conditionally divided into two areas: 1) The map with objects displayed on it. This area occupies about 80% of the window. In this area, the movement of the UAV is drawn and all routes are displayed at the end of the movement.
2) The area with buttons and current simulation information. Here the information about the state of UAV is reflected and the simulation time and the number of visited points are displayed at the end of the simulation.
The window of map selection allows opening the required image using the explorer. The map preview function is available to the user only until the selection is confirmed. The displayed map is scaled to fit the actual size of the window.
After the final selection of the map, the "Modeling" and "Set parameters" icons become available. The main windows used in the simulation are as follows.

10.
Experimental verification of developed software In order to check the performance of the software, it was launched with a set of predefined parameters, most of which are presented below.
When modeling, a group of four UAVs with the following characteristics was considered:

11.
Conclusion As a result of this research, we can single out the developed algorithm for planning UAV flight routes in a group flight, taking into account the effect of the wind, the need to shoot from a given height and fly around obstacles of the route. The experimental software was created on the basis of the developed algorithm. The testing the software on a sufficiently large number of test examples showed its performance in a wide range of initial data (the number of UAVs is -2-10, the number of route points is up to 150). The methods used in the work have been applied in other industries [2][3][4].