Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

Lets say I have the point (x,y,z) and the plane with normal (a,b,c) with the point (d,e,f). I am trying to use this in 3d programming. Thank you.

share|improve this question

4 Answers 4

up vote 8 down vote accepted

You want to find $t$ such that $(x+ta,y+tb,z+tc)$, $(x,y,z)$, and $(d,e,f)$ form a right angled triangle, with the first of these (the point you are looking for) being the right angle. You can do this with dot products, and this will give you

$$t = \frac{ad-ax+be-by+cf-cz}{a^2+b^2+c^2}.$$

Substitute this into $(x+ta,y+tb,z+tc)$ and you have your result.

share|improve this answer

You have to take the parallel line to the normal vector in the point $(x,y,z)$ and the projection will be the intersection of this line whit the plane.

share|improve this answer

Let us denote your point as $(x_0,y_0,z_0)$ instead of $(x,y,z)$ and projection as $(x'_0,y'_0,z'_0)$

Parametric equation of the line that passes through point and its projection is given by :

$x'_0=x_0+a\cdot t$

$y'_0=y_0+b\cdot t$

$z'_0=z_0+c\cdot t$

Equation of the plane is :

$a \cdot(x-d)+b\cdot(y-e)+c\cdot(z-f)=0$

Now , since point $(x'_0,y'_0,z'_0)$ belongs to the plane you have to substitute its coordinates into equation of the plane instead of $x,y,z$ and calculate parameter $t$ .

share|improve this answer

Take the displacement vector from the point in the plane to the given point: $$ {\bf v}=(x-d , y-e, z-f) $$ and let ${\bf w}$ be the normal vector to the plane.

If you set $$ {\bf v}_\parallel = {{\bf v}\cdot{\bf w}\over\Vert{\bf w}\Vert^2} {\bf w} $$ and $$ {\bf v}_\perp = {\bf v}-{\bf v}_\parallel $$ Then

$\ \ \ \ {\bf v}={\bf v}_\parallel +{\bf v}_\perp$,

$\ \ \ \ {\bf w}\perp{\bf v}_\perp$,

$\ \ \ \ {\bf w}\parallel {\bf v}_\parallel $.

From this, the required point is $(d,e,f)+{\bf v}_\perp$.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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