# Show that $x' = \nabla E(x)$ has no nonconstant periodic solution

I am trying to solve the following:

Assume that $$E$$ is a smooth function in $$\mathbb{R}^n$$, and let $$\nabla E$$ denote the gradient, show that

$$x' = \nabla E(x)$$

has no nonconstant periodic solution.

So I start by assuming that $$x(t)$$ is a nonconstant periodic solution with minimal period $$T$$. Then $$\frac{d}{dt}E(x(t)) = \nabla E(x(t))x'(t) = |\nabla E(x(t))|^2 \geq 0.$$

Since $$x(t)$$ is periodic, we have $$x(0) = x(T)$$ and thus $$E(x(0)) = E(x(T))$$. I'm told this implies that $$|\nabla E(x(t))|^2 = 0$$ for all $$t \in [0,T]$$, which, if it is, really helps me out because then I've reached a contradiction. However, I haven't been able to understand why $$E(x(0)) = E(x(T)) \implies |\nabla E(x(t)) |^2 = 0$$. Hoping that someone can help clarify this.

$$x(T)-x(0) = \int_0^T \frac{dE(x(s))}{ds} ds = \int_0^T |\nabla E (x(s))|^2 ds,$$
so if $$x(T) = x(0)$$, then the integral is zero; since the integrand is nonnegative, is must be also be zero.