You are currently viewing a new version of our website. To view the old version click .
Sensors
  • Article
  • Open Access

25 September 2023

An Energy-Efficient Routing Algorithm for WSNs Using Fuzzy Logic

,
,
and
1
National Institute of Technology Goa, Ponda 403401, Goa, India
2
Department of CSE, Indian Institute of Information Technology Pune, Pune 411041, Maharashtra, India
*
Author to whom correspondence should be addressed.
These authors contributed equally to this work.
This article belongs to the Section Sensor Networks

Abstract

Battery replacement or recharging is essential for sensor nodes because they are typically powered by batteries in wireless sensor network (WSN) applications. Therefore, creating an energy-efficient data transfer technique is required. The base station (BS) receives data from one sensor node and routes the data to another sensor node. As a result, an energy-efficient routing algorithm using fuzzy logic (EERF) represents a novel approach that is suggested in this study. One of the reasoning techniques utilized in scenarios where there is a lot of ambiguity is fuzzy logic. The remaining energy, the distance between the sensor node and the base station, and the total number of connected sensor nodes are all inputs given to the fuzzy system of the proposed EERF algorithm. The proposed EERF is contrasted with the current systems, like the energy-aware unequal clustering using fuzzy logic (EAUCF) and distributed unequal clustering using fuzzy logic (DUCF) algorithms, in terms of evaluation criteria, including energy consumption, the number of active sensor nodes for each round in the network, and network stability. EAUCF and DUCF were outperformed by EERF.

1. Introduction

Wireless channels connect the sensor nodes in a wireless sensor network, which are then placed throughout the region being monitored. Sensor node placement may be random or static [1,2]. Depending on the applications, some mobile devices can be connected to the sensor nodes. Sensor nodes keep an eye on the area and measure environmental factors like temperature and humidity. The base station (BS) receives the collection of data and transmits it. In order to obtain information from the targeted region, the BS is connected to the internet to deliver notifications about the target area [3,4]. The transmission of data by sensor nodes uses a lot of energy. In order to decrease energy consumption, clustering and routing are used. The grouping of sensor nodes is one of the efficient techniques used for utilizing energy effectively. A sensor node in the clustering method leads to a specific cluster, known as the cluster head (CH). The CH from each cluster of the network gathers information from every sensor node and then transmits it to the BS. The application of the routing mechanism prevents direct data transmission from CHs to the BS [5]. Figure 1 shows both the routing path between CHs and the WSN with clusters.
Figure 1. Wireless sensor network with clusters.
The network’s lifespan is significantly increased through routing. It is difficult to build a routing path for a network of sensor nodes because they have little computational power, short transmission ranges, and limited battery life. Since the next hop does not take the energy of the sensor node into account, using minimum hop might not be the best option. The hop will continue in this case until the sensor node fails or dies. As a result, the network develops an energy hole and becomes dispersed. A protocol that guarantees uniform energy consumption by sensor nodes is necessary to extend the network’s lifespan. There are three basic types of routing protocols: location-based routing, hierarchical routing, and data-centric flat routing. Because sensor nodes and cluster heads aggregate data during hierarchical routing (cluster-based routing), fewer packets are sent throughout the network, which reduces energy consumption. Cluster-based routing utilizes multi-hop communication and aids network scalability [6].
As energy is a crucial factor in WSNs, designing energy-efficient algorithms to communicate is necessary. As the routing distance increases, the energy consumption of the network increases. Therefore, it is also essential to route the data sensed by the sensor nodes to the base station through an efficient path. In this paper, the fuzzy system is used to route the data using an energy-efficient routing path. The existing EERF supports multi-hop routing by generating the least distant and most energy-efficient routing path, whereas in energy-aware unequal clustering using fuzzy logic (EAUCF) and distributed unequal clustering using fuzzy logic (DUCF), clustering is preferred for the communication of the data.
Making decisions that follow human logic is an essential application of fuzzy logic. Fuzzy logic makes decisions depending on the result by combining different features on pre-established principles. Fuzzifiers, fuzzy rules, fuzzy inference systems, and defuzzifiers are some of fuzzy logic’s key elements. Fuzzifier creates a fuzzy set from a clean input. Each set is given a degree of membership as well. The connections between linguistic input variables and fuzzy output variables are made by fuzzy rules. The fuzzy inference system uses rules to process values that have been fuzzified. By utilizing a defuzzifier, the fuzzy outputs are provided as a solution in terms of crisp values. A fuzzy logic-based routing algorithm has been suggested in this study. The development of the routing path and router selection are carried out in accordance with the fuzzy output values. Section 2 of the proposal describes the work that went into this. In Section 3, the proposed routing algorithm has been described. The experimental findings are discussed in Section 4. At the end, Section 5 brings the paper to a conclusion.

3. Proposed Work

The clusters in this work are constructed in accordance with DUCF [10]. In order to choose routers from CHs and create a routing path, an algorithm is suggested. From CHs to routers, the data are sent in the direction of the BS. The fuzzy routing process comprises three stages: the fuzzy router competition phase, the router selection phase, and the route formation phase. These phases are described in the sections below.

3.1. Fuzzy Router Competition Phase

All CHs are initially thought of as, for instance, provisional routers. The CHs are assessed using several membership functions. The three input variables for the fuzzy routing strategy are “Residual Energy”, “Distance to BS”, and “Nodes Connected After Clustering (NCC)”.
At first, all CHs are thought of as temporary routers. Additionally, the fuzzy system’s linguistic variables are used to evaluate the CHs. “Residual energy”, “Distance to the BS”, and “NCC” are the input parameters for the fuzzy technique for routing. The residual energy has the following linguistic variations: less, average, and more. The linguistic variables for “Distance to BS” are far, reachable, and near, whereas those for “NCC” are many, medium, and few.
The membership functions were chosen in accordance with [9] and the results of their own experimental work. All the membership functions (MFs) of the input parameters “Residual energy”, “NCC”, and “Distance to BS” are shown, respectively, in Figure 2, Figure 3 and Figure 4. The range of MFs for “Residual Energy” is from 0 to 1 because the maximum energy of the sensor node is assumed to be 1 J. Because there can be a maximum of 20 sensor nodes in the range in this network scenario, the range of MFs for “NCC” is from 0 to 20. The range of “Distance to BS” is presumed to be between 0 and 142 because the greatest distance to the BS is 141.42 m. Between the sink point (100, 100) and the sensor node at the area’s corner (0, 0), the maximum distance is computed.
Figure 2. ‘Residual Energy’ as an input variable: degree of membership.
Figure 3. ‘NCC’ as an input variable: degree of membership.
Figure 4. ‘Distance to BS’ as an input variable: degree of membership.
The possibility that a CH will function as a router is taken into consideration for the first fuzzy output variable, Confidence. The MF values for confidence are smallest, smaller, small, small moderate, moderate, big moderate, big, bigger, and biggest. The membership functions for the output variable “Confidence” are shown in Figure 5. ‘Capacity’, the second output variable, also demonstrates the analogous nine linguistic variables, including compact, rather compact, less compact, compact bearable, bearable, huge bearable, huge, less huge, and more huge. The membership function for the ‘Capacity’ of the sensor node is shown in Figure 6. Each CH in a routing path is accommodated by carefully choosing the ranges of all membership functions using a variety of experimental evaluations. For the routing method, Table 1 defines a total of 27 fuzzy if-then rules. In this case, defuzzification is accomplished using the centroid technique, whereas fuzzification is accomplished using the Mamdani model [20].
Figure 5. ’Confidence’ as an output variable: degree of membership.
Figure 6. ’Capacity’ as an output variable: degree of membership.
Table 1. Fuzzy if-then rules for routing in WSN.

3.2. Router Selection and Routing Path Formation Phase

An initial arrangement of each CH is based on its distance from the BS. Within their communication range, the CHs transmit ‘candidate’ messages. Only the CHs are able to receive “candidate” messages. ‘Confidence’ and ‘Capacity’ information is included.
The CHs that are quite remote from the BS cannot function as routers; hence, they are only regarded as CHs. The CHs can participate in the routing process as the BS’s distance reduces. Different numbers of candidate messages are sent to each CH. Following the ‘candidate’ communication, CH assesses its confidence and capability in relation to the candidates that have been sent. The receiving CH will send a “join” message to the candidate CH if the candidate CHs’ confidence and capacity are higher than those of the receiving CH. The potential CHs may now get several ‘join’ notifications. So, in accordance with their capacity, they send “accept” messages to their closer CHs. The CHs that sent the “accept” message to them also send their data to those CHs. The CHs that send the “accept” message are known as “routers”. Data is sent from CHs and routers to the routers that are on the routing path leading to the BS. Any sensor node sending data straight to the BS does not receive an “accept” message. As a result, the data from all the CHs is sent in this way to the BS. Table 2 displays the message summaries.
Table 2. Message descriptions.
The complexity can be amounted according to the time required for sending messages (t) for one CH. The number of CHs selected in the worst case would be a predefined number k at each iteration. If N is the total number of iterations, then the worst case for complexity amounts to O ( t k N ) . The flow chart of the proposed EERF is shown in Figure 7.
Figure 7. Flowchart of proposed EERF.

4. Discussion

The simulations were run on Windows 10 using MATLAB R2015. With the placement of 100 sensor nodes at random, the area under observation was considered to be 200 × 200 m 2 . Each sensor node has an initial energy level of 1 J. The energy needed for intra-cluster activities is calculated as E e l e c = 50 nJ/bit, ϵ f s = 10 pJ / bit / m 2 , and 10% of the data was aggregated.
This was compared to two well-known methodologies, EAUCF and DUCF, in order to assess the performance of the suggested methodology. In this work, the network’s overall energy consumption throughout each round, the number of active sensor nodes during a round, and the stability of the network were all evaluated during the simulations. The network’s stability is defined as the difference between the first sensor node to die (FND) and half of the sensor nodes having died (HND). The stable network has a larger difference.
Figure 8 displays the network’s sensor nodes’ cumulative energy use for each round. Performance-wise, the suggested method outperforms EAUCF and DUCF. The number of neighbor nodes is not taken into account as an input parameter in EAUCF. As a result, the network’s total load is not balanced. Although node degree is taken into account in DUCF, the direct communication between the CHs and BS was applied. Because of this, the CHs consume more energy and eventually perish. Both of these criteria were taken into account, and a routing algorithm was also suggested for use in the EERF. As a result, it uses less energy during each round.
Figure 8. Total energy consumption per round in Joules.
The network’s overall number of active sensor nodes for each round is shown in Figure 9. It demonstrates that the line graph of the proposed approach up until the 1000th round displays the greatest values of all the algorithms that were compared. This is a result of the planned EERF’s lower energy consumption. EERF conserves energy and outlasts the other compared techniques across all rounds.
Figure 9. Active sensor nodes per round.
The FND and HND values are recorded by the network. Table 3 shows the network stability, FND, and HND values, as well as the difference between the two. It was found that the suggested approach significantly differs from FND and HND. In comparison to EAUCF and DUCF, it is, therefore, more stable.
Table 3. Comparison of FND, HND, and the stability of the network.
The energy usage at each round is tracked because energy efficiency is the main goal of this endeavor. The amount of energy used during each loop is shown in Figure 10. For this parameter, it can be seen that EERF performs better than EAUCF and DUCF. When compared to EAUCF and DUCF, EERF uses a lot less energy. As the number of rounds in which the FND in the network and the HND in the network are noted, the relative energy consumption at each round is observed. When the number of rounds increases, the network is not stable and consumes a high amount of energy for transmission. So, the rate of death of sensor nodes is higher.
Figure 10. Energy consumption at each round in Joules.
According to all the results, the proposed EERF algorithm outperforms EAUCF and DUCF and generates energy-efficient communications in the routing. Due to the energy-efficient communications and routing path, the network stability increases. Consequently, a better network lifespan is achieved.

5. Conclusions

As a result of the battery-powered sensor nodes in WSNs, an efficient level of energy consumption is essential. In this study, fuzzy logic is used to propose a routing algorithm that is energy-efficient. The outputs from the fuzzy inference system are used to detect the appropriate routers and the routing path. The proposed EERF is compared to the current EAUCF and DUCF under several assessment criteria, including total network energy consumption, active sensor nodes, network stability, and energy consumption at each round, in order to assess how well it performs. It was discovered that EERF outperforms EAUCF and DUCF as a result of the fuzzy system’s addition of the parameter “NCC” and the efficient generation of routing paths. Furthermore, EERF can be improved with different clustering techniques and considering various computational parameters in terms of the sensor node’s capacity to transfer data and the node degree for the selection of CHs.

Author Contributions

Conceptualization, P.R.R., A.L., D.R.E. and S.R.P.; methodology and software, P.R.R. and A.L.; validation, formal analysis and investigation, D.R.E. and S.R.P.; resources, data curation, and writing—original draft preparation, P.R.R. and A.L.; writing—review and editing, D.R.E. and S.R.P.; visualization, and supervision, D.R.E. and S.R.P. All authors have read and agreed to the published version of the manuscript.

Funding

This research received no external funding.

Institutional Review Board Statement

Not applicable.

Data Availability Statement

Not applicable.

Conflicts of Interest

The authors declare no conflict of interest.

References

  1. Raghavendra, C.S.; Sivalingam, K.M.; Znati, T. Wireless Sensor Networks; Springer: London, UK, 2006. [Google Scholar]
  2. Akyildiz, I.F.; Weilian, S.; Yogesh, S.; Erdal, C. Wireless sensor networks: A survey. Comput. Netw. 2002, 38, 393–422. [Google Scholar]
  3. Edla, D.R.; Lipare, A.; Cheruku, R.; Venkatanareshbabu, K. An Efficient Load Balancing of Gateways Using Improved Shuffled Frog Leaping Algorithm and Novel Fitness Function for WSNs. IEEE Sens. J. 2017, 17, 6724–6733. [Google Scholar] [CrossRef]
  4. Edla, D.R.; Lipare, A.; Cheruku, R. Shuffled Complex Evolution Approach for Load Balancing of Gateways in Wireless Sensor Networks. Wirel. Pers. Commun. 2018, 98, 3455–3476. [Google Scholar] [CrossRef]
  5. Lipare, A.; Edla, D.R. Novel Fitness Function for SCE Algorithm Based Energy Efficiency in WSN. In Proceedings of the 9th International Conference on Computing, Communication and Networking Technologies (ICCCNT), Bengaluru, India, 10–12 July 2018; pp. 1–7. [Google Scholar]
  6. Jaradat, T.; Benhaddou, D.; Balakrishnan, M.; Al-Fuqaha, A. Energy efficient cross-layer routing protocol in Wireless Sensor Networks based on fuzzy logic. In Proceedings of the 2013 9th International Wireless Communications and Mobile Computing Conference (IWCMC), Sardinia, Italy, 1–5 July 2013; pp. 177–182. [Google Scholar] [CrossRef]
  7. Handy, M.J.; Haase, M.; Timmermann, D. Low energy adaptive clustering hierarchy with deterministic cluster-head selection. In Proceedings of the 4th International Workshop on Mobile and Wireless Communications Network, Stockholm, Sweden, 9–11 September 2002; pp. 368–372. [Google Scholar]
  8. Kim, J.M.; Park, S.H.; Han, Y.J.; Chung, T.M. CHEF: Cluster head election mechanism using fuzzy logic in wireless sensor networks. In Proceedings of the 10th International Conference on Advanced Communication Technology, Gangwon, Republic of Korea, 17–20 February 2008; Volume 1, pp. 654–659. [Google Scholar]
  9. Bagci, H.; Yazici, A. An energy aware fuzzy approach to unequal clustering in wireless sensor networks. Appl. Soft Comput. 2013, 13, 1741–1749. [Google Scholar] [CrossRef]
  10. Baranidharan, B.; Santhi, B. DUCF: Distributed load balancing Unequal Clustering in wireless sensor networks using Fuzzy approach. Appl. Soft Comput. 2016, 40, 495–506. [Google Scholar] [CrossRef]
  11. Adnan, M.; Yang, L.; Ahmad, T.; Tao, Y. An Unequally Clustered Multi-hop Routing Protocol Based on Fuzzy Logic for Wireless Sensor Networks. IEEE Access 2021, 9, 38531–38545. [Google Scholar] [CrossRef]
  12. Jiang, H.; Sun, Y.; Sun, R.; Xu, H. Fuzzy-logic-based energy optimized routing for wireless sensor networks. Int. J. Distrib. Sens. Netw. 2013, 9, 216561. [Google Scholar] [CrossRef]
  13. Al-Kiyumi, R.M.; Foh, C.H.; Vural, S.; Chatzimisios, P.; Tafazolli, R. Fuzzy logic-based routing algorithm for lifetime enhancement in heterogeneous wireless sensor networks. IEEE Trans. Green Commun. Netw. 2018, 2, 517–532. [Google Scholar] [CrossRef]
  14. Ramkumar, K.; Ananthi, N.; Brabin, D.D.; Goswami, P.; Baskar, M.; Bhatia, K.K.; Kumar, H. Efficient routing mechanism for neighbour selection using fuzzy logic in wireless sensor network. Comput. Electr. Eng. 2021, 94, 107365. [Google Scholar] [CrossRef]
  15. Lipare, A.; Damodar, R.E.; Saidi, R.P. Fuzzy rule-based system for energy efficiency in wireless sensor networks. J. Supercomput. 2021, 77, 9947–9970. [Google Scholar] [CrossRef]
  16. Narayan, V.; Daniel, A.K.; Chaturvedi, P. E-FEERP: Enhanced Fuzzy based Energy Efficient Routing Protocol for Wireless Sensor Network. Wirel. Pers. Commun. 2023, 131, 371–398. [Google Scholar] [CrossRef]
  17. Singh, J.; Deepika, J.; Zaheeruddin; Sathyendra Bhat, J.; Kumararaja, V.; Vikram, R.; Jegathesh Amalraj, J.; Saravanan, V.; Sakthivel, S. Energy-efficient clustering and routing algorithm using hybrid fuzzy with grey wolf optimization in wireless sensor networks. Secur. Commun. Netw. 2022, 2022, 9846601. [Google Scholar] [CrossRef]
  18. Mehta, D.; Saxena, S. Hierarchical WSN protocol with fuzzy multi-criteria clustering and bio-inspired energy-efficient routing (FMCB-ER). Multimed. Tools Appl. 2022, 81, 35083–35116. [Google Scholar] [CrossRef]
  19. Heinzelman, W.B.; Chandrakasan, A.P.; Balakrishnan, H. Application specific protocol architecture for wireless microsensor networks. IEEE Trans. Wirel. Commun. 2002, 1, 660–670. [Google Scholar] [CrossRef]
  20. Mamdani. Application of fuzzy logic to approximate reasoning using linguistic synthesis. IEEE Trans. computers. 1977, 100, 1182–1191. [Google Scholar]
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Article Metrics

Citations

Article Access Statistics

Multiple requests from the same IP address are counted as one view.