# Reconstruct a functional from Euler-Lagrange equation

Assume a functional $I[u(x)] = \int\limits_{{x_{\min }}}^{{x_{\max }}} {F(x,u,u')dx}$.

Given I have the Euler-Lagrange (EL) equation $u'(x) = 0$, I need to find the form of $F$ that leads to this EL.

I intuitively tried $F(x,u,u')=u(x)u'(x)$ and this yields $$\frac{{\partial F}}{{\partial u}} - \frac{d}{{dx}}\left( {\frac{{\partial F}}{{\partial u'}}} \right) = u'(x) - u'(x) = 0$$ but I would need $F$ such that $$\frac{{\partial F}}{{\partial u}} - \frac{d}{{dx}}\left( {\frac{{\partial F}}{{\partial u'}}} \right) = u'(x).$$ Does such an $F$ that would lead to EL $u'(x) = 0$ exist?

• @MrYouMath I hoped there exists one solution but maybe I could work with a non-unique solution as well. I'm going to use $F$ in a numerical method. The long answer would be that I need to find a variational formulation for $\frac{{\partial u}}{{\partial t}} + r\frac{{\partial u}}{{\partial x}} + \left( {r - \frac{1}{2}{\sigma ^2}} \right)\frac{{{\partial ^2}u}}{{\partial {x^2}}} - ru = 0$ which I can't do without being able to find $F$ for the first order derivative $\frac{{\partial u}}{{\partial x}} = u'(x)$ – fragile Sep 29 '17 at 10:00
• – MrYouMath Sep 29 '17 at 10:32

I. If $u\in\mathbb{C}$ is complex-valued: Then the Lagrangian $F(x,u,u^{\prime})=i\bar{u}u^{\prime}$ works.
II. If $u\in\mathbb{R}$ is real-valued: Then there is no Lagrangian $F(x,u,u^{\prime},u^{\prime\prime},u^{\prime\prime\prime},\ldots)$.
1. $F(x,u,u^{\prime},u^{\prime\prime},\ldots)$ can not depend on higher derivatives $u^{\prime\prime},u^{\prime\prime\prime},\ldots$, in order for the higher-order EL equation to be independent of them.
2. The Lagrangian must be an affine function $$F(x,u,u^{\prime})=A(x,u) +u^{\prime}B(x,u) \tag{1}$$ in $u^{\prime}$ in order for the EL equation to be independent of $u^{\prime\prime}$.
3. It is not hard to see that the EL equation $$\frac{\partial A}{\partial u}- \frac{\partial B}{\partial x}~=~0 \tag{2}$$ for the Lagrangian (1) does not depend on derivatives. Contradiction. $\Box$