The second problem is to find the set of active base stations, their orientation, and transmission power to achieve the optimum coverage and capacity assignment to users. The problem is separated into two parts.

#### 1 Transmission Towers Construction

We define the concept of

*Transmission tower*as a fixed set of active base stations placed at one active site. One site can have many*transmission towers*but only one of them can be active. We try to explore different alternatives for the number of antennas, their transmission power, orientation, and radiation pattern. After we build them, the problem reduces to choose one of them from every available active site.
The process begins with a set of candidate sites. We discard candidate sites with very low coverage. Also, if there are two sites with similar coverage, we discard the one with the lowest coverage. To build the

*transmission towers*at one site, we begin placing one omni-directional antenna with the maximum transmission power. If this base station is not saturated, i.e., all covered users can connect to it, then we create several*transmission towers*with one single antenna and different transmission powers, chosen from a set of discrete values. We use also 120° and 180° sectorized antennas.
On the other case, if the first omni-directional antenna base station is saturated, i.e., not all covered users can connect because of capacity restrictions, then we build a set of

*transmission**towers*composed of several antennas with 120° and 180° sectors. We use all possible combinations of transmission power and sectors to build several options for the site. We solve coverage and capacity assignment by previously described algorithms to find the orientation of each set of active base stations. We finally remove redundant*transmission towers*from the set of available ones. We solve this for every site to get a set of*transmission towers*and a matrix that keeps a record of the users that connect to each one of them. This information is used in the optimization process.#### 2 Optimization Process

In this process, we try to find the set of active

*transmission towers*to optimize coverage and connect the highest number of users. We fix the number of sites during one execution of the algorithm to find the best solution. After that, we increment the number of sites and run the algorithm once again. At the beginning, we start from an empty solution, then we try to improve it by activating, deactivating, or moving*transmission towers*. We do this every iteration using a probabilistic model to decide if a new solution is chosen or not over the current one. However, we keep track of the best solution that has been reached so far. The iterative process has two main components:*Building of a new solution*: In this process, we start from the current solution and try to improve it by a randomly chosen modification. Our modifications are based on those presented in Ref. [20]. We can deactivate any*active transmission*tower and activate any inactive*transmission tower*. We deactivate an active*transmission tower*randomly by assigning a deactivation probability inversely proportional to the number of users connected to it. We activate a new transmission tower randomly by assigning an activation probability proportional to the number of uncovered users that could connect to it. A new solution is analyzed for a feasible channel assignment by trying several combinations to reduce interference. We fix the number of available channels. We finally use the channel combination that has the lowest interference level, represented by the highest number of connected users.*Optimization process*: This algorithm iterates, comparing the new candidate solution and the current solution. This is the core process for simulated annealing, in which a new candidate solution replaces the current solution according to the improvement and the temperature of the system. If the candidate solution is better than the current solution, it is accepted. Otherwise, it has an acceptance probability that depends on how bad is the new solution with respect to the current solution and the temperature of the system. This process keeps track of the current solution and the best solution ever found.

The metric used to decide the performance of a solution is the percentage of users that could connect to any base station. It means that a better solution has more connected users than a previous one. We must recall, that other optimization criteria are included in the inner process.

- Interference is reduced during the building of a candidate solution by choosing the lowest interference channel assignment, i.e., each new candidate solution tries to increase the number of connected users with the minimal interference.
- For the iteration process we add and remove base transmission towers to the new candidate solution. If we have two solutions with similar number of connected users, we choose the one with the lowest number of base stations. This way we reduce the cost related to the number of base stations.
- The QoS guarantees are included in the User-Base station assignment model, where we try to connect users to base stations according to their spectrum efficiency. Also, in the Capacity assignment model, if we connect a user to a base station, we guarantee that the requirements are satisfied.