# Adaptive Parameters for LoRa-Based Networks Physical-Layer
## 3 Proposal
### SlidingChange: A Proposal of a Sliding Window for Automatic Parameter Changing
This particularity of our evaluation and proposal objectives could have influenced the LR-ADR performance's final result. \begin{table}
\begin{tabular}{c c c c c c c c c c c} \hline \hline  & \multicolumn{8}{c}{**BW**} \\ \cline{2-10}
**Window/Technique** & \multicolumn{2}{c}{**125 kHz**} & \multicolumn{2}{c}{**250 kHz**} & \multicolumn{2}{c}{**500 kHz**} & \multirow{2}{*}{**Average**} \\ \cline{2-10}  & & \multicolumn{2}{c}{**SF**} & & \multicolumn{2}{c}{**SF**} & & \multicolumn{2}{c}{**SF**} \\ \cline{2-10}  & **10** & **11** & **12** & **10** & **11** & **12** & **10** & **11** & **12** \\ \hline LR-ADR [28] & 46 & 52 & 55 & 58 & 57 & 42 & 43 & 39 & 41 & 48.111 \\ \hline Windowless & 33 & 32 & 32 & 38 & 37 & 24 & 15 & 13 & 22 & 27.333 \\ \hline w = 10 & 32 & 52 & 38 & 46 & 46 & 39 & 30 & 28 & 28 & **37.667** \\ \hline w = 20 & 24 & 29 & 22 & 23 & 32 & 22 & 15 & 21 & 18 & 22.889 \\ \hline w = 30 & 19 & 19 & 17 & 19 & 18 & 17 & 12 & 13 & 15 & 16.556 \\ \hline w = 40 & 14 & 17 & 11 & 13 & 14 & 15 & 9 & 9 & 13 & **12.778** \\ \hline \hline \end{tabular}
\end{table} 
Table 4: Summary of the number of configuration changes for each setup. \begin{table}
\begin{tabular}{c c c} \hline \hline
**Window** & **SNR Gain** & **Number of Changes** \\ \hline
10 & 44.89\% & 37.80\% \\
20 & 36.73\% & \(-\)16.26\% \\
30 & 13.77\% & \(-\)39.43\% \\
40 & \(-\)8.92\% & \(-\)53.25\% \\ \hline \hline \end{tabular}
\end{table} 
Table 5: Results of SlidingChange technique compared with average results from the InstantChange technique. ## 5 Conclusions

In this paper, we described the results from [14] using the InstantChange technique. We also presented a novel technique called SlidingChange, which obtained improvements on Bit Error Rate and Signal-to-Noise Ratio values. Those improvements can be demonstrated considering the relationships shown in Figure 3. Moreover, our work proposed techniques that considerably reduced the **configuration** (parameter) changes, improving the LoRa's network quality. The sliding window technique, SlidingChange, achieved significant improvements compared to the windowless technique, InstantChange, and it performed better than the static LoRa configuration, which does not change any parameter over time. We noted that due to the filtering properties of the sliding window, the number of changes becomes lower when the window length is increased. However, the same effect could make the algorithm perform bad frequency changes, as illustrated by the results from the smaller sliding windows. From the analysis of the average of SNR gain and the number of changes shown in Tables 3 and 4, we can conclude that the best results (when considering these results only) were achieved by the sliding window of \(W=10\) for the SNR gain and the sliding window of \(W=40\) for the number of changes. The results related to the window technique presented in Table 5 show that the window length \(W=20\) achieved the best balance between SNR gains and reduction of the number of carrier changes. This configuration achieved, when compared with the windowless technique, an improvement of 36.73% on the SNR gain and 16.26% fewer frequency changes. The hypothesis that the sliding window always reduces the number of frequency changes was tested as true only for the windows of 20, 30, and 40 units of length, as the window of 10 units scored a higher number of changes. Nevertheless, the hypothesis that a sliding window for the moving average of SNR as an input to the decision-making regarding LoRa's carrier frequency changes was partially confirmed, because longer window lengths reduced the gain instead of increasing it. Therefore, the proposed technique demonstrated that for a desired window length range there was an increase compared with the windowless technique. Those improvements represent advancements in LoRa's communication quality, as highlighted in Figure 3 that shows the relation between a decreasing BER and an increasing signal's SNR value.