# Projection of a point on a plane

I have a homework problem which I cannot solve.

Equation of a hyperplane is given as

$$f(x) = w^tx + b$$

Given $f(x) = 0$

show that the projection of a point xa on the plane is :

$$x_p = x_a - \frac{|f(x_a)|w}{\| w\|^2}$$

I was thinking of taking a unit vector lying on the plane and taking the dot product. But I am not getting the result I am looking for

Could anyone point me into the right direction ? Thanks.

-
Do I interpret you correctly? You're finding a unit vector $u$ in the plane, and taking the dot product in order to find the vector $w$? This won't work since the set of vectors perpendicular to $u$ is another hyperplane. What is the context of the problem? –  Doc Dec 2 '13 at 14:12
@Doc Its a classification problem. f(x) is the decision boundary. –  Ajit Dec 2 '13 at 14:33
Choose $w$ s.t. $b\le0$. Then $x_p=x_a-\frac{f(x_a)}{\|w\|^2}w$. –  Michael Hoppe Dec 2 '13 at 14:50
But that doesn't make sense to me b is just an offset. Can you tell me why b should not be positive? –  Ajit Dec 2 '13 at 15:09
Sorry, I don't understand the question. Do you want to show the formula you give for the projection is correct or what? –  Abramo Dec 2 '13 at 18:15

## 1 Answer

For any two points $x$, $y$ on the hyperplane $\pi:\> f(x)=0$ one has $w\cdot(x-y)=f(x)-f(y)=0$. It follows that the vector $w$ (assumed $\ne0$) is orthogonal to $\pi$ and in fact defines the unique direction orthogonal to $\pi$. Therefore the line $$g:\quad t\mapsto x_a+ t\>w\qquad(-\infty<t<\infty)$$ is the projection ray we are interested in, and it only remains to intersect $g$ with $\pi$.

-
Thanks :) It seems I am getting the point projection at the intersection of the line and the plane. But I don't understand how you chose this line and why is it orthogonal to the plane Could you please ellaborate your answer? –  Ajit Dec 3 '13 at 10:11