# Improving Energy Efficiency in LoRaWAN Networks with Multiple Gateways
## 1 Introduction  
Low-power wide area networks (LPWAN) address the stringent requirements of IoT applications where a massive number of low-cost, power-constrained nodes need to transmit small amounts of data over a long communication range [1]. LoRaWAN is one of the most widely used LPWAN technologies. Long Range (LoRa) is a wireless communication standard that operates in the unlicensed industrial, scientific, and medical (ISM) band using chirp spread spectrum (CSS) modulation developed by Semtech [2]. LoRaWAN is the medium access control MAC protocol standardized by the LoRa Alliance that runs on top of the LoRa physical layer. A LoRaWAN network has a star-of-stars architecture consisting of four entities: nodes, gateways, a network server, and an application server. Thus, there is no communication between nodes, and single-hop LoRa communication is used between nodes and gateways. The gateways simply forward the received messages to a central network server over an IP backbone. Precisely, there is no association between nodes and gateways, and a packet sent by a node can be received by multiple gateways. Moreover, the gateways also receive network server acknowledgments (ACK) or MAC commands and send them to the intended nodes. The central network server is in charge of managing network access and functionality, as well as routing messages between nodes and the LoRaWAN application.  
The two main configurable parameters in the LoRa physical layer are the spreading factor (SF) and the transmission power (TP). SF refers to the number of bits encoded per symbol. This is the key parameter in LoRa because it affects the time of transmission, datarate, communication range, and power consumption. The greater the SF, the larger the coverage, and the lower the data rate. Lowering the data rate lengthens the transmission time and thus increases power consumption. The nodes closest to a gateway transmit with the lowest SF and highest data rate, thereby extending the battery life. More distant nodes transmit at a higher SF and require a longer time of transmission; therefore, their batteries will be drained quickly. Since SFs are quasi-orthogonal [3], communication with different SFs on the same frequency channel does not interfere with each other. As for the TPs, these are discrete values depending on the regional regulations [4]. Using higher TP values extends the communication range at the expense of increased power consumption.  
The Aloha access scheme used in LoRaWAN increases the probability of collision and therefore reduces the network throughput, particularly when the density of nodes increases at some SFs. To overcome this problem, some nodes can be reconfigured to use higher SFs. However, this will lead to an increase in power consumption and degrade the energy efficiency of the network. Thus, energy efficiency can be improved by finding the best SF allocation and tuning the TPs of the nodes. In this paper, we introduce EE-LoRa, an algorithm that carefully distributes nodes among different SFs to enhance the energy efficiency of the LoRaWAN network and tunes TPs to the lowest possible levels.  
The remainder of this paper is organized as follows. In Section 2, related work and our contributions are described. Section 3 presents an overview of LoRa and LoRaWAN technologies. Section 4 presents the system model. The EE-LoRa algorithm for SF selection and power control to improve the energy efficiency of LoRaWAN networks is described in Section 4. The simulation setup and obtained results are shown in Section 6. Finally, we conclude the article in Section 7.