## 3 System Model and Problem Formulations
### Capacity and Coverage Dimensioning
#### 3.2.3 Optimization Problem and Constraints  
This paper aims to optimize the location of RRU\({}_{\text{m}}\) and RRU\({}_{\text{M}}\) with their minimum number for both dense urban and suburban areas, fulfilling the required data rate and ensuring coverage. We assume all users are connected with at least one of RRU\({}_{\text{m}}\) or RRU\({}_{\text{M}}\), and we also assume that all users have the same demand of equal data rate. Initially, we distribute randomly generated RRU\({}_{\text{M}}\) and RRU\({}_{\text{m}}\) for 5G greenfield. If we distribute enough RRU\({}_{\text{m}}\) and RRU\({}_{\text{M}}\), we can achieve the required data rate and have good coverage, but we need to spend more cost due to more resources and will be costly services. So, we use optimization techniques to locate RRU\({}_{\text{m}}\) and RRU\({}_{\text{M}}\) properly using metaheuristic algorithms fulfilling the required constraints. Now, we define constraints and decision variables and set and formulate objective function and optimization problems.  
Binary Constraints : Binary variables are used for sensing where there is the connection of UE to RRU\({}_{\text{m}}\) or RRU\({}_{\text{M}}\) or not. To address the connectivity with RRU\({}_{\text{m}}\) or RRU\({}_{\text{M}}\), \(\xi_{RRU}\) (\(x^{i},y^{i}\)) is used to check whether the UE located at (\(x^{i},y^{i}\)) is connected to any RRU or not. i.e.,  
\[\xi_{RRU}(x^{i},y^{i})=\begin{cases}1&\text{if there is coverage from any RRU}\\ 0&\text{otherwise}\end{cases} \tag{21}\]But any UE can be connected with multiple RRU\({}_{\text{m}}\) or RRU\({}_{\text{M}}\). But if there is no connectivity, then there is a coverage issue.  
Coverage Constraints: Coverage constraints are ensured for all interest areas when the following equation satisfies,  
\[\frac{\sum_{i=1}^{NUM_{RRU_{M}}}\xi_{RRU_{M}}(x^{i},y^{i})+\sum_{i=1}^{NUM_{ RRU_{m}}}\xi_{RRU_{m}}(x^{i},y^{i})}{NU_{total}}\geq\alpha NU_{total} \tag{22}\]  
where \(\alpha\) is the tolerance factor for relaxing coverage constraints.  
Capacity Constraints: For capacity constraints \(\beta\), the parameters are to be considered: the sector of the antenna and \(NUM_{total}\). Capacity constraints should satisfy the condition,  
\[\frac{\sum_{j=1}^{NUM_{RRU_{M}}}\sum_{i=1}^{N_{RRU_{M}}}\xi_{RRU_{M}^{j}}(x^{ i},y^{i})+\sum_{k=1}^{NUM_{RRU_{m}}}\sum_{l=1}^{N_{RRU_{m}}}\xi_{RRU_{m}^{k}}(x^{ l},y^{l})}{NU_{total}}\geq\beta NU_{total} \tag{23}\]  
where \(\beta\) is the tolerance factor for relaxing capacity constraints.  
Optimization Problem: The main aim of optimization problem is to minimize the number of RRU\({}_{\text{m}}\) and RRU\({}_{\text{M}}\) ensuring required data rate and coverage. The optimization problem (OP) is defined as,  
\[OP:\quad\quad\begin{subarray}{c}minimize\\ p_{j}^{i}\in\{0,1\}^{i},(x_{j}^{i},y_{j}^{i})\sum_{i\in\{RRU_{M},RRU_{m}\}} \sum_{i=1}^{NUM_{total}}\rho_{j}^{i}\end{subarray} \tag{24}\]  
subject to the condition in Equations (22) and (23). Since the optimization problem is an NP-hard problem and computationally complex, we carry out optimization using PSO, GWO, SSA, WOA, ALO, and MPA simultaneously for comparative analysis and select the best-optimized locations of RRU\({}_{\text{m}}\) and RRU\({}_{\text{M}}\).