Research Article  Open Access
Lu Jian Yin, "A New Distance VectorHop Localization Algorithm Based on HalfMeasure Weighted Centroid", Mobile Information Systems, vol. 2019, Article ID 9892512, 9 pages, 2019. https://doi.org/10.1155/2019/9892512
A New Distance VectorHop Localization Algorithm Based on HalfMeasure Weighted Centroid
Abstract
Considering the defects of the Distance VectorHop (DVHop) localization algorithm making errors and having error accumulation in wireless sensor network (WSN), we proposed a new DVHop localization algorithm based on halfmeasure weighted centroid. This algorithm followed the twodimensional position distribution, designed the minimum communication radius, and formed a reasonable network connectivity firstly. Then, the algorithm corrected the distance between the beacon node and its neighbour node to form a more accurate jump distance so that the shortest path can be optimized. Finally, we theorized the proposed localization algorithm and verified it in simulation experiments, including same communication radius, different communication radii, and different node densities in same communication radius, and have compared the localization error and localization accuracy, respectively, between the proposed algorithm and the DVHop localization algorithm. The experiment’s result shows that the proposed localization algorithm have reduced the localization’s average error and improved the localization’s accuracy.
1. Introduction
As there is rapid development in wireless communication, the rapid development of low energy, low cost, intensive, multifunctional tiny wireless sensor network is promoted. And a large number of wireless sensor nodes are one of the key elements of wireless sensor networks [1, 2]; therefore, research on location technology in wireless sensor networks is one of the key issues in the research of wireless sensor networks, which is of great significance.
The DVHop localization algorithm [3] was first proposed by Dragos Niculescu et al. of Rutgers, USA, which is a distributed localization algorithm based on distance vector routing protocol without ranging [4]. Many scholars and scientific research institutions have carried out indepth research on the DVHop Localization algorithm. In reference [5], in order to reduce the DVHop error, the ideal beacon node spacing is introduced to eliminate the larger error in the average singlehop distance calculated by the beacon node, and the average singlehop distance of the whole network is corrected. Then, the unknown node coordinates calculated by the least squares method are corrected. In reference [6], the weighted average of distance error and estimation distance error is proposed to correct the original average hop distance. The weight of the particle group is improved by using the subsection index and logarithmic decrement weight. In reference [7], for each beacon node, the weight of each beacon node is added to calculate the average hop distance. The main node definition is proposed, the network topology structure will be considered more comprehensively, and the local and global characteristics will be weighed better; in order to calculate the estimated distance of nodes, the improved particle swarm optimization algorithm is used instead of the maximum likelihood estimation method to locate the node coordinates. In reference [3], the range of broadcasting information of beacon nodes is limited by the threshold of the hop number; the average distance of each anchor node is corrected by the average distance error of each beacon node; the unknown node of this round is upgraded to a new anchor node for the next round of positioning. In reference [8], the multicommunication radius method is introduced to refine the hops between nodes. When calculating the average hop distance of unknown nodes, the isolated nodes are eliminated, and the average hop distance obtained by beacon nodes is weighted and normalized to improve the localization accuracy of unknown nodes. In reference [9], the distance between the unknown nodes and the beacon nodes is calculated using different average hop distances. Using the Galactic Swarm Optimization thought of beacon nodes in the network is divided into different species: the particle swarm optimization algorithm is used to estimate the unknown node in each population, which is the optimal location, and the weighted centroid algorithm is used to optimize the suboptimal solution which is set as the coordinates of the unknown node.
All of the above studies give a good research idea for the DVHop localization algorithm. This paper proposes another improvement scheme based on the DVHop algorithm. This algorithm followed the twodimensional position distribution, designed the minimum communication radius, and formed a reasonable network connectivity firstly. Then, the algorithm corrected the distance between the beacon node and its neighbour node to form a more accurate jump distance so that the shortest path can be optimized. Finally, we theorized the proposed localization algorithm and verified it in simulation experiments, including same communication radius, different communication radii, and different node density with same communication radius, and have compared the localization error and localization accuracy, respectively, between the proposed algorithm and the DVHop localization algorithm. The experimental result shows that the proposed localization algorithm have reduced the localization’s average error and improved the localization’s accuracy. Compared with the DVHop algorithm, whose localization accuracy increases from 0.6 to 0.7, other DVHOP is about 0.3; and new DVHop shows a localization accuracy fluctuating stably within 0.1.
2. Analysis of the DVHop Localization Algorithm
The DVHop localization algorithm is a distributed rangefree localization algorithm based on the distance vector routing protocol [5]. The main principle therein is to calculate the distances between beacon nodes and unknown nodes by multiplying the average hop distance in WSNs by the hop count of the beacon nodes. Then, the position information of unknown nodes is obtained through trilateration, triangulation, and multilateration [10], thus realizing localization. For a network topology established by a random arrangement of wireless sensor nodes, the 40 paths from beacon nodes to unknown nodes are possibly not straight. Hence, some errors are likely to exist in the node localization process when using the DVHop algorithm [11]. Moreover, the more numerous the hop counts, the larger the errors (i.e., error accumulation occurs).
2.1. Basic Procedure of the DVHop Algorithm
The localization of nodes using the DVHop [12, 13] algorithm is mainly divided into three steps.
Step 1. Calculating the minimum hop count between beacon nodes and unknown nodes. Beacon nodes broadcast information which shows their positions to neighbouring nodes by using the classical distance vector routing protocol [14]. The information contains , where , , and represent the identifier, the coordinate, and the hop count of beacon nodes , respectively. Moreover, the initial value of is set to zero. The nodes receiving the broadcast information record the localization and hop counts of beacon nodes as vectors, which are then transmitted to neighbouring nodes (the value of hop count is incremented by one). When a node receives the same id group, it is supposed to compare the newly obtained value of with the original value and then select the minimum value to replace and update the original group; otherwise, the newly obtained group is abandoned. The position information and minimum hop count of all beacon nodes are obtained by this communication mode in WSNs.
Step 2. Estimating the average hop distance. The purpose of calculating the average hop distance and minimum hop count first is to estimate the distance between unknown nodes and beacon nodes. After acquiring the localization and the hop count of beacon nodes in the first stage, the average hop distance of whole networks can be computed. The information is then broadcast to the whole network, or all networks. Furthermore, most nodes are required to receive the average hop distance from their nearest beacon nodes. The distances between beacon nodes and unknown nodes can be calculated by multiplying the average hop distance by the hop count. Here, and denote the average hop distance and the hop distance between a beacon node and an unknown node , respectively, as shown in the following formula:The distances between unknown nodes and beacon nodes are calculated using the following formula:where signifies the average hop distance, while Hop is the minimum hop count between unknown nodes and beacon nodes.
As shown in Figure 1, which shows the network topology of the DVHop localization algorithm, the red and the blue circles indicate beacon nodes and unknown nodes, respectively. The distances and hop counts among beacon nodes are known, and A represents an unknown node. According to formula (1), the average hop distance can be calculated as (40 + 75)/(2 + 5) = 16.42 m. In Figure 1, unknown node A receives the average hop distance from beacon node . On this basis, according to formula (2), the distances between the three beacon nodes and the unknown node A are 3 × 16.42 m, 2 × 16.42 m, and 3 × 16.42 m, respectively.
Step 3. Based on plane geometry, the coordinates of unknown nodes can be acquired in the case of knowing the coordinates and distances between three beacon nodes. Suppose that the coordinates of three beacon nodes are , , and , respectively, and the distances between these three beacon nodes and an unknown node D are expressed as , , and , separately, then, the following formula is obtained:Meanwhile, the coordinate of node D can be calculated by using the following formula:In this way, the coordinates of unknown nodes can be computed. For a network topology established by a random arrangement of wireless sensor nodes, the paths from beacon nodes to unknown nodes are possibly not straight. Hence, some errors likely exist in the node localization process when using the DVHop algorithm. Moreover, the more numerous the hop counts, the larger the errors (i.e., error accumulation occurs).
2.2. Error Analysis for the DVHop Algorithm
The DVHop algorithm is based on the shortest path first mechanism. Nodes in WSNs broadcast their localization information and calculate distances to other nodes so that beacon nodes acquire the least hop counts required to reach other nodes and known position information. Meanwhile, the real paths between nodes are regarded as approximately straight lines to calculate the average hop distance, which is applied as the average hop distance of node localization in networks, while unknown nodes are expected to obtain the average hop distance from the nearest beacon nodes with favorable communication conditions to estimate their selflocalization positions. Therefore, in the localization process, various factors can make localization errors exceed the actual demand. These factors include the fact that network nodes are distributed unevenly, the actual hop distances between nodes are far longer than, or less than, the communication radius, and there are no beacon nodes which can be used for communication near unknown nodes. However, the centroid localization algorithm [15] takes the coordinates of a polygon centroid as a reference position and has low requirements for the actual distances between nodes, the communication radius, and the density of beacon nodes. Therefore, the cost of network construction can be reduced by using the algorithm. Hence, the authors proposed a new DVHop localization algorithm based on the halfmeasure weighted centroid [16].
3. HalfMeasure Weighted Centroid Localization Algorithm
3.1. Improving the Algorithm
In computational geometry, the centroid of a polygon can be obtained by calculating the average coordinate of the vertices. Suppose that the position vector of a polygon with edges satisfies the following equation, that is, , then the coordinate of its centroid [17, 18] is expressed as shown below:
Theorem 1. Given the network node G with N nodes, the node density and the node distribution follow the twodimensional Possion point process with density; to ensure that the probability (G connectivity) is established, the optimal communication radius of nodes is
Certificate. If the network G is connected, , , it is not an isolated node; that is, the node degree , then the minimum node degree of graph G .
Because nodes are distributed as twodimensional Poisson points,
Therefore, .
According to the independence of Poisson process events,
, according to the probability (G connectivity), then , and it can be reasoned. , and the minimum communication radius of nodes can be obtained, ·QED.
Definition 1. Regions are chosen, the neighbourhood of node relative to node set isThe advantage of using 1norm is saving calculation time, so square regions are chosen.
Definition 2. The order node density of node relative to set isIn the equation, Since neighbourhood is an open set, so it has at least nodes in the node set .
Definition 3. Assume as the neighbourhood set of node , as the Euclidean distance between node and node , as the network communication radius, then the neighbourhood distance model is
Definition 4. Assume and are chance variables in a network of random uniform distribution, there exists , is all the nodes within the common area of & , i.e., , then the neighbourhood distance isThere may exist , , but , and the neighbouthood distance of halfmeasure weighted centroid proposed in this paper is
3.1.1. HalfMeasure Weighted Centroid Localization Communication Model
The adopted lognormal shadow fading model is an empirical model based on experiments:
Theoretically, the weight factor reflects the influence of all beacon nodes on centroid position. The positioning weight iswhere is the estimated distance between unknown node and beacon node . However, is the weight factor (Figure 2).
3.1.2. Localization Model
Assume path to be the path from node to node , and are neighbours, and the localization distance of path is
Path between and is not unique, but there exists a shortest path that satisfies the value. Assume to be the shortest path distance,
Choose the optimized weight within the communication range of unknown nodes and calculate , the estimated distance from the unknown node to the beacon node is
Calculating error and accuracy, while calculating the average hop distance, beacon nodes adjacent to beacon nodes are searched to obtain error factors, which are expressed by , as shown in formula:
Calculating the localization accuracy for the centroid of a beacon node , denoted as , and then, the normalized average localization error:
3.1.3. Computing Coordinates of Nodes
By using the least squares method (LSM), the distance from the unknown node to beacon node is calculated, and then the distance between the two nodes can be calculated from the following formula:
Accordingly,
Let,
Then,
It can be found from formula (20) that
The coordinates of the nodes areunknown node is
3.2. Procedures of the Improved Algorithm
Step 1. The hop count in the shortest path is acquired by broadcasting information among nodes, which is the same as the procedure used in the DVHop localization algorithm.
Step 2. Based on halfmeasure weighted centroid neighbourhood distance model, calculate neighbourhood distance, weight factor, shortest path, and optimize.
Step 3. The distances from the unknown nodes to the beacon nodes are calculated by using formulas (6)–(25). Then, by using LSM, the coordinates of unknown nodes are obtained, and the flowchart is shown in Figure 3.
4. Simulation and Data Analysis
4.1. Establishing a Network Simulation Environment
Assess the efficacy and practicability of the improved algorithm proposed here, carry out system level simulation with MATLAB software and analyze and compare test data. One hundred wireless sensor nodes are arranged randomly in a square region of 100 m × 100 m, including 40 beacon nodes and 60 unknown nodes. Other parameters are set as shown in Table 1.

4.2. Simulation and Performance Analysis
The network topology of the DVHop localization algorithm based on the halfmeasure weighted centroid. Thereinto, the red ○ and the black + denote beacon nodes and unknown nodes, respectively (Figure 4). Distance estimation between unknown nodes and beacon nodes is obtained by the product of the minimum hop and the average hop distance between the two nodes; however, the minimum number of hops between nodes is largely determined by the communication radius of the nodes. Different communication radii will have different hop distances, which will also lead to different node locations; as shown in Figures 4(a)–4(c), the larger the node density, the smaller the communication radius, and the topology is closer to the actual location. In addition, optimizing network topology can save network energy consumption and prolong network lifetime.
(a)
(b)
(c)
The localization errors arising from the DVHop localization algorithm and the proposed localization algorithm are compared over the same communication radius (R = 50 m), and the node localization error of the DVHop localization algorithm fluctuates within the range 15 to 60, while that of the proposed algorithm ranges between 2 and 15 and is more stable. The main reason is that the increase of the number of unknown nodes will reduce the minimum communication radius. The number of unknown nodes is equivalent to the total number of nodes (fewer beacon nodes) which is an important factor affecting the current network connectivity. The localization errors arising from the DVHop localization algorithm and the proposed localization algorithm are compared over the same communication radius (R = 50 m), and the node localization error of the DVHop localization algorithm fluctuates within the range 15 to 60, while that of the proposed algorithm ranges between 2 and 15 and is more stable (Figure 5).
It shows the comparison of average localization accuracy of DVHop algorithm with that of the proposed localization algorithm. It shows that the localization accuracy of the DVHop localization algorithm varies within the range 0.3 to 1.2, while that of the improved localization algorithm fluctuates between 0.1 and 0.2. The main reason is that the location accuracy of New DVHop algorithm is higher with the increase of the number of communication radius (Figure 6).
The comparison of the average localization errors arising from the DVHop localization algorithm with those of the proposed localization algorithm under different communication radii is done. A total of 100 groups of experiments were carried out as the communication radius R was increased from 10 m to 80 m. In the new DVHop localization algorithm, when the node communication radius increases, the positioning accuracy is smaller and the positioning performance is better (Figure 7).
The localization accuracy of the DVHop algorithm are compared with that of the DVHop localization algorithm based on the halfmeasure weighted centroid, and other DVHop. To obtain the results, 100 groups of experiments were conducted with increasing communication radius R (10 m ≤ R ≤ 80 m) (Figure 8).
At the same communication radius, and for different densities of beacon nodes, the comparison of the average localization errors of the two algorithms is done. Similarly, the communication radius R was fixed at 50 m, while the number of beacon nodes was increased from 10 to 80 in the 50 groups of experiments. The average localization error of the DVHop algorithm increased gradually from 30. While other DVHop localization algorithm is about 15, and the new DVHop localization algorithm based on a halfmeasure weighted centroid was below 5; in particular, its localization performance was optimal for between 30 and 60 beacon nodes. It is almost unaffected by the communication radius and the total number of nodes. The main reason is that the more accurate distance between beacon nodes and their neighbours can be obtained by optimizing equations (13) and (14), which can undoubtedly reduce the positioning error of all unknown nodes (Figure 9).
The comparison of localization accuracies of the two algorithms at the same communication radius, but for different densities of beacon nodes, is done. The communication radius R was set to 50 m, and the number of beacon nodes was increased gradually from 10 to 80 in the 50 groups of experiments. Compared with the DVHop algorithm, whose localization accuracy increases from 0.6 to 0.7, other DVHOP is about 0.3; and new DVHop shows a localization accuracy fluctuating stably within 0.1. Beacon nodes are calculated by the halfmeasure weighted centroid localization model, next step is to design optimized weight, and optimize the shortest path. The higher the density of beacon nodes and the more reasonable the distribution, the higher the positioning accuracy and the better the positioning performance (Figure 10).
5. Conclusion
In view of the disadvantages in the practical application of the DVHop algorithm in WSNs, such as the uneven distribution of nodes, holes, and large errors in the average hop distance, a novel localization algorithm, combining the DVHop algorithm with a halfmeasure weighted centroid, was proposed. Beacon nodes realize their localization by using the centroid algorithm and then use the localized accuracy as the weight for localizing unknown nodes. Through theoretical reasoning and simulation experiments, it was found that the improved localization algorithm reduced the localization errors and improved the localization accuracy of unknown nodes compared with the DVHop algorithm whether used in the same networks or not. Compared with the DVHop algorithm, whose localization accuracy increases from 0.6 to 0.7, other DVHOP is about 0.3; and new DVHop shows a localization accuracy fluctuating stably within 0.1. It was worth noting that the study was performed in an ideal network simulation environment, so there remains the need to research the application of the improved algorithm under realistic network environments in the future.
Data Availability
The data used to support the findings of this study are available from the corresponding author upon request.
Conflicts of Interest
The author declares no conflicts of interest.
Acknowledgments
The research was funded with the project no. KJ2014A096 entitled “Intelligent Tourism Platform—application of Internet of things location perception service in tourism industry,” supported by funds for a key project from the Natural Science Foundation in Anhui Province, China.
References
 S. Chatterjea and P. Havinga, “A dynamic data aggregation scheme for wireless sensor networks,” Proc Program for Research on Integrated Systems and Circuits, vol. 41, no. 2, pp. 116–125, 2017. View at: Google Scholar
 B. Rashid and M. H. Rehmani, “Applications of wireless sensor networks for urban areas: a survey,” Journal of Network and Computer Applications, vol. 60, pp. 192–219, 2016. View at: Publisher Site  Google Scholar
 M. Mehrabi, H. Taheri, and P. Taghdiri, “An improved DVhop localization algorithm based on evolutionary algorithms,” Telecommunication Systems, vol. 64, no. 4, pp. 639–647, 2017. View at: Publisher Site  Google Scholar
 A. M. A. A. Znaid, M. Y. I. Idris, A. W. A. Wahab et al., “Low communication cost (LCC) scheme for localizing mobile wireless sensor networks,” Wireless Networks, vol. 23, no. 3, pp. 737–747, 2017. View at: Publisher Site  Google Scholar
 L. Gui, X. Zhang, Q. Ding, F. Shu, and A. Wei, “Reference anchor selection and global optimized solution for DVhop localization in wireless sensor networks,” Wireless Personal Communications, vol. 96, no. 4, pp. 5995–6005, 2017. View at: Publisher Site  Google Scholar
 X. Yang and W. Zhang, “An improved DVhop localization algorithm based on hop distance and hops correction,” International Journal of Multimedia and Ubiquitous Engineering, vol. 11, no. 6, pp. 319–328, 2016. View at: Publisher Site  Google Scholar
 S. Tomic and I. Mezei, “Improvements of DVhop localization algorithm for wireless sensor networks,” Telecommunication Systems, vol. 61, no. 1, pp. 93–106, 2015. View at: Publisher Site  Google Scholar
 G. Sharma and A. Kumar, “Improved DVhop localization algorithm using teaching learning based optimization for wireless sensor networks,” Telecommunication Systems, vol. 67, no. 2, pp. 163–178, 2018. View at: Publisher Site  Google Scholar
 L. Cui, C. Xu, G. Li et al., “A high accurate localization algorithm with DVhop and differential evolution for wireless sensor network,” Applied Soft Computing, vol. 68, 2018. View at: Publisher Site  Google Scholar
 S. Kumar and D. K. Lobiyal, “An advanced DVhop localization algorithm for wireless sensor networks,” Wireless Personal Communications, vol. 71, no. 2, pp. 1365–1385, 2013. View at: Publisher Site  Google Scholar
 M. M. Ren, Z. J. Xie, G. Jin et al., “DVhop localization algorithm based on multimobile beacon,” Computer Engineering, vol. 40, no. 10, pp. 92–97, 2014. View at: Google Scholar
 F. Shahzad, T. R. Sheltami, and E. M. Shakshuki, “DVmaxHop: a fast and accurate rangefree localization algorithm for anisotropic wireless networks,” IEEE Transactions on Mobile Computing, vol. 16, no. 99, pp. 2494–2505, 2017. View at: Publisher Site  Google Scholar
 X. L. Cui, W. B. Chen, and C. Hao, “Research on DVHOP algorithm for wireless sensor networks,” in Proceedings of International Conference on Knowledge Management in Organizations, Beijing, China, August 2017. View at: Google Scholar
 J. G. Ko and M. Chang, “MoMoRo: providing mobility support for lowpower wireless applications,” IEEE Systems Journal, vol. 9, no. 2, pp. 585–594, 2017. View at: Publisher Site  Google Scholar
 A. Ademuwagun and V. Fabio, “Reach centroid localization algorithm,” Wireless Sensor Network, vol. 9, no. 2, pp. 87–101, 2017. View at: Publisher Site  Google Scholar
 K.Y. Kim and Y. Shin, “A distance boundary with virtual nodes for the weighted centroid localization algorithm,” Sensors, vol. 18, no. 4, p. 1054, 2018. View at: Publisher Site  Google Scholar
 J. MassSanchez, E. RuizIbarra, J. CortezGonzález et al., “Weighted hyperbolic DVhop positioning node localization algorithm in WSNs,” Wireless Personal Communications, vol. 96, no. 4, pp. 5011–5033, 2017. View at: Publisher Site  Google Scholar
 T. Wang, X. Wei, J. Fan, and T. Liang, “Adaptive jammer localization in wireless networks,” Computer Networks, vol. 141, pp. 17–30, 2018. View at: Publisher Site  Google Scholar
Copyright
Copyright © 2019 Lu Jian Yin. This is an open access article distributed under the Creative Commons Attribution License, which permits unrestricted use, distribution, and reproduction in any medium, provided the original work is properly cited.