# Why is the Projection (cB) of Vector A on B perpendicular to Vector A - cB?

The following excerpt can be found in Serge Lang's Introduction to Linear Algebra. I am trying to understand mathematically why the vector $$\mathbf{A}- c\mathbf{B}$$ is perpendicular to the vector $$c\mathbf{B}$$. I suppose there would be a simple mathematical explanation behind this, but I haven't been able to find any. I have tried taking the dot product of $$\mathbf{A} - c\mathbf{B}$$ and $$c\mathbf{B}$$ to equal $$0$$, but I cannot find any proof as to why this dot product would have to equal $$0$$.

• It won't be true for an arbitrary value of $c$ .Presumably Lang goes on to calculate what value of $c$ makes it true?
– user169852
Jul 3 '20 at 1:11
• Can you provide the complete question or the page no. of your context from the book which you have taken. Jul 3 '20 at 1:51
• From the part of the text you show, it seems like he is defining the projection to be the unique vector $P$ which is parallel to $B$ and such that $A-P$ is perpendicular to $B$. At least secretly. Jul 3 '20 at 2:00
• @Doubtnut The diagram was on page 23 of his second edition. Jul 3 '20 at 2:06
• I've edited the question by posting image of the complete section which might be helpful for other users to understand the scenario. Jul 3 '20 at 2:17

As @Bungo has mentioned, it is not true for an arbitrary value $$c\in\textbf{F}$$. It just states the projection of $$A$$ lies in the direction $$B$$. More precisely, in order to find $$c$$, it has to satisfy the following relation: \begin{align*} \langle A-cB,cB\rangle = 0 & \Longleftrightarrow \langle A,cB\rangle - \langle cB,cB\rangle = 0\\\\ & \Longleftrightarrow \overline{c}\langle A,B\rangle - c\overline{c}\langle B,B\rangle = 0 \end{align*}
If $$B\neq 0$$ and $$c\neq 0$$, it results that \begin{align*} \langle A,B\rangle - c\langle B,B\rangle = 0 \Longleftrightarrow c = \frac{\langle A,B\rangle}{\langle B,B\rangle} \end{align*} and we are done.