# Blockchain-Based UAV-Assisted Mobile Edge Computing for Dual Game Resource Allocation
## 3 Model of a Drone-Assisted Mobile Edge Computing System
### DSO Double-Decker Game Rationality Analysis  
The main difference between the DSO (two-stage optimization) algorithm and existing resource allocation strategies lies in its innovative design of a hierarchical optimization framework, a dynamic game combined with auction, real-time dynamic pricing, complex environment adaptability, and blockchain integration. First, the DSO algorithm uses a two-stage optimization framework that combines Stackelberg games and multi-attribute auction mechanisms to hierarchically address the resource allocation problem among ECSs, UAVs, and UEs. It takes into account resource pricing and bidding, improving the efficiency and fairness of the system. Existing strategies, on the other hand, mostly use a single-stage centralized approach, which is difficult to handle dynamic competition among multiple entities. Second, the DSO algorithm uses a Stackelberg game model in the first stage to achieve dynamic pricing of resources by ECS, and in the second stage uses a multi-attribute auction mechanism to ensure that users bid for resources according to demand, optimizing revenue and resource utilization. Existing methods usually use fixed pricing or static optimization and cannot adaptively respond to changes in demand. In addition, the DSO algorithm is more robust in complex dynamic environments and can adjust resource allocation in real-time according to user needs and drone movement. Traditional methods usually assume a static environment and are not adaptable enough. More importantly, the DSO algorithm combines blockchain technology to use smart contracts to automate and transparently trade resources, ensuring data immutability and secure authentication, and avoiding the single point of failure and data tampering risks of centralized methods. In summary, the DSO algorithm solves the deficiencies of existing resource allocation strategies in terms of dynamics, incentives, adaptability, and security through multi-level dynamic games and blockchain integration, significantly improving the efficiency, fairness, robustness, and transparency of resource allocation in the UAV-MEC system. The proposed two-tier game-based resource allocation approach offers significant improvements over existing security frameworks for drone-assisted mobile edge computing (MEC) in several ways. Existing security frameworks typically focus on static resource allocation or a single security mechanism, which often fails to effectively address dynamically changing environments and complex resource requirements. In these frameworks, resource allocation decisions are often inflexible and vulnerable to malicious node attacks or system overload. In contrast, the optimization algorithm based on the two-layer game proposed in this study optimizes the resource allocation between servers and UAVs through the Stackelberg game theory, and further optimizes the resource allocation between UAVs and users through the auction algorithm, which forms a multilevel resource scheduling system that can better cope with different levels of demands. This method not only improves the efficiency of resource allocation, but also can deal with the interests of multiple parties more fairly and avoid the possible bias of a single decision-making mechanism. The proposed optimization method considers the resource scheduling problem in dynamic and heterogeneous environments, and can dynamically adjust the resource allocation strategy according to the real-time network state and user demand, with stronger adaptability and robustness. This feature enables the method to better meet the changing demands in practical deployment, especially in rapidly changing application scenarios such as urban air transportation and disaster emergency response. Therefore, the proposed method not only enhances safety while improving system performance, but also provides a more flexible and efficient solution for future UAV-assisted MEC systems.