2

I am having a line with start point as sp(x1,y1,z1) and end point as ep(x2, y2, z2). I need to check if the line is lying on the plane which is defined by three Cartesian coordinate points p1(x3,y3,z3), p2(x4,y4,z4) and p3(x5,y5,z5)

  • First, find the equation of the plane via this. Then, check whether both $sp$ and $ep$ are in said plane, since if both are, the whole plane is. – Rushabh Mehta Oct 09 '19 at 14:37
  • First check if the line is parallel to the triangle. Then compute the normal vector of both the plane $A$ and the line $B$. If the length of the normal vector is $A=B$ or if both $A=0$ and $B=0$, then the line is lying on the plane, depending on how you compute the normal. –  Oct 09 '19 at 14:50
  • Upvote, as many approaches possible. – z100 Oct 09 '19 at 19:35

4 Answers4

1

You may check whether the volumes of the parallelepipeds defined by $p_2-p_1$, $p_3-p_1$, $sp-p_1$ and $p_2-p_1$, $p_3-p_1$, $ep-p_1$, resp., equal zero. Use the Gram-determinant.

Michael Hoppe
  • 18,103
  • 3
  • 32
  • 49
0

To check if the line is lying the plane, you could check whether both points sp(x1,y1,z1) and ep(x2,y2,z2) are lying in the plane defined by the three points. So you need to check whether there is a solution of

$$ \vec{sp} = \vec{p_{1}}+a\cdot(\vec{p_{2}}-\vec{p_{1}})+b\cdot(\vec{p_{3}}-\vec{p_{1}})\\ \vec{ep} = \vec{p_{1}}+c\cdot(\vec{p_{2}}-\vec{p_{1}})+d\cdot(\vec{p_{3}}-\vec{p_{1}}) $$

where you have to solve for a,b,c, and d.

0

Both the start and end points should be in the plane contained among points $(p1,p2,p3)$.

Consider each point separably. We should have zero volume of tetrahedron, so the scalar triple product should vanish for each vector triad in the plane. A $(3\times3)$ matrix can be employed.

$$ (sp-p1) \cdot (sp-p2) \times (sp-p3) =0 $$ $$ (ep-p1) \cdot (ep-p2) \times (ep-p3) =0. $$

Narasimham
  • 40,495
0

Pure linear algebra approach: check if all 5 points lies in the same plane. So if a system of 5 equations with 4 variables $ax+by+cz=d$ have a solution, answer is yes, otherwise no. Easier to calculate in practice for 3 variables and consider 2 possibilities for d=1 and d=0. Solvability condition of systems of linear equations of course is extensively used and well known.

z100
  • 530