1 Introduction

The rapid technological advancements have triggered the sensing devices to experience a massive growth [19, 27]. Wireless Sensor Network (WSN), in general, is of utmost significance in network technology research [1]. It operates in a faster manner than self-organization at any spot around the globe will never be inadequate, at any cost. WSN has very often undergone a number of enhancements, and therefore, numerous applications have been employing it till date [11]. IoT refers to a system, which has an interconnection with mechanical or digital instruments, computing devices, persons, animals and entities of similar kind [20, 22, 23]. Identifiers of distinctive type are rendered to the IoT. The IoT system owns the ability to achieve data communication over the network, even if user-to-computer or user-to-user influence never exists. Therefore, the people are enabled to interact with the physical world in an immensely closer way, in accordance with the real-time activity that the sensor nodes exhibit [9, 10]. The users can also examine sense and control the objects that the surroundings hold, instead of customizing the environmental data [14, 15, 18]. WSN stands discriminated from other networks, since the nodes of the WSN-based IoT renders restricted bandwidth, processing, storage volume and battery power [16, 17]. The WSNs normally own rechargeable battery power. Hence, the energy deployment has to be aptly scheduled, at instances the sensors are set apart [12, 13]. Redundant data transfer frequently occurs, as multiple data that correspond to a particular event gets conveyed between the base station and a several numbers of nodes [6, 7]. The nodes basically sense, process and transmit information. The network complexity increases with the emergence of redundant data. Hence, the means to lessen redundant data transfer with greater energy saving ability is utmost essential for any network to have increased life expectancy [28,29,30].

In spite of the incessant developments, a small number of difficulties that the modern-day researchers have failed to solve can also be noted. Energy awareness has been assumed to be the principal challenge of all those difficulties, which are concerned with the IoT [21, 24,25,26]. IoT exploits energy awareness, so as to impart a mechanism for the network entities to save energy. Few protocols like Medium Access Control (MAC) and routing protocols create an ingenious environment for operation. Yet, these protocols never succeed to function in all situations. Node clustering serves as an enriched methodology of WSN, which augments the lifetime as well as the scalability feature of the network, and it has never been deployed in an IoT environment. Plenty of hierarchical protocols, which include the data-centric protocols, location-based protocols, and many more such protocols, tempt to achieve nodal clustering in WSN with the aim of augmenting the network lifetime as well as saving energy through a plethora of operating constraints.

Contribution This paper contributes a hybrid cluster head selection framework in WSN–IoT network using the recently introduced MFO and ALO algorithms. The major challenge in WSN is to select the appropriate cluster head. Here, the cluster selection models are examined on the basis of the distance constrained selection and energy constrained selection, delay, load as well as the temperature constraints. In distance constrained selection each and every node in the network need be located within a certain distance to the nearest cluster head. In energy constrained selection, the depletion of energy in WSN should be minimized. Likewise, the delay, load and temperature of the sensors must be minimized. Hence, to overcome this challenges, hybrid model is adopted here. The simulation model concerns energy, distance, delay, load and temperature of sensors and IoT devices. Finally, the proposed simulation model is compared with ABC, GA, PSO, GSA, ALO, MFO and AGSA models.

The rest of the paper is organized as follows. Section 2 depicts the literature review with related works and review. Section 3 portrays the cluster head selection on WSN connected with IoT. Section 4 illustrates the hybrid algorithm for CHS model on WSN–IoT. Section 5 describes simulation results, and Sect. 6 concludes the paper.

2 Literature review

2.1 Related works

In 2014, Duan et al. [1] have utilized the game theoretic approach to putting forward the approach of energy-aware trust derivation that assures IoT security. At first, the risk strategy model was employed to accomplish assistance among the nodes. The game theoretic approach was chiefly involved in cutting down the overhead, resulting from the trust derivation approach. The simulation results revealed the dominant performance of the trust derivation approach in rendering greater levels of security as well as efficiency within an IoT environment.

In 2016, ZhangBing et al. [2] have caused the generation and utilization of the Internet of Underwater Things through the use of the Enhanced-Channel-Aware Routing Protocol (E-CARP). Here, the chief aim was to attain a system with price-efficient data forwarding and reduced energy intakes. They have dealt with the common difficulties of the traditional Carp approach and the PING-PONG approach. The Carp approach does not adhere to the reusability property, whereas the PING-PONG approach makes a choice of the relay node during the steady state of the network. The outcomes of simulation confirmed the network’s larger capability and the reduced expense of communication.

In 2016, Qiu et al. [3] have put forth a routing protocol, termed as [(Global Information Decision (ERGID)], to aid the emergency response IoT. They have dealt with the problems that are associated with the elimination of valid paths through a procedure for delay assessment, known as Delay Iterative Method (DIM). Additionally, load balancing in the network was attained through the Residual Energy Probability Choice. This approach considered the simulation results, which were obtained for energy consumption, packet loss, and delay. The network’s real-time response potential was confirmed with all the testing results.

In 2016, Lee and Kim [4] have attempted to evade the Adjacent Channel Interference (ACI) from occurring through introducing an Interference-Aware Self-Optimizing (IASO) approach. This approach utilized the multichannel with multi-level carrier sense to have control over the gain. During testing, the amplifier’s dynamic range was raised, and an adequate fall in the false carrier sensing, as well as the saturation, was set. It was apparent from the simulation of the network that the IoT network owns a maximal quality improvement with the rise in latency, energy efficiency and overall throughput.

In 2016, Qiu et al. [5] have assured enhanced performance and sustained robustness for the IoT structure using Greedy Model with Small World (GMSW). The Greedy criterion facilitated the determination of a node’s local significance. It was assumed that the small world model only supports in yielding the feasibility of the optimization algorithm. As a result, their approach rendered a network using little world attributes through summing up the shortcuts that exist within the nodes, in accordance with the local significance. The speed that corresponds to the SMSW algorithm for making access to the network, which contains fewer shortcuts, was gained through assessing the performance of their approach and conventional approaches.

Fig. 1
figure 1

Architecture of cluster head selection in WSN–IoT platform

2.2 Review

The recently introduced cluster head selection models in IoT network is based on Game theoretic approach [1], Iterative Method [2], IASO [4] and Greedy Model [5]. The Game theoretic approach [1] is a highly secure and efficient algorithm. However, there is difficulty in solving mixed strategies, and all types of competitive problems cannot be solved. Moreover, the response ability of Iterative method [3] is high, yet each phase of the iteration is rigid with no overlaps, and the system architecture is highly expensive. The IASO [4] algorithm increases throughput, energy efficiency, and latency, but it requires precise channel estimation. In addition, the convergence speed of Greedy algorithm [5] seems to be enhanced whereas it cannot handle some problems and is not an automatic method. These limitations have motivated the current researchers to develop extremely advanced cluster head selection model in WSN–IoT network.

3 Cluster head selection on WSN connected with IoT

3.1 WSN model connected with IoT

Figure 1 shows the integration of WSN with an IoT platform. WSN serves as a residence for umpteen number of sensor nodes, which operate autonomously in a spatially distributed fashion to examine a phenomenon of some sort, in accordance with the application under consideration. These nodes chiefly constituted of microcontroller, power units, transceiver, and memory units, consume large power that they become worn out within a limited duration. The larger the number of exhausted nodes, the smaller will be the network lifetime. Hence, some means for efficient energy storage is highly anticipated. Clustering schemes support this idea of energy preservation. The reason is that all the nodes in a cluster, except the Cluster Head, are prevented from spending their energy to establish individual communication with the Base Station.

Consider a WSN that is composed of N number of clusters denoted as \(C_i \), where, \(i=1,2,\ldots ,N\). Every single cluster owns any number of nodes. The sensor nodes in any cluster are represented as \(S_{ij} \), where, \(i=1,2,\ldots ,N\) and \(j=1,2,\ldots ,M\). For a particular cluster, i and j need not be the same and j may differ from cluster to cluster. In every cluster, a particular node is chosen as the Cluster Head \(CH_i \). The choice of a cluster node as the Cluster Head depends on the WSN characteristics like the temperature observations of the sensors, distance among the sensors and similar other features. A total of N Cluster Heads only communicates with the Base Station, rather than all \(S_{ij} \). When IoT and WSN are integrated, the CH selection becomes even harder because the choice has to be made with consideration of both the WSN characteristics as well as the energy intake of the entities in IoT. Thus, an effective clustering scheme that makes an optimization in the energy storage for greater network lifetime is necessitated.

3.2 Objective model

The key parameters such as energy, distance, and delay are needed to determine for selecting the appropriate cluster head in WSN. In IoT network, it is necessary to concern the parameters of IoT. i.e., as the current experiment integrates both WSN and IoT, it is essential to consider both temperature and load of the IoT devices along with the parameters of WSN. Thus this experiment optimally selects the cluster head from WSN–IoT platform after determining distance, energy, delay, load, and temperature. The reliable network performance can be obtained only when delay, distance, load, and temperature are less and energy is high. Accordingly, the proposed objective model is a maximization function, which is given in Eqs. (1)–(3). In those equations, the terms \(\alpha \) and \(\beta \) are the constants with values 0.9 and 0.3, respectively.

$$\begin{aligned} F_1= & {} f^{\textit{energy}}1\big /{f^{\textit{load}}}+f^{\textit{energy}}1\big /{f^{\textit{temperature}}} \end{aligned}$$
(1)
$$\begin{aligned} F_2= & {} \alpha 1\big /{f^{\textit{distance}}}+(1-\alpha )F_1 \end{aligned}$$
(2)
$$\begin{aligned} F_3= & {} \beta F_2 +(1-\beta )1\big /{f^{\textit{delay}}} \end{aligned}$$
(3)

Computation of distance Equation (4) defines the distance between the IoT devices and the base station. In Eq. (4), \(f^{\textit{energy}}(m)\) indicates the distance between the normal node and the cluster head and between the cluster head and the base station of the IoT network (as given by Eq. (5)). In addition, \(f^{\textit{energy}}(n)\) specifies the distance between two normal nodes (as given in Eq. (6)). In fact, \(f^{\textit{distance}}(m)\) should take the value between the range [0, 1].

$$\begin{aligned} f^{\textit{distance}}(m)= & {} \frac{f^{\textit{distance}}(m)}{f^{\textit{distance}}(n)} \end{aligned}$$
(4)
$$\begin{aligned} f^{\textit{distance}}(m)= & {} \sum _{i=1}^N {\sum _{j=1}^M {\Vert {S_i -\textit{CH}_j}\Vert }} +\Vert {\textit{CH}_j -B}\Vert \end{aligned}$$
(5)
$$\begin{aligned} O_f^{\textit{distance}} (m)= & {} \sum _{i=1}^N {\sum _{j=1}^M {\Vert {S_i -S_j }\Vert } } \end{aligned}$$
(6)

Computation of energy Eq. (7) depicts the energy utilization of the WSN–IoT network. In Eq. (10), the term \(E(S_i )\) indicates the energy of ith normal node and \(E(CH_j )\) indicates the energy of jth cluster head.

$$\begin{aligned}&f^{\textit{energy}}=\frac{f^{\textit{energy}}(m)}{f^{\textit{energy}}(n)} \end{aligned}$$
(7)
$$\begin{aligned}&f^{\textit{energy}}(m)=\sum _{j=1}^M {nE} (j) \end{aligned}$$
(8)
$$\begin{aligned}&nE(j)=\sum _{\begin{array}{l} i=1 \\ i\in j \\ \end{array}}^N {({1-E(S_i ){*}E(\textit{CH}_j )})};\quad 1\le j<M \end{aligned}$$
(9)
$$\begin{aligned}&f^{\textit{energy}}(n)=M{*}\mathop {\textit{Max}}\limits _{i=1}^N ({E(S_i )}){*}\mathop {\textit{Max}}\limits _{j=1}^M ({E(\textit{CH}_j )}) \end{aligned}$$
(10)

Computation of delay During the data transmission from the sensor node to the base station, the delay of IoT devices is based on Eq. (11) that usually takes the value between [0, 1]. Under each cluster, the delay is compensated by minimizing the number of clusters. In Eq. (11), numerator value represents the count of cluster head in WSN, and denominator value indicates the total count of IoT devices.

$$\begin{aligned} f_{\textit{delay}} =\frac{\mathop {\textit{Max}({\textit{CH}_j })}_{j=1}^M }{M} \end{aligned}$$
(11)

Computation of load and temperature The measurement of load and temperature is done using the considerable load and temperature devices by Xively (http://www.xively.com/xively-iotplatform).

4 Hybrid algorithm for CHS model on WSN–IoT

4.1 Conventional algorithms

MFO MFO [35] is a recently introduced meta-heuristic algorithm that operates based on the navigation pattern of moths in night. In this particular algorithm, moths are assigned as the solutions, whereas positions of moths are assigned as the parameters of problems. In fact, the position of moths may change in 1D, 2D, 3D, or hyper dimensional space. To find the best position for moths, the mathematical model of this algorithm is depicted as follows. Consider n number of moths, which are represented in a matrix format as given in Eq. (12), where d indicates the number of parameters. Based on the objective function, the array for sorting the moths is as expressed in Eq. (13).

$$\begin{aligned} A= & {} \left[ {{\begin{array}{c@{\quad }c@{\quad }c@{\quad }c} {a_{1,1} }&{} {a_{1,2} }&{} \ldots &{} {a_{1,d} } \\ {a_{2,1} }&{} {a_{2,2} }&{} \ldots &{} {a_{2,d} } \\ \vdots &{} \vdots &{} \ddots &{} \vdots \\ {a_{n,1} }&{} {a_{n,2} }&{} \ldots &{} {a_{n,d} } \\ \end{array} }} \right] \end{aligned}$$
(12)
$$\begin{aligned} \textit{OA}= & {} \left[ {{\begin{array}{c} {\textit{OA}_1 } \\ {\textit{OA}_2 } \\ \vdots \\ {\textit{OA}_n } \\ \end{array} }} \right] \end{aligned}$$
(13)

Similarly, consider n number of flames that are shown in matrix format (given in Eq. (14)), where d indicates the number of parameters. The sorting of flames according to the objective function is expressed in Eq. (15).

$$\begin{aligned} B= & {} \left[ {{\begin{array}{c@{\quad }c@{\quad }c@{\quad }c} {b_{1,1} }&{} {b_{1,2} }&{} \ldots &{} {b_{1,d} } \\ {b_{2,1} }&{} {b_{2,2} }&{} \ldots &{} {b_{2,d} } \\ \vdots &{} \vdots &{} \ddots &{} \vdots \\ {b_{n,1} }&{} {b_{n,2} }&{} \ldots &{} {b_{n,d} } \\ \end{array} }} \right] \end{aligned}$$
(14)
$$\begin{aligned} \textit{OB}= & {} \left[ {{\begin{array}{c} {\textit{OB}_1 } \\ {\textit{OB}_2 } \\ \vdots \\ {\textit{OB}_n } \\ \end{array} }} \right] \end{aligned}$$
(15)

The three tuple of approximation of MFO algorithm is characterized as in Eq. (16), where U are a function that generates moth’s population randomly and it is corresponding fitness values as shown in Eq. (17), V is a required function that finds out the movement of moths around the search area as shown in Eq. (18), W is a function that checks the stop criteria as shown in Eq. (19).

$$\begin{aligned}&\textit{MFO}=\{ {U,V,W}\} \end{aligned}$$
(16)
$$\begin{aligned}&U:\phi \{ {A,\textit{OA}}\} \end{aligned}$$
(17)
$$\begin{aligned}&V:A\rightarrow A \end{aligned}$$
(18)
$$\begin{aligned}&W:A\rightarrow \{ {\textit{true},\textit{false}}\} \end{aligned}$$
(19)

The position of each moth is updated using Eqs. (20)–(22) with respect to the corresponding flame. In Eq. (20), P specifies the spiral function, \(A_i\) denotes ith moth and \(B_j\) denotes jth flame. Moreover in Eq. (21), \(D_j\) indicates the distance between the ith moth and jth flame (shown in Eq. (22)), x specifies a constant used for terming the spiral function, l is a random number with \(l=(g-1)\,{*}\,\textit{rand} + 1\) having the values between [\(-1\), 1]. The value of g varies from \(-1\) to \(-2\).

$$\begin{aligned} A_i= & {} P\{A_i,B_j\} \end{aligned}$$
(20)
$$\begin{aligned} P\{A_i,B_j\}= & {} D_j \exp ^{xl} \cdot \cos ( {2\pi l})+B_j \end{aligned}$$
(21)
$$\begin{aligned} D_j= & {} | {B_j -A_i }| \end{aligned}$$
(22)

The pseudo code of standard MFO algorithm is depicted in Algorithm 1.

figure c

ALO ALO [36] is a recently introduced nature-inspired algorithm that operates based on the hunting behavior of ant lions. They easily capture the preys as it has sharp edge cone that is enough for the insects to fall. After catching the prey, the ant lion pulls it under the soil and consume. Further, it gets ready for the next hunting. The random walks of the ants are based on Eq. (23) as their movement is stochastic in nature, where t indicates the step of random walk and w(t) is a stochastic function given in Eq. (24).

$$\begin{aligned} Z(t)= & {} \left[ {\begin{array}{l} 0, \quad \textit{cums}({2w({t_1})-1}),\textit{cums}({2w({t_2})-1}) \\ ,.......\textit{cums}( {2w( {t_k })-1}) \\ \end{array}} \right] \end{aligned}$$
(23)
$$\begin{aligned} w(t)= & {} \left\{ {{\begin{array}{ll} 1&{} \quad \textit{if\;rand}>0.5 \\ 0 &{}\quad \textit{if rand} \le 0.5 \\ \end{array}}} \right\} \end{aligned}$$
(24)

It is needed to normalize the random walk of ants within the search space using Eq. (25), where \(s_i \) represents the minimum of random walk of ith variable, \(r_i^t \) represents the minimum of ith variable at tth iteration, \(h_i \) indicates the maximum of ith variable.

$$\begin{aligned} Z_i^t =\frac{\left( {Z_i^t -s_i } \right) \times ({h_i -r_i^t })}{({h_i -s_i})}+r_i^t \end{aligned}$$
(25)

The mathematical assumption of trapping in ant lion’s pit is expressed in Eqs. (26) and (27), where \(r^{t}\) indicates the minimum of all variables at tth iteration, \(h^{t}\) represents a vector that has a maximum of all variables at tth iteration and \(\textit{Antlion}_j^t\) indicates the position of jth ant lion at tth iteration.

$$\begin{aligned} r_i^t= & {} \textit{Antlion}_j^t +r^{t} \end{aligned}$$
(26)
$$\begin{aligned} h_i^t= & {} \textit{Antlion}_j^t +h^{t} \end{aligned}$$
(27)

The formulation for sliding ant towards the ant lion is expressed in Eqs. (28) and (29), where I is a ratio given in Eq. (30), q is a constant and \(t_{\max }\) represents the maximum number of iterations.

$$\begin{aligned} r^{t}= & {} \frac{r_i^t }{I} \end{aligned}$$
(28)
$$\begin{aligned} h^{t}= & {} \frac{h_i^t }{I} \end{aligned}$$
(29)
$$\begin{aligned} I= & {} 10^{q}\frac{t}{t_{\max } } \end{aligned}$$
(30)

The mathematical model of catching the prey is given in Eq. (31), where \(\textit{Antlion}_j^t \) specifies the position of chosen jth ant lion at tth iteration and \(\textit{Ant}_i^t \) specifies the ith ant at tth iteration.

$$\begin{aligned} \textit{Antlion}_j^t =\textit{Ant}_i^t\; \textit{if}\; f(\textit{Ant}_i^t )>f(\textit{Antlion}_j^t ) \end{aligned}$$
(31)

The random walk of each ant around a specific ant lion by roulette wheel and the elitism mechanism is based on Eq. (32), where \(R_a^t\) denotes the arbitrary walk around the selected ant lion by roulette wheel and \(R_e^t \) denotes the random walk around the elite.

$$\begin{aligned} \textit{Ant}_i^{t^{{*}}} =\frac{R_a^t -R_e^t }{2} \end{aligned}$$
(32)

The pseudo code of the standard ALO algorithm is portrayed in Algorithm 2.

figure d

AGSA AGSA is the proposed algorithm in the previous paper [37]. It is the combination of GSA and ABC algorithms. The position and velocity of agents are updated in standard GSA algorithm. However, the updated equation of ABC algorithm is applied to the GSA algorithm in the proposed ASGA method. Equation (33) represents the formulation of updated velocity by the concept of ABC algorithm, where \(V_m^d (t)\) indicates the velocity of the particular agent, \(V_n^d (t)\) indicates the velocity of the neighborhood agent and \(\phi _m\) indicates the random number between [\(-1\), 1].

$$\begin{aligned} V_m^d (t+1)=V_m^d (t)+\phi _m (V_m^d (t)-V_n^d (t))+A_m^d \end{aligned}$$
(33)

of the neighborhood agent

figure e

4.2 Proposed hybrid algorithm

The proposed hybrid model hybridizes the well-known and effective algorithms called MFO and ALO to attain the superior performance while selecting cluster head in IoT network. This algorithm induces MFO algorithm into ALO algorithm. Consider the population of ant lions as the solution that is to be optimized, which is assigned as the set of clusters (group of IoT devices and sensor). Rather than the conventional ALO algorithm, the proposed hybrid model calculates the random walk around the selected ant lion by roulette wheel \(R_a^t\) based on MFO algorithm using Eq. (33). Algorithm 4 and Fig. 2 present the pseudo code and flowchart of proposed hybrid cluster head selection model in IoT, respectively.

$$\begin{aligned} R_a^t =D_j \exp ^{\textit{xt}} \cdot \cos ({2\pi l})+B_j \end{aligned}$$
(34)
figure f
Fig. 2
figure 2

Flowchart of proposed hybrid mode

Fig. 3
figure 3

Convergence analysis of a proposed and conventional models and b proposed model by varying g

Fig. 4
figure 4

Analysis on number of alive nodes for a proposed and conventional models and b proposed model by varying g

The description of above-mentioned pseudo code and algorithm is illustrated below.

  1. (1)

    The initial population of ant lions and ants are randomly initialized.

  2. (2)

    Further, it is essential to calculate the fitness function of both ant lions and ants.

  3. (3)

    The best ant lion is recognized, and it is assigned as elite.

  4. (4)

    An ant lion is selected using Roulette wheel and the variables r and h is updated by Eqs. (28) and (29).

  5. (5)

    An arbitrary walk is produced by Eq. (23), and it is normalized using Eq. (25).

  6. (6)

    The arbitrary walk around the selected ant lion by roulette wheel \(R_a^t\) is calculated using Eq. (34).

  7. (7)

    The position of ant is updated using Eq. (32) and the fitness of entire ants is calculated.

  8. (8)

    An ant lion is substituted with ant using Eq. (31) if the ant is fitter than ant lion.

  9. (9)

    Then it is needed to update elite for the condition of having better ant lion than elite.

  10. (10)

    The steps are repeated until the completion of maximum iteration.

5 Simulation results

5.1 Procedure

The cluster head selection of IoT devices of IoT network is simulated in MATLAB R2015a, and the results are observed. To conduct the simulation, the parameters such as distance, delay, energy, load and temperature of the IoT devices are considered. The additional parameters with fixed values required for the accomplishment of the simulation are depicted as follows. The total area of the IoT network is assigned as 100 m \(\times \) 100 m with centralized base station. Moreover, the initial energy of the network \(E^{I}\) is set as 0.5 and energy of the free space model \(E^{F}\) is set as 10 pJ/bit/m\(^{2}\). The energy of the power amplifier \(E^{\textit{PA}}\) is set as 0.0013 pJ/bit/m\(^{2}\) and transmitter energy \(E^{T}\) is set as 50 nJ/bit/m\(^{2}\). Furthermore, the energy required for data aggregation is set as 5 nJ/bit/signal. In fact, the current simulation is done by proposed hybrid algorithm with 2000 rounds. Once the simulation is completed, the performance of proposed hybrid model is compared with ABC, GA, PSO, GSA, ALSO, MFO and AGSA based-cluster head selection models.

Fig. 5
figure 5

Analysis on normalized network energy for a proposed and conventional models and b proposed model by varying g

Fig. 6
figure 6

Analysis on load a proposed and conventional models and b proposed model by varying g

Fig. 7
figure 7

Analysis on temperature for a proposed and conventional models and b proposed model by varying g

5.2 Convergence analysis

As the proposed objective model deals with maximization function, the convergence performance of proposed hybrid model should be high. The convergence analysis of proposed and conventional models for cluster head selection in WSN–IoT network is shown in Fig. 3a. Here, the cost function of proposed hybrid model is 7.40% better than ABC, 19.58% better than GA, 12.62% better than PSO, 20.83% better than GSA, 0.86% better than ALO and 0.43% better than AGSA based cluster head selection models at 10th iteration. Similarly, Fig. 3b displays the convergence of proposed model by altering the value of g from \(-1\) to \(-2\). It shows that the convergence of proposed hybrid model at \(g=-1.8\) is 11.74% superior to model at \(g=-1\) and 11.63% superior to model at \(g=-2\). At 2nd iteration, the convergence of proposed model at \(g=-1.8\) is 3.8% better than the proposed model at \(g=-1\), 7.4% better than the proposed model at \(g=-1.5\), 1% better than the proposed model at \(g=-2\).

5.3 Sustainability of alive nodes

The analysis on the existence of number of alive node is shown in Fig. 4a. After the completion of 1400 rounds, the number of alive nodes present in the proposed hybrid model is 12% superior to ABC, GA, and GSA, 6.66% superior to ALO and AGSA, respectively and 7.69% better than PSO and MFO models respectively. Further, as the round increases, the number of alive nodes are supposed to increase in the proposed model. Thus at the 2000th round, the proposed hybrid model and AGSA maintains the number of alive nodes as 15, which is attained as the maximum number of alive nodes present till the completion of final round over the conventional models. By varying the value of g as shown in Fig. 4b, the number of alive nodes present in the 1500 round for proposed hybrid model at \(g=-2\) is 3.33% better than model at \(g=-1\), \(g=-1.5\) and \(g=-1.8\). At 1300th round, the proposed hybrid model at \(g=-2\) is 5% better than the proposed model at \(g=-1.8\), \(g=-1.5\) and \(g=-1\).Thus the proposed hybrid model outperforms the traditional cluster head selection models in maintaining maximum number of alive nodes for extending the lifetime of WSN–IoT network.

5.4 Normalized energy

Figure 5a shows the analysis on normalized network energy for proposed and conventional models. As per the simulation outcome, the normalized energy attained by the proposed hybrid model is 75% superior to ABC, 50% superior to PSO, 68% superior to GSA, 5% superior to ALO, 55.55% superior to MFO and 7.69% superior to AGSA-based cluster head selection model in WSN–IoT network till the completion of 2000 rounds. Moreover, the normalized energy analysis of the proposed hybrid cluster head selection model by varying g is shown in Fig. 5b. Here, the normalized energy of hybrid model at \(g=-2\) is 34.45% better than model at \(g=-1\), 3.22% better than model at \(g=-1.5\) and 6.66% better than model at \(\text {g}=-1.8\) at 2000 round. At 1500th round, the normalised energy of the proposed model at \(g=-2\) is 8% better than the proposed model at \(g=-1.5\) and 7% better than the proposed model at \(g=-1\) and 6.3% better than the proposed model at \(\text {g}=-1.8\). Hence, the energy preserved by the proposed hybrid model is higher than the traditional models.

Table 1 Energy, temperature, and load of selected cluster head for proposed and conventional models
Table 2 Energy, temperature, and load of selected cluster head for proposed hybrid model by varying g

5.5 Load analysis

The analysis on load maintained by the proposed and existing cluster head selection models is shown in Fig. 6a. Here, the load is determined by taking the mean of 10 cluster heads that is chosen for each instant. In fact, the effective performance of WSN–IoT network can be attained by minimizing load. As shown in Fig. 6a, the proposed hybrid model maintains the minimum load before 1500 rounds. Further at the beginning of the 1500th round, there is a sudden rise in load, and at the 1600th round, it starts to reduce the load. Figure 6b displays the load analysis on proposed hybrid model by varying the value of g. Here, the load is minimized by proposed model at \(-2\) where as the load is slightly higher in model at \(g=-1.5\).

5.6 Temperature analysis

Figure 7a shows the temperature analysis of the proposed hybrid cluster head selection model in WSN–IoT network. The temperature of the IoT devices should be reduced to achieve the superior performance. Accordingly, the temperature minimized by proposed hybrid model is 5.17% better than ABC, 1.78% better than GSA, 3.50% better than ALO, 2.13% better than MFO and 1.78% better than AGSA models at 1200th round. Similarly, temperature analysis of proposed hybrid model by altering the value of g is shown in Fig. 7b. Here, the temperature is seemed to be highly reduced in hybrid model at \(g=-2\) than other values.

5.7 Cluster head quality

As mentioned earlier, the current simulation is accomplished with a total of 2000 rounds, where each round selects 10 cluster heads. Therefore, it is essential to analyze the selected 10 cluster heads to validate the effectiveness. This section analyses the selected 10 cluster heads at 2000th round of proposed and conventional models in terms of preserved energy (E), temperature (T) and load (L). The associated outcome is shown in Table 1, which reveals the fact that maximum energy preserved by the cluster head is \(3.72 \times 10^{-44}\) and minimum temperature and the load is 5.2 and 3, respectively for the proposed hybrid model. In terms of the minimum temperature, the proposed model is 2.2% better than the conventional ABC, 3.44% better than the conventional GA, 1.6% better than the conventional GSA, 1.5% better than the conventional AGSA, 1.2% better than the conventional ALO and 0.89% better than the conventional MFO. Hence, the cluster head quality of the proposed model is better than the conventional methods.

5.8 Spiral function frequency

Table 2 provides the energy, temperature, and load carried by the selected 10 cluster head from proposed hybrid model by varying the value of g. The result shows that energy preserved by each cluster head is \(3.72 \times 10^{-44}\) and minimum temperature and load is 5.6 and 3, respectively. In addition, the proposed model at \(\text {g}=-2\) is 4.5% better than the proposed hybrid model at \(\text {g}=-1\) and 1.06% better than the proposed hybrid model at \(\text {g}=-1.5\).

6 Conclusion

This paper has presented the optimal cluster head selection model in WSN–IoT network using a hybrid algorithm with the combination of MFO and ALO algorithms. The main objective of the proposed model was to select the cluster head by not only preserving the energy of the node by minimizing distance and delay, but also by balancing temperature and load of IoT devices. To the next of the simulation, it has compared the performance of the hybrid model with conventional models like ABC, GA, PSO, GSA, ALO, MFO and AGSA. The simulation analysis was done by concerning the convergence, sustainability of alive nodes, normalized energy, load, and temperature. Finally, the simulation results have showed that the convergence of the proposed hybrid model was 7.40% superior to ABC, 19.58% superior to GA, 12.62% superior to PSO, 20.83% superior to GSA, 0.86% superior to ALO and 0.43% superior to AGSA-based cluster head selection models. Therefore, the performance of proposed hybrid model has extended the life expectancy of WSN–IoT network as it preserves more energy and minimizes distance, delay, load and energy of sensors and IoT devices.