# Improving Energy Efficiency in LoRaWAN Networks with Multiple Gateways
## 6 Performance Evaluation  
### Simulation Setup  
To represent a multi-gateway LoRaWAN network in a dense environment, we consider a 4-gateway deployment in an urban square region with a 7 km side length and \(N_{t}\) nodes, where \(N_{t}\) is a Poisson-distributed random variable with mean \(\bar{N_{t}}\). Various scenarios are considered in which \(\bar{N_{t}}\) ranges between 1000 and 4000. To imitate a realistic model, the Okumura-Hata path-loss model for the urban environment is considered, where the fraction of nodes that are located indoors (dense urban) \(f_{1}=\frac{1}{2}\). The remaining fraction, \(f_{2}\), is made up of outdoor nodes. Log-normal shadowing with a zero mean and 8 dB standard deviation is assumed. We assume that all nodes are of class A with unconfirmed transmission and generate the same traffic intensity \(\lambda\). Since we have a massive number of nodes, we suppose that the two situations \(S_{1}\) and \(S_{2}\) that may occur after transmitting an uplink message are equiprobable, like the assumption taken in [30]. Consequently, \(d_{1}=d_{2}=\frac{1}{2}\). Considering a payload length of \(k=40\) bytes, we set \(\lambda\) to the minimum packet generation rate of 18 packets/h. It corresponds to the highest SF 12 and the longest time on air \(ToA\) value as shown in Table 10.  
In our work, a single channel from the three default channels in the EU863-870 ISM band with a bandwidth of 125 kHz and duty cycle \(d\) of 1% is considered, without loss of generality. Therefore, we divide the traffic intensity by 3. Each node sends an uplink message periodically at a packet generation rate of 6 packets/h. Such data rate and  
\begin{table}
\begin{tabular}{c c c} \hline \hline
**SF** & \(ToA\) **[s]** & \(\lambda\) **[Packets/h]** \\ \hline
7 & 0.1048 & 343.32 \\
8 & 0.1802 & 199.75 \\
9 & 0.3211 & 112.1 \\
10 & 0.5636 & 63.87 \\
11 & 1.0485 & 34.33 \\
12 & 1.9398 & 18.55 \\ \hline \hline \end{tabular}
\end{table}
Table 10: ToA and \(\lambda\) for different SFs, \(k=40\) bytes.  
\begin{table}
\begin{tabular}{c c} \hline \hline
**Set** & **Description** \\ \hline \(\mathcal{T}_{1}\) & 3 dB step \\ \(\mathcal{T}_{2}\) & 1 dB step \\ \hline \hline \end{tabular}
\end{table}
Table 9: TP set description.  
packet generation rate are suitable for smart buildings, waste management, and agriculture monitoring applications where we need to transmit small amounts of data at low data rates.  
The simulation parameters are listed in Table 11. Note that, in the simulation, all nodes are always covered. The simulation is performed using MATLAB, and the numerical results are obtained from 30 runs. We use a random starting point for fmincon and we consider the local minimum as global since we work in the domain that ensures the convexity of our optimization problem. Table 12 represents an example of 4000-node distribution among different SFs before using our algorithm according to the required SNR at each SF. This node distribution satisfies the convexity condition of our optimization problem.  
The following metrics are used in the performance evaluation:  
* The total throughput is computed as in Equation (10);
* The total consumed network energy during \(T\) is computed as in Equation (14);
* The overall energy efficiency \(Eff\) of the LoRaWAN network represents the objective of our optimization problem \((\mathcal{P})\);
* The LoRaWAN network's active energy efficiency is defined as the ratio of the total network throughput to the total network consumed energy during period \(T_{active}\), expressed as follows:  
\[Eff_{active}=\frac{\mathcal{R}}{\mathcal{E}_{active}} \tag{27}\]