## 3 Clustering Model for UAV Systems
### Network Clustering Process  
#### 3.2.1 Information Exchange Process Between Nodes  
In the network clustering process, the information exchange between nodes is mainly divided into five main phases: network partitioning, node neighbor discovery, cluster head and backup cluster head selection, cluster head invitation, and cluster member joining and confirmation. Each phase involves specific message exchanges that ensure efficient organization and stable operation of the network. During this process, five types of messages are primarily transmitted: Partition message, Hello message, C_Clustering message, C_Reply message, and C_Update message. The following is a brief overview of each message type:  
* Partition message: Sent by the ground control station to notify UAV nodes of the initial partitioning results and task information. * Hello message: Used for node sharing of basic information to perform initial partitioning, cluster head selection, and backup cluster head selection. * C_Clustering message: Sent by the cluster head node to inform other nodes within the partition to join its cluster. * C_Reply message: Used by cluster members to reply to the cluster head, informing it of new nodes joining the cluster. * C_Update message: Sent by the cluster head to notify all nodes within the cluster of the updated cluster member information. Subsequently, we will provide a detailed description of the work processes for each phase, including the specific operations, message transmissions, and node interactions involved in each phase. 1. Network partitioning stage  
Upon receiving the mission information, the ground control station obtains the location data of all nodes and performs initial regional partitioning of UAV nodes using a partitioning algorithm based on the number of tasks. The partitioning results are then broadcast to all nodes via Partition messages, which contain details such as node IDs and tasks for each partition. Upon receiving their respective partition information, nodes update the Cluster ID field in their Hello messages and store the corresponding partition node list. 2. Node neighbor discovery stage  
After partitioning, all nodes remain in a \"pending\" state. Each node periodically broadcasts Hello messages to perform neighbor discovery within its partition. These messages allow nodes to gather information such as the position, velocity, and residual energy of neighboring nodes. Based on this information, each node computes a local weight value using a predefined weighting formula and includes this weight in its subsequent Hello message broadcasts. 3. CH and BCH node selection Stage  
Nodes collect the weight values from neighboring nodes within the same partition via Hello messages and compare them with their own. The node with the highest weight is selected as the cluster head. In the case of equal weight values, the node with a greater number of neighbors is preferred. Both a primary cluster head and a backup cluster head are selected through this process. 4. Cluster Head Invitation Phase  
The selected cluster head broadcasts a C_Clustering message to invite other nodes to join the cluster. It then waits for incoming C_Reply messages from prospective cluster members. Upon receiving a C_Reply, the cluster head updates its member list and subsequently broadcasts a C_Update message to all confirmed cluster members. This message includes the updated member list and the assigned time slots for communication. A portion of the time slots is reserved for future node additions. The cluster head further compares the current cluster member list with the partition node list. If the number of joined members does not meet the predefined threshold, it will re-broadcast the C_Clustering message repeatedly until the required number is met or the clustering time limit is reached. * Cluster Member Joining and Confirmation Phase Backup cluster heads and candidate member nodes listen for C_Clustering messages.