# Projection of vector on a plane

How do I find a vector which is the projection of another vector onto a plane?

By projection, I mean perpendicular projection onto this plane. I know that this vector must lie in the plane and have a minimum angle with the original vector, but it seems like setting up the problem in this manner is unnecessarily messy. There should be another (better/faster) way.

chiro
How do I find a vector which is the projection of another vector onto a plane?

By projection, I mean perpendicular projection onto this plane. I know that this vector must lie in the plane and have a minimum angle with the original vector, but it seems like setting up the problem in this manner is unnecessarily messy. There should be another (better/faster) way.

I think you would have to project two points on to the plane: the origin and the end point of the vector. You can do this by calculating the dot product of the points with the normal of the plane and subtract that component in the direction of the normal.

In other words d = n . p and the point on the plane = p - d x n which should lie on the plane.

For the origin, if you have the plane equation in the form of ax + by + cz + d = 0, then you have to calculate the point -n.d. These two points should allow you to construct a vector that lies on the plane.

HallsofIvy