## 4 A Hybrid Algorithm for Power Allocation in Macrocell/Femtocell Architecture  
Giving the fact that all the femtocells are deployed within the umbrella of the macrocell using a full frequency reuse scheme, the transmission signal from FBSs will cause a strong interference to neighboring MUEs, leading to a large degradation of their received \(SINR^{k}_{M,MUE_{i}}\). The aim of the femtocell power adjustment is to maximize the sum of the macrocell and femtocells' throughputs, while satisfying both MUEs' and FUEs' SINR requirements. In order to proceed, we propose an algorithm to achieve the above-mentioned objective through the following steps: (i) defining clusters according to the geographical locations of interfering Fs; (ii) dividing clusters into sub clusters of Master/Slave-Fs; (iii) applying centralized power allocation in Master-Fs clusters; and (iv) applying distributed power allocation to Slave-Fs clusters. Our aim is to increase the spectral efficiency of MUEs, decrease the signaling overhead caused by the fully centralized power allocation method and decrease the time calculation in M which is needed to allocate RBs to all interfering femtocells (Figure 2 shows the flow diagram of the proposed framework). Initially, the MUEs are randomly positioned in M and in active mode i.e., they are sending back periodically the \(SINR^{k}_{M,MUE_{i}}\) on each RB \(k\) during the UL transmission before executing the RB allocation procedure based on a scheduling strategy. As a consequence, M verifies the users' quality channels based on the returned measurement reports \(SINR^{k}_{M,MUE_{i}}\) resulted from the following comparison:  
\[SINR^{k}_{M,MUE_{i}}<SINR^{Threshold}, \tag{3}\]  
where \(SINR^{Threshold}\) is the SINR threshold by which a minimum QoS can be guaranteed. If condition (3) is fulfilled, M asks the concerned users to send another measurement report in terms of RSS, which contains the received pilot signal of the current serving cell and all neighboring cells regardless their types (M or FBSs). The RSS reports help M in identifying the source of interference and checking whether it is caused by neighboring cells or the consequence of another sources such as fast fading or some noise signals. For this purpose, condition (4) is checked to determine if the \(RSS^{k}_{F_{I},MUE_{i}}\) of a user \(MUE_{i}\) from neighboring cell \(F_{l}\) is greater than the \(RSS^{k}_{M,MUE_{i}}\) of the serving cell. If so, M identifies the \(F_{l}\) as interfering and \(MUE_{i}\) as a victim:  
\[RSS^{k}_{M,MUE_{i}}\leq RSS^{k}_{F_{I},MUE_{i}}. \tag{4}\]  
If Equation (4) is fulfilled, M identifies the received \(RSS^{k}_{F_{I},MUE_{i}}\) on \(F_{l}\) as the interfering signal and then keeps tracking each of the \(F_{l}^{\prime}s\) position, i.e., \(PT_{F_{l}}\), the \(MUE_{i}\) victims are placed into a temporary table. The hybrid algorithm proceeds in mitigating interference through the following steps (see Algorithm 1):  
**Step 1: Defining clusters**. Initially, M starts to group the interfering Fs into clusters \(CLS_{y}\) depending on the \(F_{l}^{\prime}s\) geographical position, which is referred to as \(PT_{F_{l}}\). In the case where F's \(PT_{F_{l}}\) are far from each other (depending on the street width, etc. ), M subdivides the Fs into more than one cluster \(CLS_{y}s\) as \(y\) represents the index of the clusters. The M will count the repeated position \((RP_{PT_{F_{l}}})\) and the total MUEs \((T_{MUE})\) verifying the condition (4) in every \(CLS_{y}\), respectively. The objective of this step is to find the average number of the MUEs that are impacted by each interfering femtocell. In order to proceed, M calculates the average \(AVG_{(RP_{PT_{F_{l}}},T_{MUE})}\) for each \(CLS_{y}\) as follows:  
\[AVG_{(RP_{PT_{F_{l}}},T_{MUE})}=\frac{\sum_{MUE_{i}}^{MUE_{i}},RP_{PT_{F_{l}}}} {T_{MUE}} \tag{5}\]  
where \(MUE_{X}\) is the number of MUEs fulfilling the condition (5) with a \(PT_{F_{l}}\), so  
\[RP_{PT_{F_{l}}}=