0

Let us have 3 points, p0, p1, p2 in 3d space.

These 3 points form a plane.

I have already computed and normalized the normal of the plane (n).

Now, given a point exterior to my plane (p) I would like the distance from this point to my plane.

I have found this question click that treats the solution however I am confused about the final dot product.

In this figure:

fig. 1

The distance from p to the plane is given as |dot ( p-p0 , n )| so the dot between n and the vector going from p0 to p (lets name this vector P (capital P)).

From what I can see using the figure and my own logic, is that the distance from p to the place is basically the length of the projection of P onto n. But the length of this projection is not a complete dot product. A complete dot product would be |P||n|cos(P,n). But I have found that the length of the projection of P onto n is just |P|cos(P,n).

So my questions are:

  1. Is my thinking correct that the distance from p to the plane is the projection of P onto n? If not why?
  2. which interpretation is correct and why?
Rares Dima
  • 1,575
  • 1
  • 15
  • 38
  • 1
    I’m voting to close this question because it's a math problem, not programming, and best for https://math.stackexchange.com/ Also, do not ask multiple questions in one posting. [ask] – Rob Aug 02 '22 at 10:53
  • @Rob I assume you already voted to close the question I linked, correct? Because they treat the exact same subject. – Rares Dima Aug 02 '22 at 11:00

1 Answers1

1

Distance is length of perpendicular projection of P onto the plane P0P1P2 (or another interpretation with the same result - projection of P0P vector onto n direction)

Perhaps you forgot that your normal n is normalized vector, so it has unit length, and

|P||n|cos(P,n) == |P|cos(P,n)
MBo
  • 77,366
  • 5
  • 53
  • 86
  • Ooh so basically both my interpretation and the one in the linked question are correct because `|n|` is a neutral term and doesn't affect anything. Correct? Also, if `|n|` was not normalized, then would my interpretation be correct? – Rares Dima Aug 02 '22 at 15:44
  • if `n` is not normalized, correct formula is `|dot ( p-p0 , n )| / |n|`. What your interpretation do you mean? `length of the projection of P onto n` is not correct – MBo Aug 02 '22 at 15:56
  • Perhaps we consider different meanings of `projection of P onto n` – MBo Aug 02 '22 at 16:04