Dynamic threat adaptive unmanned aerial vehicle distributed cooperative control method based on model prediction and unmanned aerial vehicle system

By acquiring UAV status and obstacle data, reconstructing the communication topology, and utilizing model predictive control optimization, the obstacle avoidance and formation stability issues of UAV formations under dynamic threats were solved, achieving efficient obstacle avoidance safety and formation stability.

CN121900490APending Publication Date: 2026-04-21CHONGQING UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
CHONGQING UNIV
Filing Date
2025-12-31
Publication Date
2026-04-21

AI Technical Summary

Technical Problem

When faced with dynamic threats such as internal node failures, dynamic additions and subtractions, external aircraft intrusions, and gust disturbances, existing UAV formations cannot meet the requirements of multi-target optimization and anti-interference by using traditional control methods, resulting in insufficient obstacle avoidance safety and formation stability.

Method used

By acquiring the current state data and dynamic obstacle data of the UAV formation, broadcasting heartbeat packets for threat detection, reconstructing the communication topology and formation, and utilizing nonlinear extended state observers and multi-objective model predictive control optimization, the coordinated control of UAV obstacle avoidance and formation maintenance is achieved.

Benefits of technology

It improves the obstacle avoidance safety and stability of UAV formations in dynamic threat environments, quickly repairs communication link interruptions and formation failures, and achieves effective obstacle avoidance and mission reliability for formations.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121900490A_ABST
    Figure CN121900490A_ABST
Patent Text Reader

Abstract

The invention provides a dynamic threat adaptive unmanned aerial vehicle distributed cooperative control method based on model prediction and an unmanned aerial vehicle system. The method comprises the steps of obtaining current state data and dynamic obstacle data of each unmanned aerial vehicle in an unmanned aerial vehicle group; for each unmanned aerial vehicle, broadcasting a heartbeat packet of each unmanned aerial vehicle, updating the dynamic obstacle data in real time, and determining a threat detection result based on the received heartbeat packet and the dynamic obstacle data updated in real time; based on the threat detection result, reconstructing communication topology and marshalling of the unmanned aerial vehicle to obtain an expected position of the unmanned aerial vehicle; determining a real-time disturbance estimation value based on the nonlinear extended state observer, the current state data and the external disturbance; and then, multi-target model prediction control optimization is carried out to obtain an optimal control sequence so as to control the flight of the corresponding unmanned aerial vehicle, thereby realizing cooperative control of obstacle avoidance and marshalling maintenance of the unmanned aerial vehicle. Therefore, the obstacle avoidance safety and marshalling stability of the unmanned aerial vehicle marshalling can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of unmanned aerial vehicle (UAV) control technology, and more specifically, to a model-predictive dynamic threat-adaptive distributed cooperative control method and UAV system. Background Technology

[0002] With the rapid development of the low-altitude economy and unmanned systems technology, multi-UAV collaborative operations have been widely applied in logistics distribution, disaster relief, and other fields. However, UAV formations face dynamic threats in actual operations, such as internal node failures, dynamic additions and subtractions, external aircraft intrusions, and gust disturbances. Existing centralized, distributed, and hybrid architectures suffer from single-point failures and poor topology adaptability. Traditional control methods struggle to balance multi-target optimization and anti-interference requirements, resulting in insufficient obstacle avoidance safety and formation stability. Summary of the Invention

[0003] In view of this, the purpose of this application is to provide a model-predictive dynamic threat-adaptive distributed cooperative control method and UAV system, which can improve the problem of insufficient obstacle avoidance safety and formation stability of UAV formations.

[0004] To achieve the above technical objectives, the technical solution adopted in this application is as follows:

[0005] In a first aspect, embodiments of this application provide a distributed cooperative control method for dynamic threat-adaptive unmanned aerial vehicles based on model prediction, the method comprising:

[0006] Acquire the current status data and dynamic obstacle data of each drone in the drone formation. The current status data includes the drone's inertial frame position, velocity, and attitude angle.

[0007] For each drone, a heartbeat packet is broadcast and dynamic obstacle data is updated in real time. The heartbeat packet includes the drone's own ID, current status information and timestamp.

[0008] For each drone, a threat detection result is determined based on the received heartbeat packets and real-time updated dynamic obstacle data. The threat detection result includes the drone's online status, external disturbances, and the distance between the drone and the obstacle.

[0009] Based on the threat detection results, the communication topology of the UAVs and the UAV grouping are reconstructed to obtain the desired location of the UAVs.

[0010] Based on the nonlinear extended state observer and the current state data of each UAV and external disturbances, the real-time disturbance estimate is determined;

[0011] Based on the current state data of each UAV, the dynamic obstacle data, the desired position and the real-time disturbance estimate, multi-objective model predictive control optimization is performed using a pre-built multi-objective cost function to obtain the optimal control sequence.

[0012] Based on the optimal control sequence, the corresponding UAV is controlled to fly, so as to achieve coordinated control of UAV obstacle avoidance and formation maintenance.

[0013] Secondly, embodiments of this application also provide an unmanned aerial vehicle (UAV) system, including multiple UAVs, each UAV including a processor and a memory coupled to each other, the memory storing a computer program, which, when executed by the processor, causes the UAV to perform the above-described method.

[0014] The invention employing the above technical solution has the following advantages:

[0015] The technical solution provided in this application achieves accurate perception of the UAV formation flight status by collecting current UAV status data and dynamic obstacle data, reconstructing the UAV communication topology and UAV formation. This facilitates the rapid repair of communication link interruptions and formation failures caused by internal dynamic threats such as node additions or removals, clearing internal dynamic threat obstacles for effective obstacle avoidance of UAV formations under external dynamic threats. Furthermore, based on the reconstructed distributed UAV architecture, multi-objective MPC optimization is performed by fusing real-time perturbation estimates from a nonlinear extended state observer. This facilitates the coordinated optimization of safety, stability, and mission reliability in obstacle avoidance under dynamic threat environments, thereby improving the obstacle avoidance safety and formation stability of UAV formations. Attached Figure Description

[0016] This application can be further illustrated by the non-limiting embodiments given in the accompanying drawings. It should be understood that the following drawings only illustrate some embodiments of this application and should not be considered as limiting the scope. For those skilled in the art, other related drawings can be obtained from these drawings without any inventive effort.

[0017] Figure 1 This is a flowchart illustrating the distributed cooperative control method for dynamic threat adaptation drones based on model prediction, provided in an embodiment of this application.

[0018] Figure 2 This is a schematic diagram of the obstacle avoidance trajectory of a drone group provided in an embodiment of this application.

[0019] Figure 3 A schematic diagram of the simulation results of the minimum relative distance between human-machine grouping and obstacles provided in the embodiments of this application.

[0020] Figure 4A schematic diagram of simulation results for the position tracking performance of UAV formations provided in the embodiments of this application.

[0021] Figure 5 A schematic diagram of simulation results for UAV group position tracking error provided in the embodiments of this application.

[0022] Figure 6 This is a schematic diagram of the simulation results of the UAV formation topology reconstruction trajectory provided in the embodiments of this application.

[0023] Figure 7 A schematic diagram of simulation results comparing the position errors of various UAVs and at each stage, provided for embodiments of this application.

[0024] Figure 8 This is a diagram of UAV group obstacle avoidance trajectory under dynamic threats from an axisymmetric perspective, provided in an embodiment of this application.

[0025] Figure 9 This is a diagram showing the obstacle avoidance trajectory of a UAV formation under dynamic threats from a top-down perspective, provided as an embodiment of this application. Detailed Implementation

[0026] The present application will be described in detail below with reference to the accompanying drawings and specific embodiments. It should be noted that similar or identical parts are referred to by the same reference numerals in the drawings or description. Implementations not shown or described in the drawings are forms known to those skilled in the art. In the description of this application, terms such as "first" and "second" are used only to distinguish descriptions and should not be construed as indicating or implying relative importance.

[0027] Please refer to Figure 1 This application provides a model-predictive-based distributed cooperative control method for dynamic threat adaptation of unmanned aerial vehicles (UAVs) (hereinafter referred to as "this method"). This method can be applied to UAV systems, which may include multiple UAVs, to execute the steps in this method. The method may include the following steps:

[0028] S10, acquire the current status data and dynamic obstacle data of each UAV in the UAV formation, wherein the current status data includes the UAV's inertial frame position, velocity and attitude angle;

[0029] S20: For each drone, broadcast the heartbeat packet of each drone and update the dynamic obstacle data in real time. The heartbeat packet includes the drone's own ID, current status information and timestamp.

[0030] S30, for each drone, based on the received heartbeat packets and real-time updated dynamic obstacle data, determine the threat detection result, which includes the drone's online status, external disturbances, and the distance between the drone and the obstacle;

[0031] S40, Based on the threat detection results, reconstruct the communication topology of the UAV and the UAV grouping to obtain the desired location of the UAV;

[0032] S50 determines real-time disturbance estimates based on nonlinear ESO (Extended State Observer) and the current state data of each UAV, as well as external disturbances.

[0033] S60, based on the current state data of each UAV, the dynamic obstacle data, the desired position and the real-time disturbance estimate, multi-objective MPC (Model Predictive Control) optimization is performed using a pre-built multi-objective cost function to obtain the optimal control sequence;

[0034] S70, based on the optimal control sequence, controls the flight of the corresponding UAV to achieve coordinated control of UAV obstacle avoidance and formation maintenance.

[0035] The steps of this method will be explained in detail below:

[0036] Before step S10, the UAV system needs to be initialized, and the initialization process is in the conventional manner.

[0037] In step S10, the current state data refers to the core motion and attitude data of the UAV in the inertial coordinate system, which is the basis for subsequent decision-making and control, and may include the position of the inertial frame. ,speed and attitude angle (roll angle) Pitch angle Yaw angle ).

[0038] Dynamic obstacle data: refers to data related to moving targets that may pose a collision risk to UAV formation flight, including the initial position and real-time position of obstacles. ,speed And the trend of motion (such as uniform speed, variable speed, turning direction, etc.).

[0039] The current status data comes from sensors such as the inertial measurement unit (IMU), GPS sensor, and vision sensor carried by the drone.

[0040] Dynamic obstacle data can include: initial information on known static and dynamic obstacles loaded by the UAV during the system initialization phase, as well as data on newly added dynamic obstacles and updated motion status data of existing obstacles detected in real time by the UAV's sensors (such as cameras, radar, etc.).

[0041] The current status data and dynamic obstacle data are obtained in a conventional way, which will not be described in detail here.

[0042] In step S20, the heartbeat packet refers to a standardized data frame used for status interaction and online status determination between UAV nodes, serving as the carrier data for node communication in a distributed architecture. The data in the heartbeat packet may include, but is not limited to, the UAV's current status data (position, speed, attitude angle), the UAV's preset node ID, working status identifier (normal / abnormal), and current timestamp. Here, one node represents one UAV.

[0043] Each drone can broadcast heartbeat packets to neighboring nodes via the ROS (Robot Operating System) topic at a preset communication cycle, ensuring that neighboring nodes can receive its status in real time. The preset communication cycle can be flexibly determined according to actual conditions and is not specifically limited here.

[0044] In addition, each drone can update the current position of dynamic obstacles in real time based on the position and speed changes of obstacles detected by its own sensors (such as radar, depth cameras, etc.) and the obstacle movement trends during the initialization phase, using linear interpolation or adaptive motion models. ,speed This completes the obstacle trajectory prediction information, resulting in updated real-time dynamic obstacle status data. Understandably, the method of broadcasting heartbeat packets and updating dynamic obstacle data is conventional and will not be elaborated upon here.

[0045] In this embodiment, step S30 may include:

[0046] The online status of the corresponding drone is determined based on the drone's ID and timestamp in the received heartbeat packet;

[0047] External disturbances are determined based on the strength and frequency of the drone's sensor signals.

[0048] Based on real-time updated dynamic obstacle data, the distance between the drone and the dynamic obstacle is determined, and the online status, external disturbances, and distance are used as threat detection results. If the online status indicates that the number of currently online drones has increased or decreased, all online drones are controlled to enter a hovering state.

[0049] In this embodiment, the threat detection result refers to the quantitative and qualitative judgment result of the internal and external dynamic threats faced by the UAV formation. It is the basis for triggering topology reconfiguration and control optimization, including the UAV online status (normal online / offline / fault), external disturbances (gusts, wind shear, etc.), and the distance between the UAV and obstacles.

[0050] External disturbances refer to unpredictable disturbances in the environment, including airflow disturbances such as gusts and wind shear.

[0051] Sensor signal data: Signal strength and frequency data collected from barometric pressure sensors, wind speed sensors, IMUs, etc., carried by the drone.

[0052] Specifically, each drone can store received heartbeat packets categorized by node (drone) ID, recording the latest heartbeat packet timestamp for each node. Next, the difference between the current time and the latest heartbeat packet timestamp for each node is calculated. If the difference is less than or equal to the timeout threshold, and the online status is marked as "normal," then the node is determined to be online. If the difference is greater than the timeout threshold, or the online status is marked as "abnormal", then the node is determined to be offline or faulty. The system counts the current number of online nodes and compares it with the number of online nodes in the previous period to determine if there has been an increase or decrease in nodes. It should be noted that the various thresholds in this application (such as timeout thresholds and disturbance identification thresholds) can be flexibly set according to actual circumstances.

[0053] External disturbances can be determined by calculating the difference between the real-time sensor signal strength and the reference signal strength, and the deviation between the real-time signal frequency and the reference frequency. A disturbance identification threshold is set. If the difference or deviation exceeds the threshold, an external disturbance is identified. The disturbance intensity level (e.g., weak, medium, strong) is then classified according to the magnitude of the deviation, and the disturbance type (gusts, wind shear, etc.) is identified. The reference signal data comes from the sensor reference signal strength and frequency recorded during the system initialization phase of the UAV in a undisturbed environment.

[0054] In this embodiment, the distance between the drone and dynamic obstacles is determined using a conventional method. Threat detection results are generated by integrating the drone's online status, external disturbances, and distance.

[0055] If the number of online nodes increases or decreases, a hovering control command is immediately generated and sent to all online UAV actuators (e.g., motors) to control the UAV to enter a hovering state, avoiding collisions within the group caused by changes in node status. If the hovering time exceeds the preset time, proceed to step S40.

[0056] Understandably, by comprehensively summarizing internal and external threat information, an emergency hovering response is triggered to minimize the collision risk caused by dynamic changes in nodes.

[0057] If the number of online nodes does not increase or decrease, proceed directly to step S40.

[0058] In this embodiment, the unmanned aerial vehicle (UAV) system adopts a self-reconfigurable distributed architecture. This architecture is the core framework designed based on the distributed autonomous decision-making and dynamic collaboration requirements of multi-UAV systems. Its core idea is to treat each UAV in the system as an independent node with complete perception, decision-making, and execution capabilities. Through local information interaction and dynamic topology maintenance, it achieves global collaborative operation without a central node dependency. This architecture integrates single-UAV functional units and multi-UAV collaborative mechanisms through modular design. A single UAV node uses a state machine to manage its state from initialization, takeoff, hovering to obstacle avoidance, and integrates core functions such as trajectory planning and multi-target MPC trajectory tracking. At the multi-UAV collaborative level, a dynamic topology manager and formation calculator maintain topology relationships and adaptively adjust formations, enabling the UAV formation to possess internal dynamic threat response capabilities during obstacle avoidance.

[0059] From an architectural perspective, each UAV node publishes its own position, speed, and mission progress status via ROS topics and subscribes to neighbor node information. A dynamic topology manager aggregates the online node list in real time, detecting node online / offline status to update the topology. The formation calculator dynamically calculates the positional offset of the formation based on the current topology and preset grouping parameters, supporting self-reconfiguration of the formation when nodes are added or removed. When the topology changes, the node state machine triggers state transitions and path replanning, generating smooth trajectories using the A* algorithm with grouping constraints and the Minimum snap algorithm, with high-precision tracking achieved by the MPC controller. This design enables the system to autonomously adjust communication topology and formation through distributed decision-making when internal dynamic threats such as node state changes occur during obstacle avoidance, ensuring the safety and stability of UAV grouping obstacle avoidance missions.

[0060] Distributed obstacle avoidance in UAV swarms relies on reliable communication connections. However, scenarios such as node failures and the addition of new nodes can disrupt the original communication topology between nodes, making it impossible to effectively respond to external dynamic threats. Therefore, the communication topology of UAV swarms must have adaptive reconfiguration capabilities.

[0061] In this embodiment, step S40 may include:

[0062] Configure undirected graph This is used to describe the communication topology of a drone, where the vertex set... , represents a set of drone nodes; edge set , represents the communication connection between drone nodes; if drones i and j communicate directly, it is represented as ;

[0063] Configure adjacency matrix The elements in the adjacency matrix Represented as:

[0064] (1)

[0065] in, Indicates time edge set, For self-loop constraints, This is a two-way communication constraint; "Other situations" refers to situations that do not fall under " "the situation";

[0066] For self-reconfiguration at the communication topology level, a dynamic topology manager was designed, which is implemented based on real-time updates of node online status detection and communication connection status. Regarding node online status determination, each UAV node periodically broadcasts a "status heartbeat packet," which includes core information such as node ID, working status identifier, location, speed, and timestamp, while simultaneously receiving heartbeat packet data from a dynamic set of neighboring nodes. To quantify the online status of a node, a node online status function is configured. , is represented as:

[0067] (2)

[0068] In the formula, This indicates that the drone i is sending heartbeat packets stably according to a preset cycle; This indicates that drone i has not sent a heartbeat packet for a specified number of consecutive preset periods. The preset period can refer to the broadcast period of the heartbeat packet, which is consistent with the detection period Δt and is preset to a fixed value (such as 0.1s). The specified number of consecutive preset periods refers to the timeout threshold for determining that the node is offline, such as 3 communication periods (which can be adjusted according to the real-time requirements of the system).

[0069] when and hour, drones and Maintain a two-way communication connection; when or hour, This indicates that communication between drones i and j has failed;

[0070] Based on the online status of the drones in the threat detection results, the online status functions of drones i and j are used. and Update the communication status between drones i and j. ;

[0071] When drones The adjacency matrix at the current time was detected. Adjacency matrix of the previous period When non-zero element differences exist, a local topology reconstruction is triggered to update the communication topology of all online drones;

[0072] Based on the updated communication topology, the initial desired position of UAV i is determined. , is represented as:

[0073] (3)

[0074] In the formula, This indicates the marshalling center obtained based on the updated communication topology; This represents the preset formation offset of drone i;

[0075] (4)

[0076] (5)

[0077] In the formula, This represents the grouping center obtained by the local perception calculated by UAV i; This represents the grouping center of the local perception calculated by the UAV j;

[0078] When the threat detection result indicates that the number of currently online drones has increased or decreased, the offset of each drone is readjusted to obtain the new expected position of the corresponding drone.

[0079] Communication topology self-reconfiguration provides a reliable information exchange channel for UAV group obstacle avoidance. As one of the core objectives of distributed obstacle avoidance in UAV grouping, maintaining the group formation requires stabilizing the preset relative positional relationships under the support of this communication architecture, without a central node. Its core objective is to maintain the relative positional accuracy of each UAV node in the global coordinate system, ensuring that the group formation remains stable under dynamic topology changes.

[0080] The grouping center will serve as the reference grouping center for each UAV node in the distributed architecture. Through iterative and distributed collaborative control, it will gradually converge to a globally consistent distributed grouping center.

[0081] When the grouping topology changes dynamically, the number of online nodes changes from N to N', where N' ≠ N. This disrupts the geometric consistency of the original grouping formation, making it unable to maintain the preset configuration and triggering a formation self-reconstruction mechanism. This mechanism will redistribute the preset offsets of each node based on the updated number of online nodes. In conjunction with a globally consistent distributed marshalling center, a new reference position is generated for each node. Then, based on the new reference positions of each node in the group, trajectory replanning is performed to obtain the new tracking trajectory after group reconstruction.

[0082] In this embodiment, the UAV can construct an undirected graph framework using each node ID as a vertex. Initially, the initial edge set is determined based on a preset communication radius. (For example, establishing initial communication connections between nodes within the communication radius, corresponding to the edges) ).

[0083] The configured adjacency matrix is ​​a square matrix that describes the connection relationships between nodes in an undirected graph and is used to quantify the communication topology.

[0084] Self-loop constraint: A constraint rule that prevents a node from establishing a communication connection with itself.

[0085] Bidirectional communication constraint: The communication connection between UAV nodes is bidirectional, if Can be with Communication, Can also be used with communication.

[0086] Understandably, by recording the heartbeat packet transmission time of each drone, it can be determined whether the transmission is stable according to the preset cycle; for drones If there are stable transmission records within a specified number of preset periods, then ;otherwise ;based on and The value of is used to update the adjacency matrix elements. When both are 1 Otherwise, it is 0. In this way, the relationship between online status and communication connection can be established, providing a basis for judgment on the dynamic update of communication topology.

[0087] Next, traverse all node pairs (i,j). ,according to and The value is used to update the communication status. :like and ,but To maintain or establish two-way communication; if or ,but This indicates a communication link failure, and communication is automatically disconnected. This allows for real-time updates of the communication status, ensuring that the communication topology is synchronized with the online status of the nodes.

[0088] In this embodiment, non-zero element difference refers to the change in the element value at any position in the adjacency matrix within two periods (from 0 to 1 or from 1 to 0).

[0089] Local topology reconfiguration: A reconfiguration method that only adjusts the communication connections of nodes whose states have changed (nodes switching between online and offline) and their direct neighbors, without requiring the participation of global nodes.

[0090] Specifically, compare the adjacency matrix element by element at the current time. Adjacency matrix of the previous period Determine if there are any non-zero elements that differ. If a difference exists, locate the node whose state has changed (let's call it node k) and its set of direct neighbors. ;

[0091] Only for node k and The communication connections between nodes are reconfirmed and adjusted, and the elements at corresponding positions in the adjacency matrix are updated to complete the local topology reconstruction. The updated adjacency matrix A(t) is then synchronized to all online drones via ROS topics. This reduces the computational overhead and communication latency of topology reconstruction, ensures system real-time performance, and guarantees the accuracy of the communication topology.

[0092] In this embodiment, the preset formation offset refers to the positional deviation of the UAV relative to the formation center in the preset formation, which is determined by the geometric parameters of the initial formation (such as a circle or rectangle).

[0093] Locally-aware grouping center: The grouping center is independently calculated by the UAV based on its own position and preset offset, without incorporating neighbor node information.

[0094] Understandably, drone i can base its actions on its current location. With preset offset Computational local awareness of marshalling center ;

[0095] Obtain the local sensing marshalling center of neighbor node j through communication. ;

[0096] Based on the updated adjacency matrix elements Calculate the number of valid neighbor nodes ;

[0097] Substituting into the above grouping center formula (4), and merging the local centers of itself and its neighboring nodes, a globally consistent distributed grouping center is obtained. ;

[0098] based on and The initial desired position of UAV i is calculated. In this way, grouping center calculations can be achieved without a central node dependency, ensuring the stability and consistency of the grouping formation.

[0099] In this embodiment, if the number of online nodes increases from... Become ( Based on the new number of online nodes Based on the geometric features of the preset grouping formation (such as a circle), the preset offsets of each online node are redistributed. (Ensure the geometric consistency of the new formation); Combine with a distributed grouping center With the new offset Calculate the new desired position for each UAV, denoted as... The new desired positions are synchronized to each online drone. This enables adaptive adjustment of the formation, ensuring that the preset formation remains stable even after nodes are added or removed, thus improving the scalability and fault tolerance of the formation.

[0100] In this embodiment, step S50 may include:

[0101] For each online drone, an extended state vector is configured based on the drone's current state data. , is represented as:

[0102] (6)

[0103] In the formula, The inertial frame position vector in the current state data. The velocity vector of the inertial frame in the current state data. The external disturbance vector formed by the external disturbance;

[0104] The position estimation update equation for configuring the extended state observer is expressed as:

[0105] (7)

[0106] That is, based on the speed estimate of the previous cycle. Current calculated position measurement error Calculated via Hadamard product Substituting into formula (7), we obtain the estimated rate of change of position for the current period. Then, by integration, the estimated current position is obtained. In this way, the position estimate can be dynamically corrected to ensure the accuracy of the position estimate and provide a basis for velocity and disturbance estimation.

[0107] The configuration speed estimation update equation is expressed as:

[0108] (8)

[0109] Among them, the rate of change of velocity is estimated. The current speed estimate can be obtained by integration. Combining force analysis with nonlinear error correction helps improve the accuracy and anti-interference capability of velocity estimation.

[0110] Configure the perturbation estimation update equation, expressed as:

[0111] (9)

[0112] Among them, the rate of change of disturbance estimate The current real-time disturbance estimate is obtained by integration. It should be noted that the real-time estimation of disturbances based on position measurement errors has a fast response speed and high estimation accuracy, which can provide reliable data for subsequent control compensation.

[0113] In the formula, Indicates the estimated position of the drone. The derivative; Indicates the estimated speed of the drone; , and All are gain vectors; Used to adjust the response speed and stability of position estimation; Used to adjust the response speed of velocity estimation; Used to adjust the response speed of disturbance estimation; This represents the Hadamard product (element-wise multiplication), used to perform element-wise multiplication of the gain vector and the error vector; This refers to the error in position measurement;

[0114] The derivative of the estimated velocity of the drone; m refers to the mass of the drone; The thrust of a drone; The weight of the drone; Disturbance estimation of drones The derivative; and All are nonlinear factor vectors; δ is the threshold of the linear interval, used to distinguish between the small error linear region and the large error nonlinear region; Used to balance response speed with large errors and estimation accuracy with small errors; Used to optimize the dynamic performance of perturbation estimation;

[0115] For nonlinear functions, the corresponding general expression is:

[0116] (10)

[0117] In the formula, This refers to the position measurement error. This refers to a nonlinear factor vector; sgn() is the sign function, for example, it outputs 1 when the input is positive, -1 when the input is negative, and 0 when the input is 0.

[0118] like Then calculate according to nonlinear rules. This reduces large errors and improves response speed.

[0119] like Then calculate according to linear rules. This ensures the estimation accuracy when the error is small, thus enabling a fast response when the error is large and a high-precision estimation when the error is small, taking into account both the dynamic performance and steady-state accuracy of ESO.

[0120] Based on the current state data, position estimation update equation, velocity estimation update equation, and disturbance estimation update equation of each UAV, the real-time disturbance estimate is obtained.

[0121] In this embodiment, the extended state vector is a high-dimensional state vector formed by adding external disturbances as extended states on the basis of the traditional system states (position and velocity) of the UAV. This is the core prerequisite for ESO to achieve disturbance estimation.

[0122] External disturbance vector: This includes three-dimensional vectors of environmental disturbances (gusts, wind shear) and unmodeled dynamics of the UAV, which need to be estimated in real time using ESO.

[0123] Specifically, the calculation and updating method for real-time disturbance estimates can be as follows:

[0124] Based on sensor measured position Position estimate compared to the previous period Calculate the position measurement error, expressed as ;

[0125] Will Substitute the values ​​into the position estimation update equation to calculate the current position estimate. ;

[0126] Will ,thrust ,gravity Previous period disturbance estimate Substitute the values ​​into the velocity estimation update equation to calculate the current velocity estimate. ;

[0127] Will Substituting into the disturbance estimation update equation, i.e., the above formula (9), we can calculate the current real-time disturbance estimate. ;

[0128] By iteratively executing the above steps, real-time disturbance estimates can be calculated and updated.

[0129] Iterative calculations enable continuous and high-precision estimation of external disturbances, providing a reliable basis for disturbance compensation in MPC control and enhancing the system's anti-interference capability.

[0130] In this embodiment, step S60 may include:

[0131] Configure the state update equation with fused disturbance compensation as the prediction model for model predictive control, expressed as:

[0132] (10)

[0133] In the formula, Represents the state vector. , Represents the position vector of the UAV; Represents the velocity vector of the UAV; Represents the control vector of the UAV. , The total thrust of the drone, These are roll angle, pitch angle, and yaw angle, respectively. This represents the disturbance estimate of the drone;

[0134] Based on trajectory tracking cost, control cost, smoothness cost, obstacle avoidance cost, grouping and coordination cost, and terminal cost, a multi-objective cost function is configured as the total cost function;

[0135] Configure the trajectory tracking cost function used to calculate the trajectory tracking cost;

[0136] Configure the control cost function used to calculate the control cost;

[0137] Configure the smoothing cost function used to calculate the smoothing cost;

[0138] Configure the obstacle avoidance cost function used to calculate the obstacle avoidance cost;

[0139] Configure the grouping coordination cost function for calculating grouping coordination costs;

[0140] Configure the terminal cost function for calculating terminal costs;

[0141] Based on the current state data of each UAV, the dynamic obstacle data, the desired position, the real-time disturbance estimate, and the preset constraints, the goal is to minimize the total cost function. The control sequence corresponding to the minimum total cost is taken as the optimal control sequence. The preset constraints include the prediction model.

[0142] By fusing disturbance estimates from extended state observers (ESOs), a predictive model with disturbance compensation is constructed, a multi-objective cost function is designed, and real-time solution of control variables is achieved through rolling optimization, ensuring that the system has both control accuracy and robustness in dynamic threat environments.

[0143] As an example, the specific implementation process of step S70 can be as follows:

[0144] Based on the disturbance estimation results from the UAV dynamics model and ESO output, a state update equation integrating disturbance compensation is constructed, which serves as the prediction model for Model Predictive Control (MPC). The system state vector is defined as follows: The control vector is ,in The total thrust in the body coordinate system. These are the roll angle, pitch angle, and yaw angle, respectively. The state equation for disturbance compensation is then integrated, which is the above formula (10).

[0145] Wherein, the position derivative satisfies That is, the rate of change of position with time is equal to the velocity vector; the derivative of velocity satisfies , Here is the attitude rotation matrix. For thrust-acceleration conversion coefficient, .

[0146] To achieve a multi-objective optimization balance of "obstacle avoidance-group maintenance-trajectory tracking" in UAV grouping under dynamic threat environments, while ensuring the physical feasibility of control inputs and trajectory smoothness, this application designs a total cost function comprising six sub-items: trajectory tracking, control output, smoothness, obstacle avoidance, group coordination, and terminal constraints. Its expression is:

[0147] (11)

[0148] Multi-objective total cost function: This function quantifies multiple independent control objectives such as obstacle avoidance, group maintenance, and trajectory tracking into a single evaluation index. It uses weighted summation to weigh the priority of each objective and serves as the optimization criterion for MPC rolling optimization.

[0149] Trajectory tracking cost The goal is to quantify the deviation between the actual motion state of the drone and the preset reference trajectory, and minimize this deviation to ensure trajectory tracking accuracy.

[0150] Control Cost : To constrain the degree to which the control input deviates from the hovering reference state, so as to avoid excessive control input leading to excessive energy consumption or damage to the actuator.

[0151] Smoothing Cost The goal of quantifying the fluctuation amplitude of control input within adjacent control cycles is to reduce fluctuations and improve flight stability and control smoothness.

[0152] Obstacle Avoidance Costs The potential field function quantifies the risk of the distance between the drone and obstacles. The closer the distance, the greater the cost, thus driving the drone away from the obstacle.

[0153] Grouping and coordination costs The goal of quantifying the relative positional deviation between the drone and its neighboring nodes is to maintain a preset safe grouping distance and ensure the stability of the grouping formation.

[0154] Terminal cost To enhance the trajectory tracking accuracy at the end of the prediction time domain and avoid excessive deviation in the end state due to the optimization process focusing on intermediate steps.

[0155] Specifically, to ensure trajectory tracking accuracy, a trajectory tracking cost is designed. The trajectory tracking cost function is used to minimize the deviation between the actual state and the reference trajectory. Its expression is:

[0156] (12)

[0157] in, For prediction in the time domain; , They are respectively Continuously measure the position and velocity calculated by the drone; , They are respectively Reference position and velocity at any given moment; , It is a positive definite weight matrix, and the position weight is greater than the velocity weight to prioritize the position tracking accuracy.

[0158] To constrain the degree to which the control input deviates from the hovering state and reduce the burden on the actuator, a control cost is designed. The expression for the control cost function is:

[0159] (13)

[0160] in, for Constantly control the input. For hover control input, The conversion coefficient between thrust and acceleration. To control the weight matrix, m is the mass of the UAV and g is the acceleration due to gravity.

[0161] To reduce fluctuations in control input between adjacent time steps and ensure trajectory continuity, a smoothness cost is designed. The expression for the smoothness cost function is:

[0162] (14)

[0163] in, This is a smoothing coefficient, which can be flexibly adjusted according to the requirements of trajectory smoothness.

[0164] To achieve effective obstacle avoidance in dynamic threat environments, an obstacle avoidance cost is designed. The expression for the obstacle avoidance cost function is:

[0165] (15)

[0166] in, The obstacle avoidance weight is used to adjust the proportion of obstacle avoidance cost in the total cost; For the first The Euclidean distance from the drone to the obstacle in real time; The direction factor dynamically adjusts the potential field strength based on the angle between the velocity and the obstacle's relative position, reducing the obstacle avoidance cost in non-dangerous directions. Its expression is:

[0167] (16)

[0168] in, Let be the cosine of the angle between the velocity direction and the relative position of the obstacle. This indicates that the drone is moving away from the obstacle. This indicates that the drone is approaching an obstacle. For a safe distance.

[0169] Potential function Based on a distance-segmented design to balance obstacle avoidance performance and trajectory smoothness, the expression is:

[0170] (17)

[0171] in, Let k be the Euclidean distance between the drone and the obstacle. This represents the threshold for the hazardous area.

[0172] To maintain the preset relative positions of multiple drones and their neighboring nodes and ensure group stability, a grouping coordination cost is designed. The expression for the grouping cooperation cost function is:

[0173] (18)

[0174] in, for The distance between the drone and its neighboring nodes in real time. For grouping weights, Let be the potential field function between neighbors, expressed as:

[0175] (19)

[0176] Among them, the safe distance of the group As a threshold.

[0177] To enhance tracking accuracy and improve system stability at the end of the prediction time domain, a terminal cost is designed. The expression for the terminal cost function is:

[0178] (20)

[0179] In the formula, , These are the positions and speeds of the drone numbered N-1; , This provides the reference position and reference speed for the drone.

[0180] To ensure the physical feasibility of control inputs and the safety of UAV operations, this application sets the following constraints as preset constraints:

[0181] Thrust constraints are set for total thrust. ,in For minimum safe thrust, For the maximum permissible thrust, Determined by the quality of the drone, this constraint helps prevent the drone from experiencing insufficient power or overload.

[0182] Based on the small angle assumption, attitude angle constraints are set. , ,in, This angle range satisfies the small angle approximation condition, which can ensure the flight stability of the UAV.

[0183] To ensure that the drone does not enter the obstacle threat area within the prediction time domain, obstacle avoidance safety constraints are set. ,in for Real-time distance between the drone and obstacles This refers to the safe distance defined above.

[0184] Within each control cycle, based on the current system state Perturbation estimation of ESO output Solve the optimization problem with the objective of minimizing the total cost function, which can be expressed as: The constraints include the state update equations. In addition to the thrust constraints, attitude angle constraints, and obstacle avoidance safety constraints set above, among which The control sequence to be solved is denoted as .

[0185] After obtaining the optimal control sequence by solving the above optimization problem, a rolling optimization strategy is adopted, in which only the first control variable in the optimal control sequence is executed. And when the next control cycle arrives, based on the updated system state With disturbance estimation Repeat the optimization process described above.

[0186] Final output control quantity Through the execution of the underlying actuators, the system achieves coordinated control of UAV obstacle avoidance, formation maintenance, and trajectory tracking in dynamic threat environments.

[0187] In this embodiment, step S70 may include:

[0188] The first control variable in the optimal control sequence is taken as the optimal control variable;

[0189] The optimal control quantity is converted into control signals for the UAV's actuator motors, so as to control the corresponding UAV flight according to the control signals.

[0190] Understandably, by employing a rolling optimization strategy, only the first control variable in the optimal control sequence is extracted, and the optimal control variable is... The signals are converted into control signals (such as motor speed signals and servo angle signals) that can be recognized by the UAV's underlying actuators (motors and servos). The actuators respond to the control signals and adjust the UAV's thrust and attitude to achieve flight status adjustment; at the same time, the sensors collect the adjusted real-time status data (position, velocity, attitude angle) and feed it back to S20 (heartbeat packet broadcast), S50 (ESO observation), and S60 (next cycle optimization) to form a closed-loop control.

[0191] In this embodiment, the method may further include:

[0192] S80 determines whether all online drones have reached the corresponding global target trajectory endpoint;

[0193] S91: When all online drones reach the corresponding global target trajectory endpoint, control all online drones to perform hovering or landing operations.

[0194] S92, when at least some of the online drones have not reached the corresponding global target trajectory endpoint, repeat steps S10 to S80 until all online drones have reached the corresponding global target trajectory endpoint, and control all online drones to perform hovering or landing operations.

[0195] In this embodiment, the global target trajectory endpoint: the final target position of the UAV formation mission, is denoted as... , is the preset task termination reference point.

[0196] Specifically, calculate the current location of each online drone. and the finish line Euclidean distance. Current location. Real-time location data can be obtained from step S70. Set a endpoint determination threshold (e.g., 0.5m). If all online drones... If all values ​​are less than the threshold, the destination is considered reached; otherwise, the destination is considered not reached.

[0197] When all online drones reach the endpoint of their respective global target trajectories, the mission is considered complete, and the drones can then safely hover or land.

[0198] If at least some of the online drones fail to reach the corresponding global target trajectory endpoint, a loop mechanism is triggered, returning to S10 to restart a series of processes including data acquisition, threat detection, topology reconstruction, and control optimization, until all online drones reach the endpoint, at which point the hovering or landing operation in S91 is executed. This ensures continuous mission progression, guaranteeing global target trajectory tracking even in dynamic threat environments and ensuring mission integrity.

[0199] The method provided in this application focuses on the collaborative control objectives of UAV group obstacle avoidance, group maintenance, and trajectory tracking under dynamic threat environments. It combines a self-reconfigurable distributed architecture, multi-target MPC, and ESO perturbation compensation to ensure that UAV groups complete distributed obstacle avoidance. To facilitate understanding of the overall implementation process of this method, an example is provided below:

[0200] Step 1: System Initialization Configuration. Complete the hardware parameter calibration and software module loading for multiple UAV nodes, including single UAV model parameter initialization, sensor calibration, and communication link establishment. Preset the formation geometry parameters and safe grouping distance. Obstacle avoidance safe distance Core parameters are defined; the communication topology adjacency matrix is ​​initialized based on undirected graph theory, the set of neighbor nodes of each node is defined, the dynamic topology manager and extended state observer (ESO) are started, the initial parameters of the MPC controller are loaded, and the global target trajectory and task execution path of the group are determined; the initial position, velocity, motion trend and other state information of known static and dynamic obstacles are loaded to provide data support for obstacle avoidance decision-making.

[0201] Step Two: Status Interaction and Obstacle Information Update. Each drone node collects its own data through its onboard sensors. ,speed Attitude angle ( Status information such as status heartbeats is periodically broadcast through ROS topics, and the status information and heartbeat data of neighboring nodes are subscribed to to achieve local information interaction; obstacle movement data is updated in real time based on the loaded obstacle information.

[0202] Step 3: Internal and External Threat Monitoring and Internal Threat Response. The system simultaneously monitors two types of dynamic threats: internal dynamic threats such as single-unit failures and temporary additions or removals of nodes within the formation, and external dynamic threats such as dynamic obstacles and gusts of wind. If an internal dynamic threat is detected, an emergency response is immediately triggered, controlling the UAV formation to enter a hovering state to avoid collisions within the formation, and then proceeding to Step 4; if no internal dynamic threat is detected, proceed directly to Step 5.

[0203] Step 4: Dynamic Topology Update and Group Reconfiguration. Addressing the internal dynamic threats detected in Step 3, the dynamic topology manager updates the topology based on node heartbeat data and through online state functions. Determine if a node is offline and update the adjacency matrix in real time. The system adjusts the communication connections between nodes in state changes and their direct neighbors to reconstruct the communication topology. Simultaneously, the formation calculator, based on the updated online node list and adjacency matrix, reallocates the preset offsets of each node. Generate new node desired positions It completes the self-reconstruction of the group formation, restoring the ability to share group information and the stability of the formation.

[0204] Step 5: Disturbance Observation and Compensation Information Generation. The Extended State Observer (ESO) generates information based on the actual positions measured by each node. With the observer to estimate the position Calculate the position measurement error External disturbance vectors are estimated in real time by updating the ESO state equations. The disturbance estimation results are integrated into the MPC controller to provide data support for disturbance compensation.

[0205] Step Six: Multi-objective MPC Optimization Solution. The MPC controller is based on the current system state vector. ESO output perturbation estimation To construct the state equation; to fuse trajectory tracking cost, obstacle avoidance cost, group coordination cost, control smoothing cost, and terminal constraint cost into a multi-objective cost function. Under thrust constraints, attitude constraints, and obstacle avoidance safety constraints, the solution is obtained using the cost function. The optimization problem with the objective of minimization yields the optimal control sequence. Extract the first control variable .

[0206] Step 7: Control command execution and status feedback. Optimal control quantity. The drone is driven by the underlying actuator to adjust its motion state, achieving coordinated control of trajectory tracking, obstacle avoidance, and group maintenance; at the same time, each node feeds back the real-time status data after execution to the dynamic topology manager and ESO, completing the closed-loop control link.

[0207] Step 8: Task Status Determination and Loop Execution. Determine if the formation has reached the endpoint of the global target trajectory. If not, return to Step 2 and continue with subsequent steps. If the target point has been reached, terminate the task, and each node executes hover or landing commands. At this point, the UAV formation has completed distributed obstacle avoidance under dynamic threats.

[0208] The inventors built an experimental platform to verify the effectiveness of this method. This platform uses Ubuntu 20.04 as its underlying runtime environment, leveraging the native compatibility of the PX4 build toolchain and ROS packages to avoid component compatibility conflicts and provide stable support. In terms of core component configuration, the algorithm deployment is based on ROS Noetic, adopting a "single UAV - single ROS node" mapping mode. Each virtual UAV corresponds to an independent decision node, integrating core modules such as dynamic topology management, extended state observation, and multi-objective MPC control. Nodes share pose, topology, and other states through standardized ROS interfaces, and task triggering and feedback are achieved through ROS services and action mechanisms. Flight dynamics simulation uses the PX4 open-source flight control firmware, configuring an independent instance for each virtual UAV. Based on rigid body kinematics, it reproduces the dynamic characteristics and physical execution constraints of multi-rotor aircraft, publishes flight control status, and simulates hardware fault responses. The communication middleware establishes a bidirectional link between ROS and PX4 through MAVROS, completing control command transmission and sensor data feedback based on the MAVLink protocol. Threat environment construction relies on the Gazebo11 physics engine, generating terrain constraints and moving obstacle models through plugins to reproduce dynamic threat scenarios. Finally, MATLAB is used to visualize the experimental data.

[0209] The experimental test scenario is as follows:

[0210] Scenario 1: In the Gazebo11 simulation environment, five drone nodes are configured, and static and dynamic obstacles and wind disturbance areas are set up. Finally, the drones complete the passage through the area in a circular formation. This scenario verifies the ability of the drone formation to cope with external dynamic threats.

[0211] Scenario 2: In the Gazebo11 simulation environment, configure 5 UAV nodes and control the formation to complete formation / communication topology reconstruction during movement, including three cases: equal number of nodes, reduced number of nodes, and increased number of nodes, to restore the formation constraints. This scenario verifies the UAV formation's ability to cope with internal dynamic threats.

[0212] Scenario 3: Combining Scenario 1 and Scenario 2, five drone nodes are configured to traverse an area containing static and dynamic obstacles and wind disturbances in a drone formation. However, during the traversal, one drone is intentionally triggered to land malfunction. The remaining drones complete communication / formation topology reconfiguration and continue obstacle avoidance, ultimately ensuring all drones safely pass through the obstacle area. This scenario verifies the drone formation's ability to cope with internal and external dynamic threats during obstacle avoidance.

[0213] Evaluation criteria for scenario 1: a) The drone formation has static and dynamic obstacle avoidance capabilities; b) The minimum safe distance between the preset drone node and the obstacle is not less than 0.3m.

[0214] Evaluation metrics for scenario 2: a) The drone formation has the ability to reconfigure its formation / communication topology; b) The positional error of adding or removing nodes in the formation is less than 0.3m.

[0215] Scenario 3 evaluation metric: The drone formation has the ability to deal with internal and external dynamic threats during obstacle avoidance.

[0216] For the experimental data in Scenario 1, please refer to [reference needed]. Figures 2 to 4 .

[0217] Analysis of Experiment Results for Scenario 1: Five drones, in a circular formation, traversed an area affected by wind disturbance and both static and dynamic obstacles. The minimum distance to static obstacles was 0.376736m, and the minimum distance to dynamic obstacles was 0.674261m. With a safety threshold of 0.3m and smooth trajectory tracking, there were no collisions throughout the entire process. This verifies that it possesses good obstacle avoidance capabilities and trajectory tracking accuracy under external dynamic threats.

[0218] For experimental data from Scenario 2, please refer to [link / reference]. Figure 5 and Figure 7 .

[0219] Analysis of Experimental Results for Scenario 2: The experimental data from Scenario 2 shows that the UAV formation exhibits good formation / communication topology reconstruction capabilities under internal dynamic threat environments. After reducing the number of nodes, the positional error between the UAV and the formation's target point is 0.0208429m; after adding nodes, the positional error is 0.139662m. 0.3m, which meets the evaluation criteria for scenario two.

[0220] See the experimental data for Scenario 3. Figure 8 and Figure 9 .

[0221] Analysis of Experimental Results for Scenario 3: The experimental data from Scenario 3 shows that after the UAV formation takes off and hovers along a preset trajectory, it moves in a stable circular formation and performs obstacle avoidance tasks. During this time, it encounters an internal dynamic threat; UAV3 malfunctions and lands, while the remaining UAVs quickly enter a hovering state and initiate a self-reconfiguration process. After restoring the circular formation and communication topology connection, it continues to perform obstacle avoidance tasks and ultimately safely passes through the target area. This demonstrates that the model-predicted dynamic threat UAV formation obstacle avoidance method possesses rapid fault response, efficient formation reconfiguration, and safe obstacle avoidance capabilities, meeting the evaluation criteria.

[0222] In summary, the method provided in this application, through a self-reconfigurable distributed architecture design, can solve the problem that traditional architectures cannot effectively cope with dynamic threats within the formation caused by UAV malfunctions, such as formation failure and communication disconnection. By fusing the perturbation estimates from the Extended State Observer (ESO) and combining them with formation topology characteristics, a multi-objective MPC optimization framework is constructed to address the problems of poor adaptability to external dynamic threats, imbalance in multi-objective decision-making, and insufficient anti-interference capability of traditional control methods, thereby improving obstacle avoidance robustness and trajectory tracking accuracy. By deeply coupling the self-reconfigurable distributed architecture with multi-objective MPC optimization that incorporates perturbation compensation, internal dynamic threat obstacles are cleared at the architecture level, while external dynamic threat interference is resisted at the control level. This solves the problem that traditional technologies cannot simultaneously address internal and external dynamic threats and have insufficient overall obstacle avoidance performance, achieving synergistic optimization of the safety, stability, and mission reliability of formation obstacle avoidance in dynamic threat environments.

[0223] This application also provides an unmanned aerial vehicle (UAV) system, including multiple UAVs. Each UAV includes a processor and a memory coupled together. The memory stores a computer program, which, when executed by the processor, causes the UAV to perform the method described above. The number of UAVs can be flexibly set according to actual needs, for example, five or more.

[0224] It should be noted that the processor (e.g., a general-purpose processor) and memory can be integrated into one unit to serve as the onboard computer of the drone. Of course, the onboard computer can also include other conventional components (e.g., a programmable gate array) to enable the onboard computer to perform the steps in this method.

[0225] Those skilled in the art will understand that, for the sake of convenience and brevity, the specific working process of the unmanned aerial vehicle system described above can be referred to the corresponding steps in the aforementioned method, and will not be elaborated further here.

[0226] In the embodiments provided in this application, it should be understood that the disclosed systems and methods can also be implemented in other ways. The system and method embodiments described above are merely illustrative. For example, the flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of this application. In this regard, each block in a flowchart or block diagram may represent a module, program segment, or part of code, which includes one or more executable instructions for implementing a specified logical function. It should also be noted that each block in a block diagram and / or flowchart, and combinations of blocks in block diagrams and / or flowcharts, can be implemented using a dedicated hardware-based system that performs the specified function or action, or using a combination of dedicated hardware and computer instructions. Furthermore, the functional modules in the various embodiments of this application can be integrated together to form an independent part, or each module can exist independently, or two or more modules can be integrated to form an independent part.

[0227] The above description is merely an embodiment of this application and is not intended to limit the scope of protection of this application. Various modifications and variations can be made to this application by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the scope of protection of this application.

Claims

1. A distributed cooperative control method for dynamic threat-adaptive unmanned aerial vehicles based on model prediction, characterized in that, The method includes: S10, acquire the current status data and dynamic obstacle data of each UAV in the UAV formation, wherein the current status data includes the UAV's inertial frame position, velocity and attitude angle; S20: For each drone, broadcast the heartbeat packet of each drone and update the dynamic obstacle data in real time. The heartbeat packet includes the drone's own ID, current status information and timestamp. S30, for each drone, based on the received heartbeat packets and real-time updated dynamic obstacle data, determine the threat detection result, which includes the drone's online status, external disturbances, and the distance between the drone and the obstacle; S40, Based on the threat detection results, reconstruct the communication topology of the UAV and the UAV grouping to obtain the desired location of the UAV; S50 determines real-time disturbance estimates based on the nonlinear extended state observer, the current state data of each UAV, and external disturbances. S60, based on the current state data of each UAV, the dynamic obstacle data, the desired position and the real-time disturbance estimate, multi-objective model predictive control optimization is performed using a pre-built multi-objective cost function to obtain the optimal control sequence; S70, based on the optimal control sequence, controls the flight of the corresponding UAV to achieve coordinated control of UAV obstacle avoidance and formation maintenance.

2. The method according to claim 1, characterized in that, The method further includes: S80 determines whether all online drones have reached the corresponding global target trajectory endpoint; S91: When all online drones reach the corresponding global target trajectory endpoint, control all online drones to perform hovering or landing operations. S92, when at least some of the online drones have not reached the corresponding global target trajectory endpoint, repeat steps S10 to S80 until all online drones have reached the corresponding global target trajectory endpoint, and control all online drones to perform hovering or landing operations.

3. The method according to claim 1, characterized in that, Step S30 includes: The online status of the corresponding drone is determined based on the drone's ID and timestamp in the received heartbeat packet; External disturbances are determined based on the strength and frequency of the drone's sensor signals. Based on real-time updated dynamic obstacle data, the distance between the drone and the dynamic obstacle is determined, and the online status, external disturbances, and distance are used as threat detection results. If the online status indicates that the number of currently online drones has increased or decreased, all online drones are controlled to enter a hovering state.

4. The method according to claim 1, characterized in that, Step S40 includes: Configure undirected graph This is used to describe the communication topology of a drone, where the vertex set... , represents a set of drone nodes; edge set , represents the communication connection between drone nodes; if drones i and j communicate directly, it is represented as ; Configure adjacency matrix The elements in the adjacency matrix Represented as: ; in, Indicates time edge set, For self-loop constraints, For bidirectional communication constraints; Configure node online status function , represented as: ; In the formula, This indicates that the drone i is sending heartbeat packets stably according to a preset cycle; This indicates that drone i has not sent a heartbeat packet for a specified number of preset periods; when and hour, drones and Maintain a two-way communication connection; when or hour, This indicates that communication between drones i and j has failed; Based on the online status of the drones in the threat detection results, the online status functions of drones i and j are used. and Update the communication status between drones i and j. ; When drones The adjacency matrix at the current time was detected. Adjacency matrix of the previous period When non-zero element differences exist, a local topology reconstruction is triggered to update the communication topology of all online drones; Based on the updated communication topology, the initial desired position of UAV i is determined. , represented as: ; In the formula, This indicates the grouping center obtained based on the updated communication topology; This represents the preset formation offset of drone i; ; ; In the formula, This represents the grouping center obtained by the local perception calculated by UAV i; This represents the grouping center of the local perception calculated by the UAV j; When the threat detection result indicates that the number of currently online drones has increased or decreased, the offset of each drone is readjusted to obtain the new expected position of the corresponding drone.

5. The method according to claim 1, characterized in that, Step S50 includes: For each online drone, an extended state vector is configured based on the drone's current state data. , represented as: ; In the formula, The inertial frame position vector in the current state data. The velocity vector of the inertial frame in the current state data. The external disturbance vector formed by the external disturbance; The position estimation update equation for configuring the extended state observer is expressed as: ; The configuration speed estimation update equation is expressed as: ; Configure the perturbation estimation update equation, expressed as: ; In the formula, Indicates the estimated position of the drone. The derivative; Indicates the estimated speed of the drone; , and All are gain vectors. Represents the Hadamard product; This refers to the error in position measurement; The derivative of the estimated velocity of the drone; m refers to the mass of the drone; The thrust of a drone; The weight of the drone; Disturbance estimation of drones The derivative; and All are nonlinear factor vectors; δ is the threshold of the linear interval; For nonlinear functions, the corresponding general expression is: ; In the formula, This refers to the position measurement error. Refers to the nonlinear factor vector; sgn() is the sign function; Based on the current state data, position estimation update equation, velocity estimation update equation, and disturbance estimation update equation of each UAV, the real-time disturbance estimate is obtained.

6. The method according to claim 1, characterized in that, Step S60 includes: Configure the state update equation with fused disturbance compensation as the prediction model for model predictive control, expressed as: ; In the formula, Represents the state vector. , Represents the position vector of the UAV; Represents the velocity vector of the UAV; Represents the control vector of the UAV. , The total thrust of the drone, These are roll angle, pitch angle, and yaw angle, respectively. This represents the disturbance estimate of the drone; Based on trajectory tracking cost, control cost, smoothness cost, obstacle avoidance cost, grouping and coordination cost, and terminal cost, a multi-objective cost function is configured as the total cost function; Configure the trajectory tracking cost function used to calculate the trajectory tracking cost; Configure the control cost function used to calculate the control cost; Configure the smoothing cost function used to calculate the smoothing cost; Configure the obstacle avoidance cost function used to calculate the obstacle avoidance cost; Configure the grouping coordination cost function for calculating grouping coordination costs; Configure the terminal cost function for calculating terminal costs; Based on the current state data of each UAV, the dynamic obstacle data, the desired position, the real-time disturbance estimate, and the preset constraints, the goal is to minimize the total cost function. The control sequence corresponding to the minimum total cost is taken as the optimal control sequence. The preset constraints include the prediction model.

7. The method according to claim 1, characterized in that, Step S70 includes: The first control variable in the optimal control sequence is taken as the optimal control variable; The optimal control quantity is converted into control signals for the UAV's actuator motors, so as to control the corresponding UAV flight according to the control signals.

8. An unmanned aerial vehicle (UAV) system, characterized in that, The system includes multiple drones, each drone comprising a processor and a memory coupled together, the memory storing a computer program that, when executed by the processor, causes the drone to perform the method as described in any one of claims 1 to 7.