3

First thing - please forgive me if my way of explaining my problem is not formal or not accurate to standards, I am an amature mathematician and I have much to learn, I welcome you to let me know about any mistakes, any feedback will be appreciated.

More precisley my problem is as such: Given 4 points moving in a plane over time, what are all of the possible solutions for the circles passing through all of the points, where a circle is defined by the time in which it occurs => $t$, radius => $R$ and it's center vector => $\vec{C}$. It can be phrased using the vectoric form of the circle equation: $|\vec{P}-\vec{C}|=R$ where $\vec{P}$ represents a point on the circle, as the following system of equations: $$|\vec{P_1}(t)-\vec{C}|=R$$ $$|\vec{P_2}(t)-\vec{C}|=R$$ $$|\vec{P_3}(t)-\vec{C}|=R$$ $$|\vec{P_4}(t)-\vec{C}|=R$$ Where $\vec{P_n}(t)$ is the position of the $n$th point given a moment $t$ in time, and it is given by $$\vec{P_n}(t)=\vec{P_n}(0)+t\vec{V_n}$$ where $\vec{P_n}(0)$ is the position of the $n$th point at $t=0$, and $\vec{V_n}$ is the velocity of the point. It can also be phrased like this: $$|\vec{P_1}(t)-\vec{C}|=|\vec{P_2}(t)-\vec{C}|=|\vec{P_3}(t)-\vec{C}|=|\vec{P_4}(t)-\vec{C}|=R$$ The problem can be further simplified by assuming one point is at the axes origin and has no velocity (by moving the axes origin with one point), this leaves us with this representation: $$|\vec{P_1}(t)-\vec{C}|=|\vec{P_2}(t)-\vec{C}|=|\vec{P_3}(t)-\vec{C}|=|\vec{C}|=R$$

What I tried: I tried solving this the traditional high-school-math way with the full parametric circle equation: $$(x-a)^2+(y-b)^2=R^2$$ This turned out to be a nightmare, I struggled with it for a while with no luck. Then I turned to equatioms describing the circle that passes through 3 points, and all I needed was to plug in the 4th point. I used the set of equations from this article http://www.ambrsoft.com/trigocalc/circle3d.htm, which was very useful and got me going. Yet still I didn't get very far, I got to an equation with $t$ as the only variable, and it got HUGE, I then used Matlab to crack it out, and it got to a 4th degree polynomial, which was ENOURMOUS, and trying to plug that in to the roots equation for quartic polynomials (discussed by this issue: Is there a general formula for solving 4th degree equations (quartic)?) was inconceivably complex (and I think it means what I think it means...).

What I am considering now: I thought about a few options, 1. Use only vector calculations without splitting into the x and y variables, that might simplify the problem and the amount of variables, but I am not strong with my linear algebra so I got no clue about how to try to solve it that way, just intuition about the direction. 2. Take generalization even further and generalize the number of dimensions of the problem to become: $$|\vec{P_1}(t)-\vec{C}|=|\vec{P_2}(t)-\vec{C}|=|\vec{P_3}(t)-\vec{C}|=...=|\vec{P_n}(t)-\vec{C}|=|\vec{P_{n+1}}(t)-\vec{C}|=|\vec{P_{n+2}}(t)-\vec{C}|=R$$ Where $n$ is the number of dimensions (not including time), which by the way is even more mind bending to grahsp, and I have no clue how it might be done.

What I want from you: Guidance, give me the tools to solve this problem, I am more than excited to learn new things, and I'm all out of tricks with this problem. If you have a solution please post it with an explanation of how you arrived to that solution and what tools I was missing. Thanks for getting this far into my post, much appreciated ;)

Now for those of you that are interested here is my motive: I want to code a program that builds a dinamic Delaunay triangulation for points moving through a plane over time, and it will update it self while moving, yet I want to calculate the exact moment the triangulation changes so it will be fast and efficient. If you are familiar with Delaunay triangulations you know that they are defined by one rule: A circle passing through 3 points which share a triangle in the graph may not contain any points inside it. That implies the graph changes once a point gets inside a circle or intersects it's circumference. THAT is why I want to find this equation.

  • In general, four points on the plane don’t lie on a circle. What guarantee do you have that your do? If you take sets of three points, there’s a straightforward determinant computation that gives you an equation for the circle through them. – amd May 04 '18 at 23:05
  • Given any $p = (x,y) \in \mathbb{R}^2$, let $\vec{p} = (x,y,x^2+y^2) \in \mathbb{R}^3$. For any $p_1, p_2, p_3, p_4 \in \mathbb{R}^2$, they lie on a circle when the corresponding $\vec{p}_1, \vec{p}_2, \vec{p}_3, \vec{p}_4$ are coplaner. This is equivalent to vanishing of a $4\times 4$ matrix or the vanishing of the triple product $(p_2 - p_1)\cdot ((p_3-p_1) \times (p_4-p_1))$. – achille hui May 04 '18 at 23:27
  • amd you are correct, they don't lie on a circle just like that, the difference here is that the points are moving, making the problem actually 3d (counting time), where that limit does not exist, the 2d interpretation is easier since this problem talks about circles in a plane parallel to the XY plane, which makes it equivalent to a circle at amoment in time. Think of it this way, at one moment there is a circle that lies on 3 points while the 4th point is not, now when time moves the point moves and now can intersect with the circle too at another moment later in time. – Alon Kellner May 04 '18 at 23:41
  • acille hui that is great, but what I need is not a verification if 4 points lie on a circle, but to find the moment in time $t$ (and circle radius $R$ and center $\vec{C}$) that the points lie on a circle (actually there might be several moments in time that happens) – Alon Kellner May 04 '18 at 23:47
  • I think your problem has no simple solution: if it was just one point moving, I would have suggested to draw the Voronoi diagram of the points and check when the moving point exits its cell, but if all points move you don't have any stable configuration and you could often have multiple solutions as one triangulation becomes invalid. – N74 May 05 '18 at 00:27
  • N74 I was afraid of that answer... It does seem like there are good directions to solving it, yet I get stumped as I think I almost found a solution each time. What I can't understand is the deeper reason why it can't be solved, and if I can't solve it I must know why. – Alon Kellner May 05 '18 at 07:28

1 Answers1

0

Your first problem is to determine when four given points in the plane are concyclic as in the MSE question 2429922 "Showing That Points Are Concyclic" answer using a $4\times 4$ determinant. Because your four points each have constant velocity, their position is a linear function of time $t$, and thus the determinant is a fourth degree polynomial with real coefficients. I suggest that you solve this numerically instead of trying to solve it symbolically because, unlike the simple quadratic formula, the formulas for solving quartic equations is, as you found out, very extensive and confusing.

The last paragraph of your question indicates another possibility. The position of the points and hence the determinant changes with time, but you don't have to solve for it being zero. Just monitor its value periodically and note when it gets close to zero and changes sign. This may be sufficient and avoids having to solve a quartic polynomial equation. Your mileage may vary.

Somos
  • 35,251
  • 3
  • 30
  • 76
  • Somos thank you for your answer, it is now clearer to me how it might be solved, yet solving it numerically still bugs me, and it really feels like this problem could have a nice symbolic solution, could you expand on why that might not be the case? – Alon Kellner May 05 '18 at 07:23
  • Somos, your answer really helped me, I am not giving up yet but I am more conservative with my expectations. Thank you very much! – Alon Kellner May 05 '18 at 17:59
  • @AlonKellner Glad to help out. I have added a alternative at the end of my answer that may work better.. – Somos May 05 '18 at 18:22
  • that alternative is not an option for me, the entire idea is to make it an event based algorithm rather than frame based, my end goal is to integrate this model with an event based collision physics engine (with circles only), the Delaunay triangulation will define each circles neighbors, and that way I can make the engine fully event based and super efficient. – Alon Kellner May 05 '18 at 18:38
  • @AlonKellner Okay. You know best. You may want to ask a programming question about this on another area of Stack Exchange. – Somos May 05 '18 at 18:43