# Three-Dimensional Localization Algorithm of WSN Nodes Based on RSSI-TOA and Single Mobile Anchor Node

Authors: Lieping Zhang; Zhenyu Yang; Shenglan Zhang; Huanhuan Yang
Journal: Journal of Electrical and Computer Engineering
 (2019)

---

## Abstract

Aimed at the shortcomings of low localization accuracy of the fixed multianchor method, a three-dimensional localization algorithm for wireless sensor network nodes is proposed in this paper, which combines received signal strength indicator (RSSI) and time of arrival (TOA) ranging information and single mobile anchor node. A mobile anchor node was introduced in the proposed three-dimensional localization algorithm for wireless sensor networks firstly, and the mobile anchor node moves according to the Gauss–Markov three-dimensional mobility model. Then, based on the idea of using RSSI ranging in the near end and TOA ranging in the far end, a ranging method combining RSSI and TOA ranging information is proposed to obtain the precise distance between the anchor node and the unknown node. Finally, the maximum-likelihood estimation method is used to estimate the position of unknown nodes based on the obtained ranging values. The MATLAB simulation results show that the proposed algorithm had a higher localization accuracy and lower localization energy consumption compared with the traditional RSSI localization method or TOA localization method.


---

## Body

## 1. Introduction

Wireless sensor network (WSN) is a distributed sensor network consisting of a large number of inexpensive microsensor nodes deployed in the monitoring area to form a multihop and self-organizing network system through wireless communication [1]. One of the basic functions of the sensor network is to get the location information of event occurrence or the message node. However, unknown nodes randomly distributed in the monitoring area cannot locate themselves in advance, so the nodes are necessary to be located.WSN node localization method can be classified into the range-based localization method and range-free localization method according to whether the distance measurement is needed in the localization process [2]. The former needs to estimate the distance between the unknown node and the anchor node when estimating the location of unknown node. And the latter estimates the location of unknown node by the connectivity of the whole network. Therefore, the accuracy of the range-based localization method is better than that of the range-free localization method. Ranging strategies commonly used in the range-based localization method are angle of arrival (AOA), time of arrival (TOA), and received signal strength indicator (RSSI) [3]. In practical applications, fusion of multiple measurement methods is one of the effective ways to improve the localization effect. Han et al. [4] proposed a novel indoor positioning algorithm based on the received signal strength indication and pedestrian dead reckoning in order to enhance the accuracy and reliability of our proposed probabilistic position selection algorithm in mixed line-of-sight (LOS) and non-line-of-sight (NLOS) environments. Angelo and Fascista [5] used the statistical characterization of the joint maximum-likelihood estimator to estimate the performance of hybrid RSSI and TOA ranging and proposed a novel closed-form estimator based on an ad hoc relaxation of the likelihood function. Tomic et al. [6] proposed a target location method by utilizing RSSI and TOA measurements in the adverse NLOS environment.According to whether the anchor node moves or not, it can be divided into static anchor node localization method and dynamic anchor node localization method [7]. Static anchor node localization requires a certain node density to meet connectivity requirements, so more anchor nodes need to be deployed. The use of dynamic anchor node localization can greatly reduce the number of anchor nodes and can also improve the localization effect. In order to reduce the number of static anchor nodes, reduce the operation cost of the whole network, and improve the localization effect, the localization algorithm based on dynamic anchor nodes has obvious advantages [8]. Karim et al. [9] proposed a range-free, energy-efficient, localization technique based on mobile anchor nodes for the large-scale machine-to-machine environment. Zhao et al. [10] proposed an RSSI-based localization algorithm, which used the RSSI values received by a sensor node from mobile anchor node to estimate the position of the sensor node. Singh et al. [11] proposed an idea of localizing target nodes with moving single anchor node using computational intelligence-based application of particle swarm optimization and H-best particle swarm optimization.In order to improve the ranging accuracy of the node and reduce the localization error of the WSN three-dimensional node, a three-dimensional localization method of WSN nodes was proposed based on RSSI-TOA and single mobile anchor node through combining the single mobile anchor node strategy and the integrated RSSI-TOA localization method. And the effectiveness of the method was verified through simulation experiments.


## 2. Three-Dimensional Mobile Strategy of Mobile Anchor Node

### 2.1. Traditional Gauss–Markov Mobility Model

The basic principle of localization algorithm based on mobile anchor node is to introduce a mobile anchor node in the WSN monitoring area and let it move according to the previously specified model. In the process of moving, the mobile anchor node broadcasts information such as its position information periodically and marks the position in the broadcast, which can make full use of the mobility of the mobile anchor node and form multiple markers. These markers can be regarded as virtual anchor nodes, and their functions are no different from fixed anchor nodes. They can also be used to locate unknown nodes, thus reducing the number of fixed anchor nodes required by WSN localization [12].In the localization algorithm of the mobile anchor node, its mobility will have a great impact on the localization effect and localization energy consumption. Random waypoint mobility model, SCAN, DOUBLE SCAN, and HILBERT mobility models, and Gauss–Markov mobility model are common anchor node movement models [13]. Among them, Gauss–Markov mobility model is a more realistic mobility model, which has the characteristics of good flexibility, high coverage, and strong stability and can cover most of the monitoring areas of WSN [14]. It can avoid the situation of small coverage probability, large blank area, and sudden change of moving trajectory in edge zone. In the Gauss–Markov mobility model, the moving speed of the mobile anchor node is a time-dependent Gauss–Markov process. Initial velocity and direction are given to the mobile anchor node in the Gauss–Markov mobility model. In a fixed time period T, the nodes are moving at a uniform speed according to the moving speed. After a fixed time period T, the current node’s moving speed and direction are updated. The updated equations are as follows [15]:(1)vt+1=avt+1−av¯+1−a2vn,(2)θt+1=aθt+1−aθ¯+1−a2θn,where vt and θt, respectively, represent the moving speed and direction of the anchor node at t time. a is a random adjustment parameter and has 0≤a≤1. When a=0, the mobile anchor node is a complete random motion. When a=1, the mobile anchor node becomes a linear motion. v¯ and θ¯, respectively, represent the moving speed and the average of the direction angles of the mobile anchor nodes, and both are constants. As random variables, both vn and θn obey the Gaussian distribution.In the Gauss–Markov mobility model, the position of the node at the next time periodT is determined by the position, velocity, and direction of the previous cycle. The position coordinates (xt+1,yt+1) at t+1 time period T can be obtained by the following equation:(3)xt+1=xt+vt⋅t⋅cosθt,(4)yt+1=yt+vt⋅t⋅sinθt.


### 2.2. Gauss–Markov Three-Dimensional Mobility Model

Extend the traditional Gauss–Markov mobility model to the three-dimensional environment. When the anchor node moves in three-dimensional space, there are two anglesθt and βt between the moving direction of velocity and the coordinate axis.The angles between the velocity and direction of the mobility model and the coordinate axis are shown in the following equations:(5)vt+1=avt+1−av¯+1−a2vn,(6)θt+1=aθt+1−aθ¯+1−a2θn,(7)βt+1=aβt+1−aβ¯+1−a2βn.The position of the extended Gauss–Markov mobility model at the next time periodT is determined by the position, velocity, and direction angle of the previous cycle. According to the moving speed in the moving trajectory, the angle of the moving direction, and the position of the previous period, the coordinate positions xt+1,yt+1,zt+1 of the next moment can be obtained by equations (8)–(10), and the coordinate position of the mobile anchor node at each moment is the position of the virtual anchor node:(8)xt+1=xt+vt⋅cosθt+1cosβt+1⋅t,(9)xt+1=xt+vt⋅cosθt+1sinβt+1⋅t,(10)zt+1=zt+vt⋅cosβt+1sinθt+1⋅t.In the experiment, the WSN location area is regarded as a cube-shaped monitoring area ofl length, width, and height, respectively. The mobile anchor node starts from the randomly occurring starting point coordinates xt,yt,zt and moves along the mobility model trajectory with the velocity vt and communication radius R and periodically broadcasts its own coordinate information and ID location information with T as the time interval. After completing a broadcast, the next movement follows. At this time, the mobile anchor node moves at a speed vt+1, and the moving direction of the speed and the two axes existing in the coordinate axis are θt+1 and βt+1. The movement is repeated continuously, so that it can be enabled to cover the entire network. When the mobile anchor node moves to the edge of the network, the mobile anchor node changes its speed and direction and starts a new movement. In the process of moving, when the anchor node realizes the localization of the last unknown node to be measured, the mobile anchor node does not move anymore and stops working. A three-dimensional moving trajectory of a Gauss–Markov mobility model is shown in Figure 1.Figure 1
Three-dimensional moving trajectory of the Gauss–Markov mobility model.


## 2.1. Traditional Gauss–Markov Mobility Model

The basic principle of localization algorithm based on mobile anchor node is to introduce a mobile anchor node in the WSN monitoring area and let it move according to the previously specified model. In the process of moving, the mobile anchor node broadcasts information such as its position information periodically and marks the position in the broadcast, which can make full use of the mobility of the mobile anchor node and form multiple markers. These markers can be regarded as virtual anchor nodes, and their functions are no different from fixed anchor nodes. They can also be used to locate unknown nodes, thus reducing the number of fixed anchor nodes required by WSN localization [12].In the localization algorithm of the mobile anchor node, its mobility will have a great impact on the localization effect and localization energy consumption. Random waypoint mobility model, SCAN, DOUBLE SCAN, and HILBERT mobility models, and Gauss–Markov mobility model are common anchor node movement models [13]. Among them, Gauss–Markov mobility model is a more realistic mobility model, which has the characteristics of good flexibility, high coverage, and strong stability and can cover most of the monitoring areas of WSN [14]. It can avoid the situation of small coverage probability, large blank area, and sudden change of moving trajectory in edge zone. In the Gauss–Markov mobility model, the moving speed of the mobile anchor node is a time-dependent Gauss–Markov process. Initial velocity and direction are given to the mobile anchor node in the Gauss–Markov mobility model. In a fixed time period T, the nodes are moving at a uniform speed according to the moving speed. After a fixed time period T, the current node’s moving speed and direction are updated. The updated equations are as follows [15]:(1)vt+1=avt+1−av¯+1−a2vn,(2)θt+1=aθt+1−aθ¯+1−a2θn,where vt and θt, respectively, represent the moving speed and direction of the anchor node at t time. a is a random adjustment parameter and has 0≤a≤1. When a=0, the mobile anchor node is a complete random motion. When a=1, the mobile anchor node becomes a linear motion. v¯ and θ¯, respectively, represent the moving speed and the average of the direction angles of the mobile anchor nodes, and both are constants. As random variables, both vn and θn obey the Gaussian distribution.In the Gauss–Markov mobility model, the position of the node at the next time periodT is determined by the position, velocity, and direction of the previous cycle. The position coordinates (xt+1,yt+1) at t+1 time period T can be obtained by the following equation:(3)xt+1=xt+vt⋅t⋅cosθt,(4)yt+1=yt+vt⋅t⋅sinθt.


## 2.2. Gauss–Markov Three-Dimensional Mobility Model

Extend the traditional Gauss–Markov mobility model to the three-dimensional environment. When the anchor node moves in three-dimensional space, there are two anglesθt and βt between the moving direction of velocity and the coordinate axis.The angles between the velocity and direction of the mobility model and the coordinate axis are shown in the following equations:(5)vt+1=avt+1−av¯+1−a2vn,(6)θt+1=aθt+1−aθ¯+1−a2θn,(7)βt+1=aβt+1−aβ¯+1−a2βn.The position of the extended Gauss–Markov mobility model at the next time periodT is determined by the position, velocity, and direction angle of the previous cycle. According to the moving speed in the moving trajectory, the angle of the moving direction, and the position of the previous period, the coordinate positions xt+1,yt+1,zt+1 of the next moment can be obtained by equations (8)–(10), and the coordinate position of the mobile anchor node at each moment is the position of the virtual anchor node:(8)xt+1=xt+vt⋅cosθt+1cosβt+1⋅t,(9)xt+1=xt+vt⋅cosθt+1sinβt+1⋅t,(10)zt+1=zt+vt⋅cosβt+1sinθt+1⋅t.In the experiment, the WSN location area is regarded as a cube-shaped monitoring area ofl length, width, and height, respectively. The mobile anchor node starts from the randomly occurring starting point coordinates xt,yt,zt and moves along the mobility model trajectory with the velocity vt and communication radius R and periodically broadcasts its own coordinate information and ID location information with T as the time interval. After completing a broadcast, the next movement follows. At this time, the mobile anchor node moves at a speed vt+1, and the moving direction of the speed and the two axes existing in the coordinate axis are θt+1 and βt+1. The movement is repeated continuously, so that it can be enabled to cover the entire network. When the mobile anchor node moves to the edge of the network, the mobile anchor node changes its speed and direction and starts a new movement. In the process of moving, when the anchor node realizes the localization of the last unknown node to be measured, the mobile anchor node does not move anymore and stops working. A three-dimensional moving trajectory of a Gauss–Markov mobility model is shown in Figure 1.Figure 1
Three-dimensional moving trajectory of the Gauss–Markov mobility model.


## 3. Ranging Principle of Fusion RSSI Method and TOA Method

### 3.1. RSSI Ranging Principle

RSSI ranging method calculates the power loss in the process of signal propagation through the signal power received by sensor nodes and then converts the power loss into distance value by using theoretical and empirical models. But for the relationship between power loss and distance, different signal transmission models have different results. In practical application, the log-normal model is the most widely used signal transmission models [16]. The relationship between signal strength and distance of the model is shown in the following equation:(11)P=P0−10nlgdd0+Xσ,where d and d0 are the distances of the receiving node and the reference node to the signal transmitter, P0 and n are the quantities of the channel characteristics, P0 is the signal strength of the reference point, and n represents the path loss index, which varies with the environment. Xσ is a random noise obeying a log-normal distribution with a mean of zero and a standard deviation of σ. Its main function is to describe the influence of uncertain factors such as signal reflection and noise interference on the received signal strength. It can be expressed by means and variances of multiple signal measurements and its distribution density function can be expressed as follows:(12)fx=12πσex−μ2/−2σ2,where the specific expressions of μ and σ are as follows:(13)μ=1k∑i=1kRSSIi,(14)σ=1k−1∑i=1kRSSIi−μ2,where RSSIi represents the signal strength value of the ith signal and k represents the total number of measurements. The empirical value of Xσ can be obtained by setting up reasonable experiments.RSSI ranging method will cause a large measurement error due to fading at a long distance, which means that when the measurement distance increases, the ranging error will increase significantly, resulting in inaccurate localization.


### 3.2. TOA Ranging Principle

TOA ranging method estimates the distance between two nodes by measuring the transmission time of the wireless signal. The ranging equation is shown as follows:(15)d=c⋅t,where d and t are the distance values and propagation times between the signal transmitter and the receiver, respectively, and c is the speed of transmission signal.In the localization process, the TOA ranging localization algorithm needs the nodes of the transmitter and the receiver to transmit signals at the same time, which makes the TOA ranging method greatly limited in practical applications. The IEEE 802.15.4a protocol provides the symmetric double-sided two-way ranging (SDS-TWR) method for TOA ranging [17], which can offset the impact of the delay time due to the inability to meet time synchronization on the ranging results. The SDS-TWR method uses a symmetrical method to measure TOA in two directions. The specific implementation process is as follows: (1) First TWR, node A serves as a signal transmitter and node B serves as a signal receiver. (2) Second TWR, node B serves as a signal transmitter and node A serves as a signal receiver. The measurement process can be described as shown in Figure 2.Figure 2
Measuring process of the TOA ranging method.In this way, a standard timetTOA, a standard time, that is, the final time measurement result, can be obtained, as shown as follows:(16)tTOA=troundA−treplyB+troundB−treplyA4.When the signal transmitter is close to the receiver, the TOA ranging algorithm measurement error will have a great influence on the accuracy of the TOA ranging localization algorithm, resulting in an excessive deviation between the measured distance value and the actual distance value.


### 3.3. Ranging Implementation of Fusion RSSI and TOA Method

Through the analysis of the RSSI and TOA ranging principle, we know that the path loss values of the RSSI ranging method vary greatly due to various factors in different environments [18]. When measuring at close range, the signal transmission basically obeys the log normal loss law used in the RSSI ranging technology, and the ranging accuracy is high. When the unknown node is far away from the anchor node, the transmission power of the signal is attenuated faster, and ranging error will be increased. On the other hand, the TOA ranging method still needs a higher precision time measuring device in the calculation process, and there is a measurement error in the close range measurement, which will cause a large deviation in the node localization process. But when it is measured at a long range, it has a high precision [19]. Aiming at the advantages and disadvantages of RSSI and TOA ranging methods, RSSI ranging method is proposed for the proximal end and TOA ranging method for the distal end in our paper, which is called RSSI-TOA ranging method. In the RSSI-TOA ranging method, the distance threshold using RSSI ranging or TOA ranging is selected by the experimental method, which is described in Section 5.4. The specific ranging process is shown in Figure 3.Figure 3
Ranging process with the RSSI and TOA method.


## 3.1. RSSI Ranging Principle

RSSI ranging method calculates the power loss in the process of signal propagation through the signal power received by sensor nodes and then converts the power loss into distance value by using theoretical and empirical models. But for the relationship between power loss and distance, different signal transmission models have different results. In practical application, the log-normal model is the most widely used signal transmission models [16]. The relationship between signal strength and distance of the model is shown in the following equation:(11)P=P0−10nlgdd0+Xσ,where d and d0 are the distances of the receiving node and the reference node to the signal transmitter, P0 and n are the quantities of the channel characteristics, P0 is the signal strength of the reference point, and n represents the path loss index, which varies with the environment. Xσ is a random noise obeying a log-normal distribution with a mean of zero and a standard deviation of σ. Its main function is to describe the influence of uncertain factors such as signal reflection and noise interference on the received signal strength. It can be expressed by means and variances of multiple signal measurements and its distribution density function can be expressed as follows:(12)fx=12πσex−μ2/−2σ2,where the specific expressions of μ and σ are as follows:(13)μ=1k∑i=1kRSSIi,(14)σ=1k−1∑i=1kRSSIi−μ2,where RSSIi represents the signal strength value of the ith signal and k represents the total number of measurements. The empirical value of Xσ can be obtained by setting up reasonable experiments.RSSI ranging method will cause a large measurement error due to fading at a long distance, which means that when the measurement distance increases, the ranging error will increase significantly, resulting in inaccurate localization.


## 3.2. TOA Ranging Principle

TOA ranging method estimates the distance between two nodes by measuring the transmission time of the wireless signal. The ranging equation is shown as follows:(15)d=c⋅t,where d and t are the distance values and propagation times between the signal transmitter and the receiver, respectively, and c is the speed of transmission signal.In the localization process, the TOA ranging localization algorithm needs the nodes of the transmitter and the receiver to transmit signals at the same time, which makes the TOA ranging method greatly limited in practical applications. The IEEE 802.15.4a protocol provides the symmetric double-sided two-way ranging (SDS-TWR) method for TOA ranging [17], which can offset the impact of the delay time due to the inability to meet time synchronization on the ranging results. The SDS-TWR method uses a symmetrical method to measure TOA in two directions. The specific implementation process is as follows: (1) First TWR, node A serves as a signal transmitter and node B serves as a signal receiver. (2) Second TWR, node B serves as a signal transmitter and node A serves as a signal receiver. The measurement process can be described as shown in Figure 2.Figure 2
Measuring process of the TOA ranging method.In this way, a standard timetTOA, a standard time, that is, the final time measurement result, can be obtained, as shown as follows:(16)tTOA=troundA−treplyB+troundB−treplyA4.When the signal transmitter is close to the receiver, the TOA ranging algorithm measurement error will have a great influence on the accuracy of the TOA ranging localization algorithm, resulting in an excessive deviation between the measured distance value and the actual distance value.


## 3.3. Ranging Implementation of Fusion RSSI and TOA Method

Through the analysis of the RSSI and TOA ranging principle, we know that the path loss values of the RSSI ranging method vary greatly due to various factors in different environments [18]. When measuring at close range, the signal transmission basically obeys the log normal loss law used in the RSSI ranging technology, and the ranging accuracy is high. When the unknown node is far away from the anchor node, the transmission power of the signal is attenuated faster, and ranging error will be increased. On the other hand, the TOA ranging method still needs a higher precision time measuring device in the calculation process, and there is a measurement error in the close range measurement, which will cause a large deviation in the node localization process. But when it is measured at a long range, it has a high precision [19]. Aiming at the advantages and disadvantages of RSSI and TOA ranging methods, RSSI ranging method is proposed for the proximal end and TOA ranging method for the distal end in our paper, which is called RSSI-TOA ranging method. In the RSSI-TOA ranging method, the distance threshold using RSSI ranging or TOA ranging is selected by the experimental method, which is described in Section 5.4. The specific ranging process is shown in Figure 3.Figure 3
Ranging process with the RSSI and TOA method.


## 4. Three-Dimensional Location Method for WSN Nodes

On the basis of synthesizing the advantages and disadvantages of RSSI and TOA ranging methods, the mobile anchor node is introduced, and a three-dimensional localization algorithm for WSN nodes is proposed, which combines RSSI and TOA ranging methods. The maximum-likelihood estimation method is used to calculate the position of WSN nodes. The implementation steps are as follows:(1)
Data information acquisitionN wireless sensor nodes Si(i=1,2,...,N) are randomly deployed in the three-dimensional WSN monitoring area Q. Among these sensor nodes, there are L anchor nodes Bi(i=1,2,...,L) N−L unknown nodes and virtual anchor nodes Bj(j=1,2,...,L) periodically broadcast by the mobile anchor nodes. It is stipulated that all sensor nodes in the monitoring area have the same communication radius R.(2)
RSSI ranging methodRSSI ranging method is used to measure the distance of the node, and the logarithmic normal wireless signal transmission model is used to obtain the attenuation value of the signal. Then, its attenuation value is transformed into the corresponding distance valuedi according to equation (11). In the WSN monitoring area, when the distance between the anchor node and the unknown node is less than the prescribed threshold in the communication range of the unknown node, the distance value is recorded.(3)
TOA ranging methodIn the WSN monitoring area, when the distance between the anchor node and the unknown node is greater than the prescribed threshold and less than the communication radiustTOA, the measurement distance dj from the anchor node to the unknown node can be obtained according to the time obtained by equation (16), and the distance value is recorded.(4)
Estimation of coordinate positionAt the node localization stage, the coordinate values of unknown nodes are obtained by maximum-likelihood estimation after the measured distance valuedi(or dj) between m(m≥4) unknown nodes and anchor nodes (or virtual anchor nodes) is obtained from the three-dimensional monitoring area of WSN.


## 5. Experimental Simulation and Analysis

### 5.1. Setting of Operating Environment and Parameters

Localization algorithm is simulated in the MATLAB simulation environment. The simulation space is the WSN three-dimensional space of200m×200m×200m. A mobile anchor node is introduced in the proposed method. The mobile anchor node moves periodically in the WSN monitoring area according to the Gauss–Markov three-dimensional mobility model and broadcasts its own data and coordinate position information every a period T to form multiple virtual anchor nodes. In the initialization process, 200 sensor nodes are randomly generated in three-dimensional space, of which the number of unknown nodes to be located is 180 and the number of fixed anchor nodes is 20. If the location of the node is deployed in an obstructed area, it will be redeployed. Once deployed, the position of all nodes cannot be changed. The communication radius of all nodes is set to 40 m, the transmission speed c of the signals is set to light speed, the reference node distance d0 is 1 m, P0 is set to −30, the path loss index n is 2, the noise Xσ is 3, and the mesh spacing t of WSN is 25. In order to be closer to the actual environment, an obstacle area is set up in this experiment, which is a cube of size 20m×20m×20m. Fixed anchor nodes, unknown nodes to be localization, and obstacle areas of the simulation experiment are shown in Figure 4. The green and red points represent unknown nodes and fixed anchor nodes, respectively, in Figure 4. All experimental results are performed on 100 experimental simulations, and then the average of all experimental results is used as the final result.Figure 4
Distribution of node initial position.


### 5.2. Influence of Anchor Density on Localization Error with or without Mobile Anchor Node

In the process of WSN node localization, the higher the density of the anchor nodes in the network, the easier it is to cover the entire WSN monitoring area, which can effectively reduce the localization error. However, the density of the anchor node increases, which generates a lot of redundant information, also increases the various burdens of the WSN. Therefore, it is not that the higher the density of the anchor nodes, the better the localization effect. As shown in Figure5, the average localization errors of RSSI method, TOA method, and RSSI-TOA method under different anchor node densities are discussed in the case of mobile anchor nodes. It can be seen from Figure 5 that when there is a mobile anchor node, the average localization errors decrease with the increase of the density of the fixed anchor node. When the density of the fixed anchor nodes is 10%, three algorithms reach a relatively ideal level. Even if the fixed anchor node density is increased, the localization errors of three algorithms no longer change significantly. It can also be seen that under the same conditions, the average localization error of the RSSI-TOA method is the smallest.Figure 5
Relationship between localization error and anchor node density with mobile anchor nodes.In Figure6, there are the average localization errors of the three algorithms under different anchor node densities without a mobile anchor node. It can be seen from Figure 6 that when the anchor node is not moved, the density of the fixed anchor node is increased, and the average localization errors of three methods tend to decrease continuously, and the average localization error of the RSSI-TOA method is the smallest. When the density of the fixed anchor node reaches 25%, the density of the fixed anchor node is increased, and the localization error does not change much. At the same time, when the density of the fixed anchor node reaches 30%, the average localization errors of three localization algorithms perform little different from the average localization error of the mobile anchor node with a fixed anchor node ratio of about 10%. It can be concluded that by introducing a mobile anchor node in advance and adopting RSSI-TOA method, not only the cost of networking and localization and the power consumption can be reduced, but also the error of node localization can be reduced in the same time, and the performance of node localization can be improved.Figure 6
Relationship between localization error and anchor node density without mobile anchor node.


### 5.3. Influence of Communication Radius on Localization Error

In the WSN monitoring area, when the communication radius of the node is large, more anchor nodes will be captured, and the corresponding node localization error will be reduced. Figure7 shows the average localization errors of three localization algorithms under different communication radius when a mobile anchor node is introduced and the density of the fixed anchor node is 10%. It can be seen from Figure 7 that when the node communication radius is increased from 10 m to 40 m, the average localization errors of three methods are reduced, but the localization error of the RSSI-TOA method is the smallest.Figure 7
Relationship between communication radius and average localization error.


### 5.4. Influence of Measurement Position on Localization Error

Localization error is affected by the measurement position of the nodes. With the increase of measuring position distance, the localization error will increase accordingly. Figure8 shows the relationship between the measuring position and the average localization error when a mobile anchor node is introduced and the density of the fixed anchor node is 10%. It can be seen from Figure 8 that the localization error of the RSSI method is smaller than that of the TOA method in the range of 0–12 m. With the increase of measurement distance, the localization error of the RSSI method is larger than that of the TOA method when the measurement distance is more than 12 m. The RSSI-TOA method proposed in this paper has the smallest average localization error under the same conditions.Figure 8
Relationship between localization error and measurement position.


### 5.5. Localization Error of Unknown Nodes

Figure9 shows the localization errors of 180 unknown nodes obtained by the three methods. It can be seen from Figure 9 that the node localization errors of RSSI method and TOA method fluctuate greatly, and there are many nodes having large errors. However, the curve fluctuation of the node localization error of the RSSI-TOA method proposed in this paper is relatively small, and the localization error is the smallest among the three methods. It shows that in the three-dimensional environment, the RSSI-TOA method proposed in this paper is the least affected by the external environment and has the highest localization accuracy and the best localization stability.Figure 9
Localization error of each node in three localization algorithms.


## 5.1. Setting of Operating Environment and Parameters

Localization algorithm is simulated in the MATLAB simulation environment. The simulation space is the WSN three-dimensional space of200m×200m×200m. A mobile anchor node is introduced in the proposed method. The mobile anchor node moves periodically in the WSN monitoring area according to the Gauss–Markov three-dimensional mobility model and broadcasts its own data and coordinate position information every a period T to form multiple virtual anchor nodes. In the initialization process, 200 sensor nodes are randomly generated in three-dimensional space, of which the number of unknown nodes to be located is 180 and the number of fixed anchor nodes is 20. If the location of the node is deployed in an obstructed area, it will be redeployed. Once deployed, the position of all nodes cannot be changed. The communication radius of all nodes is set to 40 m, the transmission speed c of the signals is set to light speed, the reference node distance d0 is 1 m, P0 is set to −30, the path loss index n is 2, the noise Xσ is 3, and the mesh spacing t of WSN is 25. In order to be closer to the actual environment, an obstacle area is set up in this experiment, which is a cube of size 20m×20m×20m. Fixed anchor nodes, unknown nodes to be localization, and obstacle areas of the simulation experiment are shown in Figure 4. The green and red points represent unknown nodes and fixed anchor nodes, respectively, in Figure 4. All experimental results are performed on 100 experimental simulations, and then the average of all experimental results is used as the final result.Figure 4
Distribution of node initial position.


## 5.2. Influence of Anchor Density on Localization Error with or without Mobile Anchor Node

In the process of WSN node localization, the higher the density of the anchor nodes in the network, the easier it is to cover the entire WSN monitoring area, which can effectively reduce the localization error. However, the density of the anchor node increases, which generates a lot of redundant information, also increases the various burdens of the WSN. Therefore, it is not that the higher the density of the anchor nodes, the better the localization effect. As shown in Figure5, the average localization errors of RSSI method, TOA method, and RSSI-TOA method under different anchor node densities are discussed in the case of mobile anchor nodes. It can be seen from Figure 5 that when there is a mobile anchor node, the average localization errors decrease with the increase of the density of the fixed anchor node. When the density of the fixed anchor nodes is 10%, three algorithms reach a relatively ideal level. Even if the fixed anchor node density is increased, the localization errors of three algorithms no longer change significantly. It can also be seen that under the same conditions, the average localization error of the RSSI-TOA method is the smallest.Figure 5
Relationship between localization error and anchor node density with mobile anchor nodes.In Figure6, there are the average localization errors of the three algorithms under different anchor node densities without a mobile anchor node. It can be seen from Figure 6 that when the anchor node is not moved, the density of the fixed anchor node is increased, and the average localization errors of three methods tend to decrease continuously, and the average localization error of the RSSI-TOA method is the smallest. When the density of the fixed anchor node reaches 25%, the density of the fixed anchor node is increased, and the localization error does not change much. At the same time, when the density of the fixed anchor node reaches 30%, the average localization errors of three localization algorithms perform little different from the average localization error of the mobile anchor node with a fixed anchor node ratio of about 10%. It can be concluded that by introducing a mobile anchor node in advance and adopting RSSI-TOA method, not only the cost of networking and localization and the power consumption can be reduced, but also the error of node localization can be reduced in the same time, and the performance of node localization can be improved.Figure 6
Relationship between localization error and anchor node density without mobile anchor node.


## 5.3. Influence of Communication Radius on Localization Error

In the WSN monitoring area, when the communication radius of the node is large, more anchor nodes will be captured, and the corresponding node localization error will be reduced. Figure7 shows the average localization errors of three localization algorithms under different communication radius when a mobile anchor node is introduced and the density of the fixed anchor node is 10%. It can be seen from Figure 7 that when the node communication radius is increased from 10 m to 40 m, the average localization errors of three methods are reduced, but the localization error of the RSSI-TOA method is the smallest.Figure 7
Relationship between communication radius and average localization error.


## 5.4. Influence of Measurement Position on Localization Error

Localization error is affected by the measurement position of the nodes. With the increase of measuring position distance, the localization error will increase accordingly. Figure8 shows the relationship between the measuring position and the average localization error when a mobile anchor node is introduced and the density of the fixed anchor node is 10%. It can be seen from Figure 8 that the localization error of the RSSI method is smaller than that of the TOA method in the range of 0–12 m. With the increase of measurement distance, the localization error of the RSSI method is larger than that of the TOA method when the measurement distance is more than 12 m. The RSSI-TOA method proposed in this paper has the smallest average localization error under the same conditions.Figure 8
Relationship between localization error and measurement position.


## 5.5. Localization Error of Unknown Nodes

Figure9 shows the localization errors of 180 unknown nodes obtained by the three methods. It can be seen from Figure 9 that the node localization errors of RSSI method and TOA method fluctuate greatly, and there are many nodes having large errors. However, the curve fluctuation of the node localization error of the RSSI-TOA method proposed in this paper is relatively small, and the localization error is the smallest among the three methods. It shows that in the three-dimensional environment, the RSSI-TOA method proposed in this paper is the least affected by the external environment and has the highest localization accuracy and the best localization stability.Figure 9
Localization error of each node in three localization algorithms.


## 6. Conclusion

In this work, a ranging method is proposed that combines RSSI and TOA ranging information in this paper. The proposed ranging method reduces the ranging errors by using RSSI or TOA ranging step by step in the ranging stage. In order to further improve the accuracy of node localization, a mobile anchor node is introduced. The anchor node is moved in the three-dimensional environment by Gauss–Markov to form virtual anchor nodes. Then, the maximum-likelihood estimation method is used to realize the three-dimensional localization of WSN nodes. The simulation results verified the effectiveness of the proposed RSSI-TOA method and achieved better localization results. Because the RSSI ranging value and the TOA ranging value are greatly affected by WSN node devices and external environment, the difference of the different node devices in different application environments at different times will be relatively large. Research on LSSVR node localization algorithm that combines RSSI and TOA ranging information in different environments will be our future research. At the same time, the static nodes are located in the three-dimensional monitoring area through a mobile anchor node in this paper. The next step is to study the method of localization of the mobile node by multiple mobile anchor nodes.



---

*Source: 4043106-2019-07-28.xml*