Problem
The ground field is $K$, $\operatorname{char}K\neq2$. Suppose $W$ is a (maybe infinite dimensional) subspace of a vector space $V$ with a symmetric/symplectic form $\langle\cdot,\cdot\rangle$. The orthogonal space of $W$, denoted as $W^\perp$, is defined as $W^\perp=\{\,v\in V\,\colon\,\langle v,w\rangle=0,\forall w\in W\,\}$. If the form is nondegenerate on $W$, say $W\cap W^\perp=\{0\}$, is it true that $V=W\oplus W^\perp$? What if the form is nondegenerate on $V$?
Background
The statement is true when $W$ is finite dimensional. One can choose an orthogonal basis for $W$, then apply the projection formula to determine a orthogonal projection. However, such a process couldn't be applied in the infinite dimensional case. I'm interested in how far we can generalize our results of psuedo-Euclidean or symplectic forms on a finite dimensional vector space to the infinite-dimensional case.