# If a vector is orthogonal to a subspace, what is its projection?

Suppose $$y$$ is orthogonal to a subspace spanned by the columns of matrix $$A$$.

My question is, what is the projection of $$y$$ onto $$A$$?

I know that the projection of $$y$$ onto $$A$$ is the vector in $$A$$ such that the distance between that vector and $$y$$ is minimal.

But I think every vector in $$A$$ in this case attains same distance.

Hence the projection of $$y$$ onto $$A$$ is the set of vectors spanned by $$A$$.

Is my intuition correct?

• Your question, and both answers given so far, assumes that there is a projection of $y$ onto the subspace $S_A$ spanned by the columns of $A$. But consider $\pmatrix{0 & 0 \\ 1 & 2}$, and $y = \pmatrix{1\\2}$. The subspace $S_A$ is the $y$-axis, so you might say that "the projection" of $y$ is $\pmatrix{0\\2}$. But the transformation represented by $B = \pmatrix{0 &0 \\ 1 & 1}$ is also a projection onto $S_A$, and takes $y$ to $\pmatrix{0\\3}$. It just happens to not be an orthogonal projection. Jan 23, 2019 at 8:08

The projection of $$y$$ onto $$A$$ will be the zero vector. For any other vector $$v\in A$$ you will have $$||y-v|| = \sqrt{||y||^2+||v||^2} > ||y||.$$
The kernel of the projection onto a subspace $$A$$ is the orthogonal complement of the subspace, $$A^{\perp}$$.
That should be your intuition. The zero vector is in a sense the closest vector in $$A$$ to an orthogonal vector.