# proof: when the dot product of a number of vectors and a specific vector is constant, those vectors are on the same line orthogonal to the vector.

Assume that there are three dot products:

a.w = c

b.w = c

d.w = c

in which, a,b,d, and w are vectors and c is a number.

I read it in a book about neural networks(by Martin T. Hagan) that when the dot product of a group of vectors and weight vector(a specific vector,w) is constant, it means those vectors are on the same line and are orthogonal to the weight vector(w). I don't understand why? Also, if two vectors are orthogonal, isn't the dot product zero?(since the cosine of 90 is 0)

refrence

• Please specify what $A, B, C$ are and their dimensions. Are them matrices?
– yes
Commented Jan 18, 2023 at 8:19
• @VanBaffo i just edited my question. a,b,d, and w are all 2d vectors. Commented Jan 18, 2023 at 8:29
• They are not necessarily all on the same line, but all on the same hyperplane. In $2$-dimensions this will indeed be a line, but in $n$-dimensions it will be something that is flat and $(n - 1)$-dimensional. Commented Jan 18, 2023 at 8:31
• @JosephHarrison can you please provide the proof? Commented Jan 18, 2023 at 8:43
• @mhd nickz I shall have a go Commented Jan 18, 2023 at 8:45

As in my comment, the points $$p \in \mathbf{R}^n$$ satisfying $$p \cdot w = c$$ for some fixed $$w \in \mathbf{R}^n$$ and $$c \in \mathbf{R}$$ form an $$(n - 1)$$-dimensional hyperplane. For example when $$n = 2$$, this is a line and when $$n = 3$$ it is a plane. It seems that OP is referring to the two dimensional case. If $$w = (u, v)$$ and $$p = (x, y)$$ then \begin{align} p \cdot w = ux + vy = c \end{align} is the familiar equation of a line. If $$v \neq 0$$, then it is the line $$y = -(u/v)x + c/v$$ having slope $$-(u/v)$$ and intercept $$c/v$$. If $$v = 0$$, then it is the vertical line $$x = c/u$$.
Addition: You're correct that the vectors $$a \in \mathbf{R}^n$$ and $$w$$ are orthogonal if and only if $$a \cdot w = 0$$. The thing is that if $$a \cdot w = c$$ and $$b \cdot w = c$$, then \begin{align*} (a - b) \cdot w = c - c = 0. \end{align*} Remember that $$a - b$$ is the displacement vector from $$b$$ to $$a$$ and so it points in the direction of the line. Then we have shown that the direction of the line is orthogonal to $$w$$.