Introduction

Wireless sensor networks (WSNs) consist of hundreds and thousands of wireless sensor nodes. These sensor nodes are capable of sensing the data and can be mounted and distributed in the area of interest. The networks formed using WSNs are utilized for performing various tasks such as environment monitoring, natural habitat monitoring, medical applications, industrial application, military application and geological survey of a landscape, etc. [1, 9]. Localization in WSN has received significant attention because of its usefulness to operate in the remote areas where human cannot reach. The localization in the applications such as identifying the environmental condition in the dense forest and remote survey of a landscape without the intervention of humans plays a vital role. WSNs are the best solution in a conditions where the data gathering from remote place is considered [2]. The formation of WSN is also investigated by applying global positioning system (GPS) to all the sensor nodes, but it is not feasible due to increase in hardware cost and makes the sensor nodes bulky [1,2,3,4,5].

To reduce the cost and energy consumption in WSN, some nodes can be equipped with the GPS system. These nodes are called as anchor node or beacon node [5]. These nodes are aware of their position and are utilized to find the position of the other sensor nodes in the network. Localization algorithms are developed with the intention of finding the location of an unknown sensor node in the specified region [4]. Generally, localization algorithms are classified in two categories: (1) range based algorithm and (2) range free algorithm [4, 5]. The range-based algorithm utilizes distance or angle estimation and shows good accuracy whereas the range free algorithms adopts only connectivity information to find the location and are cost effective [4, 5].

The localization algorithms are further classified into centralized and distributed based on the approach used for localization wherein different techniques are employed for position calculation [1]. In centralized algorithms, a central device gathers all the important information from all the sensor nodes and perform all the required computations. This central device must have high power and high computational capability [1, 6]. But, in distributed algorithms, each device estimates its own location with the help of neighboring device or the anchor node [1, 5].

Generally the distributed algorithm works on the concept of network partitioning [7]. The network is divided into sub-regions called the network partition or clusters [7, 8]. Scalability, robustness, parallel and distributed computing and reduced traffic in the network are some of the advantages of using clustering in WSN. Objectives of the clustering are application dependent, but in most cases these objectives are load balancing, fault tolerance, increased connectivity, minimal anchor count, increased network lifetime, and to increase the energy efficiency.

Most of the localization algorithms have been proposed by considering the plane surface. In real time scenario, the surface is not always plane but it is uneven such as valleys, hilly areas, mountains, etc. At such places, depth information is very much needed to find the location of the event occurring at that place. By considering these areas as the three dimensional space, the efficient localization algorithm is needed to find the location of the sensor nodes at that place. Most of the 3D localization algorithms suffers from low accuracy, high computational complexity, low positioning coverage, and relying too much on the anchor node. The non-uniform densities and irregular topologies are the issues in finding the location of the sensor node in 3D environment. The clustering algorithms can be helpful in reducing the computational complexity and provide a solution for network management using the resources efficiently. The clustering-based localization algorithm delivers wider coverage in the network and offer more accurate result.

The localization using clustering is not explored much in 3D localization. Thus, we propose a new clustering algorithm for 3D localization in WSN using received signal strength values and the angle of arrival information. The clusters are formed based on the received signal strength indicator (RSSI) information received from the surrounding sensor nodes. Once the clusters are formed, the angle of arrival (AoA) information of the signal is also collected at the cluster head. The RSSI values along with AoA information will further be utilized for localizing the sensor node by the cluster head creating the local maps. The local maps created by the cluster heads can be converted to global map with reference to the coordinates of the Base Station.

This subject is novel since RSSI-based clustering is not mentioned in the any previous literature in 3D localization. Moreover, the combination of RSSI and AoA for localizing the nodes using clusters has not yet been explored. The performance of the algorithm is studied with reference to the energy efficiency and the lifetime of the network.

The paper is organized as follows. “Literature Review” presents the literature review based on localization techniques in 3D environment. Energy efficient clustering is described in “Clustering Algorithms for Energy Efficiency”. “Spherical coordinate System for 3D localization” demonstrates the spherical coordinate system for three dimensional coordinate calculation. The material and methods and the localization process are presented in “Materials and Methods”. The experimental results are discussed in “Experimental Setup and Results”. “Conclusion” presents the simulation analysis and performance followed by the conclusion and the future scope of the work which is also discussed in this section.

Literature Review

Most of the localization algorithms are classified as range-based and range-free. In range-based localization algorithm, the distance estimation between the sensor nodes are used for localizing the target or unknown node by using RSSI or AoA measurements. The range-free localization algorithms are based on the connectivity information between the sensor nodes which is defined mostly in terms of hop count value. Some of the range-free and range-based 3D localization algorithms are presented in this section.

The effects of the Voronoi diagram in 3D location space are discussed and analyzed in [10]. The Sequence Localization Correction method based on 3D Voronoi diagram (SLC3V) is presented, which uses a 3D Voronoi diagram to split the 3D location space and creates virtual beacon node rank sequence tables. SLC3V corrects the estimated distance and adjusts the location sequence of uncertain nodes by using the RSSI method between beacon nodes as a reference. Then, by applying a normalization procedure using rank correlation coefficients, it determines the best parameter N and creates a weighted location estimate with N valid virtual beacon nodes.

SLC3V determines the centroids of three types of polyhedron areas, known as virtual beacon nodes. After partition, the distance between virtual and real beacon nodes is calculated. A location sequence table for all beacon nodes is created, including actual and virtual beacon nodes, based on their distance rank. The unknown nodes’ position sequence table is then computed and corrected using the RSSI approach. As a result, the unknown nodes’ position sequence table will be closer to the truth.

It selects the optimal parameter N, which determines the valid number of virtual beacon nodes utilized in localization estimation, by estimating the coordinates of real beacon nodes using Kendall coefficients. Finally, it generates N valid virtual beacon node optimum localization sequences and predicts the unknown node’s coordinate using Kendall coefficients between the sequences in the ideal localization sequence table and the unknown node sequence.

A cube boundary is constructed as per the 3D location environment. The real beacon nodes are scattered in the 3D space randomly. 3D Voronoi diagram is used to partition the space to create Voronoi polyhedrons. A set of min-vertical planes divides 3D space into three types of areas, such as edges, faces, and bodies.

Virtual beacon node is identified by finding the centroid of the regions. Based on the distance between virtual beacon nodes and real beacon nodes, the location sequences of virtual beacon nodes are ranked. All real beacon nodes know their position through GPS and the virtual beacon nodes are identifying their position after partitioning the region. Based on the distance, the location sequence values are assigned to virtual beacons to know how close they are to the real beacons. To rectify the measured distance and adjust the location sequence of unknown nodes, the distance and RSSI between real beacon nodes is utilized as a reference. Unknown nodes can correct their measured distance according to the environment based on the RSSI correction. As a result, the algorithm can resolve the position sequence of an unknown node and assure that it is consistent with the actual scenario. The order correlation coefficients between the vectors in the virtual beacon node sequence table and the unknown node sequence are calculated. Optimal number of virtual beacon nodes are determined by using weighted estimation which also reduces the computational complexity of the algorithm.

The log normal shadowing model is used for RSSI calculation to sample a distance function as shown in Eq. (1);

$${P}_{\mathrm{R}}(d)= {P}_{T}-\mathrm{PL}\left({\mathrm{d}}_{0}\right)- {10}_{n}\mathrm{lg} \frac{\mathrm{d}}{{\mathrm{d}}_{0}+ {X}_{\sigma }}$$
(1)

The localization error is calculated by using following Eq. (2);

$${\mathrm{P}}_{\mathrm{e}}=\frac{|\mathrm{Estimate \, location}-\mathrm{real \, location}|}{\mathrm{Wireless \, communication \, radius}} \times 100$$
(2)

An unmanned aerial vehicle (UAV) which is GPS enabled, is used to know the position of the sensor nodes in the 3D environment [11]. The UAV flies over the sensor nodes that were deployed in the monitoring region transmitting its geographical location on a regular basis.

When a node receives four or more messages indicating the UAV’s position, it can determine its own position. To determine the position of a system in three dimensions, four points of reference are required, as opposed to three in a two-dimensional system. Two well-known propagation models viz Free Space and Two-Ray Ground are considered for the simulation. The Free Space model considers no interference during signal propagation while Two-Ray Ground considers the possibility of signal reflection during propagation. The RSSI technique is used for the distance calculation since it does not require any extra hardware and no control messages for the distance estimation.

The Two-Ray Ground signal propagation model is more significant since it considers the possibility of signal reflection on the ground, to make a 3D localization system more realistic. Four reference points are required to calculate a three-dimensional position. During the UAV’s flight over the monitoring region, these reference points are collected. Aside from the four reference points, the distance between each point must be known. Then by applying multilateration method, the position of the unknown can be estimated. This method uses least square method because of its simplicity and the performance.

The proposed localization algorithms consist of two parts. The first part consists of flying the UAV periodically and broadcasting the signal to be received by the sensor nodes. The schedule of the UAV flight and broadcasting the message is maintained. The periodic broadcast takes place in time with the UAV’s movement throughout the monitored area.

In the second part of the algorithm, the RSSI for the received message is translated to a distance measurement. The UAV’s position and distance from each position are then updated in the reference set by node. If the reference set is 4, the node can calculate its three-dimensional geographical position. The set reference is supplied as a parameter to the least Squares function, and the return is the sensor node’s computed position.

The author has claimed that with a small inaccuracy, the proposed technique estimates the position of unknown nodes. The algorithm’s efficiency is independent of the number of nodes in the network, which is crucial in terms of scalability. Furthermore, all sensor nodes acquire enough data to calculate their position.

To improve the localization accuracy and to reduce the failure of localization, a range free localization scheme in 3D environment has been proposed in [12] using mobile beacon node. Location of the sensor node is calculated by obtaining two probable points by finding the intersection of three spheres with centers of the spheres as the reference points. The mobile beacon knowing its position through GPS move in the area of deployment broadcasting the message with its current position. The sensor nodes which are deployed in the 3D environment does not send any data to the beacon node and only receive the messages from the beacon node when it is in the communication range of beacon. When the sensor node receive four beacon points, then the distance can be estimated using these beacon points.

$$\left\{\begin{array}{c}\sqrt{{(x-{x}_{1})}^{2}+ {(y-{y}_{1} )}^{2}+ {(z-{z}_{1} )}^{2}}=r-d/2 \\ \sqrt{{(x-{x}_{2})}^{2}+ {(y-{y}_{2} )}^{2}+ {(z-{z}_{2} )}^{2}}=r-d/2\\ \sqrt{{(x-{x}_{3})}^{2}+ {(y-{y}_{3} )}^{2}+ {(z-{z}_{3} )}^{2}}=r-d/2\\ \sqrt{{(x-{x}_{4})}^{2}+ {(y-{y}_{4} )}^{2}+ {(z-{z}_{4} )}^{2}}=r-d/2\end{array}\right.$$
(3)

Equation (3) can be solved to estimate the position of the sensor node. Path of the beacon node movement affects the deployment of the sensor nodes. So, if the defined path is used then more accurate results can be obtained.

The combination of RSSI and TOA is proposed in [13] for locating the node in 3D environment using mobile anchor node for increasing the accuracy of location estimation. Gauss–Markov three dimensional mobility model is used to define the movement of the node in the region. RSSI is used for near end sensor nodes and TOA is used for far end sensor nodes. The maximum likelihood method is used to find the final estimated location of the sensor nodes.

The moving anchor node broadcast the message containing the position information and creates the markers as per the position. These markers are then used as the virtual reference node which can be used to locate the unknown node. The RSSI ranging method determines the power loss in the signal propagation process based on the signal power received by sensor nodes, then transforms the power loss to a distance value using theoretical and empirical models. The TOA ranging method calculates the distance between two nodes by measuring the wireless signal's transmission time.

The N sensor nodes are randomly deployed in the area of interest with the M anchor nodes. The (NM) are the unknown nodes which are to be localized. All the sensor nodes have the same communication range. After the measured distance value di (or dj) between m (m 4) unknown nodes and anchor nodes (or virtual anchor nodes) are collected from the three-dimensional monitoring region of WSN. The coordinate values of unknown nodes are determined via maximum likelihood estimate. The work can be extended for multiple mobile anchor nodes.

By using sensor depth information and a simple projection approach, the 3D underwater sensor network (USN) localization problem is converted into its 2D equivalent [14]. The idea of the research is based on the proof that non degenerative projection conserves network localizability. Underwater Sensor Positioning (USP) is a purely distributed bilateration localization technique for 3D USNs. USP is based on a new projection-based localization methodology that allows 2D localization methods to be used in 3D environments. The technique is divided into two primary stages: offline pre-distribution and distributed localization. The first phase involves preloading initial setup information into nodes, while the second phase involves iteratively executing the distributed localization method. The sensor nodes that are relatively stationary are distributed randomly with at least three anchor nodes which are GPS enabled. Sensor can compute their depth information using pressure depth knowledge or some other techniques. Projection technique uses a mechanism for converting the positions of reference nodes from one plane to another. The challenge of locating node X in a 3D space has been simplified to locating X in a 2D space using a non-generative projection. To achieve 3D underwater localization, USP uses both projection and bilateration. USP’s multi-iteration execution approach steps through the computation of a maximal bilateration extension subgraph of the original network. USP is a distributed localization framework that elegantly integrates projection and bilateration, when the two approaches that ensure its optimal localization capabilities used together.

A new distance estimation approach for 3D localization is proposed in [15] where the main focus is on the creation of a dissimilarity matrix that represents the distance between each node in the network. The node’s coordinates in a local coordinate system are determined using an MDS-based localization approach, and the Helmert Transformation is used to translate the node's local coordinates into a global coordinate system. The nodes are deployed in the 3D environment with some anchor nodes. The nodes are static in nature and adopt flat technology. The localization process consists of three steps: (1) Distance estimation, (2) Location estimation, and (3) Coordinate transformation. RSSI is used for the distance estimation and the algorithm runs at the central server. Multidimensional scaling method is used for the location estimation. Coordinate transformation is performed to map the local coordinates with the global coordinates.

The localization error increases with the increase in the communication range. The proposed algorithm works well in the minimum density network. If the density fall below the minimum level, then it does not produce good results. The time complexity of the algorithm increases with increase in the number of nodes. The algorithm can be extended for mobile anchor nodes.

A 3D localization based on single mobile beacon node is proposed in [16]. The combination of UWB signal and TOA information is used for calculating the distance between the mobile anchor and the sensor node. SDI algorithm is used as the 3D positioning algorithm. A low altitude flying aircraft carries the beacon node which know its position through GPS. Beacon node broadcast the current position periodically. UWB signal has good performance in multi path propagation. Time of arrival (TOA) is used for distance calculation. Space distance intersection (SDI) for calculating the position of unknown node using three nonlinear beacon position in 3D environment.

An adaptive flower pollination (AFPA) is presented in [17] to locate the node in 3D wireless sensor network. The flower pollination algorithm (FPA) is based on the natural pollination process that occurs in flowering plants. To simulate the pollination process, each flower has a global and local pollination phase with a switch probability ps. Instead of utilizing a fixed switch, adaptive FPA uses an adjustable switch called pt to balance the exploitation and exploration tendencies during the search phase. The implementation of the Elite Opposition-Based Learning (EOBL) technique has boosted exploration. Cauchy-based step size has improved the global pollination phase, allowing for more effective exploration of the search space. Local neighborhood search (LNS), which is based on knowledge of the optimal result, has improved exploitation. The dynamic switch probability pt is used to create a balance between exploration and exploitation. In the standard FPA, the modified AFPA is created by combining the EOBL technique, the Cauchy distribution based Global pollination phase, the LNS model, dynamic switch probability, and the catfish effect mechanism. Single anchor node is used to locate the unknown node. Three layer structure is used for the deployment of the sensor nodes. Anchor node is placed at the top level while the normal sensor nodes are randomly deployed at the middle and bottom level. RSSI is used for the distance calculation using Euclidean distance calculation method. Six virtual anchor nodes are projected at 60 degrees each after calculating Euclidean distance to locate normal nodes using the umbrella projection method. The centroid is calculated using one anchor and three virtual anchor nodes. The Adaptive FPA technique is then used to optimize the data by utilizing this centroid information. The virtual anchor nodes helps in reducing the effect of line of sight for communication. Calculating the mean square error between actual and estimated coordinate’s distances of actual and estimated nodes, yields the fitness function.

The combination of APIT and the Dv-Hop is demonstrated in [18] to develop hybrid 3D localization algorithm for increasing the localization accuracy and coverage rate of the beacon node. Changes in the signal intensity of the unknown node received by the beacon node are used to implement the improved APIT algorithm. The improved APIT algorithm reduces the area of the unknown node within the triangle, improving the node's localization accuracy. The triangle can be formed by selecting any three beacon nodes randomly. The triangle with the target node is selected. The concrete realization is to divide the triangle, allowing it to be subdivided into several small intervals, and then further subdivided into other small intervals. Dv-Hop is a range free and distance independent algorithm used for localizing the sensor node. The hop count is the base for locating the nodes where the coordinates of the sensor node can be estimated using any measurement techniques or maximum likelihood method. 3D Dv-Hop also follow the same steps for estimating the location of the sensor nodes in 3D environment. The final position estimation of the sensor node depends on the multiple degree of collinearity of the beacon nodes. The mesh quality of the tetrahedron can be used to assess the degree of multiple collinearity of the four beacon nodes in three dimensions. The tetrahedron can be thought of as a three-dimensional triangular extension. In the presented algorithm, the APIT is used when the neighboring beacon nodes are greater than six and the Dv-Hop is used when the number of neighboring beacon node is less than three.

The concept of degree of coplanarity is combined with the traditional DV-distance to minimize the positioning error in 3D localization [19]. The node which is located is made an assistance anchor node to increase the area coverage. The RSSI is used as the distance estimator between the sending and receiving node. Along with RSSI, the modified DV-hop distance technique is used in which the cumulative distance is replaced by the actual distance between the nodes. The distance and anchor node location information is used to locate the unknown node using multilateral localization. In three dimensional space at least four anchor nodes are required to locate the node as compared to three anchor nodes in two dimensional space. The coplanar degree of four anchor nodes in three-dimensional space is represented by the Degree of Coplanarity (DCP) in Fig. 1.

Fig. 1
figure 1

Localization model in three dimensional space

The degree of coplanarity is defined by Eq. (4),

$${\text{DCP}} = \left\{ {\begin{array}{*{20}c} 1 & {coplanr} \\ \rho & {else\;\;\;\;\;\;} \\ \end{array} } \right.$$
(4)

where \(\mathrm{DCP} \in \left(\mathrm{0,1}\right)\).

The anchor node with the most DCP value is called the best positioning unit. The anchor node selection is done based on the DCP value for more accurate localization. Sometimes the positioning units are not available for locating the unknown node, so to solve this problem the concept of assistant anchor node is used. The assistant anchor node is the node whose location is calculated. Localization is simply a problem of optimization based on various distances. There is a flaw in quadrilateration-based localization algorithms. The Quasi-Newton approach is used to provide optimized localization of the sensor nodes.

Bacterial foraging optimization (BFO) and invasive weed optimization (IWO), are combined to propose range-free localization techniques for 3D space in an anisotropic environment [20]. Received signal strength (RSS) information is used to locate the target node by calculating the distance between the anchor node and the target node. Edge weights between target nodes and their neighboring anchor nodes are used to estimate the positions of target nodes to overcome the non-linearity between RSS and distance. The computational complexity of the algorithm is reduced by using the fuzzy logic system. Furthermore, BFO and IWO are used to optimize the edge weights to achieve more accuracy of localization. Anchor nodes and target nodes are distributed randomly in the region of interest. The anchor nodes send the beacon signal in the network collecting RSS from the target nodes. The anchor nodes are GPS enabled and know their position. If the target nodes have four or more numbers of anchor nodes then the node is localizable. Fuzzy logic system is used to calculate the edge weights between the target node and the anchor nodes. Weighted centroid method is used to calculate the location of the target node.

A landscape-3D localization solution is proposed in [21] in which it considers localization as a functional dual of target tracking. The landscape 3D is fully independent of the network topology and density of nodes. Sensor nodes are randomly deployed in the area of interest and the location aware (LA) node may be any airplane, mobile device or any moving object which know its position. The LA can send out beacons to sensor nodes, each of which provides the LA’s current location as well as the transmitting power needed to send the beacon. After the beacons have been broadcast, the LA is free to depart. Each sensor passively listens to the beacons during the process, estimating the distance between itself and the beacon based on the beacons’ measured RSS. There is no sensor-to-sensor transmission overhead throughout the localization operation. The ability of sensor nodes to communicate with the LA is not assumed. Landscape 3D assume localization of the sensor nodes as the target tracking problem. To dynamically determine the positions of sensor nodes, the Landscape-3D system takes advantage of changing LA positions and corresponding sensor-to-LA distances.

An improved heuristic method for distance computation to construct and analyze an algorithm based on multidimensional scaling (MDS) technique for three-dimensional (3D) node localization in WSN is presented in [22]. The problem that lies with the MDS-MAP is to find the shortest distance between pair of nodes. To reduce the distance calculation error, the heuristic approach (HA) is used to calculate the distance between non-neighboring sensor nodes. MDS is an extremely precise dimensionality reduction approach. If the correct distance matrix is provided as input, the MDS method will correctly reconstruct the network map. The presented approach first calculates the shortest distance between the pair of sensor nodes by using heuristic approach to form the distance matrix. The classical multidimensional scaling algorithm is applied by taking the distance matrix as the input. The first three biggest eigenvalues and eigenvectors produce a relative map with each node’s relative location. Singular value decomposition method is used to find the optimal rigid transformation which transforms the relative map to the absolute map using at least four anchor nodes. RSSI method is used for distance identification. The sensor nodes are static in nature and the connectivity path is available between every pair of nodes. Random and grid network topologies are used for experimentation.

A parametric loop division (PLD) algorithm based 3D localization is discussed in [23]. Anchor nodes defines the boundary to locate the sensor nodes lying within that boundary. The region shrink towards the center to locate the node more accurately. The PLD algorithm’s main idea is to locate an actual localization volume in 3D space and estimate a node’s true position. With the addition of remarkable nodes in its control ring matrix, it subdivides pieces of a triangle in each phase. A triangle can be formed by three nodes in a network. Choose the closest node as a reference point and use those extraordinary nodes to create new parametric points. With the help of the reference points, new parametric points are created. PLD can be used to locate a WSN node that has a uniform or random distribution of anchor nodes. PLD generates a variety of iterations, each of which may contain a large number of unknown nodes in a large volume of anchor node distribution in 3D space. Furthermore, each PLD network may calculate the amount of nodes it has for localization. The PLD algorithm parameterizes 3D space, resulting in parametric nodes, each of which holds information about the sum of received power from all network anchor nodes. Each iterative step in PLD can produce a similar triangle with respective anchor nodes by employing the parametric node. Sum of RSS from all the anchor nodes are checked at the parametric point. If it is less than the threshold value then it is accepted. Otherwise the value is again checked in the next iteration. If the RSS value is accepted then the size of the ring is reduced by some defined amount. The centroid method is used to determine the position of a sensor node, and the localization error can be obtained.

A range-free localization technique for 3D localization is proposed in [24] where MDV-Hop algorithm is used for distance calculation which is based on dynamic error collection and multi-hop communication scheme. An improved particle swarm optimization (PSO) algorithm with inertia weight and trust coefficient is used to increase the accuracy of estimation by optimizing the calculated location. A collection of anchor nodes with the same distance from the central node s is formed. The average distance per hop is dynamically changed based on the distance to unknown node and average distance error per hop. The weighted value can be determined using the RSME of anchor nodes; nevertheless, the distance per hop in one group is equal to the total of all the distance per hop of anchor nodes with weighted values. Finally, the unknown node’s distance from the anchor node can be calculated using the distance per hop of unknown nodes in different groups. The proposed approach considers static senor nodes which can be extended for mobile anchor nodes. Range-based distance calculation algorithms can also be used to improve the accuracy of location estimation.

Hop count based 3D localization technique using anchor node to find the location of the sensor node has been presented [25]. Event triggering mechanism and event-based output technique considered to provide better accuracy and efficiency of localization. The monitoring area is divided into n × n × n grid structure to generate the cube as the output in which the target node is located. The distance estimation between the anchor node and the target node is the preliminary task that must be performed, and then finding the shortest distance between the anchor nodes and the target nodes. It is expected to have the target node within the one hop cubic space of the anchor node. More the number of anchor nodes within the grid, the target node becomes more localizable. Using Min–Max method, the upper bound and lower bounds of the coordinates can be obtained.

In [26], secure and robust localization is highlighted for 3D environment. The proposed algorithm provides the security to the sensor network from the malicious node. The algorithm is robust since it works properly in the presence of malicious node also. Quadrilateration is used to locate the unknown node with the help of beacon nodes which know their position through GPS. Beacon node share their location with the unknown sensor nodes by broadcasting the message and estimate the distance. The control unit with the beacon node ask for the authentication id before start of the transmission with the target node. A public authentication key and encryption technique are used to sign the message. The key exchange is done for decrypting the messages. Centroid of the beacon location is used to locate the target node.

The concept of flying anchors is used in [27] to localize the unknown nodes in 3D WSNs using range free localization algorithm. Since a configuration which is quite similar to a vehicle-to-infrastructure (V2I) based positioning technique is employed in the proposed method. The algorithm’s nature is also ideal for vehicle localization. For the random movement of mobile anchor nodes which are equipped with a global positioning system (GPS), a multilayer C-shaped trajectory is adopted to broadcasts its location information over the sensing space. The mobile anchor nodes continue to communicate the beacon and their position information to unknown nodes while selecting three additional anchor nodes to form a triangle. The distance is then calculated using link quality induction against each anchor node, with the localization error calculated using the centroid-based technique.

A COLA (complexity-reduced 3D trilateration localization approach) has been proposed in [28] to reduce the complexity of localization algorithm and reduce the 3D trilateration into 2D trilateration. The proposed approach uses a super anchor nodes whose coordinates differ only in z-coordinates. Increasing the number of anchor nodes increases the computational cost. The accuracy can be increased with the elimination of the possible propagation error.

A hybrid approach using RSSI and AoA is proposed for target localization in non-cooperative and cooperative 3D wireless sensor network [29] for known and unknown transmit power. The proposed approach uses maximum likelihood (ML) method to increase the accuracy of the estimates. Angle measurement error and the orientation error are considered in place of digital compass to generalize the model. Cooperative and non-cooperative localization with both known and unknown transmit power are presented in the proposed approach.

A three dimensional adaptive multilateration localization (3D-AML) is presented in [30] for light weight localization in three dimensional environment with better accuracy. 3D-AML converts the two-dimensional concept of intersecting circles into three-dimensional intersecting spheres. Geometric features are also used by 3D-AML to determine the location of a sensor node. As a result, it has a low time complexity due to the use of arithmetic operations.

Three dimensional DV hop algorithm (3DDV Hop) is combined with A* algorithm in [31] to locate the sensor node in wireless sensor network. To begin, node hop-count values are optimized, and the average distance per hop error is addressed. Then, to optimize the coordinates locally, the multi-objective optimization non dominated sorting genetic algorithm (NSGA-II) is used. The pareto-optimum solution is found after selection, crossover, and mutation. The hop-count value of the network’s localization node is optimized using the improved A* method. The initial hop-count value and deviation angle are normalized to achieve intelligent selection of the optimal node to be hopped, resulting in a straight line hop count value path between each node, and the new hop-count value is calculated iteratively. The average hop distance is adjusted. The deviation angle and the normalized values of the original hop-count value are utilized as correction factors to adjust the predicted distance per hop, further reducing the average distance per hop error. The NSGA-II algorithm is used to iteratively refine the estimated coordinates in the local area to improve accuracy. As a reference, the coordinate value produced using the least square technique formula is applied, and the optimal search target range is determined.

Based on RSSI, a 3D localization algorithm is presented in [32] using antennas radiation pattern in wireless sensor network. The proposed localization procedure is based on a target node equipped with a half wave dipole antenna that radiates in an omnidirectional manner. A new relative height estimation is proposed based on the fact that as the height increases the received signal strength at beacon from the target node decreases.

A 3D localization approach is presented in [33] based on acoustic signal to locate the sensor node in wireless sensor network. The capacity to determine the geographic location of a sound source is known as audio localization. This specialty creates subjective sound spaces by determining the sound source’s direction. Its azimuth strength and distance indicate the sound’s direction from the source. The position of each sound source in a three-dimensional spherical acoustic field can be determined by the binaural character of the listener’s auditory system. Three microphones along each axes are used to obtain more information to locate the source. Along with RSSI, TDOA and AoA are used for the estimating the location of the target node by using trigonometric formulas. Deployment of sensor nodes is based on genetic algorithm.

In [34], the localization is modeled as the optimization problem. Since the sensor nodes in the real time scenarios are mostly not time synchronized, the UAV is used to broadcast the message to all the sensor nodes in the deployed area after every defined time interval consisting of its position information. Multidimensional scaling with the intersection of three or more spheres is used to estimate the location of the target node considering interconnection point as the estimated location point. A micro-differential evolution with scalar mutation (MDESM) is used considering the additive estimation error to locate the sensor node in 3D environment. The summary of 3D localization algorithms is presented in Table 1

Table 1 Summary of 3D localization

Clustering Algorithms for Energy Efficiency

Clustering is also used for creating energy efficient network which run for longer period of time and will be used at its full capacity. Some of the clustering algorithms are described in this section.

Effect of heterogeneity of the nodes on the performance of the clustering algorithms in WSN is analyzed in [35]. All the sensor nodes and the base station considered to be stationary. Sensor node is deactivated once the energy becomes zero. Energy dissipation depends on inter cluster and intra cluster communication. In case of inter-cluster communication, the cluster heads communicate with the base station whereas in intra-cluster communication, the cluster member nodes communicate with the cluster head. The energy dissipation of the sensor nodes and the cluster head is dependent on the inter-distance and intra-distance values. Equation (5) gives the intra-cluster communication distance.

$$\mathrm{Intra}-\mathrm{cluster \, communication \, distance}= \sum_{i=1}^{N}\mathrm{Dist }\left(i,\mathrm{ CH}\right)$$
(5)

where, N represents number of nodes in the cluster, Dist (i, CH) is the distance between the nodei and the cluster head.

If the cluster head is positioned at the center of the cluster, then the energy dissipation of the cluster member node is less since the intra-cluster distance is less.

An improved LEACH clustering algorithm is developed to reduce the energy consumption in WSN [36]. Clusters are selected based on the residual energy of the sensor nodes dynamically. Sensor nodes are deployed randomly in the sensing field, and position of the base station is fixed. In this case, cluster heads communicate directly to the cluster member nodes and the base station. The responsibility of routing process is assigned to the base station. After every round of communication cluster heads are elected based on the residual energy, generally more than 10%. The authors have claimed that the proposed method is applied for static networks but can be extended for dynamic networks. In another study, an energy efficient hierarchical routing based on clustering is presented [37]. The clusters are formed based on the residual energy of the sensor nodes. Afterword, cluster head is selected with the highest residual energy and the shortest distance from the base station. The base station is responsible for transmission activities and divides the sensor nodes into small subgroups and dedicate one sensor node as the cluster head of the group. The setup of WSN consist of homogeneous nodes with same initial energy of nodes, static nodes, and different level of clusters i.e., level one, two or three. The levels decide the data transmission in clustering hierarchy. Moreover cluster heads transfer the collected data to the cluster head which is closer to the base station. To prolong the lifetime of the network, cluster heads are selected in rotation.

To find the optimum cluster size, a distributed clustering is designed in [38], wherein homogeneous and heterogeneous clusters are formed. It is observed that the heterogeneous clusters are more efficient than the homogeneous clusters. If the cluster size is bigger than the sampling, then the variance is also big and hence cost of communication increases and vice versa. Moreover, decrease in mean square errors between the clusters, increases cluster’s efficiency. In [39], cluster-based routing is proposed wherein the cluster heads are dynamically changing in heterogeneous WSN. Here, cluster heads are elected based on the higher energy level of the node. On the other hand, energy consumption is distributed efficiently over the network to achieve network stability and prolong lifetime. The proposed setup comprises of the normal node, advance node, and super node. The advance node and super nodes are penalized when their residual energy is same as compared to normal node after some rounds. Thus, to deal with this problem of cluster head selection, function is changed to provide equal probability to become cluster head to all three types of node.

Another energy efficient clustering algorithm is developed to increase the lifetime of WSN [40] which utilizes fitness function based on Glowworm swarm with Fruitfly algorithm, to identify best cluster head. While selecting the cluster head, the energy level, packet delay, and distance between the nodes are considered as important parameters. In addition, quality-of-service (QoS) is selected for efficient network performance in WSN.

Spherical Coordinate System for 3D Localization

In mathematics, a spherical coordinate system is a coordinate system for three-dimensional space where the position of a point is specified by three numbers: the radial distance of that point from a fixed origin, its polar angle measured from a fixed zenith direction, and the azimuthal angle of its orthogonal projection on a reference plane that passes through the origin and is orthogonal to the zenith, measured from a fixed reference direction on that plane. It can be seen as the three-dimensional version of the polar coordinate system [41, 42].

The spherical coordinate system generalizes the two-dimensional polar coordinate system as shown in Fig. 2. It can also be extended to higher-dimensional spaces and is then referred to as a hyper spherical coordinate system.

Fig. 2
figure 2

Spherical coordinate system

Spherical coordinates are useful in analyzing systems that have some degree of symmetry about a point, such as volume integrals inside a sphere, the potential energy field surrounding a concentrated mass or charge, or global weather simulation in a planet’s atmosphere. A sphere that has the Cartesian equation x2 + y2 + z2 = c2 has the simple equation r = c in spherical coordinates [41, 42] (Fig. 3).

Fig. 3
figure 3

Geometric configuration of point P

The relationship can be established between the Cartesian coordinate system and the spherical coordinate system as shown in Fig. 4. The coordinate r is the distance between point P and the origin. P’ is the projection of point P to the XY plane. Ф the angle between the positive X-axis and segment between origin and P’. ϴ is the angle between positive Z-axis and the line segment from the origin to P [41, 42].

Fig. 4
figure 4

Localization in cluster1 (13 node in a cluster)

The relationship between the spherical coordinate system (r, ϴ, Ф) and the Cartesian coordinate system (x, y, z) of the point P can be calculated using trigonometric equations. In the triangle in Fig. 1 which is formed by projecting point P on the Z-axis has the radius r and ϴ is the angle the hypotenuse makes with Z-axis, the Z-coordinate is z = r × cosϴ. The length of the other leg of the right triangle is the distance from point P to the Z-axis, which is d = r × sinϴ. In Fig. 4 the original 3D coordinates in XY plane, is the right triangle whose vertices are the origin, the point P’ and its projection onto the X-axis [41, 42].

Here, r represents the distance between the origin and the point P’. Ф is the angle between the hypotenuse and the X-axis. The x and y components are as given below.

$$x = d\cos \phi$$
$$y=\mathrm{d} \mathrm{sin}\phi$$

So, the spherical coordinates can be converted into the Cartesian coordinates using the following formulas,

$$x=\mathrm{r sin \theta cos \phi }$$
$$y=r\mathrm{ sin \theta sin \phi }$$
$$z=r\mathrm{ cos\theta }$$

Materials and Methods

In this section, we propose a clustering algorithm for localizing the sensor nodes in 3D WSN which is energy efficient. The proposed approach is formulated by taking into account all the characteristics of 3D WSN and creating a clustered WSN which will help in localizing the sensor nodes without solving any optimization problem. The main reason for adopting the proposed approach is to reduce the communication overhead of the sensor nodes and hence the energy consumption. So, if the clusters can be formed based on the vicinity of the sensor nodes, then the density of the sensor nodes can be distributed among the partitions and the communication overhead can be reduced by limiting the communication in the restricted group. Moreover, energy consumption is reduced by reducing the number of communications as well as the range of communication while locating the sensor nodes.

The sensor nodes are deployed in the area of interest randomly. The anchor nodes are deployed deterministically at that location. The anchor nodes are acting as the cluster heads once the clusters are formed. All the anchor nodes start communicating with the surrounding sensor nodes and request them to send the acknowledgement signal. After receiving the acknowledgement signal from the sensor nodes in its proximity, the information is sent to the base station for the further processing.

At the base station, the RSSI values received from the anchor nodes are compared to find the higher strength RSSI at the respective anchor node. The sensors having higher signal strength at the anchor node becomes the cluster member of that respective cluster with the anchor node as the cluster head. This process is performed until all the node are distributed among different clusters. The clustering algorithm utilized is presented in Algorithm 1.

figure a

Localization Process

In practice, the AoA measurement consisting of elevation angle \(\theta\) and azimuth angle \(\varnothing\) can be obtained directly by equipping the sensor nodes with the directional antenna, an antenna array or by using smart antenna [43]. In the proposed approach, the sensor are equipped with the smart antenna since they can automatically set the orientation as well as the direction of arrival as per the signal strength.

In the localization process, the distance from the sensor nodes to the cluster head is estimated based on the received signal strength values from the nodes by using Eqs. (68).

$${\text{RSSI}}\,\left( d \right) = {\text{RSSI}}\, \left( {d_{0} } \right) - 10\,n\,\log \,\,\left( {{\raise0.7ex\hbox{$d$} \!\mathord{\left/ {\vphantom {d {d_{0} }}}\right.\kern-0pt} \!\lower0.7ex\hbox{${d_{0} }$}}} \right)$$
(6)
$$\widehat{d}= {d}_{0} {10}^{\frac{\mathrm{RSSI}\left({d}_{0}\right)-\mathrm{RSSI}(d)}{10n}}$$
(7)
$$\widehat{d}=d+{X}_{\sigma }$$
(8)

In the above Eq. (6), \(d\) is the transmission distance for which the RSSI is recorded at the cluster head. \({d}_{0}\) is the threshold distance which is considered as one meter. \({X}_{\sigma }\) is the cover factor which follow the long normal distribution with mean zero and standard deviation as σ.

In the proposed approach, we consider the cluster heads equipped with GPS and smart adaptive antenna and the sensor nodes equipped with the digital compass or small smart antenna. The elevation angle \(\theta\) and the azimuth angle \(\varnothing\) are automatically recorded at the cluster head as the AoA measurement along with the RSSI value. From these angle measurement, the direction of the signal can also be calculated. The distance information and AoA information is utilized to localize a node by using some geometric relationship within the cluster. For calculating the coordinates in three dimensional space, the spherical coordinate system is used. The estimated coordinated are then converted into the equivalent Cartesian coordinate system.

This localization information help in identifying the region of coverage of the node. Each cluster head creates a local map applying localization information about the cluster members. This local maps are shared with Base station by all the cluster heads to develop a global map of localization of the entire region. In the proposed localization approach, a single anchor node is used to localize the other sensor nodes in the cluster. This is minimizing the requirement of extra hardware and reducing the cost. The 3D localization algorithm using RSSI and AoA is presented in Algorithm 2.

figure b

Experimental Setup and Results

For the experimentations, the sensor nodes are randomly distributed in the specific area and deployment of the anchor nodes are accomplished by deterministic deployment technique in the same area. The uneven surface is considered for the experimentation with the higher path loss index. Initially, we have chosen 25, 50, 100 and 150 sensor nodes for distribution to obtain the preliminary results. Simulations are performed using MATLAB software during experimentation. The 3D space with the area of 1000 × 1000 × 1000 is considered for the deployment of the sensor nodes. Simulation are carried out with 25, 50, 100 and 150 sensor nodes with random distribution and two and three anchor nodes which are deployed deterministically at a particular position in the specified area. Table 2 presents the parameters for experimentation.

Table 2 Experiment parameters

Initially, the experimentation is performed with the 25 number of sensor nodes and 2 anchor nodes. The RSSI from all the sensor nodes to both the anchor nodes are collected and the clusters are formed based on the strong RSSI values to the anchor node to check the better connectivity. Stronger the RSSI, closer the node is to the anchor node. Once the clusters are formed, the anchor node which is also the cluster head can start communication with the cluster member nodes and can give the instruction for performing intended operation. But to know the origin of the information it is necessary to find the location of the senor node. So the localization algorithm is applied to know the location of the unknown nodes in the network. The localization algorithm combines the features of RSSI and AoA (both angle of elevation [Angle1] and azimuth angle [Angle2]) to find the location of the unknown sensor node with the anchor node as the reference node. Single anchor node based localization is proposed in this paper to reduce the hardware cost and increase the efficiency by avoiding the complex computation. The use of single anchor node also reduces the time required for locating the sensor node.

The experimentation is carried out by considering different scenarios of distribution of the nodes and the anchor nodes in the area of interest. The number of nodes and the anchor nodes are increased in steps to analyze the performance of the clustering and localization algorithm.

Initially, 25 number of sensor nodes are considered with two anchor nodes to form two clusters and then localization algorithm is applied to locate the unknown sensor nodes.

In the experimentation cluster are formed with the varying number of nodes in each cluster. The best case of cluster with 13 nodes in cluster1 and 12 nodes in cluster2 is considered here and the location estimation algorithm is applied on each cluster separately to find the location of unknown sensor node as shown in Figs. 4 and 5. A distributed computing is performed by applying the localization algorithm parallel on each cluster and thus the computational complexity of the algorithm can be reduced. The algorithm is made scalable by distributing the sensor nodes into different clusters and thus can reduce the energy consumption of the sensor network increasing the lifetime of the network. The following table indicates the experimentation values for the distance calculated from the anchor node and the identified location of the unknown sensor nodes in cluster1 and cluster2. The estimated coordinates of the sensor nodes in each cluster are shown in Tables 3 and 4.

Fig. 5
figure 5

Localization in cluster1 (12 node in a cluster)

Table 3 Distance and location calculation in cluster1
Table 4 Distance and location calculation in cluster2

Another simulation is carried out with 50 number of sensor nodes randomly deployed and 2 anchor nodes which are deployed deterministically. The best case is that all 50 sensor nodes are evenly distributed between two clusters i.e., 25 nodes in each cluster. The following figures shows the localization of sensor nodes in these two clusters after applying the localization algorithm. Also, the coordinate estimation is shown in Figs. 6 and 7, respectively.

Fig. 6
figure 6

Localization in cluster1 (25 node in a cluster)

Fig. 7
figure 7

Localization in cluster2 (25 node in a cluster)

The simulation is extended for 100 sensor nodes with two and three anchor nodes for providing better coverage of the area of deployment. The best case conditions are the 50 nodes in each cluster with two anchor nodes and some best possible combination of sensor nodes with manageable clusters. With the 50 number of sensor nodes in each cluster there is a possibility of getting the anchor nodes dead early because of the communication overhead. So one anchor node is added to balance this communication overhead and to prolong the lifetime of the network. Figures 8 and 9 show the cluster formation with two anchor nodes and locating the sensor nodes.

Fig. 8
figure 8

Localization in cluster1 (50 node in a cluster)

Fig. 9
figure 9

Localization in cluster2 (50 node in a cluster)

Figure 10a–c show the cluster formation with three anchor nodes and locating the sensor nodes. Here, the cluster1 consist of 37 sensor nodes, cluster2 consist of 37 sensor nodes and cluster3 contains 26 sensor nodes, respectively.

Fig. 10
figure 10

Localization in a Cluster1, b Cluster2 and c Cluster3 with 100 sensor nodes and 3 anchor nodes

Likewise, the simulation is carried out with 150 sensor nodes with three anchor nodes. Figure 11a–c shows the localization information about the cluster members in each cluster.

Fig. 11
figure 11

Localization in a Cluster1, b Cluster2 and c Cluster3 with 150 sensor nodes and 3 anchor nodes

The localization error for the respective coordinates is calculated and presented in Figs. 12, 13, 14, 15, 16, 17 and 18. In Figs. 12, 13, 14, 15, 16, 17 and 18, X-axis represent the number of nodes and Y-axis represent the localization error (meter). The localization error is calculated by comparing the predicted coordinates with the actual coordinates. The difference between the actual coordinates and the predicted coordinates is taken as the reference for checking the accuracy of the proposed algorithm. The minimum localization error and the maximum localization error in the coordinate estimation are calculated and considered as the metric for the evaluation of the proposed algorithm as compared to the existing algorithms. The network coverage can be increased by using the clustering approach. The clustering help in providing parallel and distributed environment for performing computation through which the throughput of the overall network can also be increased.

Fig. 12
figure 12

Localization error in X coordinates (50 nodes)

Fig. 13
figure 13

Localization error in Y coordinates (50 nodes)

Fig. 14
figure 14

Localization error in Z coordinates (50 nodes)

Fig. 15
figure 15

Localization error in X coordinates (100 nodes)

Fig. 16
figure 16

Localization error in Y coordinates (100 nodes)

Fig. 17
figure 17

Localization error in Z coordinates (100 nodes)

Fig. 18
figure 18

Localization error in normal nodes position estimation

Two scenarios are considered for the localization error calculation. First scenario consider two anchor node with 50 normal nodes and the other scenario considers three anchor node with 100 anchor nodes.

The localization error with respect to the position estimation for 100 nodes is depicted in Fig. 18. The Euclidean distance is considered as a base to calculate the difference between the actual position and the estimated position which is the localization error. From the simulation results, it is observed that with the communication range of about 25 m, the success rate for localizing the node within the range is 92%. Through the rigorous simulation it is observed that as the number of nodes increases, the accuracy of position estimation increases.

The minimum and maximum localization error comparison is shown in Table 5. The average localization error with respect to distance estimation is also calculated and compared with some existing optimization algorithms which is shown in Table 6.

Table 5 Distance error estimation
Table 6 Average localization error (distance estimation)

Energy Dissipation in the Network

The LEACH model of energy dissipation is used to check the performance of the network as far as the energy efficiency is considered. In LEACH, the distance between the cluster head and the member node is the key for the energy depletion of the sensor node during each communication which the sensor node does with the cluster head.

The energy consumption of a node during signal transmission can be formulated as given by Eq . (9).

$$\begin{aligned} E_{{Tx}} \left( {n,d} \right) =\, & E_{{{\text{T}}x - {\text{elec }}}} \left( n \right) + E_{{{\text{T}}x - {\text{amp}}}} \left( {n,d} \right) \\ =\, & n \times E_{{{\text{elec}}}} + n \times \varepsilon _{{fs}} \times d^{2} ,\;d < do \\ =\, & n \times E_{{{\text{elec}}}} + n \times \varepsilon _{{{\text{mp}}}} \times d^{4} ,\;d > do \\ \end{aligned}$$
(9)

The energy consumption for receiving n bits message is modelled as follows;

$${E}_{\mathrm{R}x}(n)=n\times {E}_{\mathrm{elec}}$$
(10)

The total energy consumption of the node during transmission and receiving of the signal is expressed by Eq. (11).

$${E}_{\mathrm{Total} }\left(n,d\right)= {E}_{Tx}\left(n,d\right)+ {E}_{\mathrm{Rx}}(n)$$
(11)

In the above equations, \({\varepsilon }_{\mathrm{fs}}\) and \({\varepsilon }_{\mathrm{mp}}\) are the free space and multipath fading channel energy parameters; and \(do\) is the threshold value. \({E}_{\mathrm{elec}}\) is the emission/reception energy and \(n\) is the length of message in bits.

The average energy of the network in each round can be calculated by using Eq. (12).

$${E}_{\mathrm{Avg}-\mathrm{Round}}=\frac{\sum_{i=1}^{N}\mathrm{node}\left(\mathrm{i}\right).\mathrm{energy}}{N}$$
(12)

The average consumption of energy of network is formulated as follows;

$${E}_{\mathrm{Avg}-\mathrm{Network}}= \frac{\sum_{i=1}^{R}{E}_{\mathrm{Avg}-\mathrm{Round}}}{R}$$
(13)

Different scenarios are considered for the experimentation. The average energy dissipation in each cluster is shown separately in Fig. 19a and b while the average energy dissipation of the complete network is shown in Fig. 20. Likewise the average energy dissipation in different scenarios with different number of clusters and network are shown in Figs. 21, 22, 23, 24, 25, 26, 27 and 28. The average energy dissipation varies with varying numbers of nodes in the network as well as with the cluster count which is also depicted in Table 7. The lifetime of WSN depends on the energy dissipation in the network, moreover, lifetime of WSN can be increased by using clustering for network management.

  • Case 1: network with 25 sensor nodes.

    Fig. 19
    figure 19

    Energy dissipation in each round of communication—a Cluster1 with 13 Nodes, b Cluster2 with 12. Nodes

    Fig. 20
    figure 20

    Overall energy dissipation in each round of communication in the network (25 Nodes)

  • Case 2: network with 50 sensor nodes.

    Fig. 21
    figure 21

    Energy dissipation in each round of communication a cluster1 with 25 nodes, b cluster2 with 25 nodes

    Fig. 22
    figure 22

    Overall energy dissipation in each round of communication in the network (50 Nodes)

  • Case 3: network with 100 sensor nodes (2 Clusters).

    Fig. 23
    figure 23

    Energy dissipation in each round of communication a Cluster1 with 50 nodes, b Cluster2 with 50 nodes

    Fig. 24
    figure 24

    Overall energy dissipation in each round of communication in the network (100 Nodes)

  • Case 4: network with 100 sensor nodes (3 Clusters).

    Fig. 25
    figure 25

    Energy dissipation in each round of communication a Cluster1 with 37 nodes, b Cluster2 with 37 Nodes, c Cluster3 with 26 Nodes

    Fig. 26
    figure 26

    Overall energy dissipation in each round of communication in the network (100 Nodes)

  • Case 5: network with 150 (3 clusters).

    Fig. 27
    figure 27

    Energy dissipation in each round of communication a Cluster1 with 59 nodes, b Cluster2 with 40 nodes, c Cluster3 with 51 nodes

    Fig. 28
    figure 28

    Overall energy dissipation in each round of communication in the network (150 Nodes)

Table 7 Summary of energy dissipation in various cases

Conclusion

Localization in WSN is still a complex problem to find the accurate solution. Most of the localization algorithms are proposed for 2D localization of the sensor node. In many real time applications, the 3D location identification of the sensor node is required. In this paper, the cluster-based 3D localization algorithm is proposed for WSN. The nearest neighbor approach is utilized for forming the clusters with RSSI information collection. The anchor node itself is acting as the cluster head. The cluster-based 3D localization is not yet explored much for finding the location of the sensor node in WSN. This paper identified some insight of the work done for finding the location in 3D environment. The cluster-based localization algorithm is more efficient as far as the computational complexity of the algorithm is concerned. The clusters provide distributed and parallel processing so as to use the resources efficiently. The distance between the cluster head and the member node has a great impact on prolonging the lifetime of the sensor network. Cluster formation makes this possible by creating the local partitions and provides independent processing at each cluster reducing the burden of base station. The cluster formation provides an alternate way of communication through cluster head. Thus, the lifetime of the network can be increased by using clustering techniques which is proved through experimentation. It is also observed from the simulation results that the proposed clustering based localization method using the combination of RSSI and AoA perform better as compared to some optimization algorithms such as PSO, BBO and FA in average localization error estimation. During the experimentation, a 3D localization using single anchor node is performed which also reduces the cost of communication and computation in the network. Moreover, static sensor node and the cluster head is considered which can be extended for mobile sensor and cluster head node. The use of mobile anchor node may provide better network coverage for location estimation. The localization technique can also be used for efficient routing and security in WSN. The localization technique can be utilized for intrusion detection in WSNs.