Space-air-ground integrated network has the advantages of extensive coverage,high throughput,and strong elasticity.A resource allocation algorithm for dense scenarios is proposed to solve the problems of network congestion and deterioration of service quality caused by concurrent access of many users and network load imbalance.Firstly,the user utility function is constructed based on the user demand and the preferences of different types of user tasks.Then,load balancing is realized based on the matching game network selection algorithm and the power control algorithm combined with the dual ascending method,and the resource allocation scheme is optimized.Experimental results show that compared with the traditional strategy,the proposed strategy increases the overall user access rate by at least 35%,and improves the performance of delay and throughput by more than 50%.Load balancing is more effective in dense scenarios and network performance is improved.