Prove that vectors of a real inner product space are linearly independent. Let $V$ be a real inner product space. Let $u, v_1, ..., v_m \in V$ such that
$$\langle u, v_i \rangle > 0, \ \forall{i}$$
$$ \langle v_i, v_j \rangle \leq 0, \ \forall i \neq j.$$
Prove that vectors $v_1, ..., v_m$ are linearly independent.
There is a hint which says if a linear combination of the vectors with nonnegative coefficients is equal to zero, then all the coefficients must be equal to zero. I'm not sure how to carry out this proof using the hint.
 A: Suppose the contrary that $v_i$s are linearly dependent. Then some non-trivial linear combination of them is zero. Thus there exist two disjoint subsets $\mathcal I,\mathcal J\subseteq\{1,2,\ldots,m\}$ such that $\mathcal I\cup\mathcal J$ is non-empty, $\sum_{i\in\mathcal I}c_iv_i-\sum_{j\in\mathcal J}c_jv_j=0$ and $c_k>0$ for all $k\in\mathcal I\cup\mathcal J$. It follows that
\begin{align}
0=\langle0,0\rangle
&=\left\langle\sum_{i\in\mathcal I}c_iv_i-\sum_{j\in\mathcal J}c_jv_j,
\ \sum_{i\in\mathcal I}c_iv_i-\sum_{j\in\mathcal J}c_jv_j\right\rangle\\
&=\left\|\sum_{i\in\mathcal I}c_iv_i\right\|^2
-2\sum_{i\in\mathcal I,\ j\in\mathcal J}c_ic_j\langle v_i,v_j\rangle
+\left\|\sum_{j\in\mathcal J}c_jv_j\right\|^2.
\end{align}
As $-2\sum_{i\in\mathcal I,\ j\in\mathcal J}c_ic_j\langle v_i,v_j\rangle\ge0$, it must be zero. Thus $\sum_{i\in\mathcal I}c_iv_i=\sum_{j\in\mathcal J}c_jv_j=0$. Since $\mathcal I\cup\mathcal J$ is non-empty, we may assume that $\mathcal I$ is non-empty. But then
$$
0=\langle u,0\rangle=\left\langle u,
\ \sum_{i\in\mathcal I}c_iv_i\right\rangle
=\sum_{i\in\mathcal I}c_i\langle u, v_i\rangle>0,
$$
which is a contradiction. Hence the $v_i$s must be linear independent at the beginning.
A: since you have an inner product, we can do this via Gram Schmidt, in particular by treating $\{v_1,v_2,...,v_m\}$ as a triangular system.
Start with the first vector.
$q_1 := v_1$ and $\mathbf q_1$ is $q_1$ normalized to have length one. (Note: none of the $v_i$ are the zero vector since they have a positive inner product with $u$.)
and algorithmically march through Gram Schmidt.
for $k=2,3,...,m$
$q_k := v_k -\sum_{j=1}^{k-1}\langle \mathbf q_j, v_k\rangle \cdot \mathbf q_j$
$\mathbf q_k := \frac{q_k}{\langle q_k,q_k\rangle^\frac{1}{2}}$
If the for loop makes it through $k=m$ then we have an orthonormal set $\{\mathbf q_1, \mathbf q_2, ..., \mathbf q_m\}$ which implies linear independence and we are done.
Now suppose for a contradiction that the for loop generates an error at $k=r$.  This occurs necessarily at the normalization stage when $q_{r}$ has length zero, and by positive definiteness of the inner product, this means $q_r = \mathbf 0$.  That is
$\mathbf 0 = q_{r} = v_{r} -\sum_{j=1}^{r-1}\langle \mathbf q_j, v_{r}\rangle \cdot \mathbf q_j = v_{r} +\sum_{j=1}^{r-1}\big\vert\langle \mathbf q_j, v_{r}\rangle \big\vert\cdot \mathbf q_j$
But
$0=\langle u, \mathbf 0\rangle =\langle u,v_{r}\rangle +\sum_{j=1}^{r-1}\big\vert\langle \mathbf q_j, v_{r}\rangle \big\vert\cdot\langle u,\mathbf q_j\rangle\geq \langle u,v_{r}\rangle \gt 0$
which is a contradiction
A: Let me know if this works for you:
Consider a linear combination $c_1v_1+\dots+c_nv_n=0$ $(*)$. We want to show that $c_i=0$ for all $i$. Let's prove it by contradiction. Assume that some coefficients are non-zero. Then I claim that we can rewrite $(*)$ as
$$v=c_1v_1+\dots+c_kv_k=d_1w_1+\dots+d_mw_m\text{ with }k+m\leq n\text{ and }c_i>0,d_j>0\text{ }(**)$$
where $w_i$ are renamed $v_j$ vectors with negative coefficients.
In other words, we should have a mix of strictly positive and strictly negative coefficients. Check it (Hint: assume all coefficients are going to have the same sign and then use $u$).
From $(**)$, we have
$$0\leq|v|^2=\langle v,v\rangle=\langle c_1v_1+\dots+c_kv_k,d_1w_1+\dots+d_mw_m\rangle=\sum_{i,j}c_id_j\langle v_i,w_j\rangle\leq0$$
since $c_i>0,d_j>0,$ and $\langle v_i,w_j\rangle\leq0$. So, $v=0$ and $c_1v_1+\dots+c_kv_k=0$ is a linear combination of $v_1,\dots,v_k$ with positive coefficients which gives us a contradiction since
$$0<c_1\langle u,v_1\rangle+\dots+c_k\langle u,v_k\rangle=0.$$
