TITLE: Flows in Hilbert spaces
QUESTION [7 upvotes]: Let $\varphi: [0,T] \rightarrow H$ be a Hilbert space valued $C^1$-function. Let $H = X \oplus X^{\perp}$ such that $\varphi(0) \in X$ and the implication $\varphi(t) \in X \Rightarrow \varphi'(t) \in X$ holds. 
I ask: How can I show that $\varphi$ stays in $X$? It sounds natural and I guess it is true, but I fail to see how it can be shown.

REPLY [7 votes]: Consider $\phi(t) = (1-e^{-1/t^2}, t)\in \mathbb R^2$. It satisfies your assumptions for $X= 0\times \mathbb R$, but it does not stay in $X$.