# Does every inner product space (not necessarily complete) have an orthonormal basis?

I've been trying to prove that every Hilbert space has a Hilbert basis, and think I have succeeded with the proof below, but I am not sure since this would seem to suggest that it in fact has an orthonormal basis in the standard sense (that every element is a finite linear combination of basis elements), and moreover this proof only uses the inner product and not completeness. Is the proof correct and do the consequent results hold?

Let $$P$$ be the set of orthonormal subsets of $$V,$$ a pre-Hilbertian vector space and define on $$P$$ the partial ordering $$T_1\leq T_2$$ for $$T_1\subset T_2.$$ Then any chain $$M$$ in $$P$$ has a maximal element by the union of elements of $$M,$$ so Zorn's Lemma implies existence of a maximal element $$B$$ of $$P.$$

Suppose for contradiction that $$B$$ is not a basis, so there exists $$v\in V\setminus\operatorname{span}(B).$$ Choose $$u\in B,$$ which is non-empty for $$V$$ non-empty, and set $$\tilde{v}=\frac{v-\langle v,u\rangle u}{\|v-\langle v,u\rangle u\|}$$. Then $$\|\tilde{v}\|=1$$ and $$\langle u,\tilde{v}\rangle =0,$$ so $$\{u,\tilde{v}\}$$ is orthonormal, so contained in $$B$$ by maximality. But then $$v=(\|v-\langle v,u\rangle u\|)\tilde{v}+\langle u,\tilde{v}\rangle u\in\operatorname{span}(B)$$. Contradiction.

p.s. I am aware similar questions to this have been asked but I have not found my answer in any of those I have read. Standard proofs of the result I was trying to prove seem to use the orthogonal decomposition in a Hilbert space, which indeed uses the properties I avoided above.

There is an error in your proof, when you write that $$\left\{u,\tilde v\right\}\subset B$$ “by maximality”. The fact that $$B$$ is maximal doesn't imply that it contains every orthonormal set. In $$\mathbb R^2$$, endowed with its usual inner product, $$\{(1,0),(0,1)\}$$ is a maximal orthonormal set, $$\left\{\frac35,\frac45\right\}$$ is orthonormal, but $$\{(1,0),(0,1)\}\not\supset\left\{\frac35,\frac45\right\}.$$