Find the projection of $e_{1}+e_{2}$ onto the plane defined by $3x+y-1=0$. To find the projection of $X$ to the line from the origin through the unit vector $U / \left| U\right|$, i.e.,
$P_{U}\left( x\right) =\dfrac { < X,U>} { < U,U>}\cdot U$
So, how can I solve the question? Can you give a hint?
My answer is:
Since $ e_{1}+e_{2}=\left( \begin{matrix} 1\\ 0\end{matrix} \right)+\left( \begin{matrix} 0\\ 1\end{matrix} \right)$ we have $ e_{1}+e_{2}=\left( \begin{matrix} 1\\ 1\end{matrix} \right)$. 
Now, The projection is $\dfrac { < \left( \begin{matrix} 1\\ 1\end{matrix} \right) ,\left( \begin{matrix} 3\\ 1\end{matrix} \right) >} { < \left( \begin{matrix} 3\\ 1\end{matrix} \right) ,\left( \begin{matrix} 3\\ 1\end{matrix} \right) >}\left( \begin{matrix} 3\\ 1\end{matrix} \right)
=\left( \begin{matrix} 6 / 5\\ 2 / 5\end{matrix} \right)$.
Can you check my answer?
 A: What you are doing is projecting the vector onto the normal vector to the plane, not projecting onto the plane. Your answer should lie in the plane, and you can see that your solution does not satisfy the equation of the plane. Try to come up with an equation of the vector in the direction of the projection. That will be your $U$ vector in your equation.
Edit: It's actually not quite as as simple as this. Notice that we are not projecting onto a subspace here, since the plane does not pass through the origin. The plane in question is actually an affine space. The equation for projecting onto an affine space $A$ is $$P_A\vec{v} = \vec{r_{0}} + P_S(\vec{v}-\vec{r_{0}})$$ where the plane is expressed as $$\vec{r} = \vec{r_{0}} + \vec{A}t$$ with $\vec{A} = \begin{bmatrix}1 \\ -3\end{bmatrix}$, and $\vec{r_{0}} = \begin{bmatrix}0 \\ 1\end{bmatrix}$, and $S$ is the plane shifted to the origin so that it is a subspace. Thus $S$ is the plane $3x + y = 0$. Working through this, I got the solution of $P_A\vec{v} = \begin{bmatrix}\frac{1}{10} \\ \frac{7}{10}\end{bmatrix}$.
Note that I'm intentionally ignoring the 3rd dimension here since it's not needed. The projection lies in the $x$-$y$-plane, so the "plane" here can be thought of as affine line, and the subspace, $S$, the line shifted so that it passes through the origin.
A: An equivalent way of writing the given equation of the plane is $(3,1,0)\cdot(x,y,z)=1$. (I’ll write vectors as row vectors but suppress the superscript $T$s to reduce clutter.) The vector $\mathbf n=(3,1,0)$ is normal (orthogonal) to the plane, and this equation says that the plane consists of all vectors that have the same projection onto this normal vector. (More generally, this type of equation will be of the form $\mathbf n\cdot\mathbf x=d$.) Each vector in this plane can be decomposed into this common projection onto the normal and a component orthogonal to it. To project an arbitrary vector $\mathbf v$ onto the plane, then, you have to find its component that’s orthogonal to the normal—the orthogonal rejection from the normal and add it to this common normal component.  
The orthogonal rejection is simply what’s left over after subtracting the orthogonal projection onto $\mathbf n$, i.e., $\mathbf v-{\mathbf v\cdot\mathbf n\over\mathbf n\cdot\mathbf n}\mathbf n$. The common normal component of vectors in the plane is some scalar multiple $k\mathbf n$ of $\mathbf n$, which we can compute by plugging it into the equation of the plane: $\mathbf n\cdot k\mathbf n=d$, so $k=d/\mathbf n\cdot\mathbf n$. Putting this all together, the projection of $\mathbf v$ onto the plane $\mathbf n\cdot\mathbf x=d$ is given by $$\mathbf v-{\mathbf v\cdot\mathbf n\over\mathbf n\cdot\mathbf n}\mathbf n+{d\over\mathbf n\cdot\mathbf n}\mathbf n=\mathbf v+{d-\mathbf v\cdot\mathbf n\over\mathbf n\cdot\mathbf n}\mathbf n.$$ The (directed) distance from $\mathbf v$ to the plane is in fact $(d-\mathbf v\cdot\mathbf n)/\|\mathbf n\|$, so this last expression basically says that the projection of $\mathbf v$ onto the plane is found by moving in a direction normal to the plane until you hit it, which is exactly what you’d expect from an orthogonal projection.  
For your problem, we have $\mathbf v=(1,1,0)$, $\mathbf n=(3,1,0)$ and $d=1$, so the projection of $\mathbf v$ onto the plane is $$(1,1,0)+{1-(1,1,0)\cdot(3,1,0)\over(3,1,0)\cdot(3,1,0)}(3,1,0)=(1,1,0)+{1-4\over10}(3,1,0)=\left(\frac1{10},\frac7{10},0\right).$$
