Minimizing Integral - Euler-Lagrange The question is to find the minimum value of the integral $$ \begin {aligned}\mathcal {I} [y] &=\int_{- \infty}^{\infty} \dfrac{1}{2} y'^2 + 1 - \cos y \; \mathrm d x  \\ \quad y(-\infty)&=0, \quad y(\infty)= 2 \pi \end {aligned} $$ I have tried applying Euler-Lagrange explicitly to obtain the equation $ y'' = \sin y $ but this doesn't seem to be much help. Since the integral has no explicit $x$-dependence, I applied the Beltrami identity to show that $$- \dfrac{1}{2} y'^2 + 1 - \cos y = C$$ for some real constant. Since the boundary conditions are finite at infinity, it follows that $y'$ goes to zero at infinity (assuming $y$ is "nice enough"), so plugging in our boundary conditions shows that $ C = 0 $. Going back to our original form, we find that most things cancel out and we are left with $$ \int_{- \infty}^{\infty} y'^2 \; \mathrm d x $$ and I'm not sure where to go from here. I've tried using integration by parts on this term to give $$ \int_{- \infty}^{\infty}y'^2 \; \mathrm d x = \bigg[ yy' \bigg]^{\infty}_{-\infty} - \int_{- \infty}^{\infty} yy'' \; \mathrm d x $$ and I think the first term drops out due to the boundary conditions but that still leaves the second term which I'm not sure how to deal with. 
 A: Consider the functional $I$ on the space of $C^1$-functions $y$ satisfying $y(-\infty)=0$ and $y(+\infty) = 2\pi$ defined by
$$ I(y) = \int_{-\infty}^{\infty} \left( \frac{y'(x)^2}{2} + 1 - \cos y(x) \right) \, dx. $$
By the Cauchy-Schwarz inequality, we have
\begin{align*}
I(y)
&\geq \int_{-\infty}^{\infty} 2\sqrt{ \frac{y'(x)^2}{2} (1 - \cos y(x)) } \, dx \\
&\geq \int_{-\infty}^{\infty} \sqrt{2(1-\cos y(x))} \cdot y'(x) \, dx \\
&= \int_{0}^{2\pi} \sqrt{2(1-\cos y)} \, dy
= 8.
\end{align*}
Now let us examine whether there is a function satisfying $I(y) = 8$. If this holds, then the above inequalities are saturated and hence yields equalities. By the equality condition of the Cauchy-Schwarz inequality, this implies that
$$ \frac{y'(x)^2}{2} = 1-\cos y(x) \qquad \text{and} \qquad y'(x) \geq 0, $$
which is then equivalent to
$$ y'(x) = \sqrt{2(1- \cos y(x))}. $$
This equation can be solved by the separation of variables technique to yield
$$ y(x) = 4\arctan(e^x). $$
With this function we obtain
$$ I(y) = \int_{-\infty}^{\infty} \frac{4}{\cosh^2 x} \, dx = 8. $$
A: Following on from my last step, I solved for $ y' $ using the Beltrami identity and then rewrote the integral as $$ \begin{align} \int_{-\infty}^{\infty} y'^2 \; \mathrm d x &= \int_{-\infty}^{\infty} \sqrt{2 ( 1 - \cos y )} \; \dfrac{\mathrm d y}{\mathrm d x} \; \mathrm d x \\ \\ &= \int_{0}^{2 \pi} \sqrt{2 (1 - \cos y )} \; \mathrm d y \\ \\ &= \int_{0}^{2 \pi} \sqrt {2} \sqrt {2 \sin ^2 \frac {y}{2} } \; \mathrm d y \\ \\&= \int_0^{2 \pi} 2 \sin \frac{y}{2} \; \mathrm d y \\ \\ &= \bigg[ -4 \cos \frac {y}{2} \bigg]^{2 \pi}_{0} \\ \\ &= 8 \end{align}$$ eliminating the need to explicitly find the minimizer.
