Finding One Origin by using Triangle Calculation and Least Square in 3D

42 Views Asked by At

I have been working on an assignment to find the exact origin from 2 points. I have a plane equation that contains 8 points (P1 and P8) and 4 angels from a combination of 2 points. P1 and P2 with angel 60 degrees also known as OP1 = OP2 (Isoclese Triangle), I can find two origin O1 and O2.

enter image description here

Same go to P3, P4 with angel 40 degrees, P5, P6 with angel 50 degrees, P7, P8 with angel 60 degrees, we will get 2 origins of each combination. But from each origin to existing 8 points O1P1 = O1P2 = O2P1 = O2P2 = O3P3 = O3P4 = ...... = O8P8. My lecturer just pointed out that we can one exact origin each combination points by using Isosceles Traiganle and Least Square Method. Is there any way that we can solve this one? Thank you so much

1

There are 1 best solutions below

9
On

Use least squares to find that point which minimizes the errors in $|OP_i|=|OP_{i+1}|$. If $\mathbf{y}$ are the coordinates of the origin, and $\mathbf{p}_i$ are the coordinates of $P_i$, then $|\mathbf{p}_1-\mathbf{y}|=|\mathbf{p}_2-\mathbf{y}|$ gives $$2(\mathbf{p}_1-\mathbf{p}_2)\cdot\mathbf{y}=|\mathbf{p}_1|^2-|\mathbf{p}_2|^2$$ You can write these equations as a matrix equation $A\mathbf{y}=\mathbf{b}$. Then least squares gives $A^TA\mathbf{y}=A^T\mathbf{b}$. Solving this matrix equation gives the best $\mathbf{y}$.

For example, suppose we have the points $P=(-0.66,0.75,0.1)$, $(0.45,-0.88,0.2)$, $(0.26,0.97,0.3)$, $(-0.80,0.58,0.4)$, $(-0.97,0.15,0.5)$, $(-0.22,0.97,0.6)$. Then The first pair of points give the condition $|OP_1|=|OP_2|$, that is, $$2(-1.11, 1.63,-0.1)\cdot(y_1,y_2,y_3)=1.0081-1.0169=-0.0088$$ Repeating this for the other two pairs gives three equations: $$\begin{pmatrix}-2.22&3.26&-0.2\\2.12&0.78&-0.2\\-1.5& -1.64&-0.2\end{pmatrix}\begin{pmatrix}y_1\\y_2\end{pmatrix}=\begin{pmatrix}-0.0088\\-0.0379\\-0.1359\end{pmatrix}$$ Then $A^TAy=A^Tb$ is $$\begin{pmatrix}11.67&-3.12&0.32\\-3.12&13.93&-0.48\\0.32&-0.48& 0.12\end{pmatrix}\begin{pmatrix}y_1\\y_2\\y_3\end{pmatrix}=\begin{pmatrix}0.14\\0.16\\0.036\end{pmatrix}$$ which gives $(y_1,y_2,y_3)=(0.0089, 0.027, 0.39)$.

However, this procedure does not guarantee that $|OP|$ are all equal, just that they are equal in pairs. The condition $|OP_i|=|OP_j|$ for all $i,j$ is impossible to satisfy.