0
$\begingroup$

Im trying to solve one equation which I will be using in one software.

I have two fixed points a and b in 2D space and also point c in which i know just coordinate x .

I need to solve coordinate y for point c. This equation can have more solutions. In this equation must be true that

s2*d1 + s1+d2 =d1*d2

where: d1 = squared distance between points a and c d1 = squared distance between points b and c s1 = variable which must be contained in equation s2 = variable which must be contained in equation

Here is the link for Desmos: https://www.desmos.com/calculator/g85twlnqcx

$\endgroup$
1
$\begingroup$

As said in comments, your wording is not very clear.

If I try to understand, you have two numbers $(s_1,s_2)$, the coordinates $(x_a,y_a)$ for point $A$, $(x_b,y_b)$ for point $B$, $(x_c,y_c)$ for point $C$ and you want to solve for $y_c$ the equation $$s_2 d_1+s_1 d_2=d_1 d_2$$ where $$d_1=(x_a-x_c)^2+(y_a-y_c)^2 \qquad \text{and} \qquad d_2=(x_a-x_c)^2+(y_a-y_c)^2$$ Expanding, you will end with a quartic equation in $y_c$ $$y_c^4+\alpha \,y_c^3+\beta\, y_c^2+\gamma \,y_c+\delta=0$$ where $$\alpha=-2(y_a+y_b)$$ $$\beta=-2 x_c (x_a+x_b)+4 y_a y_b+x_a^2+y_a^2+x_b^2+y_b^2+2 x_c^2-s_1-s_2$$ $$\gamma=-2 y_a \left(-2 x_b x_c+x_b^2+y_b^2+x_c^2\right)-2 y_b \left(-2 x_a x_c+x_a^2+y_a^2+x_c^2\right)+2 s_2 y_a+2 s_1 y_b$$ $$\delta=\left(\left((x_a-x_c)^2+y_a^2\right) \left((x_b-x_c)^2+y_b^2\right)+2 s_2 x_a x_c-s_2 x_a^2-s_2 y_a^2+2 s_1 x_b x_c-s_1 x_b^2-s_1 y_b^2-s_1 x_c^2-s_2 x_c^2\right)$$

$\endgroup$
  • $\begingroup$ Thank you, this is what I tried to ask $\endgroup$ – Patrik Bašo Apr 30 '19 at 5:55
  • $\begingroup$ @PatrikBašo. You are welcome ! Now, have fun with the quartic ! I strongly suggest numerical methods. $\endgroup$ – Claude Leibovici Apr 30 '19 at 6:02
  • $\begingroup$ I found already some equations on stackoverflow , so I hope it will be working 😄 $\endgroup$ – Patrik Bašo Apr 30 '19 at 6:11

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.