I have a problem with what seems a very simple functional maximization. Let's define:
$$ J[z]=\int \left( u(z)-\frac{\dot z^2}{2} \right) dt $$
Where $u(z)=-z^2+5$. The problem is to find
$$ \arg\max_z J[z]$$
Said in a colloquial way, to maximize the function $u(z)$ without varying too much $z$ with time. The second variation of the functional for an arbitrary variation $h(t)$ is:
$$ \frac{\delta^2}{\delta z^2}J[z]=\int \left(h^2 u''(z)-\dot h^2 \right) dt = -\int \left(2 h^2+ \dot{h}^2 \right) dt \le 0 \quad \forall h $$
So then the functional is convex and any stationary point satisfying the Euler-Lagrange equations would be a global maximizer of $J$. The Euler-Lagrange equations for this functional reduce to the following differential equation:
$$ \ddot z=-u'(z)=2z $$
But this doesn't make any sense, since the maximum of $u(z)$ is at $z=0$, and all the trajectories starting in $z\ne0$ diverge from that point in an exponential way. Where did I go wrong?
Thank you
Put $$ L[z] = 5 - z^2 - \frac{\dot z^2}{2} $$
Then by Euler-Lagrange the extremal solutions satisfy $$L_z = \frac{d}{dt}L_{\dot{z}} \Rightarrow -2 z = - \frac{d}{dt}\dot{z} $$ So we have $$ z_{*}(t) = A e^{\sqrt{2} t} + B e^{- \sqrt{2} t} $$ and $$L[z_{*}] = 5 - (A e^{\sqrt{2} t} + B e^{- \sqrt{2} t})^2 - \frac{(\sqrt{2} A e^{\sqrt{2} t} - \sqrt{2} B e^{- \sqrt{2} t})^2}{2}$$ $$= 5 - 2(A^2 e^{2\sqrt{2} t} + B^2 e^{- 2 \sqrt{2} t})$$
$$J[z_{*}] = \int L[z_{*} (t)] dt = 5*\mu(\Omega) - \left.\frac{A^2 e^{2\sqrt{2} t} + B^2 e^{- 2 \sqrt{2} t}}{\sqrt{2}} \right|_{\partial \Omega}$$
This appears to be perfectly convergent to me. Given boundary conditions on the function you could solve this easily.