Research on Algorithm of Three-Dimensional Wireless Sensor Networks Node Localization

This paper proposes a three-dimensional wireless sensor networks node localization algorithm based on multidimensional scaling anchor nodes, which is used to realize the absolute positioning of unknown nodes by using the distance between the anchor nodes and the nodes. The core of the proposed localization algorithm is a kind of repeated optimization method based on anchor nodes which is derived from STRESS formula. The algorithm employs the Tunneling Method to solve the local minimum problem in repeated optimization, which improves the accuracy of the optimization results. The simulation results validate the effectiveness of the algorithm. Random distribution of three-dimensional wireless sensor network nodes can be accurately positioned. The results satisfy the high precision and stability requirements in three-dimensional space node location.


Introduction
Node localization technology is one of the key technologies of wireless sensor network (WSN).Node localization approaches in WSN locate unknown nodes through the location of anchor nodes by an algorithm or a rule.The two-dimensional (2D) WSN node positioning technology has been mature, but research in three-dimensional (3D) nodes localization has not been rich.In practical application, the space distribution of wireless sensor is often 3D rather than 2D due to the shape of ground and the environment.So localization in 2D plane is not enough, and research on localization algorithms in the 3D space is necessary.With the increase of dimension, the computational complexity and the error increase greatly.Even though the error of node position is so little, it will be apparent after the 3D calculation.In addition, it is necessary to combine the WSN system position with node position to realize accurate positioning of external nodes.Therefore, the node localization algorithm requires higher precision [1][2][3].
In recent years, many new ideas and solutions have been proposed to solve the problem of WSN node localization in 3D.The theory that originated in psychometrics multidimensional scaling (MDS) positioning technology proposed by Shang et al. provides a new method for node localization.
In the existing MDS algorithms, MDS-MAP, MDS-MAP(P), and MDS-MAP(P,R) algorithm are the most influential.MDS-MAP is a centralized location algorithm based on MDS.First, MDS-MAP uses multidimensional scaling technique to build a local map of a series of neighboring nodes in 3D and to achieve global network positioning through coordinate conversion.MDS-MAP algorithm makes full use of MDS advantages and avoids the error caused by the shortest path distance in place of the real distance.As a result, its positioning accuracy has been improved to a certain extent but its biggest disadvantage requires centralized calculation, which is not suitable for large-scale, uneven distribution network.MDS-MAP(P) and MDS-MAP(P,R) are the improvement based on MDS-MAP distributed algorithm.Through dividing the whole network into many subnets and using MDS-MAP to compute each subnet to get local coordinate system, MDSMAP(P) and MDS-MAP(P,R) then realize the entire network position by transform and fusion of local coordinates.The complexity of algorithm will greatly increase since the transform and fusion.It will introduce the transmission error and lead to the accumulation of error.The bigger the network is, the more apparent the error will be.And the computational complexity will be a geometric growth [4,5].
The improved positioning algorithm mentioned in this paper uses anchor nodes calibration technology of MDS to directly get the absolute coordinates of unknown nodes, which requires neither integration of local coordinate system nor conversion from the relative coordinates to the absolute coordinates.As a consequence, it avoids the cumulative errors produced in this process.At the same time, taking into account the MDS optimization of local minimum problem, this paper employs Tunneling Method algorithm to solve the repeated optimization algorithm of values in local minimum problem.The simulation result demonstrates that the MDS node localization algorithm based on Tunneling Method (TMDS) achieves high positioning accuracy and high stability.
The rest of the paper is organized as follows.In Section 2, the node localization algorithm based on MDS is described in detail.Section 3 introduces node localization algorithm based on MDS.Section 4 reports the simulation scenarios and analysis results.Finally a conclusion is given in Section 5.

Node Coordinates Calculation
Based on the MDS.Assume that WSN in 3D space is made up of  unknown nodes and  anchor nodes. = [  ] ×3 represents the unknown node coordinate matrix. = [  ] ×3 represents the anchor nodes coordinate matrix.  represents the measuring distance between unknown nodes  and .  represents the measuring distance between unknown node  and anchor nodes .The distance can be expressed by the minimum hop between two nodes and also can be expressed by the shortest path distance between two nodes or any other distance, such as the Euclidean distance.To guarantee the accuracy, this paper measures the distance between one-hop neighbor nodes by the Euclidean method.The problem of node localization is using repeated optimization algorithm to calculate the coordinates of unknown nodes matrix  under the condition that   and   distance and the anchor nodes coordinate matrix  have been known [6,7].
Matrix  ×3 represents the coordinates of the  nodes in 3D space.For any two nodes  and ℎ, their Euclidean distance can be shown as follows: For three nodes in 3D space, their corresponding matrix is as follows: 2 () represents the square of the distance matrix and it can be represented as follows: where   is the  column of matrix . is the column vector which is composed of ∑ 3 =1      .Vector  is a column matrix and its elements are 1.

The Repeated Optimization Algorithm Based on the
Anchor Node.Repeated optimization algorithm aims at finding coordinate matrix  representing the unknown nodes' location.The algorithm makes nodes distance calculated by coordinates be closer to the real measuring distance.When the difference is smaller, coordinate values in a matrix are close to the real coordinates of nodes.Using the repeated optimization method, find the coordinate matrix .The first step is to build a function about matrix  as the objective function.Then find the minimization inequality of the objective function.Finally obtain the repeat optimization formula.When the formula reaches its minimum value,  is the coordinate for unknown nodes.Regard the difference square sum between computing distance and the measuring distance as target function of repeated optimization algorithm in MDS technology [8][9][10].
According to the Euclidean Metric, the distance between the unknown nodes  and  can be obtained by According to matrix , the distance between the unknown node  and the anchor node  can be obtained by In order to get the coordinate matrix , we usually use Kruskal's STRESS formula to set the objective function as follows: where the weights   and   decide their corresponding sum's influence on objective function.This paper applies the calculation method of weight proposed by the literature [6], and weights can be calculated by Otherwise, both of them are zero.  in (7) represents the biggest distance between unknown node  or  and other nodes.  represents the biggest distance between unknown node  and other nodes or anchor node .For a given matrix , the value of corresponding objective function can be obtained according to formula (3).Our goal is to find , which makes the objective function minimum.Namely, minimize the objective function, and find the optimal solution  of objective function.
There are many ways to solve the local minimum problem of repeated optimization method in minimizing the objective function, for example, Dimensionality Reduction, multivalue random testing method, Distance Smoothing, and Tunneling Method.Among those methods, multivalue random testing method may attain good optimal result but it has great randomicity and poor stability.Dimensionality Reduction is complex and large in the amount of calculation in the 3D space environment.Distance Smoothing is simple in calculation and does well in positioning in 2D space environment.But its global search is poor in the 3D space environment [8].On the contrary, the repeated optimization method based on tunneling can almost find the global optimal value due to cycle search method that first searches in the horizontal direction and then searches in the vertical direction and then searches in the horizontal direction again.Therefore, Tunneling Method used in this paper solves the local minimum problem of repeated optimization algorithm.And the MDS 3D node localization algorithm based on Tunneling Method is proposed.

MDS Location Algorithm Based on
the Tunneling Method Step 1 (local minimizing step).Starting from an initial point, it applies local minimization algorithm, such as quasi-Newton method, gradient method, or the conjugate gradient method, to obtain the first local minimum value point  1 * of the objective function () [8].
Step 2 (tunneling step).First, define the tunneling function in  1 ) Among the three situations, the former two may appear many times.Every time, tunneling function needs to be rebuilt to minimize the function until the third situation turns up and begins the next circulation.This circulation will never stop until the tunneling function cannot find a smaller local minimum in a certain period of time.The last local minima will be regarded as the global minimum.

MDS Positioning Algorithm Based on Tunneling Method.
In order to find another configuration with the same STRESS, the tunneling function must have several characteristics.Some of these characteristics are met by the tunneling function originally defined by Groenen and Heiser [9].The tunneling function is defined as follows: where  * is the local minimum point of ().The elements of the tunneling function  1 () and their purpose are given in Table 1.The final tunneling function  1 () can be expressed as follows: where   () is where  represents the number of   's available. 1 () mentioned above meets all conditions of the tunneling function.The tunneling function is shown as formula (11), which can be treated as the ratio of two functions based on .Assume that () > 0.  1 () can be written as where () and () are, respectively, as follows: 1 () can get a certain pole through ( 14) and (15).Assume that we can find , which makes formula (16) right: Let us multiply both sides with ().Then we can obtain We find  that meets (, ) < 0, and then  1 () <  1 () is right.As a result, the iterative optimization algorithm will be used to optimize (, ).Namely, it minimizes optimization  1 ().
We carry out iterative minimization operations on √ 1 (), since  1 () have the same zero and stagnation point  and √ 1 () is easier to build its optimization framework.
For every optimization step and optimization function, using formulas ( 13), ( 16), (17), and (18), (, ) can be got by step-by-step operation.According to formula (18), optimize (, ) or optimize Specific optimization steps are as follows. Step We verify the update data for each iteration.If the assumption is wrong, then there is () ≤ ( * ) and the tunneling step will be stopped.Finally  * can be found and optimization of () can be accomplished.
Step 2. Optimize the output of   () through   (  ) to be instead of   in formulas ( 4), ( 5), (6), and ( 7) and then realize the optimization of Step 3. Optimize the output of   () and −√  () to realize the optimization of The optimization step of   () is the same as Step 2.
According to Cauchy-Schwarz's inequality, the optimization for   () and −  () is to realize the optimization for −√  ().The second optimization methods will be used to optimize   () [10].Then −  () will be optimized by Holder inequality.
(, ) will be optimized by the steps mentioned above and  will be got which satisfies (, ) < 0 and makes formula (16) right.Such cycle can get global minimum and realize global optimization.

Parameters of Tunneling Method.
The Tunneling Method needs a pole strength parameter and a pole width parameter.Figure 1 is the three-dimensional effect graph of the STRESS function under different strength parameters and width parameters.The strength parameter 1/ is 1/1.5, 1/2, 1/3, . . ., 1/10, whose number adds up to 18.The width parameters  are 0.5, 1, 2, 3, 4, 5, 6, 7, 8, whose number adds up to 9. The number of iterations is 1000.We can draw a conclusion from Figure 1 that when strength parameter and width parameter are larger, more iterations are needed to get the same result.But when the strength parameters and width parameters are too small, the result is not what we want.Heiser carried out a lot of experiments and finally concluded that when the strength parameters are 1/3 and width parameter is /4 in Tunneling Method, the result of iteration is the best, where  is the number of iteration elements [8].

Simulation Results and Analysis
The TMDS 3D node localization algorithm simulation is operated on Matlab 2009(a) (64 bits) to research its performance.Analyze TMDS from three aspects: the node communication radius, the number of nodes, and the proportion of anchor node.The simulation environment is described as follows: the size of cube geometric model is 10 m × 10 m × 10 m and the nodes are placed in this model (the node communication radius is the same and all the nodes are stationary).The model is shown in Figure 2. Set the simulation environments as follows: when the iteration calculation rule is the same, node communication radius is also the same.Repeated optimization algorithm iterative time is 60.The iterative computation error threshold is 0.0001.Node localization error threshold   is 0.05 m.The error in distance measurement is taken as 15%.When the unknown node location error meets  ≤  , the node will be regarded as the accurate localization of nodes.

Node Communication Radius
Influence on the Performance of the Algorithm.Figure 3 shows the impact of node communication radius on the performance of TMDS algorithm.The simulation environment is as follows: the number of unknown nodes  is 50, which randomly distribute in a 10 m * 10 m * 10 m cube model.The number of anchor nodes  is 8, which distribute in the 8 vertex positions of the cube model.Change the node communication radius to analyze its impact on the performance of the algorithm.We can draw a conclusion form Figure 3(a) that the proportion of accurate positioning nodes will increase with the increase of node communication radius.When the node communication radius increases to 8 m, the number of accurate positioning nodes reaches 50.And with the continuous increase of the node communication radius, accurate positioning of unknown nodes rate will be maintained at 1.We can draw from Figure 3(b) that the average error of accurate positioning of node localization gradually decreases with the increase of node communication radius.When node communication radius increases from 4 m to 8 m, the average error decreases fast.When node communication radius changes from 8 m to 12 m, the error is stable.
When the communication radius is small, network connectivity is low, and the number of unknown nodes that can communicate with the node is reduced, and a small node communication radius ( = 8 m) will get higher accurate positioning node and low node localization error rate in the TMDS test.The positioning result will be stable when the radius is increased.

Influence of Network Nodes on the Performance of TMDS.
Figure 4 shows that when the node communication radius  is 8, the network node influences the TMDS algorithm.According to the analysis of 4.1, when the communication radius is 8 m, it is easier to analyze other factors influence of nodes on the performance of the algorithm.So in this section, the simulation environment is set as follows: The number of anchor nodes  is 8, which are, respectively, distributed on the 8 vertex positions of the cube model.Nodes have the same radius ( = 8 m) of communication.Change the proportion of anchor nodes by changing the number of unknown nodes, and then analyze the influence of network nodes on the performance of the algorithm.
We can draw a conclusion from the curve of Figure 4 that, with the number of nodes increasing from 38 to 78, that is, the numbers of unknown nodes increase from 30 to 70, accurate positioning of unknown nodes rate has been 1.When the network nodes number is 83, that is, the unknown nodes number is 75, accurate localization rate begins to decline.The results show that when TMDS algorithm works in an environment of few anchor nodes and many network nodes, the location accuracy of unknown nodes can be maintained at 1.So when the TMDS algorithm works in environment of few anchor nodes, the unknown nodes can be located accurately and the result is significant.

Influence of the Proportion of Anchor Nodes on the
Performance of TMDS. Figure 5 shows the proportion of anchor nodes influence on the performance of algorithm.The simulation environment is as follows: the number of unknown nodes  is 100, which are randomly distributed in the space model.Eight anchor nodes are distributed in the 8 vertex positions of the cube model, and others are distributed randomly in the space model.All the nodes have the same communication radius ( = 8 m).Change the number of the anchor nodes to analyze the proportion of anchor impact on the performance of the algorithm.
We can draw form Figure 5(a) that the number of accurate positioning nodes will increase with the increase of the proportion of anchor nodes.When the proportion of anchor nodes is 0.1, the number of accurate positioning nodes reaches 100.And the proportion of anchor nodes changes from 0.15 to 0.5; the rate of accurate positioning of unknown nodes will be maintained at 100.Namely, when the proportion of anchor nodes is greater than or equal to 0.15, TMDS algorithm can locate the unknown nodes accurately.
We can draw from Figure 5(b) that the unknown node localization error gradually decreases with the increase of the proportion of anchor nodes.When the proportion of anchor nodes changes from 0.1 to 0.16, the unknown nodes location error decreases fast.When the proportion of anchor nodes changes from 0.16 to 0.5, the average location error fluctuates a little.But the positioning error is within the threshold range.The result of accurate positioning of unknown nodes is stable.

The Comparison between MDS Algorithm and TMDS
Algorithm.Tables 2 and 3 represent MDS algorithm and TMDS algorithm for 10 times the continuous operation under the same simulation environment, respectively.The content of the table includes the average positioning error of unknown nodes, number of accurate positioning nodes, node location accuracy rate, and the program running time results data.The same simulation environment settings are as follows: the number of anchor nodes  is 8, which are, respectively, distributed on the 8 vertex positions on a cube model; all nodes have the same radius of communication ( = 8 m).
From the accuracy of positioning algorithm, TMDS algorithm can achieve 9 times accurate positioning of all the unknown node in 10 times continuous operation, whose location accuracy rate was 1; only 1 time accurately positioning node number is 49 and its accurate localization rate is 0.98.We can draw from Tables 2 and 3 that TMDS algorithm can basically realize accurate positioning of the node.MDS algorithm can achieve 4 times the accurate positioning of all the unknown node in 10 times the continuous operation and have 2 times the low positioning rate, respectively: 0.08 and 0.1.
From the running time of the algorithm, TMDS and MDS can complete the algorithm in a relatively short period of time.Time of MDS algorithm that completes the basic algorithm within 13 s∼14 s is relatively stable.TMDS takes a long time because of iterative computation of repeated

Figure 1 :
Figure 1: Strength parameters and width parameters configuration effect chart.

Figure 2 :
Figure 2: The distribution map in 3D for unknown node and anchor.

Figure 3 :Figure 4 :
Figure 3: Node communication radius influence on the performance of TMDS.

Table 1 :
The elements of the tunneling function  1 () and their purpose.