Introduction

Autonomous decisions and control for numerous UAVs are made possible by mission planning technologies. Mission planning is the process of organizing a team of UAVs to accomplish a set of coordinated goals1,2. Wide area search ammunition (WASM)3,4, suppression of enemy air defense (SEAD)4,5, electronic attack5,6, combat intelligence, surveillance, and reconnaissance (ISR), etc6., all of which rely heavily on mission planning, which is currently a hot topic in the field of study. High dynamic uncertainty and intense confrontation are established factors in the aforementioned typical application scenarios or potential future application scenarios, which pose significant challenges to the practicality of current mission planning technology. On the one hand, the current allocation/track-based decoupled mission planning method with progressive decoupling cannot guarantee obtaining the allocation decision matrix and the corresponding track. On the other hand, when the UAVs are unable to perform a task because of machine heterogeneity and task timing, the UAVs are said to be in a deadlock condition. This occurs because each UAV enters a waiting process that never ends. The traditional optimization method has a hard time producing workable mission planning results in the allotted decision time. Therefore, based on the mission planning features of the above typical application scenarios, an integrated model with strong coupling of mission planning is constructed, and a rapid solution method for the mission planning model is proposed.

The fundamental reason for the coupling in mission planning is track planning, which is the follow-up activity of task assignment. Various scholars have done extensive research into this link and provided various approaches for addressing the coupling it creates7,8. To handle both task assignment and track planning in parallel, Shima et al.9 developed a centralized framework; Wu et al.10 implemented a fast method to solve the coupled problem of task assignment and track estimate; and Wang et al.11, Yao et al.12 suggested another multi-level mission planning framework based on the A* method for completing the journey estimation between two mission points using a distributed contract network. The depth-first technique was utilized to tackle the problem proposed by Rasmussen et al.13, who equated the UAV body to the Dubins model and presented the task planning in the form of a decision tree. The solutions that are commonly used either have problems with overly simple models, such as the drone’s fixed flight altitude and independent rewards for executing tasks, or have problems with excessive algorithm computation, such as spending a lot of computing resources to check all possible solutions before executing task assignments. It follows that the model’s accuracy and the algorithm’s speed should be ensured on the condition that the coupling features of mission planning are taken into complete account.

In time-constrained, heterogeneous systems, the deadlock problem is common. Academics have offered many different strategies to avoid the deadlock phenomenon of multiple UAVs due to timing conflicts of tasks14,15. Deadlock is defined and the circumstances for deadlock creation are described by Coffman et al.16. For the deadlock issue brought on by task timing limitations, Deng et al.17 suggested a deadlock detection and repair method based on graph theory and matrix transposition; however, a new deadlock would be established during the matrix transposition procedure. Although Guang et al.18 optimized the genetic algorithm’s initialization and genetic operation strategy to keep individuals from getting stuck in a deadlock, this narrows the search space and makes it harder to locate the globally optimal solution. The deadlock problem can be avoided in principle thanks to the deadlock criterion of timing tasks established by Cao Yan et al.19. The size of the potential learning space was similarly condensed by this approach. The non-deadlock allocation of the system was achieved when Edison et al.20 employed a genetic algorithm to tackle the job planning problem by decreasing the fitness of deadlock individuals. The algorithm relied on finding a way to lengthen the waiting circle, but doing so lengthened the time needed to plan out each individual assignment. Studies commonly encounter issues, such as high computational complexity and reduced feasible space of the solution, when attempting to solve the deadlock problem. Therefore, the optimality of the algorithm and the efficacy of the allocation outcomes should be prioritized to solve the deadlock problem.

Some researchers have presented fast solving algorithms and distributed solutions frameworks in order to meet the speed needs of mission planning and solving, but these studies have simplified the mission planning model to varying degrees, leading to poor solution quality. Prior work on the issue of collaborative task assignment has been conducted by Long Tao et al.21, but their task planning model and constraints are ideal. Similarly, Alighanbari et al.22, who employed the concept of model predictive control in task planning, neglected to take into account the impact of UAV kinematic constraints and timing constraints between tasks. Wu et al.23 employed a distributed evolutionary algorithm to quickly address the problem of job assignment and track planning within the limitations of the UAV’s kinematics, but they neglected to take into account the three-dimensional track characteristics of the UAV. The job assignment problem was efficiently solved by Zhang Ruipeng et al.24, who took into account the UAV’s range and task time window constraints in full and employed a hybrid particle swarm optimization approach. The scenarios examined were also straightforward. Moreover, none of these studies have shown that it can be applied to mission planning issues that are linked, blocked, and take place in three dimensions.

This study employs the distributed genetic algorithm to swiftly tackle the common issues in the existing multi-UAV task assignment by establishing an integrated solution model for multi-UAV cooperative job assignment. In order to avoid Time sequence conflicts leading to deadlock, the depth-first algorithm is used to detect the loops in the sequence task graph and eliminate infeasible solutions in the task planning; secondly, in order to avoid Time sequence conflicts leading to deadlock, the UAV body is equivalent to a three-dimensional Dubins model, and the integrated model of task assignment and track planning is established by discretizing the heading angle of the UAV arriving at the target point and adopting discrete graph theory. As a result, a parallel processing strategy is developed and a distributed genetic algorithm is used to solve the task planning problem; finally, by creating multiple sets of simulation examples, the correctness of the model solution and the efficiency of the algorithm solution are verified and evaluated.

This paper’s remaining sections are structured as follows: In problem formulation section, we present the problem, related constraints, and optimization objectives; then we introduce the distributed genetic algorithm to solve the proposed problem; in performance evaluations and discussions section, we present simulation results to analyze the effectiveness of the proposed algorithm; eventually, we draw conclusions.

Problem formulation

By discretizing the flight heading angle of UAVs, an integration model of multi-UAV task assignment/path planning is constructed, with the UAV dynamics model being equivalent to the three-dimensional Dubins model, and the task timing restrictions and the heterogeneous characteristics of UAVs being taken into account.

Tasks and UAVs for missions

There is a rescue area set \({\varvec{T}}=\{ {T_1},{T_2},...,{T_{{N_T}}}\}\) that is made up of \({N_T}\) different rescue areas, as well as a UAV set \({\varvec{U}}=\{ U_{1}^{k},U_{2}^{k},...,U_{{{N_U}}}^{k}\}\) that is made up of \({N_U}\) heterogeneous UAVs, which \(k=1\) signifies the type of UAV with both reconnaissance payload and rescue payload, \(k=2\) signifies the type of UAV only with reconnaissance payload, and \(k=3\) signifies the type of UAV only with rescue payload. A UAV with reconnaissance payload can perform reconnaissance and verification tasks.

Each rescue zone requires the completion of multiple sets of tasks (each denoted by \({{\varvec{M}}_T} \subseteq {\varvec{M}}=\left\{ {C,R,V} \right\}\)), styled as reconnaissance (signified by C), rescue (signified by R), and verification (signified by V). For any given rescue region, there is a \({N_c}\)-task execution sequence that must be followed, with the reconnaissance task needing to be finished before the rescue task and the verify task needing to be carried out only after the rescue task has been finished. The total number of required tasks is:

$${N_{total}}=\sum\limits_{{T=1}}^{{{N_T}}} {{N_{{M_T}}}}$$
(1)

where \({N_{{M_T}}}\) represents the total number of tasks to be executed on the rescue area \({{\varvec{M}}_T}\).

UAV kinematics model

Considering the UAV as a mass, the motion model of the UAV is established as follows:

$$\left\{ \begin{gathered} \frac{{dx}}{{dt}}=V\cos \psi \cos \gamma \hfill \\ \frac{{dy}}{{dt}}=V\sin \psi \cos \gamma \hfill \\ \frac{{dz}}{{dt}}= - V\sin \gamma \hfill \\ \end{gathered} \right.$$
(2)

.

where \({(x,y,z)^T}\) represents the location of UAV; V, \(\psi\),\(\gamma\) represent the velocity magnitude, the path deflection angle and the path inclination angle, respectively.

If g represents the gravitational acceleration, the relationship between the track angular rate \(\dot {\psi }\) and the roll angle \(\phi\) is:

$$\dot {\psi }=\frac{g}{V}\tan \phi$$
(3)

During flight, the maximum values of the track angle and roll angle are constrained by the UAV’s own physical performance limitations, which are depicted as follow.

$$\left\{ \begin{gathered} \left| \phi \right| \leqslant {\phi _{\hbox{max} }} \hfill \\ \left| \gamma \right| \leqslant {\gamma _{\hbox{max} }} \hfill \\ \end{gathered} \right.$$
(4)

.

where \({\phi _{\hbox{max} }}\) and \({\gamma _{\hbox{max} }}\) represent maximum allowable roll angle and track angle, respectively.

Three-Dimensional dubins path

Let’s say that \(({x_s},{y_s},{z_s},{\psi _s})\) and \(({x_e},{y_e},{z_e},{\psi _e})\) represent the beginning and ending pose points of the UAV’s three-dimensional path, respectively, and that \(\left\{ {{x_s},{y_s},{z_s}} \right\}\) and \(\left\{ {{x_e},{y_e},{z_e}} \right\}\)represent the position of the UAV within the inertial system, and \({\psi _s}\) and \({\psi _e}\) represent the UAV’s path deflection angle.

Let \({R_{\hbox{min} }}\) be the minimum turning radius of the UAV, then

$${R_{\hbox{min} }}=\frac{{{V^2}}}{{g\tan {\phi _{\hbox{max} }}}}$$
(5)

.

With the UAV’s minimum turning radius \({R_{\hbox{min} }}\), the length of the two-dimensional Dubins curve between the start and finish pose positions can be calculated based on the research of Dubins L. E25. The three-dimensional Dubins curve is classified into three types based on the altitude difference between the starting and ending positions of the UAV, the length of the two-dimensional Dubins curve, and the maximum track angle constraints. These are low-altitude type, hollow type, and high-altitude type.

The low-altitude type

When the flight height between the start and end pose points satisfies:

$$\left| {{z_e} - {z_s}} \right| \leqslant {L_{2D}}({R_{\hbox{min} }})\tan {\gamma _{\hbox{max} }}$$
(6)

.

it is currently a low-altitude kind, where \({L_{2D}}({R_{\hbox{min} }})\) represents the length of the two-dimensional Dubins curve between two points when the minimum radius is taken. The maximum altitude gain of the UAV flying along the two-dimensional Dubins curve in the horizontal plane at the maximum track angle is the right term of the inequality.

Fig. 1
figure 1

Three-dimensional Dubins curve in the low-altitude type.

In the low-altitude type, the altitude gain of the UAV flying along the two-dimensional Dubins curve is equal to the height difference between the start and end pose points, and the flight route of the UAV may be obtained by modifying the flight path angle of the UAV, as shown in Fig. 1. The angle is:

$${\gamma ^ * }={\tan ^{ - 1}}(\frac{{\left| {{z_e} - {z_s}} \right|}}{{{L_{2D}}({R_{\hbox{min} }})}})$$
(7)

.

Currently, the distance between the drone’s initial and final pose positions along the three-dimensional Dubins curve is:

$${L_{3D}}({R_{\hbox{min} }},{\gamma ^ * })=\frac{{{L_{2D}}({R_{\hbox{min} }})}}{{\cos {\gamma ^ * }}}$$
(8)

.

The medium-altitude type

When the flight height between the start and end pose points satisfies:

$${L_{2D}}({R_{\hbox{min} }})\tan {\gamma _{\hbox{max} }}<\left| {{z_e} - {z_s}} \right| \leqslant \left[ {{L_{2D}}({R_{\hbox{min} }})+2\pi {R_{\hbox{min} }}} \right]\tan {\gamma _{\hbox{max} }}$$
(9)

.

Currently, the type is hollow and the Eq. (9)’s right-hand term represents the altitude increase that corresponds to the UAV traversing a two-dimensional Dubins curve and a full arc with a radius of \({R_{\hbox{min} }}\) in the horizontal plane at the maximum track angle.

Within this particular airspace, the vertical ascent of the UAV cannot be achieved by traversing the length of the two-dimensional Dubins curve, due to the imposed limitation on the maximum track angle. Thus, to augment the incremental increase in altitude, the UAV must execute supplementary maneuvers. In cases where the altitude of the drone’s initial location is lower than that of its final destination, supplementary maneuvers are incorporated at the point of departure. In cases where the initial elevation surpasses that of the final elevation, supplementary maneuvers are incorporated at the terminal point.

Fig. 2
figure 2

Three-dimensional Dubins curve in the medium-altitude type.

Figure 2 illustrates the coordinates associated with the UAV’s three-dimensional Dubins curve, where \(pos=(x,y,\psi )\) represents the coordinates of the UAV in the horizontal plane, \(C=(x,y)\) denotes the center of the circle where the UAV turns in the horizontal plane, and \(po{s_s}\) and \(po{s_e}\) indicate the starting and ending pose points of the UAV. Additionally, \({C_s}\) and \({C_e}\) correspond to the centre of the circle that corresponds to the UAV’s turning arc. The UAV’s supplementary manoeuvring action commences at point \(po{s_i}\), with point \({C_i}\) serving as the corresponding centre of the circle. The angle \(\varphi\) corresponds to the UAV’s flight from point \(po{s_s}\) to \(po{s_i}\), with the smallest possible turn, then:

$$po{s_i}={C_s}+R({\varphi ^ * })(po{s_s} - {C_s})$$
(10)

.

where \(R({\varphi ^ * })\) represents the rotation matrix with angle \({\varphi ^ * }\).

Currently, the aggregate length of the two-dimensional Dubins curve is the summation of the length pertaining to the journey from point \(po{s_s}\) to point \(po{s_i}\) and the length of the two-dimensional Dubins curve from point \(po{s_i}\) to point \(po{s_e}\).

$${L_{2D}}({\varphi ^ * })={\varphi ^ * }{R_{\hbox{min} }}+{L_{2D}}(po{s_i},po{s_e})$$
(11)

.

Now, the dichotomy method is utilized to determine the rotation angle \({\varphi ^ * }\) of the turning arc by calculating the height gain equivalent to the height difference between the initial and final attitude points.

$${L_{2D}}({\varphi ^ * })=\frac{{\left| {{z_e} - {z_s}} \right|}}{{\tan {\gamma _{\hbox{max} }}}}$$
(12)

.

The calculation of the overall length of the Dubins path in three dimensions can be derived as follows:

$${L_{3D}}({\gamma _{\hbox{max} }},{\varphi ^ * })=\frac{{{L_{2D}}({\varphi ^ * })}}{{\cos ({\gamma _{\hbox{max} }})}}$$
(13)

.

The high-altitude type

When the vertical distance between the initial and final position points meets the condition:

$$\left| {{z_e} - {z_s}} \right|>\left[ {{L_{2D}}({R_{\hbox{min} }})+2\pi {R_{\hbox{min} }}} \right]\tan {\gamma _{\hbox{max} }}$$
(14)

.

it is classified as a high-altitude variety. The present scenario entails an altitude differential that surpasses the altitude increment produced by the unmanned aerial vehicle’s execution of a two-dimensional Dubins curve at the highest attainable track inclination, between the initial and final positions. The increase in altitude gain of a drone can be achieved through the implementation of a helix at either the initial or terminal position, coupled with an alteration in the drone’s turning radius. In cases where the starting height is lower than the final height, it is recommended to incorporate a helix at the starting point, as demonstrated in Fig. 3. Similarly, if the initial position point exceeds the end pose point, it is advisable to include a helix at the end position.

Fig. 3
figure 3

Three-dimensional Dubins curve in the high-altitude type.

Let k denote the smallest possible number of rotations of the helix, then:

$$\left[ {{L_{2D}}({R_{\hbox{min} }})+2\pi k{R_{\hbox{min} }}} \right]\tan {\gamma _{\hbox{max} }} \leqslant \left| {{z_e} - {z_s}} \right|<\left[ {{L_{2D}}({R_{\hbox{min} }})+2\pi (k+1){R_{\hbox{min} }}} \right]\tan {\gamma _{\hbox{max} }}$$
(15)

Therefore, \(k=\left\lfloor {\frac{1}{{2\pi {R_{\hbox{min} }}}}(\frac{{\left| {{z_e} - {z_s}} \right|}}{{\tan {\gamma _{\hbox{max} }}}}) - {L_{2D}}({R_{\hbox{min} }})} \right\rfloor\).

The above formula involves determining the maximum integer value of \(\left\lfloor x \right\rfloor\) that is not surpassing x. Subsequently, by precisely adjusting the turning radius \({R^ * }\) to ensure that the increase in height is equivalent to the disparity in height between the initial and final positions, the desired outcome can be achieved as:

$$\left[ {{L_{2D}}({R_{\hbox{min} }})+2\pi k{R^ * }} \right]\tan {\gamma _{\hbox{max} }}=\left| {{z_e} - {z_s}} \right|$$
(16)

The solution \({R^ * }\) for the given Eq. (16) can be obtained through the dichotomy method. Currently, the minimum length of a three-dimensional Dubins curve is:

$${L_{3D}}({R^ * },{\gamma _{\hbox{max} }})=\frac{{{L_{2D}}({R^ * })}}{{\cos {\gamma _{\hbox{max} }}}}$$
(17)

.

Modelling for distributed task assignment

The objective is to discretize the heading angle of a UAV and develop an integrated solution framework for task assignment and track planning using graph theory. The depicted nodes in the graph denote the spatial coordinates of both the UAV and the designated target location. The interconnecting lines between the nodes signify the trajectory of the UAV as it traverses from one target point to another, which is produced by the three-dimensional Dubins curve of the track planning module.

The heading discretization is defined as:

$${\varvec{H}}=\left\{ {{\psi _i}:{\psi _i}=2\pi i/{N_\psi },i=1,...,{N_\psi }} \right\}$$
(18)

.

Where \({N_\psi }\) denotes the level of discretization of the heading angle.

A model for the integrated solution of UAV task assignment/track planning is developed by discretizing the heading angle of the UAV. Figure 4 presents a graphical representation of a task allocation model that encompasses three UAVs and two designated targets.

Fig. 4
figure 4

Graph model of Multi-UAVs task assignment.

The illustration depicted in Fig. 4 denotes that the nodes with numerical labels 1, 2, and 3 correspond to UAVs, while nodes with numerical labels 4 and 5 correspond to the nodes designated as targets. Each target node requires the completion of multiple tasks, and the connection between nodes signifies the associated relationship monitoring the expenses incurred during UAV flights. The decision variable is denoted by \(x_{{(m,{\psi _i}),(n,{\psi _j})}}^{{v,a}}\), while the track cost variable is represented by \(\omega _{{(m,{\psi _i}),(n,{\psi _j})}}^{{v,a}}\). The UAV number is indicated by the superscript v in the decision and track cost variable. a is used to denote the task type, m represents the corresponding number of nodes in the graph, n represents the specific target node in the graph. \(\psi\) denotes the heading angle of the UAV; a serves as an indicator of the task type to be executed. Specifically, the values of a are assigned as 1, 2, and 3, corresponding to reconnaissance, rescue, and evaluation tasks, respectively.

The value of \(x_{{(m,{\psi _i}),(n,{\psi _j})}}^{{v,a}}\) being equal to 1 indicates that the UAV denoted by v is in transit from node m to node n, with an angle of \({\psi _i}\) being maintained during the flight. Additionally, the heading angle towards node n is represented by \({\psi _j}\). Conversely, when \(x_{{(m,{\psi _i}),(n,{\psi _j})}}^{{v,a}}\) is equal to 0, it signifies that the UAV v is not currently in flight. The variable \(\omega _{{(m,{\psi _i}),(n,{\psi _j})}}^{{v,a}}\) denotes the expenses accrued during the transfer of UAV v.

The mathematical model for mission allocation and track planning is established through the utilisation of the multi-UAV mission planning graph model. This model encompasses the mathematical representation of cost functions and mission constraints. There exists a multitude of cost functions that may serve as metrics for task assignment fulfillment. The present study employs the aggregate distance traversed by UAV as a metric for assessing task planning efficacy as follows:

$$J=\sum\limits_{{a=1}}^{3} {\sum\limits_{{v=1}}^{{{N_U}}} {\sum\limits_{{m=1}}^{{{N_T}+{N_U}}} {\sum\limits_{{n=1}}^{{{N_T}}} {\sum\limits_{{i=1}}^{{{N_\psi }}} {\sum\limits_{{j=1}}^{{{N_\psi }}} {x_{{(m,{\omega _i}),(n,{\omega _j})}}^{{v,a}}} } } } } } \omega _{{(m,{\omega _i}),(n,{\omega _j})}}^{{v,a}}$$
(19)

.

Furthermore, it is imperative to satisfy five significant constraints simultaneously, as these constraints impact both the feasibility of task allocation and the integrity of the task.

The task constraints

The primary requirement that must be fulfilled is that the UAVs must successfully accomplish all designated tasks.

$$\sum\limits_{{a=1}}^{3} {\sum\limits_{{v=1}}^{{{N_U}}} {\sum\limits_{{m=1}}^{{{N_T}+{N_U}}} {\sum\limits_{{n=1}}^{{{N_T}}} {\sum\limits_{{i=1}}^{{{N_\psi }}} {\sum\limits_{{j=1}}^{{{N_\psi }}} {x_{{(m,{\omega _i}),(n,{\omega _j})}}^{{v,a}}} } } } } } ={N_c}$$
(20)

.

The task uniqueness constraints

The second limitation pertains to the fact that each task is restricted to a single execution.

$$\begin{gathered} \sum\limits_{{v=1}}^{{{N_U}}} {\sum\limits_{{m=1}}^{{{N_T}+{N_U}}} {\sum\limits_{{i=1}}^{{{N_\psi }}} {\sum\limits_{{j=1}}^{{{N_\psi }}} {x_{{(m,{\omega _i}),(n,{\omega _j})}}^{{v,a}}} } =1,} } \hfill \\ n=1,...,{N_T},a=1,2,3 \hfill \\ \end{gathered}$$
(21)

.

The range constraints

The total range of each UAV for its own missions cannot exceed the maximum range.

$$\begin{array}{*{20}{c}} {\sum\limits_{{a=1}}^{3} {\sum\limits_{{m=1}}^{{{N_T}+{N_U}}} {\sum\limits_{{n=1}}^{{{N_T}}} {\sum\limits_{{i=1}}^{{{N_\psi }}} {\sum\limits_{{j=1}}^{{{N_\psi }}} {x_{{(m,{\omega _i}),(n,{\omega _j})}}^{{v,a}}} } } } \omega _{{(m,{\omega _i}),(n,{\omega _j})}}^{{v,a}}} \leqslant L_{{\hbox{max} }}^{v}}&{v=1,2,3} \end{array}$$
(22)

.

The collision avoidance constraint

The distance between any two UAVs cannot be less than the safety distance, let a certain moment be \(\tau\), according to the collision avoidance constraint there are:

$$\begin{array}{*{20}{c}} {\left\| {{{\text{p}}_i}\left( \tau \right) - {{\text{p}}_j}\left( \tau \right)} \right\| \geqslant {d_{safe}}}&{i \ne j} \end{array}$$
(23)

.

The timing constraints for task execution

The temporal sequencing of task objectives on the designated target set must adhere to timing constraints. For instance, the reconnaissance task must not precede the rescue task, and the evaluation task must not precede the rescue task. Let \(t_{n}^{k}\) denote the moment at which task k is executed at target n. Here, k can take on values of 1, 2, and 3, which correspond to reconnaissance, rescue, and evaluation tasks, respectively. Additionally, \(n=1,2,...,{N_T}\) represents the target node. In accordance with the limitations imposed by time:

$$t_{n}^{1} \leqslant t_{n}^{2} \leqslant t_{n}^{3}$$
(24)

Methodology

Considering that the problem in the paper has computational complexity and coupling characteristics, we use the distributed genetic algorithm with the elite model as an efficient solution method. The genetic algorithm with elite model is characterized by global convergence and good applicability, please refer to the literature26 for the proof of convergence. And we extend the algorithm to a distributed parallel architecture to improve the efficiency of task allocation23.

Process of the distributed genetic algorithm

The primary distinction between the distributed genetic algorithm and the fundamental genetic algorithm pertains to the modification of the elite operator. Figure 5 depicts the flowchart of the distributed genetic algorithm. During the operation of the algorithm, each UAV executes the fundamental genetic algorithm autonomously to accomplish the corresponding fitness evaluation, selection, crossover, mutation, and elite selection. In comparison to the fundamental genetic algorithm, the elite operator in the distributed genetic algorithm experiences the subsequent modifications: UAVs transmit progeny elites to fellow UAVs, while simultaneously receiving progeny elites from them. The proposed approach involves evaluating the fitness of elite individuals and selecting the one with the highest fitness. This process is carried out independently by each UAV to retain the most fit elite operator. Iterate the aforementioned procedure until the solution that yields the best outcome remains constant. The algorithm’s distributed computing capability allows it to operate autonomously on multiple computers concurrently, resulting in enhanced computational efficiency.

Fig. 5
figure 5

Flow chart of distributed genetic algorithm.

Genetic coding and deadlock coordination

Coding

The fundamental element of the genetic algorithm is the genetic code. By means of coding, the problem’s solution space is projected onto the coding space, and the task assignment problem is resolved via the genetic algorithm.

Fig. 6
figure 6

Gene coding.

Figure 6 presented in the study illustrates that every gene is comprised of four gene fragments, namely the target number gene slice, task type gene slice, track angle gene slice of the arrival task, and UAV number gene slice. It is important to note that all genes are arranged in a specific order. The arrangement of genes on a chromosome determines the sequence in which a drone carries out its objectives. Thus far, a chromosome can be understood as a comprehensive allocation of responsibilities.

The diagram depicted in Fig. 6 illustrates a UAV code that encompasses a pair of UAVs, a duo of designated targets, and a total of four distinct missions. The present discourse pertains to the explication of the information encoded within the chromosome. UAV \({U_1}\) initiates its mission by commencing from its initial position and subsequently executing a rescue operation on target \({T_1}\), while approaching at an angle \(\psi ={40^ \circ }\). Following this, it proceeds to undertake a reconnaissance operation on target \({T_2}\), while approaching at an angle \(\psi ={90^ \circ }\). Similarly, UAV \({U_2}\) performs a rescue operation with an approaching angle \(\psi ={140^ \circ }\) on its designated target \({T_2}\), and subsequently undertakes a reconnaissance operation on target \({T_1}\), while approaching at an angle \(\psi ={100^ \circ }\).

Deadlock

The issue of deadlock is prevalent in heterogeneous systems that have timing constraints, as indicated in reference15. Graph theory is utilized to provide an explanation for the deadlock problem.

The task timing priority graph can be defined as follows: \(T=(V,E)\) denotes the graph itself, while V represents the set of nodes that are comprised of genes within the chromosome. \(E=\left\{ {\left. {(u,v)} \right|u \gg v,\forall u,v \in V} \right\}\) denotes the directed edge that is composed of nodes. Lastly, \("\gg"\) indicates that the UAVs are adjacent to each other in the task performed, or the task itself has a relationship of timing constraints. If a deadlock problem exists in task assignment, then the task timing priority graph \(T=(V,E)\) must contain a cycle. For the proof of this definition, please refer to the reference17.

Fig. 7
figure 7

Cycle state of the precedence task graph.

The illustration depicted in Fig. 7 exemplifies a task assignment scenario that encounters a deadlock issue. In this context, each gene is representative of a node within the graph, and the collection of nodes within the graph is denoted as \(V=\left\{ {1,2,3,4} \right\}\). A task execution subgraph and a task constraint subgraph are formed based on the order in which Unmanned Aerial Vehicles (UAVs) carry out tasks and the timing constraint relationship between said tasks. An edge is formed by two nodes that are adjacent in the subgraph. The diagram depicted in Fig. 7 displays a collection of edges \(E=\left\{ {{e_{12}},{e_{34}},{e_{41}},{e_{23}}} \right\}\) that are comprised solely of nodes. At present, the task sequence priority diagram exhibits a loop, indicating the presence of a deadlock in the current task allocation scheme.

To avoid the transmission of chromosomal genes with deadlock issues to the next generation, the parent generation’s chromosomes undergo deadlock detection. The loops present in the task timing priority graph can be searched by the depth-first algorithm (DFS)27, and then any chromosomes with deadlock problems can be removed.

The computational complexity of DFS-based deadlock detection merits detailed analysis. For a chromosome containing N tasks, the temporal constraint graph contains \(V=N\)nodes and \(E \leqslant N\left( {N - 1} \right)\) directed edges in worst-case scenarios. Our DFS implementation achieves \(O\left( {V+E} \right)\) time complexity through adjacency list representation and visited node marking. In this study, each task and drone starting point is considered a node, so the total number of nodes is \(V=3 \times {N_T}+{N_u}\). The three tasks for each goal must be executed sequentially, and the length of the task chain for each drone is related to the number of goals, which is assumed to be on average k. Therefore, the total number of edges is \(E=2 \times {N_T}+k \times {N_u}\). The final algorithmic complexity for the DFS is \(O\left( {{N_T}+k \times {N_u}} \right)\), which exhibits linear scalability with respect to the number of drones and the number of tasks.

Coordination path

In instances where the UAV adheres to the designated task order, the execution of a subsequent task with greater priority is precluded, necessitating the UAV to remain in a holding pattern until the arrival of additional UAVs. During the operation, the UAV employs the minimum turning radius. In order to execute a fixed-altitude cruise, the drone’s flight path is considered a closed loop, and it is imperative that the entire flight cycle is carried out once initiated. Let \({t_{\text{a}\text{r}\text{r}}}\) denote the point in time at which the drone reaches the designated location, and let \({t_{\text{p}\text{r}\text{i}\text{o}\text{r}}}\) represent the moment at which the preceding task pertaining to the current target is completed. By means of computation, the duration required for the UAV to execute the present assignment can be ascertained as follows:

$${t_\text{m}}={t_{\text{a}\text{r}\text{r}}}+{n_{\text{c}\text{i}\text{r}\text{c}\text{l}\text{e}}}{t_{\text{c}\text{i}\text{r}\text{c}\text{l}\text{e}}}$$
(25)
$${n_{\text{c}\text{i}\text{r}\text{c}\text{l}\text{e}}}=\left\lceil {\frac{{{t_{\text{p}\text{r}\text{i}\text{o}\text{r}}} - {t_{\text{a}\text{r}\text{r}}}}}{{{t_{\text{c}\text{i}\text{r}\text{c}\text{l}\text{e}}}}}} \right\rceil$$
(26)
$${t_{\text{c}\text{i}\text{r}\text{c}\text{l}\text{e}}}=\frac{{2\pi {r_{\hbox{min} }}}}{V}$$
(27)

.

where \(\left\lceil a \right\rceil\) denotes the minimum integer value that is greater than a.

Fitness function

The fitness function that has been chosen is:

$$J=\frac{b}{L}$$
(28)

.

where L represents the cumulative length of all UAVs’ flight paths, while b denotes a fixed value utilised to modify the fitness metric.

The process of elitism employs a roulette mechanism to determine the parent individuals that will generate the subsequent generation. The likelihood of a parent individual being chosen is directly proportional to its fitness value relative to the total fitness value of the parent population. Given a probability of \({P_i}\) for the selection of parent individual i, then

$${P_i}={J_i}/\sum\limits_{{i=1}}^{N} {{J_i}}$$
(29)

where \({J_i}\) represents the fitness value of the i-th individual within the population. The process of generating parent individuals in roulette can be achieved through the utilisation of random numbers.

Genetic operator

Crossover operator

The rationale behind the utilisation of the crossover operator is that it facilitates the inheritance of genetic material from both parents by the offspring, thereby enabling the offspring to benefit from the advantageous traits of both parents. The present study employs the single-point crossover technique for the purpose of generating offspring chromosomes.

The crossover operator involves the random selection of a crossover point s from \([1,W]\), followed by the copying of the first \(s - 1\) genes of parent A onto the offspring’s chromosome. To maintain the integrity constraints of the execution task, the chromosome of the offspring is first populated with a copy of the gene sheet containing the target number and target type gene sheet located at the \([s,W]\) gene position of parent generation A. Subsequently, the gene sheet containing the same target number and target type gene sheet from parent generation B is also copied onto the offspring’s chromosome. The genetic material encoding the traits specified by the gene sheet is replicated and transmitted to the appropriate locus in the progeny.

Figure 8 depicts an instance of a crossover operation. The point of intersection between two or more variables occurs at a value of 3. The gene located at node \([1,3]\) in the parent A is transmitted to the offspring along with the target number gene segment and target type gene segment located at position 4. These genetic elements are subsequently identified in the parent B. The gene containing gene segment \({T_1}\) as the target number and gene segment V as the target type is situated at the first position of chromosome 1 in the parental generation B. Upon completion of the parental generation’s individual crossover operation, this gene is transmitted to the offspring.

Fig. 8
figure 8

Crossover operator.

Mutation operator

Mutation is a genetic operation that alters the genes within a chromosome, resulting in increased diversity among individuals within a given population. This process facilitates the algorithm’s ability to escape local minimums, ultimately enhancing the likelihood of discovering the global optimal solution.

There exist three primary categories of chromosomal variation.

1) Heading Angle Variation: Introduce random variations in the heading angle at which the UAV reaches its designated target.

2) UAV mutation: Under the constraint of ensuring the ability of UAVs to perform tasks, randomly change the UAVs performing tasks at the corresponding target.

Genetic variation in task performance sequencing among UAVs

Figure 9 illustrates various instances of basic mutations. To enhance chromosomal diversity and augment the likelihood of the algorithm escaping the local minimum, one of the three mutations is chosen at random during the execution of the mutation operator.

Fig. 9
figure 9

Mutation operator.

Elite operator

The UAVs involved in the mission exhibit a recognition of the coherence of planning outcomes through the exchange of offspring elites. During the operation of the algorithm, the UAV transmits the parent elites to other UAVs and simultaneously receives the parent elites of other UAVs. The UAV retains the elite with the highest fitness value to the parent population and proceeds to the subsequent cycle of the genetic algorithm.

Performance evaluations and discussions

This section presents a validation of the proposed method through simulation experiments in a typical task scenario. The distributed genetic algorithm’s efficiency is compared with the basic genetic algorithm to evaluate its performance in solving the task scenario. Furthermore, to demonstrate the optimality of the integrated solution method, a comparison is made with the “decoupling” method, and multiple sets of simulation experiments are conducted. The hardware environment utilised for the simulation comprises an AMD R5 5600 H processor and 16G memory, while the software environment employed is matlab 2020b.

Sample run test

Tables 1 and 2 present the space designated for mission planning. The safety distance for UAVs is taken as 100 m. The present simulation entails the deployment of five UAVs and four designated targets. Each target must undergo three consecutive tasks, which consist of reconnaissance, rescue, and evaluation. The aggregate quantity of assignments is twelve. All unmanned aerial vehicles collaborate to accomplish all assigned objectives across all designated locations. The distributed genetic algorithm was employed to address the challenge of task allocation and track planning in a comprehensive approach. Table 3 displays the design of the algorithm parameter. In the table, \({p_m}\) denotes the probability of mutation, \({p_c}\) denotes the probability of crossover, and \({N_a}\) represents the algebra of population genetics. The algorithm’s optimisation objective is to minimise the total track length of the UAV. Each UAV involved in the mission operates the fundamental genetic algorithm autonomously. The UAVs then communicate with one another via the elite operator to ensure the uniformity of planning outcomes.

Table 1 Parameters of UAV.
Table 2 Parameters of target.
Table 3 Parameters of distributed genetic algorithm.

The findings of the simulation are illustrated in Figs. 10 and 11. The Gantt chart depicting the duration of task execution is presented in Fig. 10. The depicted figure illustrates a square that denotes the task target point, while \({T_1}\sim {T_4}\) symbolises the corresponding task target point. In the given table, the horizontal axis denotes the duration of task execution, while the vertical axis represents another variable. The three task execution types, namely 1, 2, and 3, correspond to reconnaissance, rescue, and assessment tasks, respectively. The Gantt chart displays the temporal sequence of UAV task execution at designated target points, with \({T_1}\sim {T_4}\) denoting the respective positions of each task. Based on the simulation, it can be inferred that the planning outcome successfully meets the timing limitations among the tasks.

Fig. 10
figure 10

Gantt chart of task execution time.

Fig. 11
figure 11

Trajectory of UAVs.

Figure 11 displays the UAV flight track acquired through the integrated solution. The diagram depicts the initial location of the UAV denoted by a five-pointed star. The UAVs are labelled \({U_1}\sim {U_5}\), and the target points are represented by circles, labelled \({T_1}\sim {T_4}\). The UAV commences its mission by departing from its designated point of origin and traversing along the predetermined trajectory towards the specified target location in order to fulfil its assigned objective. According to the simulation results, the tasks performed by the UAV on each rescue zone target satisfy the requirements of the execution order and the capability constraints of the UAV. For example, UAV \({U_4}\) performs a reconnaissance mission on target \({T_2}\) before performing an attack mission on target point \({T_1}\) as a way to wait for \({U_3}\) to perform a reconnaissance mission on \({T_1}\), and UAV \({U_2}\) performs a verification mission after UAV \({U_4}\) completes the attack mission. The total length of the trajectory of all UAV flights was 38.22 km.

The paper proposes an integrated solution method for task assignment and track planning that can obtain the task decision matrix of multiple UAVs while considering the constraints of heterogeneous UAV execution platforms, task timing non-deadlock constraints, and UAV tracks. The simulation results support the effectiveness of this approach.

Algorithm efficiency comparison

A comparative analysis is conducted between the distributed genetic algorithm and the basic genetic algorithm to examine their respective characteristics. The algorithm’s task planning space is in accordance with the aforementioned. Please refer to Tables 1 and 2. The size of the population in the fundamental genetic algorithm has been established as 1000, along with other parameters of the algorithm. In accordance with the principles of the Distributed Genetic Algorithm, the algorithm’s assessment metric was provided:

$${Q_{algo}}=\frac{{{J_{\text{e}\text{l}\text{i}\text{t}\text{e}}}(1)}}{{{J_{\text{e}\text{l}\text{i}\text{t}\text{e}}}(i)}}$$
(28)

.

where \({J_{\text{e}\text{l}\text{i}\text{t}\text{e}}}(i)\) denotes the fitness value of the i-th generation elite of the population.

The comparison of simulation results with those obtained from the distributed genetic algorithm is presented in Fig. 12. The horizontal axis represents the genetic algebra of the population, while the vertical axis represents the evaluation value of the algorithm. Based on the simulation outcomes, the distributed genetic algorithm achieves convergence at around 96 generations, whereas the basic genetic algorithm reaches convergence at around 160 generations. Thus, in contrast to the fundamental genetic algorithm, the distributed genetic algorithm has the capability to enhance task allocation efficiency significantly.

Fig. 12
figure 12

Comparison results of algorithm evaluation values.

Parameter sensitivity analysis

To evaluate the sensitivity of the distributed genetic algorithm to key parameters, we conduct a series of experiments to analyze the impact of crossover rate and mutation rate on convergence speed and solution quality. The experimental scenario uses the mission parameter from Sect. 4.1 with fixed population size and maximum generations.

 Crossover rate analysis

We test four crossover rates (\({P_c}=\)0.4, 0.6, 0.8, 1.0) while maintaining \({P_m}=\)0.5. Figure 13 shows the convergence curves with different \({P_c}\) values.

Fig. 13
figure 13

Convergence curves at different \({P_c}\) values.

Lower crossover rate (\({P_c}=\)0.4) leads to premature convergence and tends to fall into local optimal solutions. The final path length will be longer due to reduced population diversity. Higher crossover rates (\({P_c}=\)0.8, 1.0) lead to excessive population diversity because of frequent gene makes, and the search process is close to random, resulting in poorer convergence stability. At the same time, it does not get much better results than the moderate crossover rate (\({P_c}=\)0.6). Moderate crossover rate achieves the optimal balance between exploration and exploitation, and reaches stable convergence at generation 91.

Mutation rate analysis

The mutation rate sensitivity analysis was conducted with a fixed crossover rate (\({P_c}=\)0.6), testing \({P_m}\) values of 0.3, 0.5, and 0.7.

Fig. 14
figure 14

Convergence curves at different \({P_m}\) values.

As shown in Fig. 14, all curves exhibit rapid convergence during the initial 40 generations, followed by distinct stabilization patterns. At \({P_m}=\)0.3, the algorithm achieves rapid initial Q-value reduction but stagnates prematurely due to insufficient diversity, aligning with the theoretical risk of local optima entrapment. Higher mutation rate(\({P_m}=\)0.7) generates excessive randomness, resulting in the worst final Q-value as high mutation disrupts stable gene structures. At \({P_m}=\)0.5, the case demonstrates sustained optimization: although slower in early generations, it gradually attains the lowest Q-value through controlled exploration, validating moderate mutation’s efficacy in complex search landscapes.

Comparison case

The problem of task assignment and trajectory planning is approached through a decoupled approach, wherein a progressive solution strategy is employed to address the decision matrix for task assignment and the flight path of the UAV separately. The algorithm’s resolution of the task planning domain is congruent with the preceding section. The task allocation decision matrix is solved through the utilisation of the distributed genetic algorithm. Table 3 displays the design parameters utilised in the distributed genetic algorithm. The utilisation of the Euler distance within three-dimensional space serves as a means of task allocation. As per the task assignment decision matrix derived from the task assignment layer, the trajectory of the UAV is resolved using the three-dimensional Dubins curve. The cumulative length of the trajectory of all UAVs is 49.62 km, and the results of the distribution of tasks are shown in Table 4. Upon comparison with the simulation outcomes derived from the integrated approach of task allocation/track planning utilising distributed genetic algorithm, as presented in the preceding section, it is evident that the computed track exhibits a 29.83% increase in size.

Table 4 Task assignment results of \(N=5,M=4\).

Expand the scope of the mission planning domain to encompass a fleet of ten unmanned aerial vehicles and eight designated targets. The location and classification of the UAV, as well as the location of the target, are generated in a random manner as \(x \in [0,8000]\), \(y \in [0,8000]\), \(z \in [1000,1500]\). The tasks at each target point comprise reconnaissance, rescue, and evaluation tasks. The design parameters of the distributed genetic algorithm have been presented in Table 3. The results of the task assignment were obtained using the task assignment/track planning integrated solution and progressive solution, and are presented in Table 5. The track length acquired through the integrated solution of task assignment and track planning is 75.89 km, while the track length obtained through the progressive solution of task assignment and track planning is 105.93 km. The optimised solution’s simulation results indicate that the track length obtained through task assignment/track planning using the progressive solution is 39.58% greater.

Table 5 Task assignment result of \(N=10,M=8\).

The decoupling approach towards task assignment and track planning fails to account for the influence of the track layer on the task assignment layer. This leads to inaccuracies in the estimation of the UAV track by the task assignment layer, ultimately resulting in suboptimal task assignment outcomes. As the size of the planning space expands, the interdependence between mission planning and trajectory planning becomes increasingly intricate. This complexity results in a greater degree of deviation between the trajectory estimation of the task allocation layer and the actual situation. Consequently, the integration of task assignment and track planning can enhance solution optimality by accounting for the interdependence between task assignment and track planning.

Conclusions

The establishment of an integrated solution framework for UAV task assignment/track planning is achieved through the discretization of the heading angle of the UAV. Additionally, a distributed genetic algorithm is developed to address the problem. The findings of the task planning problem are validated through several simulation experiments. The conclusions of the study are as follows:

  1. 1)

    This paper presents an algorithm that can obtain the decision matrix for UAV task assignment and the UAV flight track simultaneously, while satisfying the constraints of the UAV execution platform and timing. Compared with the basic genetic algorithm, the distributed genetic algorithm has a faster convergence speed and effectively improves the efficiency of task planning.

  2. 2)

    The progressive solution strategy of task allocation/track planning may yield suboptimal results due to the neglect of coupling characteristics between task allocation and track planning. As the task planning space expands, the coupling relationship between task assignment and track planning will become more complex. In this case, the planning results obtained by the progressive solution strategy of task assignment/track planning have worse planning quality compared to the integration of task assignment/track planning. The paper proposes a comprehensive solution method considering the coupling of task allocation/track planning. This approach significantly improves the optimality of the solution.

This study comprehensively examines the interdependent features of task allocation and track planning and devises a solution that integrates the task planning problem. Methodology employs a distributed genetic algorithm to enhance computational efficiency while optimising the solution. The approach exhibits favourable suitability for task-oriented scenarios.

Future research will extend the proposed framework to address practical challenges such as initial condition disturbances and environmental uncertainties. While current research assumes deterministic scenarios to focus on the core coupling issues between task assignment and track planning, these uncertainties have important implications for the actual deployment of UAVs. Advanced robust optimization techniques and real-time adaptation mechanisms will be explored to enhance the robustness of the integrated solution.