# Find the point $P$ on the $x$-axis which orthogonal projection on the line $r:x+y=z-1=0$ is $M=(1,-1,1)$.

The points such as their orthogonal projection on the line $r$ is $M=(1,-1,1)$ lay on the plane that passes through that point $M$ and that is orthogonal to $r$.

First of all, then, I determined the directional vector of the line, which is (one can also write $r$ in parametric form and infer it): $$\mathbf{v}_{r}=(1,1,0)\wedge(0,0,1)=\begin{vmatrix} \mathbf{i}&\mathbf{j}&\mathbf{k}\\1&1&0\\0&0&1\end{vmatrix}=(1,-1,0)$$ This vector is parallel to the normal vector of the searched plane $\pi$. Thus, the Cartesian equation of $\pi$ is found via dot product. Precisely, I impose that the scalar product between the normal vector of the plane $\mathbf{n}$ and the direction of the vector linking a generic point $A=(x,y,z)$ of $\pi$ and $M$ is zero: $$\pi:(x-1,y+1,z-1)\cdot(1,-1,0)=x-1-y-1+0=x-y-2=0$$ The point I'm looking for is given by the intersection of $\pi$ and $r$. Hence, I write $r$ in parametric form and substitute in the equation of $\pi$: $$r:\begin{cases} x=t\\y=-t\\z=1 \end{cases}$$ Substituting in $\pi$ gives: $t+t-2=0\Rightarrow t=-1$.

In conclusion I find the point $P=(-1,1,1)$ whereas $\mathbf{\text{the correct solution is } P=(2,0,0)}$.

What did I do wrong?

As others have pointed out the second plane $z - 1 = 0$ does reduce the problem to a 2D problem, but this is along the lines you were initially following, so you have identified that the line between $P$ and $M$ will have a direction vector orthogonal to a the direction vector of the line $r$, i.e. $d_1 \cdot 1 + d_2 \cdot(-1 ) + d_3 \cdot 0 = 0$ so you end up a direction vector of the form $d = (1,1,d_3)$ say and therefore the line is given by \begin{align} P &= M + t\begin{bmatrix} 1 \\ 1 \\ d_3 \end{bmatrix} \\ &= \begin{bmatrix} 1 + t \\ -1 + t \\ t d_3 \end{bmatrix}, \end{align} but you are also given that $P$ is on the $x$-axis \begin{align} P = \begin{bmatrix} x \\ 0 \\ 0 \end{bmatrix} = \begin{bmatrix} 1 + t \\ -1 + t \\ t d_3 \end{bmatrix} \end{align} so that you can deduce $t = 1$ and therefore $P=(2,0,0)$. I think maybe you went wrong in insisting that $P$ was the interesection of $r$ and $\pi$, when of course that point is the given point $M$.

• You are absolutely right, thank you very much! Commented Dec 2, 2016 at 13:58

The correct solution is in fact, as you say, $(2,0,0)$ and this can be deduced very easily because either all happen in the plane $z=1$ and the point $P$ is on the $x$-axis so $P=(x,0,0)$. Therefore you can act likely as you were in the plane $XOY$ as follow:

The distance of $M$ to $O$ is equal to $\sqrt2$ so you have a right triangle of sides equal both to $\sqrt2$ so the hypotenuse is equal to $2$ because $$x\cos 45^{\circ}=\sqrt2$$

• You are welcome. Commented Dec 3, 2016 at 1:13

Somewhere after calculating the expression for $\pi$, I lost you: you say that $P$ is the intersection of $\pi$ and $r$, so in particular you demand that $P$ must be a point on $r$, which it is not. This is your only mistake. But, you have done all the work: from $\pi: x-y=2$ and the fact that $P$ lies on the x-axis, i.e. $P=(x,0,0)$ you can conclude immediately that $x=2$.

• Urg, sometimes I fear I just stop using my brain...Thank you very much!! Commented Dec 2, 2016 at 13:56
• @M.Giacchello Perhaps, you were tired after so many exact and difficult calculations that you performed correctly! Commented Dec 2, 2016 at 13:57
• more like 4 hours of exercises in various topics of linear algebra & geometry! But that should not be an excuse! Thanks again, math.stackexchange comunity is helping me greatly, as most excercise given by my professor doesn't have solution and a few just the numerical results... Commented Dec 2, 2016 at 14:02