# Thread: have two points and there distance from third, find third

1. ## have two points and there distance from third, find third

I have 2 points, and i know those two points distance from the location im trying to find. From that data i need to find a 3rd points location.

Such as 6,8 is 5 from the location, and 0.0 is also 5 from the location. So it could be at 3,4.

I just cant figure out the math to do it. Ive been trying to derive it from the distance formula but its not working.

Thanks for any suggestions or help.

2. I'd use the formula for a circle centred at a point $\displaystyle (x_0,y_0)$ and radius = $\displaystyle r$

$\displaystyle (x-x_0)^2 + (y-y_0)^2 = r^2$

In this case you have two equations

$\displaystyle (x-6)^2 + (y-8)^2 = 25, \quad x^2 + y^2 = 25$

Solving simultaneously you get

$\displaystyle 3x + 4y = 25 \qquad (1)$

Now substitute $\displaystyle y = \frac{25 - 3x}{4}$ into the second circle equation you get

$\displaystyle x^2 + \left(\frac{25 - 3x}{4}\right)^2 = 25$

which simplifies to $\displaystyle (x-3)^2 = 0$ and therefore $\displaystyle x = 3$.

Substituting back into equation (1) gives $\displaystyle y=4$.

So your intuition was right but following the steps above you can prove $\displaystyle (3,4)$ is the only solution.

Generally for these sorts of problems there are either 2 distinct solutions, one exact solution (this case) or no solution. Infinitely many solutions are a possibility too but only when the circle centres and radii are equal.

3. Thanks! im going to try and derive a useful java function from that for the program im trying to make. I fear that knowing a formula is only half the battle, and that formula is kinda monstrous :-) Well thanks for your help, im gonna jump into this soon.

4. If you have the distance between the first two points you could probably solve it with trigonometry.