# Are two vectors equal if their inner product with each vector from some generator set is the same?

I need to decide wether the following is true (and, of course, justify it): given $V = [v_1, v_2, ..., v_n]$, $v$, $w$ in $V$ and $<v,v_i> = <w,v_i>$, for any $i$, so $v = w$.

I wrote the following: if $v$ is in V, we have $v = \alpha_1v1 + \alpha_2v_2 + \dots + \alpha_nv_n$. The same holds for $w$: $w = \beta_1v_1 + \beta_2v_2 + \dots + \beta_nv_n$. Now $<v,v_i> = <\alpha_1v1 + \alpha_2v_2 + \dots + \alpha_nv_n, v_i>$ and $<w,v_i> = <\beta_1v_1 + \beta_2v_2 + \dots + \beta_nv_n, v_i>$.

But $<v,v_i> = <\alpha_1v1 + \alpha_2v_2 + \dots + \alpha_nv_n, v_i> = \alpha_1<v_1,v_i> + \alpha_2<v_2,v_i> + \dots + \alpha_n<v_n,v_i>$ due to linearity property of the internal product. Also, $<w,v_i> = <\beta_1v1 + \beta_2v_2 + \dots + \beta_nv_n, v_i> = \beta_1<v_1,v_i> + \beta_2<v_2,v_i> + \dots + \beta_n<v_n,v_i>$.

The only way we can have $<v,v_i> = <w,v_i>$ is if $\alpha_j = \beta_j, j = 1, \dots, n$. But if $\alpha_j = \beta_j, j = 1, \dots, n$ implies $v=w$ because they are from the same span.

Is this correct? Is it enough to justify? The proof would still hold if nothing was said about $v$ and $w$ in $V$?

• What are the properties of $V$, because depending on them, this could be true or false. – Don Thousand Aug 20 '18 at 22:13
• V is a vector space with an inner product. That's the only other info given. – daniel.franzini Aug 20 '18 at 22:18
• Please try to make the titles of your questions more informative. For example, Why does $a<b$ imply $a+c<b+c$? is much more useful for other users than A question about inequality. From How can I ask a good question?: Make your title as descriptive as possible. In many cases one can actually phrase the title as the question, at least in such a way so as to be comprehensible to an expert reader. You can find more tips for choosing a good title here. – Shaun Aug 20 '18 at 22:30
• Fixed. Thank you. – daniel.franzini Aug 20 '18 at 22:35

This is correct.

Another way would be to suppose $v\neq w$. Then $v-w\neq0$ so that $$\left\langle v-w, v-w\right\rangle =\left\lVert v-w\right\rVert^2 >0$$ On the other hand, the nonzero vector $v-w$ is guaranteed to be a vector in a basis, so $$\left\langle v-w, v-w\right\rangle = \langle v, v-w\rangle-\langle w, v-w\rangle = \langle v, v-w\rangle-\langle v, v-w\rangle = 0$$ This contradiction implies that $v=w$.

Here's how I would show it

Let $v,w\in V$ be expressed as linear combinations of the basis vectors of $V$. Since we assume $v\neq w$, $\exists b_i\in B$, the basis, such that in the linear combination, the coefficient of $b_i$ for $v$, which we call $v_{bi}$, is different from the coefficient of $b_i$ in $w$'s linear combination, denoted by $w_{bi}$.

Hence, $v\cdot b_i=v_{bi}$ and $w\cdot b_i=w_{bi}$, so $<v,v_i> \neq <w,v_i>$ for all $v_i$. We have proved the contrapositive, so we are done.

I guess you essentially have it... Here's my try:

For some $k\le n$, $\{v_{i_1},\dots, v_{i_k}\}\subset\{v_1,\dots, v_n\}$ is a basis for $V$.

Apply the hypothesis to get that $v$ and $w$ have the same components relative to this basis. Specifically, $\frac{\langle v,v_{i_j}\rangle}{\mid v_{i_j}\mid^2}=\frac{\langle w,v_{i_j}\rangle}{\mid v_{i_j}\mid^2}$ is the $j$th component of both $v$ and $w$, $j=1,\dots, k$. That proves $v=w$.

• The hypothesis only says that $<v,v_i> = <w,v_i>$. I fail to see why the components are equal because nothing was said about the norm of $v_i$. – daniel.franzini Aug 22 '18 at 20:59
• The norm of $v_i$ is the same on both sides, so I think it's alright... – Chris Custer Aug 22 '18 at 23:31
• You are right, sorry. – daniel.franzini Aug 24 '18 at 18:55