Maximization through Joint User Association and Power Allocation for a UAV-Integrated H-CRAN

The heterogeneous cloud radio access network (H-CRAN) is considered a promising solution to expand the coverage and capacity required by fifth-generation (5G) networks. UAV, also known as wireless aerial platforms, can be employed to improve both the network coverage and capacity. In this paper, we integrate small drone cells into a H-CRAN. However, new complications and challenges, including 3D drone deployment, user association, admission control, and power allocation, emerge. In order to address these issues, we formulate the problem by maximizing the network throughput through jointly optimizing UAV 3D positions, user association, admission control, and power allocation in H-CRAN networks. However, the formulated problem is a mixed integer nonlinear problem (MINLP), which is NP-hard. In this regard, we propose an algorithm that combines the genetic convex optimization algorithm (GCOA) and particle swarm optimization (PSO) approach to obtain an accurate solution. Simulation results validate the feasibility of our proposed algorithm, and it outperforms the traditional genetic and K-means algorithms.


Introduction
Mobile data traffic demand is growing exponentially each year due to the increased mobile users and advances in traffic-intensive applications [1]. Therefore, the ability of mobile data to meet such rising demands is approaching its limit. In order to meet the higher data rate requirements of future data, networks are becoming more and more intensive [2]. The recent integration of HetNet and the cloud radio access network (CRAN), denoted as the heterogeneous cloud radio access network (H-CRAN), has been identified as a promising solution for fifth-generation (5G) networks [3][4][5].
H-CRAN has been demonstrated to minimize the cost and energy required for HetNet. The coordination between the high-power node (HPN) and the low-power radio frequency remote head (RRH) for interlayer interference mitigation in H-CRAN is performed via the baseband unit (BBU). The RRH is configured to perform symbol processing and simple functions, while the remaining upper layer functions are performed by the BBU pool [6].
User associations between HPN and RRH are the key for improving energy and spectral efficiency. HPN exhibits greater transmission energy compared to RRH. Based on the received power strength, the user tends to associate with the RRH more frequently than the HPN. This creates strong downlink interference for the user equipment (UE), while resulting in uplink interference to nearby UE. Numerous approaches have been proposed in order to reduce this interference. For example, the connection of several RRHs to just one BBU pool allows for more efficient interference management and resource allocation optimization [3]. By controlling the BBU, an RHH can be turned off when it is not linked to a user. This results in an approximate 60% rise in energy efficiency compared to modes where the sleep option is not permitted [7]. The extensive application of RRHs in HetNet hotspots leads to that a number of RRHs and HPNs are available to each user. Thus, each user association in H-CRAN requires an optimization strategy, which consequently has a great impact on the spectral efficiency performance of H-CRAN [3].
There have been many researches focusing on the resource allocation of cloud radio access networks. For example, [8] considered the problem of minimizing both the forward transmission power and the system energy consumption under the CRAN architecture. In [9], the architecture of H-CRAN was further considered by minimizing the network energy consumption of the cell based on the maximum transmit power and the guaranteed user service quality. Following on from this, [10] focused on maximizing the energy efficiency of the system using the rate, QoS, and transmit power as constraints. [6] maximized the system capacity with minimum rate constraints. [11] optimized the network output by focusing on problems related to joint user association and the distribution of energy in H-CRAN. Table 1 provides a brief comparison of the current literatures.
In particular, wireless communication technology allows for the rapid application of UAVs as airborne base stations (BSs). Aerial deployment is considered as a promising approach for the universal access from air to ground user equipment (UE) in designated areas during temporary events (e.g., hot spots and events in large public spaces) [18][19][20][21][22][23][24]. Such dynamic aerial BSs are able to dynamically adjust their positions and altitudes to provide air-to-ground (A2G) links, which are superior to ground-based static BSs. The application of aerial BSs is considered as beneficial to the existing cellular systems, which can enhance the wireless capacity and coverage on the ground. This can meet the requirements of uses in 5G and beyond 5G (B5G) networks.
The main bottlenecks related to UAV communications include the 3D deployment of UAVs, energy efficiency, resource allocation, and cell association. Existing research on UAV communications generally focuses on ATG channel model. For example, [24] provided a statistical ATG propagation model for low-altitude platform (LAP) frameworks, whereby the elevation angle is the main factor controlling the LoS channel probability. In addition, [25] investigated the shadow and path loss effects of UAV communication in dense urban environments. [26] highlighted the relationship between the aerial BS height and ATG properties, resulting from the impacts of path loss and shadows. [27] provided an in-depth review of ATG propagation models in the recent literature.
In order to overcome the challenges associated with UAV deployment, [28] proposed an approach that optimizes UAV height for maximum ground coverage, while [29,30] introduced a framework for on-demand coverage of a UAV airborne network. In order to attain the maximum number of potential users, [31] optimized the layout of UAVsupported small units for terrestrial wireless networks. Although current research has provided valuable insights into UAV communications, they are applicable to single-UAV systems. Multi-UAV deployment is more challenging as the system coverage is a function of the distance between the UAV-BSs and their positions. [32] proposed a novel framework for the efficient connectivity of energy-saving rechargeable UAVs in regions that are highly urbanized. In addition, [33] investigated the impact of intercell interference on the coverage of two fixed-height UAV BSs. [34] employed multiple UAVs in a wireless relay for ground sensor node communication, yet the UAVs were not used as airborne BSs. A multi-UAV throughput analysis approach is proposed by [35] for wireless networks, with an equal hovering height and frequency for each UAV hover. In particular, the cochannel interference induced on the ground was minimized by applying a system based on power control. [36] determined the minimum number of BSs for multiple ground users by optimizing the horizontal two-dimensional UAV position specific for a fixed flying height. Furthermore, [37] optimized the deployment of multiple symmetrical UAVs with equal transmission power and height.
Different from the aforementioned works, UAV-assisted H-CRAN is employed to optimize network throughput via ground-based macro BSs, RRHs, and aerial UAV platforms. In this paper, we propose an approach that optimizes 3D positions of multiple UAVs, user association, admission control, and power allocation in order to maximize system throughput and user numbers. In order to solve this radio resource management problem, we introduce a two-layer optimization framework. First, the position of the UAV is fixed, and the optimum user association matrix and connection power are then determined in order to maximize a single UAV position value. The UAV position is optimized, and the optimal value is subsequently derived for different UAV positions, thus obtaining the approximate optimal solution of the system.
The main contributions of this work are summarized as follows.
(1) In order to improve the user service quality, we consider a UAV-assisted resource allocation in the H-CRAN system. The system model is established by jointly determining the optimal 3D UAV position, user association, admission, and power distribution. By adjusting the 3D position of the UAV and the user association and combining the power distribution of RRH and UAV, the maximum system throughput is achieved (2) We formulate a mixed integer nonlinear programming problem (MINLP). More specifically, the 0-1 integer constraints of user association and power allocation in the model are integrated with the branch and bound method to propose an approach based on genetic convex optimization that maximizes user association and resource allocation. In addition, a particle swarm optimization algorithm is implemented to optimize the 3D UAV position (3) We prove that the proposed algorithm exhibits polynomial-level computational complexity, with an improved performance compared to that of traditional genetic algorithms, and the greedy heuristic and discrete particle swarm optimization. Furthermore, we prove that the performance of the proposed particle swarm optimization algorithm is superior to that of the uniform distribution of UAV and base station and K-means algorithm The rest of the paper is organized as follows. The system model and MINLP problem formulation are introduced in 2 Wireless Communications and Mobile Computing Section 2. The genetic convex optimization algorithm and particle swarm optimization are introduced in Section 3.
The numerical results are detailed in Section 4. And Section 5 concludes the paper. Table 2 lists the notation and abbreviations used throughout the paper.

System Model and Problem Formulation
2.1. System Model. The system model is shown in Figure 1. When the system is initialized, the UAVs will quickly move to an appropriate location according to the user's distribution and QoS requirements and hover in place, until the service is provided for the user, or the user distribution changes.
We assume that the cloud radio access to heterogeneous cellular networks forms a heterogeneous cloud radio access network (H-CRAN). The network includes macro cell eNB, R RRHs, and E UAV radio heads. A total of S = 1 + R + E subcells and M users are randomly distributed within the network. The user, RRH, and UAV sets are denoted as M = f1, 2,⋯,m,⋯,Mg, ℝ = f1, 2,⋯,r,⋯,Rg and E = f1, 2,⋯,e,⋯, Eg, respectively. Users are able to connect to the macro cell, UAV, or a RRH to transmit data when needed. The RRHs, UAVs, and eNB are connected to a centralized baseband unit pool for effective resource allocation. In addition, the UAV, macro cell, and RRHs share N μW subcarriers.
We can express the power of the uplink and downlink from the n-th user connected to the macro cell, RRH cell, and UAV cell as p ul ðMac,nÞ , p dl ðMac,nÞ ,p ul ðRRHðϕÞ,nÞ , p dl ðRRHðϕÞ,nÞ , p ul ðUAV ðeÞ,nÞ , and p dl ðUAVðeÞ,nÞ , respectively. The sequence number of RRH is represented by ϕ.

Channel
Model. Two types of channel models are employed in the network, namely, the air-to-ground (A2G) channel model (including UAV-to-UE channels) and the ground-to-ground (G2G) channel model (including userto-RRH and user-to-eNB channels).
2.2.1. Ground-to-Ground Channel Model. When the distance between user m and radio unit i is less than the maximum service distance, radio unit i can serve user m. In addition, each user can only be connected to one radio unit (macro cell, RRH, or UAV). The antenna gains of the macro cell and RRH are denoted as G 0 and G R , respectively. The channel gain of the n-th user connected to both the macro cell and RRH can be described as follows: where LP eNB and LP RRH are the path loss when the user is connected to the macro cell and RRH, respectively. In this paper, the Okumura-Hata model is applied for the path loss of the ground user connection and is expressed as follows: where f is the operating frequency (MHz), h b is the effective height of the base station antenna (m), h m is the effective height of the user antenna (m), d is the distance between the user and the base station (km), and α ðhmÞ is the user antenna height factor. For large cities, the user antenna height factor is defined by the following formula: 2.2.2. Air-to-Ground Channel Model. The wireless link between the ground nodes and UAVs in the proposed problem exhibits both LoS and nonline-of-sight (NLoS) elements. This is attributed to multipath and shadow effects. Note that we only consider the LoS components for the UAV system due to the high flight altitude and limited number of obstacles. Such components can be modelled with free space path loss methods. Two approaches can be employed to characterize the NLoS components: (i) the probabilistic line-of-sight channel model, whereby elevation and altitude are used to express the space-to-ground line-of-sight channel probability. Research has demonstrated higher LoS link probabilities for high UAV altitudes and minimal ground obstacles (e.g.,   The distance between user n and corresponding UAV e is where x e , y e , and z e represent the x, y, and z coordinates of UAV e in the Cartesian plane, respectively. The height of UAV e is described as z e = s e tan ðθ e Þ, where s e is the 2D distance between m and e. θ = π/2 -υ and υ is the halfbeam width angle of the UAV. Similarly, the LoS probability between e and n is given by PðLoS, θÞ = 1/1 + a exp ð−bð½θ − aÞÞ [28], where a and b are constants depending on environment type (e.g., rural, urban, and dense city). The UAV path loss can thus be described as follows: where η LoS and η NLoS (dB) represent the average additional loss for the LoS or NLoS links relative to the free space propagation loss.
The average path loss between e and corresponding user n is then expressed as follows: Thus, the channel gain when user n is connected to UAV e can be calculated according to the following: where G E denotes the antenna gain of the UAV.

Problem Formulation.
The channel capacity when the user is connected to the macro eNB, RRH, and UAV can be, respectively, expressed as follows: The user channel capacity matrix can then be determined as

Wireless Communications and Mobile Computing
The user can subsequently select the optimal channel for the required connection based on the channel information.
We assume that each user n is associated with just a single RRH or UAV. Based on this, the cell indicator matrix is defined to be associated with the user is as follows: where a ij ∈ f0, 1g. a i1 = 1, a i,1+m = 1, and a i,1+W+l = 1 denote the connection between the i-th user and the macro cell, RRHm, and the l-th UAV, respectively. Each of the matrix rows has just one value > 0, with the rest equal to 0. If the minimum channel capacity requirement for user i is Γ min i ; then, the minimum channel capacity requirement matrix is expressed as follows: The goal of this paper is to determine the optimal 3D layout of the UAV under the user QoS and power allocation constraints and to jointly consider user association and power allocation to maximize the system throughput. The optimization problem can be written as P0: subject to : where C1 denotes the requirement of all user communication rates to exceed the minimum value Γ min i , C2, C4, and C6 are the user uplink power constraints, C3, C5, and C7 are the user downlink power constraints, C8 is the user access strategy and is based on the 0-1 variable, C9 indicates that each user can only be connected to one RF unit, and C10 indicates that users must be connected to the radio unit within its service range.
The solution to this problem is a function of the user association matrix, the UAV 3D position, and the power allocation. Furthermore, the problem is of the NP-complete nonconvex mixed integer type, and thus, exhaustive searching is needed. The calculation costs of the exhaustive search algorithm increase significantly with both the number of users and RRH. In order to overcome this, we employ an intelligent search algorithm to determine an approximate optimal solution, with a relatively low computational complexity.

Proposed Algorithm
3.1. Basic Principle. Determining a solution to the problem described the series of equations in (12) proves to be a challenge due to the presence of both integer and continuous variables and nonlinear behavior. It is thus transformed into a complete NP problem for high numbers of licensed users.
P0 in (12) is a MINLP problem and is thus NP-hard. The branch and bound approach is widely used to estimate an accurate solution for this type of problem. Despite its popularity, the computational complexity of this approach, which is just 2-3 times smaller than that of the brute force method, becomes excessive once the number of users and F-APs reach a certain level. Therefore, the greedy algorithm is used to solve P0 due to the greater performance of the genetic and particle swarm algorithm fusion.
Furthermore, the channel capacity and the user association matrices in the P0 are affected by the final result. In addition to the perceptible channel environment, the channel capacity matrix is a function of the power matrix, the relative position of the user, and the radio frequency unit. Under the same association matrix, if the connection is distinct to the drone position, the final throughput gap will be very large. Therefore, we solve the problem P0 using the following steps. First, the position of the drone is fixed in order to determine the optimum user association matrix and connection power. The position of a single drone is then optimized, and the optimal value of this position is then obtained at different UAV positions to estimate the optimal solution of the system.

Optimal User Association Matrix and Power Allocation.
Once the position of the UAVs is fixed, problem P0 is It can be seen that the problem after conversion depends on the association matrix A M×S and power P. Since the user association matrix is still {0, 1} variable, this problem is still a MINLP problem. Further, we fixed the incidence matrix. The association matrix A M×S is then determined, and P1 can subsequently be converted into the following problem: Standard convex optimization can be used to solve the affine exponential sum as it is a typical convex optimization problem.
Thus, the problem P1 compromises two components: (i) the convex optimization of the association matrices and (ii) determining the optimal association matrix via a genetic algorithm. This two-step approach is described as a genetic convex optimization algorithm (GCOA), with the specific procedure detailed as follows. The algorithm flow is shown in Figure 2.

Chromosome Expression.
Assuming that the optimal power allocation scheme for each connection is known, the genetic algorithm optimizes the power association matrix. More specifically, the user association matrix is taken as a chromosome expression as follows: where a ij ∈ f0, 1g. a i1 = 1, a i,1+m = 1, and a i,1+W+l = 1 denote the connection between the i-th user and the macro cell, RRHm, and the l-th UAV, respectively. Each of the matrix rows has just one value >0, with the rest equal to 0.

Generation of the First Generation Chromosomes.
In order to obtain excellent simulation results, the first generation chromosomes were carefully selected in this paper. It is foreseeable that connecting all users to the base station with the best channel conditions is an excellent method. And it is also a possible result that all users access the eNB. Therefore, when selecting the first generation chromosomes, these two schemes are regarded as two of the first generation chromosomes. The remaining chromosomes are randomly generated.

Evaluation Function.
The objective function of our framework must satisfy the user QoS and power allocation constraints to maximize the system throughput and can thus be directly applied as the evaluation function U i = max a,p ∑ i,j ða ij · C ij Þ.

Genetic
Operations. The chromosome inheritance can either originate from preservation or cross mutation. For our framework, we retain the top 25% of the chromosomes. According to the roulette selection method, chromosomes are selected for cross mutation. The selection is based on the size of the objective function value. Make the chromosome with the larger objective function more likely to be selected, and make the chromosome with smaller objective function less likely to be selected. p i = U i /∑U is the probability that a chromosome is selected.
(1) Crossover. A column is randomly selected as the crossover point for the central region of the chromosome. High (low) fitness functions are used to identify which chromosome gene segment is kept prior to (following) the intersection, thus determining a new chromosome.
(2) Variation. Chromosome variation is crucial for chromosome diversity. In our framework, we achieve chromosome variation by randomly generating the number key in [1][2][3].
If key = 1, no mutation will be performed; if key = 2, a gene point on the chromosome will be randomly selected for a 0, 1 transformation; if key = 3, the whole chromosome is flipped based on the mutation probability. This ensures that a certain amount of variation is included in the next generation population.

Stop Condition.
The stopping condition of the algorithm is set to stop automatically when the number of iterations reaches a predetermined value. In addition, if the algorithm has not updated the optimal value for 15 consecutive iterations, it is considered that the iteration can be stopped.
Algorithm 1 describes the steps of this algorithm.

Optimal UAV 3D Location.
Since the position of the drone has a crucial influence on the result, in addition to determining the user association matrix, the optimal position of the drone also needs to be determined. In this paper, particle swarm optimization is used to find the optimal 3D position of the drone. Specific steps are as follows.
3.3.1. Initialization. This initial step includes the establishment of the maximum iteration number and the initialization of the population position and maximum particle speed. The space to be searched is taken as the position information, and random points on the speed range and search space are chosen for the initialization. Each particle is then initialized at a random flying speed, with M denoting the particle swarm size.
As the goal of this algorithm is to determine the optimal UAV 3D position, the initial population is set as the initial position of the UAV. It is foreseeable that the uniform distribution of drones and base stations in the entire area is an 7 Wireless Communications and Mobile Computing excellent choice. Therefore, take it as one of the initial positions, and randomly generate positions in M-1 areas as the initial positions of the drone.

Fitness Function.
The objective function must satisfy the user QoS and power allocation constraints in order to maximize the system throughput. Therefore, the objective function can be employed as the evaluation function, such that max a,p,d UAVðeÞ

Update Speed and Position.
The fitness value of each particle is then calculated based on the fitness function. This enables the updating of the speed and position based on the following formula: where r 1 and r 2 are numbers that are randomly generated at each iteration, s 1 and s 2 are learning factors that represent the learning proportion to the global optimal solution and optimal position for particle i, respectively, p i is the current optimal position of particle i, p g is the optimal position for all particles, and w is the inertial weight. Greater values of w simultaneously result in a slower convergence speed and a stronger the ability to jump out of the local optimal solution. Algorithm 2 describes the steps of this algorithm.  Wireless Communications and Mobile Computing 3.3.4. Algorithm Complexity. The computational complexity of genetic algorithms and particle swarm optimization is generally a function of the number of iterations. In particular, each gene in the genetic algorithm must solve an NLP problem once per iteration. If m genes are generated and n iterations are performed, then m × n NLP problems need to be solved. In addition, during the particle swarm optimization process, the genetic algorithm must be solved in order to update each particle position. Thus, if m 1 particles are generated and n 1 iterations are performed, a total of m 1 × n 1 genetic algorithms must be solved, that is, m × n × m 1 × n 1 NLP problems. Hence, the computational complexity of the algorithm is at the polynomial level.

Simulation Setup.
In this section, we compare the UAVintegrated H-CRAN with the traditional terrestrial BS based H-CRAN. We then simulate scenarios with varying UAV 3D positions. For the simulations, the cell radius is set to 1 km and the maximum user power is 1 W. Users are randomly distributed in a cell of 1 km radius. Two fixed RRHs are located in the cell. Table 3 lists the primary simulation parameters.

The Impact of UAVs on User Association.
In this section, we investigate the impact of UAVs on user association. 1: Initialization: m = 0, G 0 , G R , G E , N 0 , p max ðMac,nÞ , P max eNB , p max ðRRHðϕÞ,nÞ , P max RRHðϕÞ , p max ðUAVðeÞ,nÞ , P max UAVðeÞ 2: Calculate the channel gain. 3: Produce the first generation genetic factors. 4: Use convex optimization to calculate the best power allocation P 0 i . 5: Calculate the fitness function ad 0 i . 6: Set the maximum number of iterations n. 7: while m < n 8: Calculate the selection probability of each genetic factor. 9: Select the best 1/4 of genetic factors to retain into the next generation. 10: According to P i , select genetic factors to for crossover. 11: Cross the selected genetic factors in pairs. 12: Generate mutated random integer rand int ∈ f1, 2, 3g. 13: if randint = 1 then 14: No changed. 15: else 16: if randint = 2 then 17: Randomly select a gene point on the chromosome for 0,1 transformation.  Calculate the fitness function of each particle according to Algorithm 1 7: Update speed and position according to formula (15). 8: k = k + 1. 9: end while 10: Output: Best 3D position of drone. 11: Calculated maximum sum rate.
Algorithm 2: Particle swarm optimization. 9 Wireless Communications and Mobile Computing Figure 3 presents the user associations of 0 and 2 UAVs when the number of users increases from 10 to 50, respectively. All users are observed to connect to the eNB when the number of users is less than 30. Users subsequently begin to connect to the RRHs for user numbers greater than or equal to 30. For the 2 UAV system, even if the number of users is less than 30, users remain connected to the UAV. In addition, the number of users connected to the UAVs is greater than those connected to the RRHs. However, the number of users connected to the eNB is generally larger and significantly more those connected of the RRHs and UAVs. This is attributed to the significantly greater antenna gain of the eNB compared to that of the RRH and UAV. Therefore, for similar channel conditions, the gain of the user connected to the eNB is higher than the corresponding gain from the RRH and UAV. Once the allocable power (20 W) of the eNB has been allocated, a continuous connection with the eNB will reduce the power of the connected users, and thus, users will connect to the RRHs or UAVs with their similar channel conditions and sufficient power.  In order to further explore the impact of UAVs on user association, we perform simulations with an eNB antenna gain equal to that of the RRHs and UAVs. Figure 4 presents the simulation results. The reduction in the eNB antenna gain to that of the UAV and RRH significantly decreases the number of users connected to the eNB. This is a result of the signal channel used to determine the transmission rate for equal antenna gains. In a system without UAVs, the number of users connected to the eNB is approximately 1/2 of that of the RRH. However, once the user number reaches 11 Wireless Communications and Mobile Computing 20, continuing to connect with the RRH will reduce the power. Thus, more users are connected to the eNB, with poor channel conditions but with enough power.
For the 2-UAV system, when the number of users is low, they are more inclined to connect with the UAVs. This is attributed to the greater line-of-sight probability of the UAV compared to the ground base station, as well as the potentially better channel conditions. However, this preference changes when the number of users connected to the drone reaches 20 due to the insufficient power allocation of the UAVs. In order to display the user association more intuitively, Figure 5 depicts an example UAV distribution and corresponding user association. The blue square, red star, and green circle indicate the eNB, UAV, and RRH, while the blue, red, and green crosses are the users connected to the eNB, UAV, and RRH, respectively. It can be seen from Figures 5(b) and 5(c) that the user allocation of the Kmeans algorithm and the PSO algorithm is the same, but the location of the drone is different. This is also the reason why the performance of the PSO algorithm is better than that of K-means, that is, a better UAV position has been found. This is more obvious when the system includes 4 UAVs and no RRH. As shown in Figure 6, the K-means algorithm only cares about the distribution of users, and the purpose is to make the UAV distance as close as possible to all users. But in fact, not all users who are closer have better channel conditions. The PSO algorithm comprehensively considers the user's channel conditions, correlation, and power allocation, so the performance is better.

Impact of UAVs on User Sum
Rates. In this section, we evaluate the impact of drones on the total communication rate of the user. Figure 7 shows the comparison of the total user rate of the system with the assistance of different numbers of UAVs.
The total user rate for UAV-assisted systems is significantly higher than that of the system with no UAV. This is a result of the higher line-of-sight probability for the UAV, as well as improved channel conditions compared to the RRH. With the increase in the number of UAVs, this is more obvious, because through the PSO algorithm, drones find more suitable hovering locations. However, as the number of drones increases, the channel gain brought by the increase of drones is getting lower and lower. Therefore, the increase in the total user rate becomes insignificant.
In order to eliminate the possible rise in the total rate due to differences in BS numbers, simulations are performed with the total number of pico-BSs (RRH and UAV) set to 4. The following systems were used: 4 RRHs and 0 UAVs, 2 RRHs and 2 UAVs, and 4 UAVs and 0 RRH. Figure 8 demonstrates that the overall system rate is significantly greater with the presence of UAV assistance, even for an equal number of BSs. In addition, the total rate increases with the number of UAVs. More specifically, under the same circumstances, the UAV performance surpasses that of the RRH. Thus, the application of UAV assistance can increase both the system sum rates and system coverage.

Performance Comparison across Algorithms.
In this section, we compare the performance of the two proposed algorithms, namely, the genetic convex optimization algorithm (GCOA) and particle swarm optimization (PSO). We simulate the convergence speed for the algorithms and compare them with those of commonly used algorithms.   4.4.1. GCOA Performance Analysis. The user association problem of the GCOA is of the MINLP type. Genetic algorithms exhibit an improved performance compared to other approaches for discrete problems. Figure 9 presents variations in the fitness function of the genetic algorithm for incrementing iteration steps. Our proposed algorithm converges rapidly to a more optimal result compared to the traditional algorithms. In addition, the performance improves with iteration step, with the optimal value converging at a specific iteration number. Figure 10 compares the GCOA, outer approximation method (OA), a traditional genetic algorithm (GA), and the greedy heuristic algorithm (GHA). Users access the RF unit with the highest channel gain, while the position of the drone is fixed in order to determine the optimal access for the performance comparisons. The performance of the 5 access strategies is equal for user numbers of 10-20. This is attributed to the enough power for low user numbers, allowing for user access based on the channel conditions. As the number of users rises, the optimal channel conditions are unable to meet the user needs, resulting in variations in algorithm performances. In particular, the higher the number of users, the stronger the performance superiority of GCOA.

PSO Performance Analysis.
We next analyze the performance of the particle swarm optimization method. Figure 11 presents variations in the particle swarm algorithm fitness function across iteration steps. The particle swarm algorithm is able to rapidly converge to an improved result compared to the other algorithms, with the performance improving with the iteration number. The optimal value subsequently converges after a specific number of iterations.     13 Wireless Communications and Mobile Computing Figure 12 compares the performances of the K-means, UAV uniform distribution, and proposed PSO algorithms. The PSO algorithm exhibits a significantly better performance compared to the other two algorithms in terms of locating the UAV 3D position. This improvement in performance increases with user number.
Note that for the 2 UAVs and 2 RRH systems, the Kmeans algorithm performance does not exceed that of the UAV uniform distribution approach. This is attributed to the absence of the RRH position during the K-means clustering. Some extent covers the same range of users as the RRH, so that the situation of some users with poor channel conditions has not improved. In order to eliminate the influence of this factor, we removed the RRHs and performed the simulations with just the UAVs. Figure 13 demonstrates the significant improvement of the K-means algorithm performance in determining the UAV position following the removal of the RRH on the UAV position. Despite this, our proposed PSO exhibits the optimal performance.
With just the UAV as a base station, the K-means algorithm converges rapidly to a suboptimal solution. However, the presence of ground base stations cannot be ignored in practical systems. Furthermore, our proposed algorithm presents promising results for all systems. And its performance is also due to the K-means algorithm, and the UAV is evenly distributed.

Conclusion
In this paper, we considered the location optimization and resource allocation for a H-CRAN system integrated with UAVs. First, we formulated the MINLP problem in order to maximize the total user rate. Then, a genetic particle swarm optimization algorithm that is able to determine the optimal UAV 3D position, user access, and power allocation was proposed to solve the optimization and allocation problem. Specifically, the genetic convex optimization algorithm was employed for a fixed UAV position in order to obtain the optimal user association and power allocation. Particle swarm optimization then determines the best UAV 3D position. The algorithm includes the advantages of genetic algorithms for discrete problems as well as the fast convergence of particle swarm optimization. Simulation results demonstrated the superiority of the proposed algorithm, with the UAV-assisted H-CRAN exhibiting a better system performance compared to the traditional H-CRAN. The time complexity of the proposed algorithm is completely dependent on the number of iterations and is of the polynomial-level time type. Therefore, the proposed solution can effectively solve problems of joint UAV deployment, user association, and power allocation for future 5G and beyond 5G networks.

Data Availability
All data are explained in the paper.

Conflicts of Interest
The authors declare that they have no conflicts of interest.   14 Wireless Communications and Mobile Computing