## 3 Estimation of Node Position Using Indirect Observations
### Multilateration Problem  
The lateration problem consists in determining the position of a node (_i.e._, the _target node_) in the space based on its distance from other nodes with known positions (_i.e._, the _anchors_) [27]. To address the lateration problem in a plane, three anchors are needed usually. Using the anchor positions and the distances, the target node position has to be at the intersection of three circles centered at the anchors. A common issue is that distance measurements are often imperfect and the intersection of these circles does not, in general, result in a single point. To overcome these imperfections, distance measurements from more than three anchors can be used (the higher the number of measurements the better), resulting in a multilateration problem [28, 29, 30, 31]. Figure 1 shows a representative scenario with four anchors, where the distance measurements brought to the grey area represent the intersection of the circles as well as the area within which the target node is expected to be located.  
The multilateration problem can then be written as follow  
\[\left\{\begin{array}{l}(x_{1}-x)^{2}+(y_{1}-y)^{2}=r_{1}^{2}\\ (x_{2}-x)^{2}+(y_{2}-y)^{2}=r_{2}^{2}\\ \vdots\\ (x_{n}-x)^{2}+(y_{n}-y)^{2}=r_{n}^{2}\end{array}\right. \tag{1}\]  
where \(n\) is the number of anchors, vector \(p=(x,y)\) is the position of the target node, vectors \(a_{i}=(x_{i},y_{i})\) are the position of anchor \(i\), and \(r_{i}\) is the distance measured from anchor \(i\) to the target node. This system can be written with the following matrix equation  
\[Ap=r \tag{2}\]  
The resulting system is not linear, but it is possible to linearize it by subtracting the \(i\)-th equation from all the other \(n-1\). The new system is the following  
\[\left\{\begin{array}{l}x_{1}^{2}-x_{n}^{2}-2\left(x_{1}-x_{n}\right)x+y_{1}^ {2}-y_{n}^{2}-2\left(y_{1}-y_{n}\right)y=r_{1}^{2}-r_{n}^{2}\\ x_{2}^{2}-x_{n}^{2}-2\left(x_{2}-x_{n}\right)x+y_{2}^{2}-y_{n}^{2}-2\left(y_{2 }-y_{n}\right)y=r_{2}^{2}-r_{n}^{2}\\ \vdots\\ x_{n-1}^{2}-x_{n}^{2}-2\left(x_{n-1}-x_{n}\right)x+y_{n-1}^{2}-y_{n}^{2}-2 \left(y_{n-1}-y_{n}\right)y=r_{n-1}^{2}-r_{n}^{2}\end{array}\right. \tag{3}\]  
Then it is possible to finally write the following matrix equation  
\[A_{lin}p=b \tag{4}\]  
Figure 1: Example of a multilateration problem. The grey area is obtained as the intersection of the three circles centered at the anchors and is where the target node is expected to be located.  
This problem is over-determined so that to find the solution the Ordinary Least Squares (OLS) can be used [32]. In the ideal case where all measures are perfect, all circles intersect at a single point, but in the real case the measures are affected by error and the circles intersect at more than one point. These points identify an area of solution (grey area in Figure 1). By the OLS, we obtain the solution that minimizes the sum of the squared distance. The precision of this solution is given by the residual  
\[res=\frac{\sum_{i=1}^{n}\sqrt{(x_{i}-x_{m})^{2}+(y_{i}-y_{m})^{2}}-r_{i}}{n} \tag{5}\]  
where \(p_{m}=(x_{m},y_{m})\) is the resulting estimated target node position.