# Joint Spreading Factor and Channel Assignment in Multi-Operator LoRaWAN Deployments
## 6 Multi-Operator Game for Channel Selection
### Best Response Algorithm for Computing the NE
Similar to before, we assume that the network can produce an estimate after a certain period of utilizing the channel. Algorithm 3 depicts the pseudo-code for our proposed learning algorithm for finding the NE. ```
Input: Learning rate \(\beta\in\) [0,1] Initialize:\(p_{c}^{i}(1)\)\(\leftarrow\)\(\dfrac{1}{C}\), \(\forall\)\(i\in\mathcal{N}\) Do \(t_{l}\)\(\leftarrow\)\(t_{l}+1\) For\(i\)=1,...,\(\mathcal{N}\)  Network \(i\) selects a channel following \(p_{c}^{i}(t)\)  It utilizes the selected channel sufficiently long to estimate the success rate per SF  Compute \(\mathcal{R}\) = \(1-U_{i}^{c}/U_{max}\) For\(c\in\mathcal{C}\) If\(\theta_{ic}\)== 1 \(p_{c}^{i}(t_{l}+1)\)\(\leftarrow\)\(p_{c}^{i}(t_{l})+\beta\mathcal{R}(1-p_{c}^{i}(t_{l}))\) Else \(p_{c}^{i}(t_{l}+1)\)\(\leftarrow\)\(p_{c}^{i}(t_{l})-\beta\mathcal{R}p_{c}^{i}(t_{l})\) End If End For End For Until\(\exists\)\(c\in\mathcal{C}\) such that \(p_{c}^{i}(1)\approx 1\), \(\forall\)\(i\in\mathcal{N}\)
```

**Algorithm 3** Learning the NE for \(n=1\)

### Generalization of the Learning Problem

The NE can still be attained for \(n\geq 1\) while using the same replicator dynamics approach. However, instead of updating the probabilities of a certain channel being allocated, the algorithm works on the probabilities of a certain combination of channels being allocated. If the number of channels chosen by each operator \(n\) is equal to two, and the total number of available channels is eight, then the total number of possible selections is equal to \(\binom{8}{2}=28\). Every time slot, and for each player, a couple of channels is selected and, afterwards, the probability of selecting the couple is updated, alongside the other probabilities, such that the sum remains equal to one. ## 7 Simulations and Results

In this section, we test the effectiveness of our proposals and compare them to the state-of-the-art in SF and channel assignment for LoRaWAN. We experiment, by simulations, the two approaches of our game theory-based proposals. The first, which we label as the 'best response', uses the best response approaches to both SF assignment and channel selection. The second, which we label as 'learning approach', combines the distributed algorithm for SF assignment and the dynamic replication learning proposal for channel selection. We compare our algorithms to the currently in use state-of-the-art approaches that are represented by ADR for SF selection by the devices, and random channel assignment per packet. Namely, each device transmits on the lowest available SF and on a randomly selected channel at each packet transmission, as in current LoRaWAN deployments. Table 3 summarizes our simulation parameters. We consider four co-located operators. The number of devices that correspond to each network is ascending and equal to 750, 1000, 1250, and 1500 devices, respectively. The packet generation rate per device also differs from one network to another and increases from one packet per hour to four, for operators one to four, respectively. The parameters remain, as shown in the table, unless they are changed by the simulation scenario. ### Impact of the Area Size

We start by studying the impact of the deployment area size on the performance of our game theoretic proposal. We vary the simulation square area size by changing the side length \(S\) between 2, 4, 8, 12, 16 km, and 20 km. For this simulation, we assume the presence of three channels, with \(n=1\) for our proposal. In other terms, in our algorithm, each operator only chooses one channel. For the legacy approach, all of the channels are open and they are used evenly by the devices. Figure 4 presents the results in terms of the total normalized throughput. Figure 4a compares the total normalized throughput, across all four networks, between our proposal and the legacy LoRaWAN approach. Our joint SF and channel assignment algorithm acts as an upper bound for the legacy approach.